Skip to content

Commit

Permalink
chore(green-coding-solutions#7): surround if condition with single qu…
Browse files Browse the repository at this point in the history
…otes
  • Loading branch information
jreimone committed Apr 14, 2023
1 parent 26dab9f commit 163e208
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions .github/workflows/data-json-test.yml
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@ on:
- introduce-measurement-output # for testing purposes only on this branch

jobs:
test-action:
test-data-output-action:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v3
Expand Down Expand Up @@ -40,7 +40,7 @@ jobs:
if [ '${{ steps.data-node-setup.outputs.data-lap-json }}' == '' ]; then
echo "Output must not be empty"; exit 1;
fi
if [ "$(echo '${{ steps.data-node-setup.outputs.data-lap-json }}' | jq -e 'has("repository", "branch", "workflow", "run_id", "label", "cpu_avg_percent", "energy_joules", "power_avg_watts") | if . then 1 else 0 end')" -eq 1 ]; then
if [ '$(echo '${{ steps.data-node-setup.outputs.data-lap-json }}' | jq -e 'has("repository", "branch", "workflow", "run_id", "label", "cpu_avg_percent", "energy_joules", "power_avg_watts") | if . then 1 else 0 end')' -eq 1 ]; then
echo "output has correct structure"
else
echo "output has wrong structure"
Expand Down

0 comments on commit 163e208

Please sign in to comment.