minitest-reporters 0.14.13 → 0.14.14
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/lib/minitest/around_test_hooks.rb +0 -10
- data/lib/minitest/reporters.rb +9 -9
- data/lib/minitest/reporters/version.rb +1 -1
- metadata +1 -1
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA1:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: b4dd29cac403b1337694f3bedc75246542d83fbc
|
4
|
+
data.tar.gz: 26b244e99fdd6ba011a2396b4e5ff7939c8f478c
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 8ce0df434790718604a78c298f3f1fa82822d6c51ffd8367938b20577e177467c132f839f1cc4707a310dcb70bc2de3bcf2d930a4685860fbc79b0cf26674bfa
|
7
|
+
data.tar.gz: 4f0f682214aa31e5422335b02da33fa7c51fdde19dcd6b2380dc22c00f008407b6b039ddbb8b3057a804a444d9602e8e9d6eeaa601ae908e7d77fb3c64e52210
|
@@ -11,15 +11,5 @@ module MiniTest
|
|
11
11
|
MiniTest::Unit.runner.after_test(instance.class, instance.__name__)
|
12
12
|
end
|
13
13
|
end
|
14
|
-
|
15
|
-
def before_setup
|
16
|
-
AroundTestHooks.before_test(self)
|
17
|
-
super
|
18
|
-
end
|
19
|
-
|
20
|
-
def after_teardown
|
21
|
-
super
|
22
|
-
AroundTestHooks.after_test(self)
|
23
|
-
end
|
24
14
|
end
|
25
15
|
end
|
data/lib/minitest/reporters.rb
CHANGED
@@ -22,7 +22,7 @@ module MiniTest
|
|
22
22
|
|
23
23
|
def self.use!(console_reporters = ProgressReporter.new, env = ENV, backtrace_filter = ExtensibleBacktraceFilter.default_filter)
|
24
24
|
use_runner!(console_reporters, env)
|
25
|
-
|
25
|
+
use_around_test_hooks!
|
26
26
|
use_backtrace_filter!(backtrace_filter)
|
27
27
|
use_parallel_length_method!
|
28
28
|
end
|
@@ -33,17 +33,17 @@ module MiniTest
|
|
33
33
|
Unit.runner = runner
|
34
34
|
end
|
35
35
|
|
36
|
-
def self.
|
37
|
-
|
38
|
-
|
39
|
-
else
|
40
|
-
Unit::TestCase.send(:define_method, :before_setup) do
|
36
|
+
def self.use_around_test_hooks!
|
37
|
+
Unit::TestCase.class_eval do
|
38
|
+
def run_with_hooks(runner)
|
41
39
|
AroundTestHooks.before_test(self)
|
42
|
-
|
43
|
-
|
44
|
-
Unit::TestCase.send(:define_method, :after_teardown) do
|
40
|
+
result = run_without_hooks(runner)
|
45
41
|
AroundTestHooks.after_test(self)
|
42
|
+
result
|
46
43
|
end
|
44
|
+
|
45
|
+
alias_method :run_without_hooks, :run
|
46
|
+
alias_method :run, :run_with_hooks
|
47
47
|
end
|
48
48
|
end
|
49
49
|
|