cucumber_analytics 1.5.1 → 1.5.2

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 (74) hide show
  1. data/History.rdoc +6 -0
  2. data/Rakefile +10 -27
  3. data/cucumber_analytics.gemspec +1 -0
  4. data/features/modeling/background_modeling.feature +0 -11
  5. data/features/modeling/directory_modeling.feature +0 -11
  6. data/features/modeling/doc_string_modeling.feature +0 -11
  7. data/features/modeling/example_modeling.feature +0 -11
  8. data/features/modeling/feature_file_modeling.feature +0 -11
  9. data/features/modeling/feature_modeling.feature +0 -11
  10. data/features/modeling/outline_modeling.feature +0 -11
  11. data/features/modeling/row_modeling.feature +0 -10
  12. data/features/modeling/scenario_modeling.feature +0 -11
  13. data/features/modeling/step_modeling.feature +0 -11
  14. data/features/modeling/table_modeling.feature +0 -11
  15. data/features/modeling/table_row_modeling.feature +0 -11
  16. data/features/modeling/tag_modeling.feature +0 -11
  17. data/features/step_definitions/background_steps.rb +4 -4
  18. data/features/step_definitions/directory_steps.rb +1 -1
  19. data/features/step_definitions/doc_string_steps.rb +6 -6
  20. data/features/step_definitions/feature_file_steps.rb +1 -1
  21. data/features/step_definitions/feature_steps.rb +11 -11
  22. data/features/step_definitions/outline_steps.rb +18 -18
  23. data/features/step_definitions/step_steps.rb +6 -6
  24. data/features/step_definitions/table_steps.rb +6 -6
  25. data/features/step_definitions/tag_steps.rb +10 -10
  26. data/features/step_definitions/test_steps.rb +8 -8
  27. data/features/step_definitions/verification_steps.rb +2 -2
  28. data/features/step_definitions/world_steps.rb +8 -8
  29. data/lib/cucumber_analytics/step.rb +3 -1
  30. data/lib/cucumber_analytics/test_element.rb +2 -0
  31. data/lib/cucumber_analytics/version.rb +1 -1
  32. data/spec/integration/background_integration_spec.rb +5 -5
  33. data/spec/integration/directory_integration_spec.rb +4 -4
  34. data/spec/integration/doc_string_integration_spec.rb +6 -6
  35. data/spec/integration/example_integration_spec.rb +8 -8
  36. data/spec/integration/feature_file_integration_spec.rb +3 -3
  37. data/spec/integration/feature_integration_spec.rb +15 -15
  38. data/spec/integration/outline_integration_spec.rb +7 -7
  39. data/spec/integration/scenario_integration_spec.rb +6 -6
  40. data/spec/integration/step_integration_spec.rb +16 -17
  41. data/spec/integration/table_integration_spec.rb +8 -8
  42. data/spec/integration/table_row_integration_spec.rb +7 -7
  43. data/spec/integration/tag_integration_spec.rb +6 -6
  44. data/spec/integration/world_integration_spec.rb +2 -2
  45. data/spec/unit/background_unit_spec.rb +2 -2
  46. data/spec/unit/containing_element_unit_specs.rb +2 -2
  47. data/spec/unit/directory_unit_spec.rb +14 -14
  48. data/spec/unit/doc_string_unit_spec.rb +18 -18
  49. data/spec/unit/example_unit_spec.rb +32 -32
  50. data/spec/unit/feature_element_unit_specs.rb +12 -12
  51. data/spec/unit/feature_file_unit_spec.rb +12 -12
  52. data/spec/unit/feature_unit_spec.rb +16 -16
  53. data/spec/unit/nested_element_unit_specs.rb +6 -6
  54. data/spec/unit/nested_unit_spec.rb +5 -5
  55. data/spec/unit/outline_unit_spec.rb +7 -7
  56. data/spec/unit/parsing_unit_spec.rb +4 -4
  57. data/spec/unit/prepopulated_unit_specs.rb +1 -1
  58. data/spec/unit/raw_element_unit_specs.rb +4 -4
  59. data/spec/unit/raw_unit_spec.rb +3 -3
  60. data/spec/unit/row_unit_spec.rb +6 -6
  61. data/spec/unit/scenario_unit_spec.rb +3 -3
  62. data/spec/unit/sourceable_unit_spec.rb +1 -1
  63. data/spec/unit/sourced_element_unit_specs.rb +2 -2
  64. data/spec/unit/step_unit_spec.rb +53 -44
  65. data/spec/unit/table_row_unit_spec.rb +6 -6
  66. data/spec/unit/table_unit_spec.rb +14 -14
  67. data/spec/unit/tag_unit_spec.rb +5 -5
  68. data/spec/unit/taggable_unit_spec.rb +14 -14
  69. data/spec/unit/tagged_element_unit_specs.rb +14 -14
  70. data/spec/unit/test_element_unit_spec.rb +11 -3
  71. data/spec/unit/test_element_unit_specs.rb +5 -5
  72. data/spec/unit/world_unit_spec.rb +26 -26
  73. metadata +26 -5
  74. data/features/step_definitions/spec_steps.rb +0 -18
@@ -18,7 +18,7 @@ describe 'TableRow, Unit' do
18
18
  expect { @element = clazz.new(source) }.to_not raise_error
19
19
 
20
20
  # Sanity check in case instantiation failed in a non-explosive manner
21
- @element.cells.should == ['a', 'row']
21
+ expect(@element.cells).to eq(['a', 'row'])
22
22
  end
23
23
 
24
24
  before(:each) do
@@ -26,24 +26,24 @@ describe 'TableRow, Unit' do
26
26
  end
27
27
 
28
28
  it 'has cells' do
29
- @row.should respond_to(:cells)
29
+ expect(@row.respond_to?(:cells)).to be true
30
30
  end
31
31
 
32
32
  it 'can get and set its cells' do
33
33
  @row.cells = :some_cells
34
- @row.cells.should == :some_cells
34
+ expect(@row.cells).to eq(:some_cells)
35
35
  @row.cells = :some_other_cells
36
- @row.cells.should == :some_other_cells
36
+ expect(@row.cells).to eq(:some_other_cells)
37
37
  end
38
38
 
39
39
  it 'starts with no cells' do
40
- @row.cells.should == []
40
+ expect(@row.cells).to eq([])
41
41
  end
42
42
 
43
43
  context 'table row output edge cases' do
44
44
 
45
45
  it 'is a String' do
46
- @row.to_s.should be_a(String)
46
+ expect(@row.to_s).to be_a(String)
47
47
  end
48
48
 
49
49
  it 'can output an empty table row' do
@@ -17,9 +17,9 @@ describe 'Table, Unit' do
17
17
  expect { @element = clazz.new(source) }.to_not raise_error
18
18
 
19
19
  # Sanity check in case instantiation failed in a non-explosive manner
20
- @element.row_elements.collect { |row| row.cells }.should == [['a table']]
20
+ expect(@element.row_elements.collect { |row| row.cells }).to eq([['a table']])
21
21
  # todo - remove once #contents is no longer supported
22
- @element.contents.should == [['a table']]
22
+ expect(@element.contents).to eq([['a table']])
23
23
  end
24
24
 
25
25
  before(:each) do
@@ -28,35 +28,35 @@ describe 'Table, Unit' do
28
28
 
29
29
  # todo - remove once #contents is no longer supported
30
30
  it 'has contents - #contents' do
31
- @table.should respond_to(:contents)
31
+ expect(@table.respond_to?(:contents)).to be true
32
32
  end
33
33
 
34
34
  # todo - remove once #contents is no longer supported
35
35
  it 'can get and set its contents - #contents, #contents=' do
36
36
  @table.contents = :some_contents
37
- @table.contents.should == :some_contents
37
+ expect(@table.contents).to eq(:some_contents)
38
38
  @table.contents = :some_other_contents
39
- @table.contents.should == :some_other_contents
39
+ expect(@table.contents).to eq(:some_other_contents)
40
40
  end
41
41
 
42
42
  # todo - remove once #contents is no longer supported
43
43
  it 'starts with no contents' do
44
- @table.contents.should == []
44
+ expect(@table.contents).to eq([])
45
45
  end
46
46
 
47
47
  it 'has row elements' do
48
- @table.should respond_to(:row_elements)
48
+ expect(@table.respond_to?(:row_elements)).to be true
49
49
  end
50
50
 
51
51
  it 'can get and set its row elements' do
52
52
  @table.row_elements = :some_row_elements
53
- @table.row_elements.should == :some_row_elements
53
+ expect(@table.row_elements).to eq(:some_row_elements)
54
54
  @table.row_elements = :some_other_row_elements
55
- @table.row_elements.should == :some_other_row_elements
55
+ expect(@table.row_elements).to eq(:some_other_row_elements)
56
56
  end
57
57
 
58
58
  it 'starts with no row elements' do
59
- @table.row_elements.should == []
59
+ expect(@table.row_elements).to eq([])
60
60
  end
61
61
 
62
62
  # todo - remove once #contents is no longer supported
@@ -66,18 +66,18 @@ describe 'Table, Unit' do
66
66
 
67
67
  contents = table.contents
68
68
 
69
- contents.is_a?(Array).should be_true
69
+ expect(contents).to be_a(Array)
70
70
 
71
71
  contents.each do |row|
72
- row.is_a?(Array).should be_true
73
- row.each { |cell| cell.is_a?(String).should be_true }
72
+ expect(row).to be_a(Array)
73
+ row.each { |cell| expect(cell).to be_a(String) }
74
74
  end
75
75
  end
76
76
 
77
77
  context 'table output edge cases' do
78
78
 
79
79
  it 'is a String' do
80
- @table.to_s.should be_a(String)
80
+ expect(@table.to_s).to be_a(String)
81
81
  end
82
82
 
83
83
  it 'can output an empty table' do
@@ -17,7 +17,7 @@ describe 'Tag, Unit' do
17
17
  source = '@a_tag'
18
18
 
19
19
  expect { @element = clazz.new(source) }.to_not raise_error
20
- @element.name.should == '@a_tag'
20
+ expect(@element.name).to eq('@a_tag')
21
21
  end
22
22
 
23
23
  before(:each) do
@@ -26,20 +26,20 @@ describe 'Tag, Unit' do
26
26
 
27
27
 
28
28
  it 'has a name' do
29
- @element.should respond_to(:name)
29
+ expect(@element.respond_to?(:name)).to be true
30
30
  end
31
31
 
32
32
  it 'can get and set its name' do
33
33
  @element.name = :some_name
34
- @element.name.should == :some_name
34
+ expect(@element.name).to eq(:some_name)
35
35
  @element.name = :some_other_name
36
- @element.name.should == :some_other_name
36
+ expect(@element.name).to eq(:some_other_name)
37
37
  end
38
38
 
39
39
  context 'tag output edge cases' do
40
40
 
41
41
  it 'is a String' do
42
- @element.to_s.should be_a(String)
42
+ expect(@element.to_s).to be_a(String)
43
43
  end
44
44
 
45
45
  it 'can output an empty tag' do
@@ -20,25 +20,25 @@ describe 'Taggable, Unit' do
20
20
 
21
21
 
22
22
  it 'has tags' do
23
- @element.should respond_to(:tags)
24
- @element.should respond_to(:tag_elements)
23
+ expect(@element.respond_to?(:tags)).to be true
24
+ expect(@element.respond_to?(:tag_elements)).to be true
25
25
  end
26
26
 
27
27
  it 'can get and set its tags' do
28
28
  @element.tags = :some_tags
29
- @element.tags.should == :some_tags
29
+ expect(@element.tags).to eq(:some_tags)
30
30
  @element.tags = :some_other_tags
31
- @element.tags.should == :some_other_tags
31
+ expect(@element.tags).to eq(:some_other_tags)
32
32
 
33
33
  @element.tag_elements = :some_tag_elements
34
- @element.tag_elements.should == :some_tag_elements
34
+ expect(@element.tag_elements).to eq(:some_tag_elements)
35
35
  @element.tag_elements = :some_other_tag_elements
36
- @element.tag_elements.should == :some_other_tag_elements
36
+ expect(@element.tag_elements).to eq(:some_other_tag_elements)
37
37
  end
38
38
 
39
39
  it 'has applied tags' do
40
- @element.should respond_to(:applied_tags)
41
- @element.should respond_to(:applied_tag_elements)
40
+ expect(@element.respond_to?(:applied_tags)).to be true
41
+ expect(@element.respond_to?(:applied_tag_elements)).to be true
42
42
  end
43
43
 
44
44
  it 'inherits its applied tags from its ancestors' do
@@ -48,8 +48,8 @@ describe 'Taggable, Unit' do
48
48
 
49
49
  @element.parent_element = parent
50
50
 
51
- @element.applied_tags.should == all_parent_tags
52
- @element.applied_tag_elements.should == all_parent_tag_elements
51
+ expect(@element.applied_tags).to eq(all_parent_tags)
52
+ expect(@element.applied_tag_elements).to eq(all_parent_tag_elements)
53
53
  end
54
54
 
55
55
  it 'knows all of its applicable tags' do
@@ -64,15 +64,15 @@ describe 'Taggable, Unit' do
64
64
  @element.tags = own_tags
65
65
  @element.tag_elements = own_tag_elements
66
66
 
67
- @element.all_tags.should == all_parent_tags + own_tags
68
- @element.all_tag_elements.should == all_parent_tag_elements + own_tag_elements
67
+ expect(@element.all_tags).to eq(all_parent_tags + own_tags)
68
+ expect(@element.all_tag_elements).to eq(all_parent_tag_elements + own_tag_elements)
69
69
  end
70
70
 
71
71
  it 'may have no applied tags' do
72
72
  @element.parent_element = :not_a_tagged_object
73
73
 
74
- @element.applied_tags.should == []
75
- @element.applied_tag_elements.should == []
74
+ expect(@element.applied_tags).to eq([])
75
+ expect(@element.applied_tag_elements).to eq([])
76
76
  end
77
77
 
78
78
  end
@@ -7,30 +7,30 @@ shared_examples_for 'a tagged element' do |clazz|
7
7
  end
8
8
 
9
9
  it 'has tags' do
10
- @element.should respond_to(:tags)
11
- @element.should respond_to(:tag_elements)
10
+ expect(@element.respond_to?(:tags)).to be true
11
+ expect(@element.respond_to?(:tag_elements)).to be true
12
12
  end
13
13
 
14
14
  it 'can get and set its tags' do
15
15
  @element.tags = :some_tags
16
- @element.tags.should == :some_tags
16
+ expect(@element.tags).to eq(:some_tags)
17
17
  @element.tags = :some_other_tags
18
- @element.tags.should == :some_other_tags
18
+ expect(@element.tags).to eq(:some_other_tags)
19
19
 
20
20
  @element.tag_elements = :some_tag_elements
21
- @element.tag_elements.should == :some_tag_elements
21
+ expect(@element.tag_elements).to eq(:some_tag_elements)
22
22
  @element.tag_elements = :some_other_tag_elements
23
- @element.tag_elements.should == :some_other_tag_elements
23
+ expect(@element.tag_elements).to eq(:some_other_tag_elements)
24
24
  end
25
25
 
26
26
  it 'starts with no tags' do
27
- @element.tags.should == []
28
- @element.tag_elements.should == []
27
+ expect(@element.tags).to eq([])
28
+ expect(@element.tag_elements).to eq([])
29
29
  end
30
30
 
31
31
  it 'has applied tags' do
32
- @element.should respond_to(:applied_tags)
33
- @element.should respond_to(:applied_tag_elements)
32
+ expect(@element.respond_to?(:applied_tags)).to be true
33
+ expect(@element.respond_to?(:applied_tag_elements)).to be true
34
34
  end
35
35
 
36
36
  it 'inherits its applied tags from its ancestors' do
@@ -40,8 +40,8 @@ shared_examples_for 'a tagged element' do |clazz|
40
40
 
41
41
  @element.parent_element = parent
42
42
 
43
- @element.applied_tags.should == all_parent_tags
44
- @element.applied_tag_elements.should == all_parent_tag_elements
43
+ expect(@element.applied_tags).to eq(all_parent_tags)
44
+ expect(@element.applied_tag_elements).to eq(all_parent_tag_elements)
45
45
  end
46
46
 
47
47
  it 'knows all of its applicable tags' do
@@ -56,8 +56,8 @@ shared_examples_for 'a tagged element' do |clazz|
56
56
  @element.tags = own_tags
57
57
  @element.tag_elements = own_tag_elements
58
58
 
59
- @element.all_tags.should == all_parent_tags + own_tags
60
- @element.all_tag_elements.should == all_parent_tag_elements + own_tag_elements
59
+ expect(@element.all_tags).to eq(all_parent_tags + own_tags)
60
+ expect(@element.all_tag_elements).to eq(all_parent_tag_elements + own_tag_elements)
61
61
  end
62
62
 
63
63
  end
@@ -21,7 +21,7 @@ describe 'TestElement, Unit' do
21
21
  steps = [:step_1, :step_2, :step_3]
22
22
  @element.steps = steps
23
23
 
24
- @element.contains.should =~ steps
24
+ expect(@element.contains).to match_array(steps)
25
25
  end
26
26
 
27
27
  it 'can determine its equality with another TestElement - #==' do
@@ -33,8 +33,16 @@ describe 'TestElement, Unit' do
33
33
  element_2.steps = :some_steps
34
34
  element_3.steps = :some_other_steps
35
35
 
36
- (element_1 == element_2).should be_true
37
- (element_1 == element_3).should be_false
36
+ expect(element_1).to eq(element_2)
37
+ expect(element_1).to_not eq(element_3)
38
+ end
39
+
40
+ it 'can gracefully be compared to other types of objects' do
41
+ # Some common types of object
42
+ [1, 'foo', :bar, [], {}].each do |thing|
43
+ expect { @element == thing }.to_not raise_error
44
+ expect(@element == thing).to be false
45
+ end
38
46
  end
39
47
 
40
48
  end
@@ -7,25 +7,25 @@ shared_examples_for 'a test element' do |clazz|
7
7
  end
8
8
 
9
9
  it 'has steps - #steps' do
10
- @element.should respond_to(:steps)
10
+ expect(@element.respond_to?(:steps)).to be true
11
11
  end
12
12
 
13
13
  it 'can get and set its steps - #steps, #steps=' do
14
14
  @element.steps = :some_steps
15
- @element.steps.should == :some_steps
15
+ expect(@element.steps).to eq(:some_steps)
16
16
  @element.steps = :some_other_steps
17
- @element.steps.should == :some_other_steps
17
+ expect(@element.steps).to eq(:some_other_steps)
18
18
  end
19
19
 
20
20
  it 'starts with no steps' do
21
- @element.steps.should == []
21
+ expect(@element.steps).to eq([])
22
22
  end
23
23
 
24
24
  it 'contains steps - #contains' do
25
25
  steps = [:step_1, :step_2, :step_3]
26
26
  @element.steps = steps
27
27
 
28
- steps.each { |step| @element.contains.should include(step) }
28
+ steps.each { |step| expect(@element.contains).to include(step) }
29
29
  end
30
30
 
31
31
  end
@@ -11,49 +11,49 @@ describe 'World, Unit' do
11
11
  end
12
12
 
13
13
  it 'has left and right delimiters used for step argument parsing - #left_delimiter, #right_delimiter' do
14
- @world.should respond_to(:left_delimiter)
15
- @world.should respond_to(:right_delimiter)
14
+ expect(@world.respond_to?(:left_delimiter)).to be true
15
+ expect(@world.respond_to?(:right_delimiter)).to be true
16
16
  end
17
17
 
18
18
  it 'can get and set the delimiters used for step argument parsing' do
19
19
  @world.left_delimiter = '"'
20
20
  @world.right_delimiter = '"'
21
- @world.left_delimiter.should == '"'
22
- @world.right_delimiter.should == '"'
21
+ expect(@world.left_delimiter).to eq('"')
22
+ expect(@world.right_delimiter).to eq('"')
23
23
 
24
24
  @world.left_delimiter = '!'
25
25
  @world.right_delimiter = '!'
26
- @world.left_delimiter.should == '!'
27
- @world.right_delimiter.should == '!'
26
+ expect(@world.left_delimiter).to eq('!')
27
+ expect(@world.right_delimiter).to eq('!')
28
28
  end
29
29
 
30
30
  it 'can have different left and right delimiters' do
31
31
  @world.left_delimiter = '"'
32
32
  @world.right_delimiter = '*'
33
33
 
34
- (@world.left_delimiter != @world.right_delimiter).should be_true
34
+ expect(@world.left_delimiter).to_not eq(@world.right_delimiter)
35
35
  end
36
36
 
37
37
  it 'can set both of its delimiters at once - #delimiter=' do
38
38
  @world.delimiter = '*'
39
39
 
40
- @world.left_delimiter.should == '*'
41
- @world.right_delimiter.should == '*'
40
+ expect(@world.left_delimiter).to eq('*')
41
+ expect(@world.right_delimiter).to eq('*')
42
42
  end
43
43
 
44
44
  it 'starts with no delimiters' do
45
- @world.left_delimiter.should == nil
46
- @world.right_delimiter.should == nil
45
+ expect(@world.left_delimiter).to be_nil
46
+ expect(@world.right_delimiter).to be_nil
47
47
  end
48
48
 
49
49
  context 'step patterns' do
50
50
 
51
51
  it 'can load step patterns - #load_step_pattern' do
52
- @world.should respond_to(:load_step_pattern)
52
+ expect(@world.respond_to?(:load_step_pattern)).to be true
53
53
  end
54
54
 
55
55
  it 'starts with no patterns loaded' do
56
- @world.loaded_step_patterns.should == []
56
+ expect(@world.loaded_step_patterns).to eq([])
57
57
  end
58
58
 
59
59
  it 'keeps track of loaded step patterns - #loaded_step_patterns' do
@@ -63,7 +63,7 @@ describe 'World, Unit' do
63
63
  @world.load_step_pattern(pattern)
64
64
  end
65
65
 
66
- @world.loaded_step_patterns.should =~ patterns
66
+ expect(@world.loaded_step_patterns).to match_array(patterns)
67
67
  end
68
68
 
69
69
  it 'can load step definition files - #load_step_file' do
@@ -78,7 +78,7 @@ describe 'World, Unit' do
78
78
 
79
79
  @world.load_step_file(file_path)
80
80
 
81
- @world.loaded_step_patterns.should =~ patterns
81
+ expect(@world.loaded_step_patterns).to match_array(patterns)
82
82
  end
83
83
 
84
84
  it 'can handle different step keywords - #load_step_file' do
@@ -95,7 +95,7 @@ describe 'World, Unit' do
95
95
 
96
96
  @world.load_step_file(file_path)
97
97
 
98
- @world.loaded_step_patterns.should =~ patterns
98
+ expect(@world.loaded_step_patterns).to match_array(patterns)
99
99
  end
100
100
 
101
101
  it 'can handle a variety of declaration structures - #load_step_file' do
@@ -110,7 +110,7 @@ describe 'World, Unit' do
110
110
 
111
111
  @world.load_step_file(file_path)
112
112
 
113
- @world.loaded_step_patterns.should =~ patterns
113
+ expect(@world.loaded_step_patterns).to match_array(patterns)
114
114
  end
115
115
 
116
116
  it 'can clear its loaded step patterns - #clear_step_patterns' do
@@ -120,9 +120,9 @@ describe 'World, Unit' do
120
120
  @world.load_step_pattern(pattern)
121
121
  end
122
122
 
123
- @world.loaded_step_patterns.should =~ patterns
123
+ expect(@world.loaded_step_patterns).to match_array(patterns)
124
124
  @world.clear_step_patterns
125
- @world.loaded_step_patterns.should == []
125
+ expect(@world.loaded_step_patterns).to eq([])
126
126
  end
127
127
 
128
128
  end
@@ -138,43 +138,43 @@ describe 'World, Unit' do
138
138
  nested_container = double(:tags => @set_2, :tag_elements => @set_2)
139
139
  container = double(:tags => @set_1, :tag_elements => @set_1, :contains => [nested_container])
140
140
 
141
- @world.tags_in(container).should =~ (@set_1 + @set_2)
142
- @world.tag_elements_in(container).should =~ (@set_1 + @set_2)
141
+ expect(@world.tags_in(container)).to match_array((@set_1 + @set_2))
142
+ expect(@world.tag_elements_in(container)).to match_array((@set_1 + @set_2))
143
143
  end
144
144
 
145
145
  it 'can collect directories from containers' do
146
146
  nested_container = double(:directories => @set_2)
147
147
  container = double(:directories => @set_1, :contains => [nested_container])
148
148
 
149
- @world.directories_in(container).should =~ (@set_1 + @set_2)
149
+ expect(@world.directories_in(container)).to match_array((@set_1 + @set_2))
150
150
  end
151
151
 
152
152
  it 'can collect feature files from containers' do
153
153
  nested_container = double(:feature_files => @set_2)
154
154
  container = double(:feature_files => @set_1, :contains => [nested_container])
155
155
 
156
- @world.feature_files_in(container).should =~ (@set_1 + @set_2)
156
+ expect(@world.feature_files_in(container)).to match_array((@set_1 + @set_2))
157
157
  end
158
158
 
159
159
  it 'can collect features from containers' do
160
160
  nested_container = double(:features => @set_2)
161
161
  container = double(:features => @set_1, :contains => [nested_container])
162
162
 
163
- @world.features_in(container).should =~ (@set_1 + @set_2)
163
+ expect(@world.features_in(container)).to match_array((@set_1 + @set_2))
164
164
  end
165
165
 
166
166
  it 'can collect tests from containers' do
167
167
  nested_container = double(:tests => @set_2)
168
168
  container = double(:tests => @set_1, :contains => [nested_container])
169
169
 
170
- @world.tests_in(container).should =~ (@set_1 + @set_2)
170
+ expect(@world.tests_in(container)).to match_array((@set_1 + @set_2))
171
171
  end
172
172
 
173
173
  it 'can collect steps from containers' do
174
174
  nested_container = double(:steps => @set_2)
175
175
  container = double(:steps => @set_1, :contains => [nested_container])
176
176
 
177
- @world.steps_in(container).should =~ (@set_1 + @set_2)
177
+ expect(@world.steps_in(container)).to match_array((@set_1 + @set_2))
178
178
  end
179
179
 
180
180
  end