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-rdf4h: rdf-tests/turtle/manifest.ttl: openFile: does not exist (No such file or directory) #39

Open
juhp opened this issue May 2, 2017 · 6 comments

Comments

@juhp
Copy link

juhp commented May 2, 2017

When building for Stackage LTS 8:

/tmp/stackage-build13/rdf4h-3.0.1$ dist/build/test-rdf4h/test-rdf4h
test-rdf4h: rdf-tests/turtle/manifest.ttl: openFile: does not exist (No such file or directory)
@robstewart57
Copy link
Owner

@juhp the instructions for running the tests for this library are in the README.md file:

$ git submodule update --init --recursive
$ git submodule foreach git pull origin gh-pages
$ stack test

I could I suppose integrate this into my Test.hs (main) file for the test suite, I thought it cleaner to do the way above.

Do you know of a way to integrate the above git commands into a script for stackage to pick up before running stack test ? Either in the stack.yaml file, or somewhere else?

@juhp
Copy link
Author

juhp commented May 3, 2017

AFAIK stack test requires the tests to be integrated.

@JonathanReeve
Copy link

Is there a workaround for this? I can't seem to build rdf4h on nixos because of this bug.

@robstewart57
Copy link
Owner

@JonathanReeve I'm not a nixos user.

Can nixos not run:

$ git submodule update --init --recursive
$ git submodule foreach git pull origin gh-pages

Before

$ stack test

?

@JonathanReeve
Copy link

Nix runs tests for whatever package (Haskell or otherwise) has tests, and installation will fail if the tests fail. So any package that depends on rdf4h will fail to install if rdf4h runs tests that fail. Is there a way to put those git commands in the test suite somehow? Or put the test suite in the submodule?

Another option is to add rdf4h to the list of packages that Nix skips checks for, but ideally it could still run the tests, and the tests would pass.

BTW you can reproduce this, even if you're not on nixos, by installing Nix and running nix-shell -p haskellPackages.rdf4h.

@robstewart57
Copy link
Owner

@juhp @JonathanReeve can there be any workaround for this? This rdf4h library now passes all W3C RDF parser unit tests for NTriples, Turtle and XML, and it'd be good to have rdf4h on stackage.

The TravisCI automated testing works out-of-the-box, because when it spots the rdf-tests submodule in this repo, it runs git submodule update --init --recursive to obtain the W3C data files needed for testing, which seems like an elegant solution to obtain all the files:

https://travis-ci.org/robstewart57/rdf4h/jobs/631996835#L182

Do similar mechanisms not exist in stackage/nix?

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

3 participants