assert 2.18.3 → 2.18.4
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/lib/assert/context.rb +5 -2
- data/lib/assert/context/let_dsl.rb +3 -3
- data/lib/assert/context/subject_dsl.rb +23 -24
- data/lib/assert/version.rb +1 -1
- data/test/system/stub_tests.rb +101 -117
- data/test/system/test_tests.rb +21 -33
- data/test/unit/assert_tests.rb +3 -1
- data/test/unit/assertions/assert_block_tests.rb +6 -8
- data/test/unit/assertions/assert_empty_tests.rb +10 -12
- data/test/unit/assertions/assert_equal_tests.rb +12 -18
- data/test/unit/assertions/assert_file_exists_tests.rb +10 -12
- data/test/unit/assertions/assert_includes_tests.rb +10 -12
- data/test/unit/assertions/assert_instance_of_tests.rb +10 -12
- data/test/unit/assertions/assert_kind_of_tests.rb +10 -12
- data/test/unit/assertions/assert_match_tests.rb +10 -12
- data/test/unit/assertions/assert_nil_tests.rb +10 -12
- data/test/unit/assertions/assert_raises_tests.rb +6 -8
- data/test/unit/assertions/assert_respond_to_tests.rb +10 -12
- data/test/unit/assertions/assert_same_tests.rb +16 -22
- data/test/unit/assertions/assert_true_false_tests.rb +20 -24
- data/test/unit/assertions_tests.rb +1 -2
- data/test/unit/config_helpers_tests.rb +8 -4
- data/test/unit/config_tests.rb +7 -2
- data/test/unit/context/setup_dsl_tests.rb +3 -3
- data/test/unit/context/subject_dsl_tests.rb +1 -2
- data/test/unit/context/suite_dsl_tests.rb +1 -2
- data/test/unit/context_info_tests.rb +9 -2
- data/test/unit/context_tests.rb +65 -73
- data/test/unit/default_suite_tests.rb +8 -2
- data/test/unit/factory_tests.rb +3 -1
- data/test/unit/file_line_tests.rb +8 -8
- data/test/unit/macro_tests.rb +10 -5
- data/test/unit/result_tests.rb +34 -45
- data/test/unit/runner_tests.rb +10 -10
- data/test/unit/suite_tests.rb +9 -9
- data/test/unit/test_tests.rb +32 -39
- data/test/unit/utils_tests.rb +3 -1
- data/test/unit/view_helpers_tests.rb +6 -7
- data/test/unit/view_tests.rb +4 -3
- metadata +2 -2
data/test/unit/utils_tests.rb
CHANGED
@@ -7,7 +7,9 @@ require "assert/config"
|
|
7
7
|
module Assert::Utils
|
8
8
|
class UnitTests < Assert::Context
|
9
9
|
desc "Assert::Utils"
|
10
|
-
subject {
|
10
|
+
subject { unit_class }
|
11
|
+
|
12
|
+
let(:unit_class) { Assert::Utils }
|
11
13
|
|
12
14
|
let(:objs1) { [1, "hi there", Hash.new, [:a, :b]] }
|
13
15
|
|
@@ -10,10 +10,9 @@ require "assert/view"
|
|
10
10
|
module Assert::ViewHelpers
|
11
11
|
class UnitTests < Assert::Context
|
12
12
|
desc "Assert::ViewHelpers"
|
13
|
-
subject {
|
13
|
+
subject { unit_class }
|
14
14
|
|
15
|
-
let(:
|
16
|
-
let(:helpers_class1) {
|
15
|
+
let(:unit_class) {
|
17
16
|
test_opt_val = test_opt_val1
|
18
17
|
Class.new do
|
19
18
|
include Assert::ViewHelpers
|
@@ -28,6 +27,8 @@ module Assert::ViewHelpers
|
|
28
27
|
end
|
29
28
|
}
|
30
29
|
|
30
|
+
let(:test_opt_val1) { Factory.string }
|
31
|
+
|
31
32
|
should have_imeths :option
|
32
33
|
|
33
34
|
should "include the config helpers" do
|
@@ -35,7 +36,7 @@ module Assert::ViewHelpers
|
|
35
36
|
end
|
36
37
|
|
37
38
|
should "write option values" do
|
38
|
-
helpers =
|
39
|
+
helpers = unit_class.new
|
39
40
|
assert_that(helpers.test_opt).equals(test_opt_val1)
|
40
41
|
|
41
42
|
new_val = Factory.integer
|
@@ -50,9 +51,7 @@ module Assert::ViewHelpers
|
|
50
51
|
|
51
52
|
class InitTests < UnitTests
|
52
53
|
desc "when init"
|
53
|
-
subject {
|
54
|
-
|
55
|
-
let(:helpers1) { helpers_class1.new }
|
54
|
+
subject { unit_class.new }
|
56
55
|
|
57
56
|
should have_imeths :captured_output, :re_run_test_cmd
|
58
57
|
should have_imeths :tests_to_run_count_statement, :result_count_statement
|
data/test/unit/view_tests.rb
CHANGED
@@ -9,7 +9,9 @@ require "assert/view_helpers"
|
|
9
9
|
class Assert::View
|
10
10
|
class UnitTests < Assert::Context
|
11
11
|
desc "Assert::View"
|
12
|
-
subject {
|
12
|
+
subject { unit_class }
|
13
|
+
|
14
|
+
let(:unit_class) { Assert::View }
|
13
15
|
|
14
16
|
should have_instance_method :require_user_view
|
15
17
|
|
@@ -24,11 +26,10 @@ class Assert::View
|
|
24
26
|
|
25
27
|
class InitTests < UnitTests
|
26
28
|
desc "when init"
|
27
|
-
subject {
|
29
|
+
subject { Assert::View.new(config1, io1) }
|
28
30
|
|
29
31
|
let(:io1) { StringIO.new("", "w+") }
|
30
32
|
let(:config1) { Factory.modes_off_config }
|
31
|
-
let(:view1) { Assert::View.new(config1, io1) }
|
32
33
|
|
33
34
|
should have_readers :config
|
34
35
|
should have_imeths :view, :is_tty?
|
metadata
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: assert
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 2.18.
|
4
|
+
version: 2.18.4
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Kelly Redding
|
@@ -9,7 +9,7 @@ authors:
|
|
9
9
|
autorequire:
|
10
10
|
bindir: bin
|
11
11
|
cert_chain: []
|
12
|
-
date: 2020-09-
|
12
|
+
date: 2020-09-07 00:00:00.000000000 Z
|
13
13
|
dependencies:
|
14
14
|
- !ruby/object:Gem::Dependency
|
15
15
|
name: much-factory
|