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

Test "print_tagged_na is stable" #190

Closed
larmarange opened this issue Jun 22, 2016 · 3 comments
Closed

Test "print_tagged_na is stable" #190

larmarange opened this issue Jun 22, 2016 · 3 comments

Comments

@larmarange
Copy link
Contributor

larmarange commented Jun 22, 2016

The test expect_output_file(print_tagged_na(x), "tagged-na.txt") is failing if the option width is not equal to 80 (could be be the case according to your local configuration).

Would it be appropriate to add the command options(width = 80) in that test? (https://github.com/hadley/haven/blob/master/tests/testthat/test-tagged_na.R#L57)

@hadley
Copy link
Member

hadley commented Jun 22, 2016

Would be better to pass width argument to print

@larmarange
Copy link
Contributor Author

It seems that the default print method used for characters doesn't take into account a width argument.

Example:

x <- c(1:100, tagged_na(letters), NA)
print(format_tagged_na(x), width = 20, quote = FALSE)

The width argument will not be taken into account.

@hadley
Copy link
Member

hadley commented Aug 9, 2016

I've decided this should actually be fixed in testthat: r-lib/testthat#514

@hadley hadley closed this as completed Aug 9, 2016
@lock lock bot locked and limited conversation to collaborators Jun 26, 2018
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants