assert 2.18.0 → 2.19.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (58) hide show
  1. checksums.yaml +4 -4
  2. data/README.md +66 -37
  3. data/assert.gemspec +4 -3
  4. data/lib/assert/actual_value.rb +140 -0
  5. data/lib/assert/assertions.rb +80 -20
  6. data/lib/assert/context.rb +31 -37
  7. data/lib/assert/context/let_dsl.rb +13 -0
  8. data/lib/assert/context/method_missing.rb +19 -0
  9. data/lib/assert/context/subject_dsl.rb +23 -24
  10. data/lib/assert/macros/methods.rb +4 -4
  11. data/lib/assert/result.rb +5 -1
  12. data/lib/assert/stub.rb +16 -0
  13. data/lib/assert/suite.rb +7 -10
  14. data/lib/assert/test.rb +0 -8
  15. data/lib/assert/version.rb +1 -1
  16. data/test/helper.rb +23 -25
  17. data/test/support/factory.rb +15 -0
  18. data/test/system/stub_tests.rb +332 -333
  19. data/test/system/test_tests.rb +99 -109
  20. data/test/unit/actual_value_tests.rb +371 -0
  21. data/test/unit/assert_tests.rb +111 -43
  22. data/test/unit/assertions/assert_block_tests.rb +30 -31
  23. data/test/unit/assertions/assert_changes_tests.rb +97 -0
  24. data/test/unit/assertions/assert_empty_tests.rb +33 -32
  25. data/test/unit/assertions/assert_equal_tests.rb +94 -74
  26. data/test/unit/assertions/assert_file_exists_tests.rb +32 -33
  27. data/test/unit/assertions/assert_includes_tests.rb +38 -37
  28. data/test/unit/assertions/assert_instance_of_tests.rb +34 -33
  29. data/test/unit/assertions/assert_kind_of_tests.rb +34 -33
  30. data/test/unit/assertions/assert_match_tests.rb +34 -33
  31. data/test/unit/assertions/assert_nil_tests.rb +30 -31
  32. data/test/unit/assertions/assert_raises_tests.rb +55 -55
  33. data/test/unit/assertions/assert_respond_to_tests.rb +36 -35
  34. data/test/unit/assertions/assert_same_tests.rb +86 -81
  35. data/test/unit/assertions/assert_true_false_tests.rb +60 -60
  36. data/test/unit/assertions_tests.rb +26 -24
  37. data/test/unit/config_helpers_tests.rb +43 -38
  38. data/test/unit/config_tests.rb +38 -34
  39. data/test/unit/context/let_dsl_tests.rb +10 -0
  40. data/test/unit/context/setup_dsl_tests.rb +70 -81
  41. data/test/unit/context/subject_dsl_tests.rb +15 -43
  42. data/test/unit/context/suite_dsl_tests.rb +15 -16
  43. data/test/unit/context/test_dsl_tests.rb +50 -52
  44. data/test/unit/context_info_tests.rb +23 -15
  45. data/test/unit/context_tests.rb +184 -179
  46. data/test/unit/default_runner_tests.rb +2 -5
  47. data/test/unit/default_suite_tests.rb +57 -53
  48. data/test/unit/factory_tests.rb +5 -3
  49. data/test/unit/file_line_tests.rb +33 -35
  50. data/test/unit/macro_tests.rb +14 -10
  51. data/test/unit/result_tests.rb +159 -183
  52. data/test/unit/runner_tests.rb +64 -64
  53. data/test/unit/suite_tests.rb +56 -59
  54. data/test/unit/test_tests.rb +118 -139
  55. data/test/unit/utils_tests.rb +43 -45
  56. data/test/unit/view_helpers_tests.rb +54 -52
  57. data/test/unit/view_tests.rb +22 -23
  58. metadata +29 -7
@@ -8,32 +8,35 @@ module Assert::Assertions
8
8
  include Assert::Test::TestHelpers
9
9
 
10
10
  desc "`assert_same`"
11
- setup do
12
- klass = Class.new; object = klass.new
13
- desc = @desc = "assert same fail desc"
14
- args = @args = [object, klass.new, desc]
15
- @test = Factory.test do
11
+ subject {
12
+ args = args1
13
+ object = object1
14
+ Factory.test do
16
15
  assert_same(object, object) # pass
17
16
  assert_same(*args) # fail
18
17
  end
19
- @c = @test.config
20
- @test.run(&test_run_callback)
21
- end
22
- subject{ @test }
18
+ }
23
19
 
24
- should "produce results as expected" do
25
- assert_equal 2, test_run_result_count
26
- assert_equal 1, test_run_result_count(:pass)
27
- assert_equal 1, test_run_result_count(:fail)
28
- end
20
+ let(:class1) { Class.new }
21
+ let(:object1) { class1.new }
22
+ let(:desc1) { "assert same fail desc" }
23
+ let(:args1) { [object1, class1.new, desc1] }
24
+ let(:config1) { subject.config }
29
25
 
30
- should "have a fail message with custom and generic explanations" do
31
- exp = "#{@args[2]}\n"\
32
- "Expected #{Assert::U.show(@args[1], @c)}"\
33
- " (#<#{@args[1].class}:#{"0x0%x" % (@args[1].object_id << 1)}>)"\
34
- " to be the same as #{Assert::U.show(@args[0], @c)}"\
35
- " (#<#{@args[0].class}:#{"0x0%x" % (@args[0].object_id << 1)}>)."
36
- assert_equal exp, test_run_results(:fail).first.message
26
+ should "produce results as expected" do
27
+ subject.run(&test_run_callback)
28
+
29
+ assert_that(test_run_result_count).equals(2)
30
+ assert_that(test_run_result_count(:pass)).equals(1)
31
+ assert_that(test_run_result_count(:fail)).equals(1)
32
+
33
+ exp =
34
+ "#{args1[2]}\n"\
35
+ "Expected #{Assert::U.show(args1[1], config1)}"\
36
+ " (#<#{args1[1].class}:#{"0x0%x" % (args1[1].object_id << 1)}>)"\
37
+ " to be the same as #{Assert::U.show(args1[0], config1)}"\
38
+ " (#<#{args1[0].class}:#{"0x0%x" % (args1[0].object_id << 1)}>)."
39
+ assert_that(test_run_results(:fail).first.message).equals(exp)
37
40
  end
38
41
  end
39
42
 
@@ -41,32 +44,36 @@ module Assert::Assertions
41
44
  include Assert::Test::TestHelpers
42
45
 
43
46
  desc "`assert_not_same`"
44
- setup do
45
- klass = Class.new; object = klass.new
46
- desc = @desc = "assert not same fail desc"
47
- args = @args = [object, object, desc]
48
- @test = Factory.test do
47
+ subject {
48
+ args = args1
49
+ object = object1
50
+ klass = class1
51
+ Factory.test do
49
52
  assert_not_same(*args) # fail
50
53
  assert_not_same(object, klass.new) # pass
51
54
  end
52
- @c = @test.config
53
- @test.run(&test_run_callback)
54
- end
55
- subject{ @test }
55
+ }
56
56
 
57
- should "produce results as expected" do
58
- assert_equal 2, test_run_result_count
59
- assert_equal 1, test_run_result_count(:pass)
60
- assert_equal 1, test_run_result_count(:fail)
61
- end
57
+ let(:class1) { Class.new }
58
+ let(:object1) { class1.new }
59
+ let(:desc1) { "assert not same fail desc" }
60
+ let(:args1) { [object1, object1, desc1] }
61
+ let(:config1) { subject.config }
62
62
 
63
- should "have a fail message with custom and generic explanations" do
64
- exp = "#{@args[2]}\n"\
65
- "Expected #{Assert::U.show(@args[1], @c)}"\
66
- " (#<#{@args[1].class}:#{"0x0%x" % (@args[1].object_id << 1)}>)"\
67
- " to not be the same as #{Assert::U.show(@args[0], @c)}"\
68
- " (#<#{@args[0].class}:#{"0x0%x" % (@args[0].object_id << 1)}>)."
69
- assert_equal exp, test_run_results(:fail).first.message
63
+ should "produce results as expected" do
64
+ subject.run(&test_run_callback)
65
+
66
+ assert_that(test_run_result_count).equals(2)
67
+ assert_that(test_run_result_count(:pass)).equals(1)
68
+ assert_that(test_run_result_count(:fail)).equals(1)
69
+
70
+ exp =
71
+ "#{args1[2]}\n"\
72
+ "Expected #{Assert::U.show(args1[1], config1)}"\
73
+ " (#<#{args1[1].class}:#{"0x0%x" % (args1[1].object_id << 1)}>)"\
74
+ " to not be the same as #{Assert::U.show(args1[0], config1)}"\
75
+ " (#<#{args1[0].class}:#{"0x0%x" % (args1[0].object_id << 1)}>)."
76
+ assert_that(test_run_results(:fail).first.message).equals(exp)
70
77
  end
71
78
  end
72
79
 
@@ -74,62 +81,60 @@ module Assert::Assertions
74
81
  include Assert::Test::TestHelpers
75
82
 
76
83
  desc "with objects that should use diff when showing"
77
- setup do
78
- @exp_obj = "I'm a\nstring"
79
- @act_obj = "I am a \nstring"
80
-
81
- @c = Factory.modes_off_config
82
- @c.use_diff_proc(Assert::U.default_use_diff_proc)
83
- @c.run_diff_proc(Assert::U.syscmd_diff_proc)
84
+ let(:config1) {
85
+ Factory.modes_off_config.tap do |config|
86
+ config.use_diff_proc(Assert::U.default_use_diff_proc)
87
+ config.run_diff_proc(Assert::U.syscmd_diff_proc)
88
+ end
89
+ }
84
90
 
85
- @exp_obj_show = Assert::U.show_for_diff(@exp_obj, @c)
86
- @act_obj_show = Assert::U.show_for_diff(@act_obj, @c)
87
- end
91
+ let(:exp_obj1) { "I'm a\nstring" }
92
+ let(:act_obj1) { "I am a \nstring" }
93
+ let(:exp_obj_show1) { Assert::U.show_for_diff(exp_obj1, config1) }
94
+ let(:act_obj_show1) { Assert::U.show_for_diff(act_obj1, config1) }
88
95
  end
89
96
 
90
97
  class AssertSameDiffTests < DiffTests
91
98
  desc "`assert_same`"
92
- setup do
93
- exp_obj, act_obj = @exp_obj, @act_obj
94
- @test = Factory.test(@c) do
99
+ subject {
100
+ exp_obj, act_obj = exp_obj1, act_obj1
101
+ Factory.test(config1) do
95
102
  assert_same(exp_obj, act_obj)
96
103
  end
97
- @test.run(&test_run_callback)
98
- end
99
- subject{ @test }
104
+ }
100
105
 
101
106
  should "include diff output in the fail messages" do
102
- exp = "Expected #<#{@act_obj.class}:#{"0x0%x" % (@act_obj.object_id << 1)}>"\
103
- " to be the same as"\
104
- " #<#{@exp_obj.class}:#{"0x0%x" % (@exp_obj.object_id << 1)}>"\
105
- ", diff:\n"\
106
- "#{Assert::U.syscmd_diff_proc.call(@exp_obj_show, @act_obj_show)}"
107
- assert_equal exp, test_run_results(:fail).first.message
107
+ subject.run(&test_run_callback)
108
+
109
+ exp =
110
+ "Expected #<#{act_obj1.class}:#{"0x0%x" % (act_obj1.object_id << 1)}>"\
111
+ " to be the same as"\
112
+ " #<#{exp_obj1.class}:#{"0x0%x" % (exp_obj1.object_id << 1)}>"\
113
+ ", diff:\n"\
114
+ "#{Assert::U.syscmd_diff_proc.call(exp_obj_show1, act_obj_show1)}"
115
+ assert_that(test_run_results(:fail).first.message).equals(exp)
108
116
  end
109
117
  end
110
118
 
111
119
  class AssertNotSameDiffTests < DiffTests
112
120
  desc "`assert_not_same`"
113
- setup do
114
- @exp_obj = @act_obj
115
- @exp_obj_show = @act_obj_show
116
-
117
- exp_obj, act_obj = @exp_obj, @act_obj
118
- @test = Factory.test(@c) do
119
- assert_not_same(exp_obj, exp_obj)
121
+ subject {
122
+ act_obj = act_obj1
123
+ Factory.test(config1) do
124
+ assert_not_same(act_obj, act_obj)
120
125
  end
121
- @test.run(&test_run_callback)
122
- end
123
- subject{ @test }
126
+ }
124
127
 
125
128
  should "include diff output in the fail messages" do
126
- exp = "Expected #<#{@act_obj.class}:#{"0x0%x" % (@act_obj.object_id << 1)}>"\
127
- " to not be the same as"\
128
- " #<#{@exp_obj.class}:#{"0x0%x" % (@exp_obj.object_id << 1)}>"\
129
- ", diff:\n"\
130
- "#{Assert::U.syscmd_diff_proc.call(@exp_obj_show, @act_obj_show)}"
131
- assert_equal exp, test_run_results(:fail).first.message
129
+ subject.run(&test_run_callback)
130
+
131
+ exp =
132
+ "Expected #<#{act_obj1.class}:#{"0x0%x" % (act_obj1.object_id << 1)}>"\
133
+ " to not be the same as"\
134
+ " #<#{act_obj1.class}:#{"0x0%x" % (act_obj1.object_id << 1)}>"\
135
+ ", diff:\n"\
136
+ "#{Assert::U.syscmd_diff_proc.call(act_obj_show1, act_obj_show1)}"
137
+ assert_that(test_run_results(:fail).first.message).equals(exp)
132
138
  end
133
139
  end
134
140
  end
135
-
@@ -8,27 +8,27 @@ module Assert::Assertions
8
8
  include Assert::Test::TestHelpers
9
9
 
10
10
  desc "`assert_true`"
11
- setup do
12
- desc = @desc = "assert true fail desc"
13
- args = @args = ["whatever", desc]
14
- @test = Factory.test do
11
+ subject {
12
+ args = args1
13
+ Factory.test do
15
14
  assert_true(true) # pass
16
15
  assert_true(*args) # fail
17
16
  end
18
- @c = @test.config
19
- @test.run(&test_run_callback)
20
- end
21
- subject{ @test }
17
+ }
18
+
19
+ let(:desc1) { "assert true fail desc" }
20
+ let(:args1) { ["whatever", desc1] }
21
+ let(:config1) { subject.config }
22
22
 
23
23
  should "produce results as expected" do
24
- assert_equal 2, test_run_result_count
25
- assert_equal 1, test_run_result_count(:pass)
26
- assert_equal 1, test_run_result_count(:fail)
27
- end
24
+ subject.run(&test_run_callback)
25
+
26
+ assert_that(test_run_result_count).equals(2)
27
+ assert_that(test_run_result_count(:pass)).equals(1)
28
+ assert_that(test_run_result_count(:fail)).equals(1)
28
29
 
29
- should "have a fail message with custom and generic explanations" do
30
- exp = "#{@args[1]}\nExpected #{Assert::U.show(@args[0], @c)} to be true."
31
- assert_equal exp, test_run_results(:fail).first.message
30
+ exp = "#{args1[1]}\nExpected #{Assert::U.show(args1[0], config1)} to be true."
31
+ assert_that(test_run_results(:fail).first.message).equals(exp)
32
32
  end
33
33
  end
34
34
 
@@ -36,27 +36,27 @@ module Assert::Assertions
36
36
  include Assert::Test::TestHelpers
37
37
 
38
38
  desc "`assert_not_true`"
39
- setup do
40
- desc = @desc = "assert not true fail desc"
41
- args = @args = [true, desc]
42
- @test = Factory.test do
39
+ subject {
40
+ args = args1
41
+ Factory.test do
43
42
  assert_not_true(false) # pass
44
43
  assert_not_true(*args) # fail
45
44
  end
46
- @c = @test.config
47
- @test.run(&test_run_callback)
48
- end
49
- subject{ @test }
45
+ }
46
+
47
+ let(:desc1) { "assert not true fail desc" }
48
+ let(:args1) { [true, desc1] }
49
+ let(:config1) { subject.config }
50
50
 
51
51
  should "produce results as expected" do
52
- assert_equal 2, test_run_result_count
53
- assert_equal 1, test_run_result_count(:pass)
54
- assert_equal 1, test_run_result_count(:fail)
55
- end
52
+ subject.run(&test_run_callback)
53
+
54
+ assert_that(test_run_result_count).equals(2)
55
+ assert_that(test_run_result_count(:pass)).equals(1)
56
+ assert_that(test_run_result_count(:fail)).equals(1)
56
57
 
57
- should "have a fail message with custom and generic explanations" do
58
- exp = "#{@args[1]}\nExpected #{Assert::U.show(@args[0], @c)} to not be true."
59
- assert_equal exp, test_run_results(:fail).first.message
58
+ exp = "#{args1[1]}\nExpected #{Assert::U.show(args1[0], config1)} to not be true."
59
+ assert_that(test_run_results(:fail).first.message).equals(exp)
60
60
  end
61
61
  end
62
62
 
@@ -64,27 +64,27 @@ module Assert::Assertions
64
64
  include Assert::Test::TestHelpers
65
65
 
66
66
  desc "`assert_false`"
67
- setup do
68
- desc = @desc = "assert false fail desc"
69
- args = @args = ["whatever", desc]
70
- @test = Factory.test do
67
+ subject {
68
+ args = args1
69
+ Factory.test do
71
70
  assert_false(false) # pass
72
71
  assert_false(*args) # fail
73
72
  end
74
- @c = @test.config
75
- @test.run(&test_run_callback)
76
- end
77
- subject{ @test }
73
+ }
74
+
75
+ let(:desc1) { "assert false fail desc" }
76
+ let(:args1) { ["whatever", desc1] }
77
+ let(:config1) { subject.config }
78
78
 
79
79
  should "produce results as expected" do
80
- assert_equal 2, test_run_result_count
81
- assert_equal 1, test_run_result_count(:pass)
82
- assert_equal 1, test_run_result_count(:fail)
83
- end
80
+ subject.run(&test_run_callback)
81
+
82
+ assert_that(test_run_result_count).equals(2)
83
+ assert_that(test_run_result_count(:pass)).equals(1)
84
+ assert_that(test_run_result_count(:fail)).equals(1)
84
85
 
85
- should "have a fail message with custom and generic explanations" do
86
- exp = "#{@args[1]}\nExpected #{Assert::U.show(@args[0], @c)} to be false."
87
- assert_equal exp, test_run_results(:fail).first.message
86
+ exp = "#{args1[1]}\nExpected #{Assert::U.show(args1[0], config1)} to be false."
87
+ assert_that(test_run_results(:fail).first.message).equals(exp)
88
88
  end
89
89
  end
90
90
 
@@ -92,27 +92,27 @@ module Assert::Assertions
92
92
  include Assert::Test::TestHelpers
93
93
 
94
94
  desc "`assert_not_false`"
95
- setup do
96
- desc = @desc = "assert not false fail desc"
97
- args = @args = [false, desc]
98
- @test = Factory.test do
95
+ subject {
96
+ args = args1
97
+ Factory.test do
99
98
  assert_not_false(true) # pass
100
99
  assert_not_false(*args) # fail
101
100
  end
102
- @c = @test.config
103
- @test.run(&test_run_callback)
104
- end
105
- subject{ @test }
101
+ }
102
+
103
+ let(:desc1) { "assert not false fail desc" }
104
+ let(:args1) { [false, desc1] }
105
+ let(:config1) { subject.config }
106
106
 
107
107
  should "produce results as expected" do
108
- assert_equal 2, test_run_result_count
109
- assert_equal 1, test_run_result_count(:pass)
110
- assert_equal 1, test_run_result_count(:fail)
111
- end
108
+ subject.run(&test_run_callback)
109
+
110
+ assert_that(test_run_result_count).equals(2)
111
+ assert_that(test_run_result_count(:pass)).equals(1)
112
+ assert_that(test_run_result_count(:fail)).equals(1)
112
113
 
113
- should "have a fail message with custom and generic explanations" do
114
- exp = "#{@args[1]}\nExpected #{Assert::U.show(@args[0], @c)} to not be false."
115
- assert_equal exp, test_run_results(:fail).first.message
114
+ exp = "#{args1[1]}\nExpected #{Assert::U.show(args1[0], config1)} to not be false."
115
+ assert_that(test_run_results(:fail).first.message).equals(exp)
116
116
  end
117
117
  end
118
118
  end
@@ -6,52 +6,54 @@ module Assert::Assertions
6
6
  include Assert::Test::TestHelpers
7
7
 
8
8
  desc "Assert::Context"
9
- setup do
10
- @context_class = Factory.modes_off_context_class
11
- @test = Factory.test
12
- @context = @context_class.new(@test, @test.config, proc{ |r| })
13
- end
14
- subject{ @context }
9
+ subject { context_class1.new(test1, test1.config, proc { |r| }) }
10
+
11
+ let(:context_class1) { Factory.modes_off_context_class }
12
+ let(:test1) { Factory.test }
15
13
 
16
14
  should have_imeths :assert_block, :assert_not_block, :refute_block
17
- should have_imeths :assert_raises, :assert_not_raises
18
- should have_imeths :assert_raise, :assert_not_raise, :assert_nothing_raised
19
- should have_imeths :assert_kind_of, :assert_not_kind_of, :refute_kind_of
20
- should have_imeths :assert_instance_of, :assert_not_instance_of, :refute_instance_of
21
- should have_imeths :assert_respond_to, :assert_responds_to
22
- should have_imeths :assert_not_respond_to, :assert_not_responds_to
23
- should have_imeths :refute_respond_to, :refute_responds_to
24
- should have_imeths :assert_same, :assert_not_same, :refute_same
25
- should have_imeths :assert_equal, :assert_not_equal, :refute_equal
26
- should have_imeths :assert_match, :assert_not_match, :assert_no_match, :refute_match
27
15
  should have_imeths :assert_empty, :assert_not_empty, :refute_empty
16
+ should have_imeths :assert_equal, :assert_not_equal, :refute_equal
17
+ should have_imeths :assert_file_exists, :assert_not_file_exists, :refute_file_exists
28
18
  should have_imeths :assert_includes, :assert_not_includes
29
19
  should have_imeths :assert_included, :assert_not_included
30
20
  should have_imeths :refute_includes, :refute_included
21
+ should have_imeths :assert_instance_of, :assert_not_instance_of, :refute_instance_of
22
+ should have_imeths :assert_kind_of, :assert_not_kind_of, :refute_kind_of
23
+ should have_imeths :assert_match, :assert_not_match, :assert_no_match, :refute_match
31
24
  should have_imeths :assert_nil, :assert_not_nil, :refute_nil
32
25
  should have_imeths :assert_true, :assert_not_true, :refute_true
33
26
  should have_imeths :assert_false, :assert_not_false, :refute_false
34
- should have_imeths :assert_file_exists, :assert_not_file_exists, :refute_file_exists
27
+ should have_imeths :assert_raises, :assert_not_raises
28
+ should have_imeths :assert_raise, :assert_not_raise, :assert_nothing_raised
29
+ should have_imeths :assert_changes, :assert_not_changes, :refute_changes
30
+ should have_imeths :assert_respond_to, :assert_responds_to
31
+ should have_imeths :assert_not_respond_to, :assert_not_responds_to
32
+ should have_imeths :refute_respond_to, :refute_responds_to
33
+ should have_imeths :assert_same, :assert_not_same, :refute_same
35
34
  end
36
35
 
37
36
  class IgnoredTests < UnitTests
38
37
  desc "ignored assertions helpers"
39
38
  setup do
40
- @tests = Assert::Assertions::IGNORED_ASSERTION_HELPERS.map do |helper|
41
- context_info = Factory.context_info(@context_class)
39
+ tests.each{ |test| test.run(&test_run_callback) }
40
+ end
41
+
42
+ let(:tests) {
43
+ context_info = Factory.context_info(context_class1)
44
+ Assert::Assertions::IGNORED_ASSERTION_HELPERS.map do |helper|
42
45
  Factory.test("ignored assertion helper #{helper}", context_info) do
43
46
  self.send(helper, "doesn't matter")
44
47
  end
45
48
  end
46
- @tests.each{ |test| test.run(&test_run_callback) }
47
- end
49
+ }
48
50
 
49
51
  should "have an ignored result for each helper in the constant" do
50
52
  exp = Assert::Assertions::IGNORED_ASSERTION_HELPERS.size
51
- assert_equal exp, test_run_result_count
53
+ assert_that(test_run_result_count).equals(exp)
52
54
 
53
55
  test_run_results.each do |result|
54
- assert_kind_of Assert::Result::Ignore, result
56
+ assert_that(result).is_kind_of(Assert::Result::Ignore)
55
57
  end
56
58
  end
57
59
 
@@ -60,7 +62,7 @@ module Assert::Assertions
60
62
  "The assertion `#{helper}` is not supported."\
61
63
  " Please use another assertion or the basic `assert`."
62
64
  end
63
- assert_equal exp, test_run_results.collect(&:message)
65
+ assert_that(test_run_results.collect(&:message)).equals(exp)
64
66
  end
65
67
  end
66
68
  end