allure-rspec 2.28.0 → 2.29.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.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA256:
3
- metadata.gz: 976bbb8464540667897631469bd8ae7b9e995a4174b4120d361ffd36f013e9ae
4
- data.tar.gz: 97081c64e4e985873af72034cf704c3fb3c2a3094025fa0830c3c858bc1b1dd2
3
+ metadata.gz: 1daf16ddce69a4fb3af5391c73174d82cbc0bad1c9eb22912596226147b8efaa
4
+ data.tar.gz: 8c9bc6dbcaeeb59ab7d58497509c3e293b7233ee90bbdb75d6a3eaa911e6add6
5
5
  SHA512:
6
- metadata.gz: b377acac69363d54043ace0f5a3daff9acde21d751063933ace20d41b9f158180e4009bddcb0473c94cdd3ae200e57a079f65d4c507884c877fcee9dd88cb0c3
7
- data.tar.gz: 722df27fcaf1094fb6d87a68ab1d5cee2351b299f133536adc3f88494e7cd7099c1e8d87757e64f0e7c336b32c9b3b1f2c5d0c56752ba15b7011e5322c6e1706
6
+ metadata.gz: 5306867b27fcebe608ef909076281600db9edcb676ad362de1eae6ebbd25dca0400fbd9fca1f1b4b8f77801e52603d663b226a3263dca53536d9bf3a826cbebd
7
+ data.tar.gz: ea381a2242110f77d3127a043c58ce7e6814a186d9a56a18ed274ebacd2fecc7f0e68085d7a9b31a73dddc86d82e01e285e6fc5f04b753e3961513fdf517eb61
@@ -108,6 +108,7 @@ module AllureRspec
108
108
  description_html: "Location - #{strip_relative(parser.location)}",
109
109
  history_id: example.id,
110
110
  full_name: example.full_description,
111
+ title_path: parser.title_path,
111
112
  labels: parser.labels,
112
113
  links: parser.links,
113
114
  status_details: parser.status_details,
@@ -67,6 +67,12 @@ module AllureRspec
67
67
  )
68
68
  end
69
69
 
70
+ # Title path without the final example display name.
71
+ # @return [Array<String>]
72
+ def title_path
73
+ [strip_relative(example.file_path), *SuiteLabels.new(example.example_group).title_path]
74
+ end
75
+
70
76
  # Example location
71
77
  #
72
78
  # @return [String]
@@ -13,9 +13,7 @@ module AllureRspec
13
13
  # Get test suite labels
14
14
  # @return [Array<Allure::Label>]
15
15
  def fetch
16
- parents = example_group.parent_groups.map do |group|
17
- group.description.empty? ? "Anonymous" : group.description
18
- end
16
+ parents = parent_groups
19
17
 
20
18
  labels = []
21
19
  labels << Allure::ResultUtils.suite_label(suite(parents))
@@ -25,10 +23,23 @@ module AllureRspec
25
23
  labels
26
24
  end
27
25
 
26
+ # Get title path from outermost group to innermost group.
27
+ # @return [Array<String>]
28
+ def title_path
29
+ parent_groups.reverse
30
+ end
31
+
28
32
  private
29
33
 
30
34
  attr_reader :example_group
31
35
 
36
+ # @return [Array<String>]
37
+ def parent_groups
38
+ @parent_groups ||= example_group.parent_groups.map do |group|
39
+ group.description.empty? ? "Anonymous" : group.description
40
+ end
41
+ end
42
+
32
43
  # @param [Array<String>] parents
33
44
  # @return [String]
34
45
  def suite(parents)
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: allure-rspec
3
3
  version: !ruby/object:Gem::Version
4
- version: 2.28.0
4
+ version: 2.29.0
5
5
  platform: ruby
6
6
  authors:
7
7
  - Andrejs Cunskis
@@ -15,14 +15,14 @@ dependencies:
15
15
  requirements:
16
16
  - - '='
17
17
  - !ruby/object:Gem::Version
18
- version: 2.28.0
18
+ version: 2.29.0
19
19
  type: :runtime
20
20
  prerelease: false
21
21
  version_requirements: !ruby/object:Gem::Requirement
22
22
  requirements:
23
23
  - - '='
24
24
  - !ruby/object:Gem::Version
25
- version: 2.28.0
25
+ version: 2.29.0
26
26
  - !ruby/object:Gem::Dependency
27
27
  name: rspec-core
28
28
  requirement: !ruby/object:Gem::Requirement