Skip to content

Commit

Permalink
Occurrences -> Findings, update to 2023.3 release
Browse files Browse the repository at this point in the history
  • Loading branch information
KocsisV committed Nov 16, 2023
1 parent be9367b commit 2682435
Showing 1 changed file with 14 additions and 14 deletions.
28 changes: 14 additions & 14 deletions action.yml
Original file line number Diff line number Diff line change
Expand Up @@ -47,7 +47,7 @@ runs:
{
echo "IncQuery Validator for Enterprise Architect will be installed."
echo "need_to_install=true" >> $env:GITHUB_OUTPUT
echo "download_url=https://build.incquerylabs.com/nexus/repository/lieberlieber-collaboration-raw/validator-for-ea/release-2023.2.1/IncQuery%20Validator%20for%20Enterprise%20Architect%202023.2.1%20Setup.exe" >> $env:GITHUB_OUTPUT
echo "download_url=https://build.incquerylabs.com/nexus/repository/lieberlieber-collaboration-raw/validator-for-ea/release-2023.3.0/IncQuery%20Validator%20for%20Enterprise%20Architect%202023.3.0%20Setup.exe" >> $env:GITHUB_OUTPUT
echo "installer_path=${{ runner.temp }}/IncQuery Validator for Enterprise Architect Setup.exe" >> $env:GITHUB_OUTPUT
}
Expand Down Expand Up @@ -145,7 +145,7 @@ runs:
{
$msg += "The following type of issues were detected:`r`n"
$msg += "| | Level | Occurrences |`r`n"
$msg += "| | Level | Findings |`r`n"
$msg += "| --- | ------------- | ------------- |`r`n"
if ( $fatals -ne 0 ) { $msg += "| :no_entry: | Fatal | $fatals |`r`n" }
if ( $errors -ne 0 ) { $msg += "| :no_entry_sign: | Error | $errors |`r`n" }
Expand All @@ -155,16 +155,16 @@ runs:
$msg += "`r`n"
$numRulesWithOccurrences = ($summary_csv.Where{$_.occurrences -gt 0}).Count
$numRulesWithoutOccurrences = $numRules - $numRulesWithOccurrences
$numRulesWithFindings = ($summary_csv.Where{$_.Findings -gt 0}).Count
$numRulesWithoutFindings = $numRules - $numRulesWithFindings
if ( $numRules -eq $numRulesWithOccurrences )
if ( $numRules -eq $numRulesWithFindings )
{
$msg += "All ($numRules) rules have occurrences in the model.`r`n"
$msg += "All ($numRules) rules have findings in the model.`r`n"
}
else
{
$msg += "Out of the $numRules rules, $numRulesWithOccurrences have occurrences.`r`n"
$msg += "Out of the $numRules rules, $numRulesWithFindings have findings.`r`n"
}
}
else
Expand Down Expand Up @@ -229,27 +229,27 @@ runs:
$summary_message += ">`r`n"
}
$summary_message += ">Only the rules with occurrences are shown.`r`n`r`n"
$summary_message += ">Only the rules with findings are shown.`r`n`r`n"
if ( "${{ inputs.fail_on }}" -eq "none" )
{
$summary_message += "| Severity | Occurrences | Rule name | Description |`r`n"
$summary_message += "| Severity | Findings | Rule name | Description |`r`n"
$summary_message += "| -------- | ----------- | --------- | ----------- |`r`n"
}
else
{
$summary_message += "| | Severity | Occurrences | Rule name | Description |`r`n"
$summary_message += "| | Severity | Findings | Rule name | Description |`r`n"
$summary_message += "| --- | -------- | ----------- | --------- | ----------- |`r`n"
}
foreach ($rule in $summary_csv)
{
$severity = $rule.Severity
$occurrences = $rule.Occurrences
$numFindings = $rule.Findings
$description = $rule.Description
$ruleName = $rule.'Rule name'
if ( $occurrences -gt 0 )
if ( $numFindings -gt 0 )
{
switch ($severity) {
"FATAL" { $severityNumeric = 5 }
Expand Down Expand Up @@ -278,15 +278,15 @@ runs:
$summary_message += " $marker |"
}
$summary_message += " $severity | $occurrences | $ruleName | $description |`r`n"
$summary_message += " $severity | $numFindings | $ruleName | $description |`r`n"
}
}
$summary_message += "`r`n"
# write out the summary message
echo $msg | Out-File -FilePath $env:GITHUB_STEP_SUMMARY
# only write per rule breakdown if there is any occurrences
# only write per rule breakdown if there is any findings
if ( $sumMinDebugs -gt 0 )
{
echo $summary_message | Out-File -FilePath $env:GITHUB_STEP_SUMMARY -Append
Expand Down

0 comments on commit 2682435

Please sign in to comment.