Running specific CoffeeScript specs doesn't work #20
Loading…
Reference in New Issue
Block a user
No description provided.
Delete Branch "%!s()"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
Found another boog. Running
jasmine-headless-webkit
without any arguments works fine with CoffeeScript files now, so that's great, but running a specific CoffeeScript file doesn't quite work -- it not only ends up running all the specs as though you didn't pass an argument, but also prints "PASS: 0 tests, 0 failures, 0 secs." at the top of the output, even if there are test failures (in which case there's also a "FAIL" line at the bottom). Specifying specific Javascript files, however, works fine.I can investigate this further tomorrow but I wanted to just jot this down now.
What is the directory structure of the working directory and the exact command line you're running the executable with?
Sorry for the delay on this. I currently have it so that I'm converting the CoffeeScript files into Javascript, and then I have the Javascript files listed in jasmine.yml. This is so that I can run the specs either using JHW or the regular Jasmine gem. That is working for me for right now, hence the delay. But anyway, I have a spec/javascripts folder and also a spec/coffeescripts folder. I've been using guard-jasmine-headless-webkit, but I just run
jasmine-headless-webkit spec/coffeescripts/some_spec.coffee
then I still get the weird PASS/FAIL thing.So just to clarify,
jasmine.yml
is roughly:Correct?
Yes, exactly.
Well the issue you're running into is that the "run specific spec file" looks within the scope of what files
jasmine.yml
sees. So, since you don't include any*.coffee
files, it won't find the*.coffee
file you're requesting.I suppose that, theoretically, since your helpers and stuff should be defined in the
helpers
part ofjasmine.yml
, one could simply replacespec_files
for that run with whatever file(s) you pass in, and everything should work. (Right now, it's actually a little too convoluted with regards to spec file filtering, so this may be an opportunity to clean that up.) What do you think of that approach?True, you would want to run all the helpers, wouldn't you. Yup, that approach makes sense to me.
Cool, then I'll rework the file list search and tag the commits with this issue so you should get notified when it's ready. Shouldn't take long, provided I don't get busy.
D'oh, I totally forgot to tag the commits for this. Here it is:
c359e8b28b
Sweet. Looks like that's working with my project. So thanks again!