Sha256: c0f2c0072dda715acb9ea8dc1d643011e8ae9946ec5d8b2009e2ae41df5f8d8b
Contents?: true
Size: 1.22 KB
Versions: 1
Compression:
Stored size: 1.22 KB
Contents
require_relative '../spec_helper.rb' class <%= options[:spec_class_name] %> extend AssessmentHelpers def self.default_test_config { } end end describe <%= options[:spec_class_name] %>, scan_assessment: true do context 'for all targets' do it 'should report results' do expect(@vulnerable_results.size).to be > 0 expect(@secure_results.size).to be > 0 end end context 'for vulnerable machine' do before :each do @result = @vulnerable_results.first end it 'should report a failure' do expect(@result['status']).to eq('fail') end end context 'for secure machine' do before :each do @result = @secure_results.first end it 'should report a passing result' do expect(@result['status']).to eq('pass') end it 'should set the sir rating to no impact' do expect(@result['sir']).to eq('no_impact') end end context 'for machine with all ports closed' do before :each do @result = @base_results.first end it 'should report a passing result' do expect(@result['status']).to eq('pass') end it 'should set the sir rating to no impact' do expect(@result['sir']).to eq('no_impact') end end end
Version data entries
1 entries across 1 versions & 1 rubygems
Version | Path |
---|---|
norad_cli-0.1.0 | lib/norad_cli/templates/tool/tool_spec.rb.erb |