foreman_openscap 12.0.2 → 12.1.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 +4 -4
- data/app/controllers/concerns/foreman_openscap/arf_reports_controller_common_extensions.rb +1 -1
- data/app/views/scap_contents/index.html.erb +1 -1
- data/app/views/tailoring_files/index.html.erb +1 -1
- data/lib/foreman_openscap/version.rb +1 -1
- data/test/functional/arf_reports_controller_test.rb +5 -0
- metadata +1 -1
checksums.yaml
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
---
|
|
2
2
|
SHA256:
|
|
3
|
-
metadata.gz:
|
|
4
|
-
data.tar.gz:
|
|
3
|
+
metadata.gz: ca23fa624c9f49705a71e43b0c62e3fcc80b8039b9843d7d11e546f9bd72ff1b
|
|
4
|
+
data.tar.gz: b1ddf80d084339947d1b24dd42f804c5d2eeef2be29c474427812ff35062d5a3
|
|
5
5
|
SHA512:
|
|
6
|
-
metadata.gz:
|
|
7
|
-
data.tar.gz:
|
|
6
|
+
metadata.gz: 1b440a9f71acd4c75255793a236c1f83c33534b8090ba47f2c5b7c93bc5897ea21b4a3ca05083c9af8f2c606583bb91d268cfde712705c453026001bcfc4c9d9
|
|
7
|
+
data.tar.gz: fc7a5874aaedd3ebce99914330aa3273c7241e449fde82c8f57d181f0f3df73f72e9432ad26dc44aedb8bf93019f27619647018be37ccaeb464fe6ff5ff1d461
|
|
@@ -2,7 +2,7 @@ module ForemanOpenscap
|
|
|
2
2
|
module ArfReportsControllerCommonExtensions
|
|
3
3
|
extend ActiveSupport::Concern
|
|
4
4
|
def format_filename
|
|
5
|
-
"#{@arf_report.
|
|
5
|
+
"#{@arf_report.host.name}-#{@arf_report.reported_at.to_formatted_s(:number)}"
|
|
6
6
|
end
|
|
7
7
|
end
|
|
8
8
|
end
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
<% title _("SCAP Contents") %>
|
|
2
2
|
|
|
3
3
|
<% title_actions(display_link_if_authorized(_("Upload New SCAP Content"), hash_for_new_scap_content_path, :class => 'btn btn-primary'),
|
|
4
|
-
scap_doc_button('
|
|
4
|
+
scap_doc_button('configuring-scap-contents-for-compliance-policies-in-foreman')) %>
|
|
5
5
|
|
|
6
6
|
<%= render :partial => 'list' %>
|
|
@@ -1,4 +1,4 @@
|
|
|
1
1
|
<% title _("Tailoring Files") %>
|
|
2
2
|
<% title_actions(display_link_if_authorized(_("Upload New Tailoring file"), hash_for_new_tailoring_file_path, :class => 'btn btn-primary'),
|
|
3
|
-
scap_doc_button('
|
|
3
|
+
scap_doc_button('customizing-xccdf-profiles-with-tailoring-files')) %>
|
|
4
4
|
<%= render :partial => 'list' %>
|
|
@@ -34,6 +34,11 @@ class ArfReportsControllerTest < ActionController::TestCase
|
|
|
34
34
|
arf_report = FactoryBot.create(:arf_report, :host_id => @host.id)
|
|
35
35
|
report_html = File.read("#{ForemanOpenscap::Engine.root}/test/files/arf_report/arf_report.html")
|
|
36
36
|
ForemanOpenscap::ArfReport.any_instance.stubs(:to_html).returns(report_html)
|
|
37
|
+
refute arf_report.asset.nil?
|
|
38
|
+
get :download_html, :params => { :id => arf_report.id }, :session => set_session_user
|
|
39
|
+
assert_equal report_html, @response.body
|
|
40
|
+
|
|
41
|
+
arf_report.asset.destroy
|
|
37
42
|
get :download_html, :params => { :id => arf_report.id }, :session => set_session_user
|
|
38
43
|
assert_equal report_html, @response.body
|
|
39
44
|
end
|