dbp / hspec-snap

BSD 3-Clause "New" or "Revised" License
13 stars 9 forks source link

hspec-snap-0.3.2.7 can't compile its test suite because of missing modules #17

Closed peti closed 9 years ago

peti commented 9 years ago

Citing from http://hydra.cryp.to/build/882874/nixlog/1/raw:

spec/Main.hs:60:18:
    Could not find module ‘Utils’
    Perhaps you meant Util (needs flag -package-key ghc-7.10.1)
    Use -v to see a list of the files searched for.
dbp commented 9 years ago

Hi @peti - how does nix compile the test suite? I only ask because the test suite both builds and runs locally, runs in CI, and presumably has run for other people who have contributed to it.

Does nix need all modules referenced in an other-modules clause for test suites as well? That's obviously important and necessary for the library section, but I've never needed it for executables (like test suites).

I can add other-modules: Utils to the test suite section, but I only want to do that if that will actually resolve the problem (as I can't reproduce the problem, I'm not sure if that's going to do anything, and I don't want to do a pointless release). If you can confirm that nix can build with that change, I'll definitely put out a release. Or if the only easy way to test it is via a minor release, I guess we can do that :)

peti commented 9 years ago

Hey @dbp, the problem is that the required source files are missing from the release tarball distributed via Hackage. Anyone trying to build the test suite using those sources will run into the errors we've seen on NixOS.

dbp commented 9 years ago

Ahh - great. Thanks! I'll fix that shortly.

dbp commented 9 years ago

@peti Mixed it up a tiny bit, so 0.3.2.8 is broken (and deprecated), but 0.3.2.9 should fix this problem.