Skip to content

Commit

Permalink
Swapped order of expect_equal
Browse files Browse the repository at this point in the history
  • Loading branch information
tripartio committed Sep 27, 2024
1 parent 66f7c78 commit 96634c3
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 4 deletions.
4 changes: 2 additions & 2 deletions tests/testthat/test-autogam.R
Original file line number Diff line number Diff line change
@@ -1,9 +1,9 @@
test_that("autogam works on mtcars", {
expect_equal(
11.253,
autogam(mtcars, 'mpg') |>
coef() |>
sum() |>
round(3)
round(3),
11.253
)
})
5 changes: 3 additions & 2 deletions tests/testthat/test-smooth_formula_string.R
Original file line number Diff line number Diff line change
@@ -1,6 +1,7 @@
test_that("mtcars smooth string works", {
expect_equal(
"mpg ~ cyl + s(disp) + s(hp) + s(drat) + s(wt) + s(qsec) + vs + am + gear + s(carb,k=3)",
smooth_formula_string(mtcars, 'mpg')
smooth_formula_string(mtcars, 'mpg'),
"mpg ~ cyl + s(disp) + s(hp) + s(drat) + s(wt) + s(qsec) + vs + am + gear + s(carb,k=3)"

)
})

0 comments on commit 96634c3

Please sign in to comment.