dradis-html_export 5.1.0 → 5.2.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: e11b7a5f3544a839e6cdd2486212e6a549999fb1a95bcbfa556cecf02351d790
4
- data.tar.gz: 979166350c1e2dbce8eb8fafdd8e262086e04087d8fd0a5e4a2c794d759b6053
3
+ metadata.gz: da3de9ef6789e2ba0c0f4dbfd052d638c0f1cbc55d302b943eaa475b200cc3f7
4
+ data.tar.gz: 953e29ffaf6423c8078e24d788d074a0d5c1d879b69d38b6fbf563a67074f5e3
5
5
  SHA512:
6
- metadata.gz: 149d902049340b0e7658e0db4601ce4836143ec9ed066cd0d8dcb8c30b269929b523b280ccef07dab62276e1a36d9dd314f524e6fde997e4be107017998ed172
7
- data.tar.gz: 2dfe643713c67ddc8082c03a9c7517fbe042a1d371108d29090ae7a51fe823c077750b8827663608bdf2d7c171be55d04763594e6c8c6a4d8314dfe65dac8d45
6
+ metadata.gz: f23f91e59ebe0492a25ec1d47370cfb948dad44a8a795b03b1bcfce7739bbbd215a80483636628158f5498639448213588038946ff2f03ea25760d9a1bf08345
7
+ data.tar.gz: 0d9d87c2fca2b4d28614a8208f3e1c78f2fcc29f89c2c8de6b548e6e483a7bc879fb8a28c53d60a5ac709baa8ff174b56885b675994b9d6349a1caea1889bf4a
data/CHANGELOG.md CHANGED
@@ -1,3 +1,6 @@
1
+ v5.2.0 (June 2026)
2
+ - No changes
3
+
1
4
  v5.1.0 (May 2026)
2
5
  - No changes
3
6
 
@@ -16,7 +16,7 @@ module Dradis
16
16
  private
17
17
  def log_report
18
18
  logger.debug { "Report title: #{title}" }
19
- logger.debug { "Template properties define a sort field: #{sort_field}" }
19
+ logger.debug { "Template properties define sort fields: #{template_properties&.sort_fields}" }
20
20
 
21
21
  if issues&.any?
22
22
  logger.debug { "Found #{issues.count} issues affecting #{nodes.count} nodes" }
@@ -51,21 +51,17 @@ module Dradis
51
51
  end
52
52
  end
53
53
 
54
- def sort_field
55
- @sort_field ||= begin
54
+ def template_properties
55
+ @template_properties ||= begin
56
56
  template_path = options.fetch(:template)
57
- properties = ::ReportTemplateProperties.find_by_template_file(File.basename(template_path)) rescue nil
58
- properties&.sort_field
57
+ ::ReportTemplateProperties.find_by_template_file(File.basename(template_path)) rescue nil
59
58
  end
60
59
  end
61
60
 
62
61
  def sort_issues(unsorted_issues)
63
- return unsorted_issues unless unsorted_issues.any? && sort_field
62
+ return unsorted_issues unless unsorted_issues.any? && template_properties
64
63
 
65
- # FIXME: Assume the Field :type is :number, so cast .to_f and sort
66
- unsorted_issues.sort do |a, b|
67
- b.fields.fetch(sort_field, '0').to_f <=> a.fields.fetch(sort_field, '0').to_f
68
- end
64
+ template_properties.sort_issues(unsorted_issues)
69
65
  end
70
66
 
71
67
  def tags
@@ -8,7 +8,7 @@ module Dradis
8
8
 
9
9
  module VERSION
10
10
  MAJOR = 5
11
- MINOR = 1
11
+ MINOR = 2
12
12
  TINY = 0
13
13
  PRE = nil
14
14
 
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: dradis-html_export
3
3
  version: !ruby/object:Gem::Version
4
- version: 5.1.0
4
+ version: 5.2.0
5
5
  platform: ruby
6
6
  authors:
7
7
  - Daniel Martin