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

tests appear to require en_US.UTF-8 #533

Open
dgoerger opened this issue Sep 8, 2016 · 1 comment
Open

tests appear to require en_US.UTF-8 #533

dgoerger opened this issue Sep 8, 2016 · 1 comment

Comments

@dgoerger
Copy link

dgoerger commented Sep 8, 2016

I'm working to package swirl for Fedora, and appear to have stumbled across an interesting locale requirement for the tests/testthat/test-encoding.R test. Namely I've had to append export LC_ALL="en_US.UTF-8" to the rpm specfile (by default mock only exports LANG="en_US.UTF-8), or building produces the following error:

* checking tests ...
  Running 'test-all.R'
 ERROR
Running the tests in 'tests/test-all.R' failed.
Last 13 lines of output:
  stri_escape_unicode(test_phrase) not equal to stri_escape_unicode("\344\270\255\346\226\207\346\270\254\350\251\246").
  1/1 mismatches
  x[1]: "<U+4E2D><U+6587><U+6E2C><U+8A66>"
  y[1]: "\\ufffd\\ufffd\\ufffd\\ufffd\\ufffd\\ufffd\\ufffd\\ufffd\\ufffd\\ufffd\\u
  y[1]: fffd\\ufffd"


  testthat results ================================================================
  OK: 13 SKIPPED: 0 FAILED: 1
  1. Failure: Trying to parse the test-encoding.yaml (@test-encoding.R#27) 

  Error: testthat unit tests failed
  Execution halted
* checking PDF version of manual ... OK
* DONE
Status: 1 ERROR, 2 WARNINGs

This may or may not be feasible to work around (I'm guessing it has stringi and testthat dependencies, but haven't dug too deeply), but it's a weird enough error that I wanted to document it.

@seankross
Copy link
Member

Hi @dgoerger,

I agree that this is a problematic test, thanks for reporting this.

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