Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Update expect_is to expect_type #671

Closed
ColinFay opened this issue May 19, 2021 · 3 comments
Closed

Update expect_is to expect_type #671

ColinFay opened this issue May 19, 2021 · 3 comments

Comments

@ColinFay
Copy link
Member

The current test-golem-recommended throws a warning, as expect_is was deprecated in the latest version of testthat.

@ColinFay
Copy link
Member Author

Another can be expect_equal(class(server), "function")

ColinFay added a commit that referenced this issue Jun 4, 2021
ColinFay added a commit that referenced this issue Jun 4, 2021
ColinFay added a commit that referenced this issue Jun 4, 2021
ColinFay added a commit that referenced this issue Jun 4, 2021
ColinFay added a commit that referenced this issue Jul 7, 2021
@ALanguillaume ALanguillaume reopened this Oct 20, 2021
@ALanguillaume
Copy link
Contributor

There are still some calls to expect_this lingering in dev

bob@lemur:~/projects/golem (dev) 
$ grep -rn "expect_is" tests/*
tests/testthat/test-js.R:2:  expect_is(activate_js(),'shiny.tag')
tests/testthat/test-favicon.R:43:    expect_is(
tests/testthat/test-make_dev.R:24:    expect_is(print_dev("test"), "character")
tests/testthat/test-make_dev.R:36:    expect_is(sum_dev(1,2), "numeric")
tests/testthat/test-make_dev.R:37:    expect_is(sum_dev, "function")
tests/testthat/test-make_dev.R:47:    expect_is(print_dev("test"), "character")

expect_type() won't work in all cases, expect_s3_class will be necessary at times.

@ALanguillaume
Copy link
Contributor

My bad this concerns {golem} itself not test-golem-recommended. I will open a dedicated issue.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants