-
Notifications
You must be signed in to change notification settings - Fork 26
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
Fix backtrace filtering #31
Comments
Won't |
Not if you require this file before anything else, which is the most common use case, right? |
That's true (though I know of at least one project where I'd end up with empty backtraces 😊). Perhaps this is a good use case for Ruby's |
The constant is created when the module is required, and the array is the result of adding |
Yes. Consider the / my typical Rakefile: $LOAD_PATH.unshift File.expand_path("./lib")
require "cutest" # or require "test_helper"
require "my_library"
task(:foo) { MyLibrary.do_something! }
task(:bar) { MyLibrary.do_something_else! }
task(:test) { Cutest.run(FileList["test/*_test.rb"]) } In such cases you'd end up with an empty backtrace and it will not be obvious why. Capturing the Another situation where you'd end up with an empty backtrace is running a single test file using |
Yes, it's true, this is opinionated based on the fact that I never include my application's directories in Maybe just using |
And make it work with e.g. gemsets.
This works: https://gist.github.com/djanowski/afed5a759687921f0569
The text was updated successfully, but these errors were encountered: