Add more tests #16
Annotations
4 errors
Run rake test:foreman_cve_scanner:
foreman_cve_scanner/test/services/foreman_cve_scanner/cve_report_scanner_test.rb#L38
Failure: test_0004_grype scan has valid data
Expected: 18
Actual: 1
|
Run rake test:foreman_cve_scanner:
foreman_cve_scanner/test/services/foreman_cve_scanner/cve_report_scanner_test.rb#L28
Failure: test_0003_trivy scan has valid data
--- expected
+++ actual
@@ -1 +1 @@
-"CVE-2023-48795: ssh: Prefix truncation attack on Binary Packet Protocol (BPP) # url: https://avd.aquasec.com/nvd/cve-2023-48795"
+"fooo"
|
Run rake test:foreman_cve_scanner:
foreman_cve_scanner/test/services/foreman_cve_scanner/cve_report_scanner_test.rb#L10
Failure: test_0001_should identify as cve scan
NoMethodError: undefined method `assert_equasl' for #<ForemanCveScanner::CveReportScannerTest:0x0000562799c4f1c8 @name="test_0001_should identify as cve scan", @failures=[#<Minitest::UnexpectedError: Unexpected exception>], @assertions=0, @fixture_cache={"users"=>{"admin"=>#<User id: 135138680, login: "secret_admin", firstname: "Admin", lastname: "User", mail: "[email protected]", admin: true, last_login_on: "2009-10-12 21:50:04.000000000 +0000", auth_source_id: 200482051, created_at: "2024-04-08 21:32:56.546822000 +0000", updated_at: "2024-04-08 21:32:56.546822000 +0000", password_hash: [FILTERED], password_salt: [FILTERED], locale: nil, avatar_hash: nil, default_organization_id: nil, default_location_id: nil, lower_login: "secret_admin", mail_enabled: true, timezone: nil, description: nil, disabled: false, password: nil>}}, @fixture_connections=[], @connection_subscriber=#<ActiveSupport::Notifications::Fanout::Subscribers::Timed:0x0000562799c4e1d8 @pattern="!connection.active_record", @DeleGate=#<Proc:0x0000562799c4e318 /home/runner/work/foreman_cve_scanner/foreman_cve_scanner/vendor/bundle/ruby/3.0.0/gems/activerecord-6.1.7.7/lib/active_record/test_fixtures.rb:134>, @can_publish=false>, @legacy_saved_pool_configs={}, @saved_pool_configs={}, @loaded_fixtures={"architectures"=>#<ActiveRecord::FixtureSet:0x0000562796670110 @name="architectures", @path="/home/runner/work/foreman_cve_scanner/foreman_cve_scanner/test/fixtures/architectures", @config=ActiveRecord::Base, @model_class=Architecture(id: integer, name: string, created_at: datetime, updated_at: datetime), @ignored_fixtures=["DEFAULTS"], @fixtures={"x86_64"=>#<ActiveRecord::Fixture:0x000056279665a220 @fixture={"name"=>"x86_64", "created_at"=>2024-04-08 21:32:56.426223981 UTC, "updated_at"=>2024-04-08 21:32:56.426223981 UTC, "id"=>501905019}, @model_class=Architecture(id: integer, name: string, created_at: datetime, updated_at: datetime)>, "sparc"=>#<ActiveRecord::Fixture:0x000056279665a1d0 @fixture={"name"=>"sparc", "created_at"=>2024-04-08 21:32:56.426223981 UTC, "updated_at"=>2024-04-08 21:32:56.426223981 UTC, "id"=>331892513}, @model_class=Architecture(id: integer, name: string, created_at: datetime, updated_at: datetime)>, "s390"=>#<ActiveRecord::Fixture:0x000056279665a1a8 @fixture={"name"=>"s390", "created_at"=>2024-04-08 21:32:56.426223981 UTC, "updated_at"=>2024-04-08 21:32:56.426223981 UTC, "id"=>381564594}, @model_class=Architecture(id: integer, name: string, created_at: datetime, updated_at: datetime)>, "s390x"=>#<ActiveRecord::Fixture:0x000056279665a180 @fixture={"name"=>"s390x", "created_at"=>2024-04-08 21:32:56.426223981 UTC, "updated_at"=>2024-04-08 21:32:56.426223981 UTC, "id"=>820784047}, @model_class=Architecture(id: integer, name: string, created_at: datetime, updated_at: datetime)>, "ASIC"=>#<ActiveRecord::Fixture:0x000056279665a158 @fixture={"name"=>"ASIC", "created_at"=>2024-04-08 21:32:56.426223981 UTC, "updated_at"=>2024-04-08 21:32:56.426223981 UTC, "id"=>578327757}, @model_class=Architecture(id: integer, name: string, created_at: datetime, updated_at: datetime)>, "ppc64"=>#<ActiveRecord::Fixture:0x000056279665a130 @fixture={"name"=>"ppc64", "created_at"=>2024-04-08 21:32:56.426223981 UTC, "updated_at"=>2024-04-08 21:32:56.426223981 UTC, "id"=>922134521}, @model_class=Architecture(id: integer, name: string, created_at: datetime, updated_at: datetime)>}, @table_name="architectures">, "audits"=>#<ActiveRecord::FixtureSet:0x0000562796659e60 @name="audits", @path="/home/runner/work/foreman_cve_scanner/foreman_cve_scanner/test/fixtures/audits", @config=ActiveRecord::Base, @model_class=Audited::Audit(id: integer, auditable_id: integer, auditable_type: string, user_id: integer, user_type: string, username: string, action: string, audited_changes: text, version: integer, comment: string, associated_id: integer, associated_type: string, request_uuid: string, created_at: datetime, remote_address: string, auditable_name: text, associated_name: string), @ignored_fixtures=["DEFAULTS"], @fixtures={"one"=>#<
|
Run rake test:foreman_cve_scanner
Process completed with exit code 1.
|
Loading