diff options
author | Yves Senn <yves.senn@gmail.com> | 2016-02-15 14:59:03 +0100 |
---|---|---|
committer | Yves Senn <yves.senn@gmail.com> | 2016-02-15 15:19:16 +0100 |
commit | ea70c295ffc7b335ed6c587f4060746e8b59d833 (patch) | |
tree | 9f75790319b11197986e5f231da92affa4c7c23a /railties/test | |
parent | 7c3dc9632b2ae2feca90f5b1f88b9ce3ca5fbba9 (diff) | |
download | rails-ea70c295ffc7b335ed6c587f4060746e8b59d833.tar.gz rails-ea70c295ffc7b335ed6c587f4060746e8b59d833.tar.bz2 rails-ea70c295ffc7b335ed6c587f4060746e8b59d833.zip |
Revert "Prefer Minitest's location for test failures."
This reverts commit 0db310586ac3e15be95d2ef27ff40cfa24c05c10.
Closes #23686.
Conflicts:
railties/test/application/test_runner_test.rb
It's possible that the `result.location` returned by minitest is outside
the test file itself. For example in the case of mocha. This resulted in
bad rerun snipptets:
```
bin/rails test app/models/deliveries/delivery.rb:103
```
Let's always use the first line of the failed test-case in our rerun
snippet. We can display the line number of the assertion error elsewhere.
Diffstat (limited to 'railties/test')
-rw-r--r-- | railties/test/application/test_runner_test.rb | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/railties/test/application/test_runner_test.rb b/railties/test/application/test_runner_test.rb index 7ecadb60ca..5a6119c483 100644 --- a/railties/test/application/test_runner_test.rb +++ b/railties/test/application/test_runner_test.rb @@ -467,7 +467,7 @@ module ApplicationTests create_test_file :models, 'post', pass: false output = run_test_command('test/models/post_test.rb') - expect = %r{Running:\n\nPostTest\nF\n\nFailure:\nPostTest#test_truth:\nwups!\n\nbin/rails test test/models/post_test.rb:6\n\n\n\n} + expect = %r{Running:\n\nPostTest\nF\n\nFailure:\nPostTest#test_truth:\nwups!\n\nbin/rails test test/models/post_test.rb:4\n\n\n\n} assert_match expect, output end |