Skip to content

Conversation

@chainsawriot
Copy link
Collaborator

The S3 method can be dispatched. But the problem is that it can't be tested with testthat. Why?

The S3 method can be dispatched. But the problem is that it can't be
tested with testthat. Why?
@chainsawriot
Copy link
Collaborator Author

Concretely, the code in #458 works. But with testthat, the custom S3 method cannot be dispatched. This case

##expect_true(is.data.frame(import('iris.custom')))

@chainsawriot
Copy link
Collaborator Author

r-lib/testthat#720

@chainsawriot
Copy link
Collaborator Author

rio/R/utils.R

Lines 66 to 68 in 727d50f

if (is.na(info$format)) {
return(input)
}

@chainsawriot chainsawriot marked this pull request as ready for review December 17, 2024 19:45
@chainsawriot chainsawriot merged commit f1094bf into main Dec 17, 2024
8 of 9 checks passed
@chainsawriot chainsawriot deleted the ex branch December 17, 2024 19:45
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

Successfully merging this pull request may close these issues.

1 participant