Skip to content

Commit 969db1a

Browse files
committed
fix tests for stricter 'assert' function, issue #329
1 parent 797b7fc commit 969db1a

File tree

3 files changed

+5
-5
lines changed

3 files changed

+5
-5
lines changed

inst/Regression/RegressionGAM.m

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -866,9 +866,9 @@ function savemodel (obj, fname)
866866
%! formula = "Y ~ A + B + C + D + A:C";
867867
%! intMat = logical ([1,0,0,0;0,1,0,0;0,0,1,0;0,0,0,1;1,0,1,0]);
868868
%! a = RegressionGAM (x, y, "predictors", pnames, "formula", formula);
869-
%! assert ({a.IntMatrix}, {intMat})
869+
%! assert (a.IntMatrix, double (intMat))
870870
%! assert ({a.ResponseName, a.PredictorNames}, {"Y", pnames})
871-
%! assert ({a.Formula}, {formula})
871+
%! assert (a.Formula, formula)
872872

873873
## Test input validation for constructor
874874
%!error<RegressionGAM: too few input arguments.> RegressionGAM ()

inst/anova2.m

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -385,7 +385,7 @@
385385
%! assert (atab{6,2}, 22);
386386
%! assert (stats.source, "anova2");
387387
%! assert (stats.colmeans, [6.25, 4.75, 4]);
388-
%! assert (stats.inter, 1, 0);
388+
%! assert (stats.inter, true);
389389
%! assert (stats.pval, 0.7462153966366274, 1e-14);
390390
%! assert (stats.df, 12);
391391

inst/fitrgam.m

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -172,9 +172,9 @@
172172
%! formula = "Y ~ A + B + C + D + A:C";
173173
%! intMat = logical ([1,0,0,0;0,1,0,0;0,0,1,0;0,0,0,1;1,0,1,0]);
174174
%! a = fitrgam (x, y, "predictors", pnames, "formula", formula);
175-
%! assert ({a.IntMatrix}, {intMat})
175+
%! assert (a.IntMatrix, double (intMat))
176176
%! assert ({a.ResponseName, a.PredictorNames}, {"Y", pnames})
177-
%! assert ({a.Formula}, {formula})
177+
%! assert (a.Formula, formula)
178178

179179
## Test input validation
180180
%!error<fitrgam: too few arguments.> fitrgam ()

0 commit comments

Comments
 (0)