Skip to content

Commit

Permalink
fix(ci): use better name for protection rules
Browse files Browse the repository at this point in the history
  • Loading branch information
gustavovalverde committed Oct 17, 2023
1 parent e7f6170 commit 77b744d
Show file tree
Hide file tree
Showing 3 changed files with 14 additions and 13 deletions.
6 changes: 3 additions & 3 deletions .github/workflows/cd-deploy-nodes-gcp.yml
Original file line number Diff line number Diff line change
Expand Up @@ -102,7 +102,7 @@ jobs:
needs: build
uses: ./.github/workflows/sub-test-zebra-config.yml
with:
test_id: 'default-conf-tests'
test_id: 'default-conf'
grep_patterns: '-e "net.*=.*Main.*estimated progress to chain tip.*BeforeOverwinter"'
test_variables: '-e NETWORK'
network: 'Mainnet'
Expand All @@ -114,7 +114,7 @@ jobs:
# Make sure Zebra can sync the genesis block on testnet
uses: ./.github/workflows/sub-test-zebra-config.yml
with:
test_id: 'testnet-conf-tests'
test_id: 'testnet-conf'
grep_patterns: '-e "net.*=.*Test.*estimated progress to chain tip.*Genesis" -e "net.*=.*Test.*estimated progress to chain tip.*BeforeOverwinter"'
test_variables: '-e NETWORK -e ZEBRA_CONF_PATH="/etc/zebrad/zebrad.toml"'
network: 'Testnet'
Expand All @@ -125,7 +125,7 @@ jobs:
needs: build
uses: ./.github/workflows/sub-test-zebra-config.yml
with:
test_id: 'variable-conf-tests'
test_id: 'custom-conf'
grep_patterns: '-e "v1.0.0-rc.2.toml"'
test_variables: '-e NETWORK -e ZEBRA_CONF_PATH="zebrad/tests/common/configs/v1.0.0-rc.2.toml"'
network: ${{ inputs.network || vars.ZCASH_NETWORK }}
Expand Down
15 changes: 8 additions & 7 deletions .github/workflows/ci-unit-tests-docker.yml
Original file line number Diff line number Diff line change
Expand Up @@ -209,34 +209,35 @@ jobs:

# Test that Zebra works using the default config with the latest Zebra version.
test-configuration-file:
name: Test Zebra default Docker config file
name: Test default config file
needs: build
uses: ./.github/workflows/sub-test-zebra-config.yml
with:
test_id: 'default-conf-tests'
test_id: 'default-conf'
grep_patterns: '-e "net.*=.*Main.*estimated progress to chain tip.*BeforeOverwinter"'
test_variables: '-e NETWORK'
network: 'Mainnet'

# Test reconfiguring the the docker image for tesnet.
test-configuration-file-testnet:
name: Test Zebra testnet Docker config file
name: Test testnet config file
needs: build
# Make sure Zebra can sync the genesis block on testnet
uses: ./.github/workflows/sub-test-zebra-config.yml
with:
test_id: 'testnet-conf-tests'
test_id: 'testnet-conf'
grep_patterns: '-e "net.*=.*Test.*estimated progress to chain tip.*Genesis" -e "net.*=.*Test.*estimated progress to chain tip.*BeforeOverwinter"'
test_variables: '-e NETWORK -e ZEBRA_CONF_PATH="/etc/zebrad/zebrad.toml"'
# TODO: improve the entrypoint to avoid using `ENTRYPOINT_FEATURES=""`
test_variables: '-e NETWORK -e ZEBRA_CONF_PATH="/etc/zebrad/zebrad.toml" -e ENTRYPOINT_FEATURES=""'
network: 'Testnet'

# Test that Zebra works using $ZEBRA_CONF_PATH config
test-zebra-conf-path:
name: Test Zebra custom Docker config file
name: Test custom config file
needs: build
uses: ./.github/workflows/sub-test-zebra-config.yml
with:
test_id: 'variable-conf-tests'
test_id: 'custom-conf'
grep_patterns: '-e "v1.0.0-rc.2.toml"'
test_variables: '-e NETWORK -e ZEBRA_CONF_PATH="zebrad/tests/common/configs/v1.0.0-rc.2.toml"'
network: ${{ inputs.network || vars.ZCASH_NETWORK }}
Expand Down
6 changes: 3 additions & 3 deletions .github/workflows/sub-test-zebra-config.yml
Original file line number Diff line number Diff line change
Expand Up @@ -25,8 +25,8 @@ on:
description: 'Zcash network to test against'

jobs:
test-zebra-config:
name: Test Zebra Docker Config
test-docker-config:
name: Test ${{ inputs.test_id }} in Docker
timeout-minutes: 15
runs-on: ubuntu-latest
steps:
Expand All @@ -41,7 +41,7 @@ jobs:

- uses: r7kamura/[email protected]

- name: Run ${{ inputs.test_id }} config test
- name: Run ${{ inputs.test_id }} test
run: |

Check warning on line 45 in .github/workflows/sub-test-zebra-config.yml

View workflow job for this annotation

GitHub Actions / actionlint

[actionlint] .github/workflows/sub-test-zebra-config.yml#L45

shellcheck reported issue in this script: SC2086:info:23:10: Double quote to prevent globbing and word splitting [shellcheck]
Raw output
.github/workflows/sub-test-zebra-config.yml:45:9: shellcheck reported issue in this script: SC2086:info:23:10: Double quote to prevent globbing and word splitting [shellcheck]
docker pull ${{ vars.GAR_BASE }}/${{ vars.CI_IMAGE_NAME }}:sha-${{ env.GITHUB_SHA_SHORT }}
docker run ${{ inputs.test_variables }} --detach --name ${{ inputs.test_id }} -t ${{ vars.GAR_BASE }}/${{ vars.CI_IMAGE_NAME }}:sha-${{ env.GITHUB_SHA_SHORT }} zebrad start
Expand Down

0 comments on commit 77b744d

Please sign in to comment.