Commit Graph

15 Commits

Author SHA1 Message Date
Guo Xiang Tan 5a973b314b Remove alias for `i_suck_and_my_tests_are_order_dependent`. 2015-03-24 00:27:53 +08:00
Rafael Mendonça França 5f777e4b5e Change the default test order from `:sorted` to `:random` 2015-01-04 11:58:41 -03:00
Godfrey Chan 2b41343c34 Default to sorting user's test cases for now
Goals:

1. Default to :random for newly generated applications
2. Default to :sorted for existing applications with a warning
3. Only show the warning once
4. Only show the warning if the app actually uses AS::TestCase

Fixes #16769
2014-09-08 05:32:16 -07:00
Zachary Scott 5efcf3800e Move as/test_test to as/test_case_test 2014-08-19 23:40:42 -07:00
kennyj 6c2cbc6fff Remove active_support/testing/pending.rb was deprecated. 2013-06-01 21:23:19 +09:00
Ryan Davis 3073c53198 Updates to make rails 4 happy with minitest 5:
+ Namespace changes, overhaul of runners.
+ Internal ivar name changes
- Removed a logger globally applied to tests that spew everywhere?!?
+ Override Minitest#__run to sort tests by name.
+ Reworked testing isolation to work with the new cleaner architecture.
- Removed a bunch of tests that just test minitest straight up. I think these changes were all merged to minitest 4 a long time ago.
- Minor report output differences.
2013-05-06 17:38:45 -07:00
Carlos Antonio da Silva da47960893 Fix failures in AS with minitest 4.7.4 2013-05-01 23:21:08 -03:00
Carlos Antonio da Silva 92da512125 Properly deprecate #pending from AS::TestCase
Check https://github.com/rails/rails/pull/4575#issuecomment-5765575.
2012-11-18 21:34:00 -02:00
Rafael Mendonça França ae6d2efd84 Make the tests pass with minitest 4.2 2012-11-05 15:12:09 -02:00
James Mead b057fab638 Exceptions like Interrupt should not be rescued.
Neither Test::Unit nor MiniTest rescue exceptions like Interrupt or
NoMemoryError, but ActiveSupport::Testing::SetupAndTeardown#run which
overrides MiniTest::Unit::TestCase#run rescues them.

Rescuing an Interrupt exception is annoying, because it means when you
are running a lot of tests e.g. when running one of the rake test tasks,
you cannot break out using ctrl-C.

Rescuing exceptions like NoMemoryError is foolish, because the most
sensible thing to happen is for the process to terminate as soon as
possible.

This solution probably needs some finessing e.g. I'm not clear whether
the assumption is that only MiniTest is supported. Also early versions
of MiniTest did not have this behaviour. However, hopefully it's a
start.

Integrating with Test::Unit & MiniTest has always been a pain. It would
be great if both of them provided sensible extension points for the kind
of things that both Rails and Mocha want to do.
2012-05-28 22:44:28 +01:00
Aaron Patterson f65559fcc2 make sure the test case name is nil 2012-01-06 15:17:08 -08:00
Rafael Mendonça França b2fca9533e No need to check if MiniTest::Assertions is defined 2012-01-06 13:31:39 -03:00
Aaron Patterson e477fc1147 fixing test case test on 1.9.3dev 2011-03-01 10:14:09 -08:00
Aaron Patterson b7c49cedba calling correct method on minitest for test name when teardown callback fails 2010-10-04 09:34:34 -07:00
Aaron Patterson ccf228b027 [#5406 state:resolved] calling the correct method on minitest to obtain the test name 2010-10-04 09:33:35 -07:00