From a710ae39b049e57bbf816c1aab1fbdd12db48d01 Mon Sep 17 00:00:00 2001 From: Camden Moors <66680985+camdenmoors@users.noreply.github.com> Date: Mon, 9 Aug 2021 15:14:56 -0400 Subject: [PATCH] Use single quotes in switch case Signed-off-by: Camden Moors <66680985+camdenmoors@users.noreply.github.com> --- .rubocop.yml | 2 ++ lib/heimdall_tools/nessus_mapper.rb | 8 ++++---- 2 files changed, 6 insertions(+), 4 deletions(-) diff --git a/.rubocop.yml b/.rubocop.yml index de3f712..05bec0e 100644 --- a/.rubocop.yml +++ b/.rubocop.yml @@ -27,6 +27,8 @@ Style/NumericLiterals: MinDigits: 10 Metrics/ModuleLength: Enabled: false +Metrics/ClassLength: + Enabled: false Style/PercentLiteralDelimiters: PreferredDelimiters: '%': '{}' diff --git a/lib/heimdall_tools/nessus_mapper.rb b/lib/heimdall_tools/nessus_mapper.rb index dcca4bc..3a8d8f9 100644 --- a/lib/heimdall_tools/nessus_mapper.rb +++ b/lib/heimdall_tools/nessus_mapper.rb @@ -94,11 +94,11 @@ def finding(issue, timestamp) finding = {} if issue['compliance-result'] case issue['compliance-result'] - when "PASSED" + when 'PASSED' finding['status'] = 'passed' - when "FAILED" - finding['status'] = 'failed' - when "WARNING" + when 'ERROR' + finding['status'] = 'error' + when 'WARNING' finding['status'] = 'skipped' else finding['status'] = 'failed'