Skip to content

Commit

Permalink
Update ccip-load-tests.yml
Browse files Browse the repository at this point in the history
  • Loading branch information
lukaszcl committed Jul 15, 2024
1 parent ee0a766 commit c65ac4b
Show file tree
Hide file tree
Showing 2 changed files with 22 additions and 16 deletions.
4 changes: 2 additions & 2 deletions .github/workflows/ccip-live-network-tests.yml
Original file line number Diff line number Diff line change
Expand Up @@ -18,9 +18,9 @@ on:
- 'load'
- 'smoke'
test_secrets_override_key:
description: 'Key to run tests with custom test secrets. Find more at: https://github.com/smartcontractkit/chainlink-testing-framework/blob/main/config/README.md#run-github-workflow-with-your-test-secrets'
description: 'Key to run tests with custom test secrets'
required: false
type: string
type: string

# Only run 1 of this workflow at a time per PR
concurrency:
Expand Down
34 changes: 20 additions & 14 deletions .github/workflows/ccip-load-tests.yml
Original file line number Diff line number Diff line change
Expand Up @@ -10,6 +10,10 @@ on:
base64_test_input: # base64 encoded toml for test input
description: 'Base64 encoded toml test input'
required: false
test_secrets_override_key:
description: 'Key to run tests with custom test secrets'
required: false
type: string

# Only run 1 of this workflow at a time per PR
concurrency:
Expand Down Expand Up @@ -143,20 +147,19 @@ jobs:
with:
ref: ${{ env.REF_NAME }}
- name: Sets env vars
id: set_override_config
shell: bash
run: |
# if the matrix.type.config_path is set, use it as the override config
if [ -n "${{ matrix.type.config_path }}" ]; then
echo "BASE64_CCIP_CONFIG_OVERRIDE=$(base64 -w 0 -i ${{ matrix.type.config_path }})" >> $GITHUB_ENV
echo "TEST_BASE64_CCIP_CONFIG_OVERRIDE=$(base64 -w 0 -i ${{ matrix.type.config_path }})" >> $GITHUB_ENV
BASE64_CCIP_CONFIG_OVERRIDE=$(base64 -w 0 -i ${{ matrix.type.config_path }})
echo ::add-mask::$BASE64_CCIP_CONFIG_OVERRIDE
echo "base_64_override=$BASE64_CCIP_CONFIG_OVERRIDE" >> $GITHUB_OUTPUT
fi
if [[ "${{ github.event_name }}" == "workflow_dispatch" ]]; then
BASE64_CCIP_CONFIG_OVERRIDE=$(jq -r '.inputs.base64_test_input' $GITHUB_EVENT_PATH)
echo ::add-mask::$BASE64_CCIP_CONFIG_OVERRIDE
if [ -n "${BASE64_CCIP_CONFIG_OVERRIDE}" && "$BASE64_CCIP_CONFIG_OVERRIDE" != "null"]; then
echo "BASE64_CCIP_CONFIG_OVERRIDE=$BASE64_CCIP_CONFIG_OVERRIDE" >> $GITHUB_ENV
echo "TEST_BASE64_CCIP_CONFIG_OVERRIDE=$BASE64_CCIP_CONFIG_OVERRIDE" >> $GITHUB_ENV
fi
echo "base_64_override=$BASE64_CCIP_CONFIG_OVERRIDE" >> $GITHUB_OUTPUT
fi
- name: step summary
shell: bash
Expand All @@ -167,30 +170,27 @@ jobs:
echo "\`${{ env.INPUT_CHAINLINK_TEST_VERSION }}\`" >> $GITHUB_STEP_SUMMARY
- name: Prepare Base64 TOML override for CCIP secrets
uses: ./.github/actions/setup-create-base64-config-ccip
id: setup_create_base64_config_ccip
with:
runId: ${{ github.run_id }}
testLogCollect: ${{ vars.TEST_LOG_COLLECT }}
chainlinkImage: ${{ env.CHAINLINK_IMAGE }}
chainlinkVersion: ${{ github.sha }}
lokiEndpoint: ${{ secrets.LOKI_URL }}
lokiTenantId: ${{ vars.LOKI_TENANT_ID }}
logstreamLogTargets: ${{ vars.LOGSTREAM_LOG_TARGETS }}
grafanaUrl: ${{ vars.GRAFANA_URL }}
grafanaDashboardUrl: "/d/6vjVx-1V8/ccip-long-running-tests"
- name: Run Tests
uses: smartcontractkit/chainlink-github-actions/chainlink-testing-framework/run-tests@b49a9d04744b0237908831730f8553f26d73a94b # v2.3.17
uses: smartcontractkit/chainlink-github-actions/chainlink-testing-framework/run-tests@d38226be720c5ccc1ff4d3cee40608ebf264cd59 # v2.3.26
env:
TEST_SUITE: load
TEST_ARGS: -test.timeout 900h
DATABASE_URL: postgresql://postgres:node@localhost:5432/chainlink_test?sslmode=disable
RR_MEM: 8Gi
RR_CPU: 4
TEST_TRIGGERED_BY: ccip-load-test-ci-${{ matrix.type.name }}
BASE64_CCIP_CONFIG_OVERRIDE: ${{ steps.set_override_config.outputs.base_64_override }},${{ steps.setup_create_base64_config_ccip.outputs.base64_config }}
TEST_BASE64_CCIP_CONFIG_OVERRIDE: ${{ steps.set_override_config.outputs.base_64_override }},${{ steps.setup_create_base64_config_ccip.outputs.base64_config }}
with:
test_command_to_run: cd ./integration-tests/ccip-tests && go test -v -timeout 70m -count=1 -json -run ${{ matrix.type.run }} ./load 2>&1 | tee /tmp/gotest.log | gotestloghelper -ci
test_download_vendor_packages_command: cd ./integration-tests && go mod download
cl_repo: ${{ env.CHAINLINK_IMAGE }}
cl_image_tag: ${{ env.CHAINLINK_VERSION }}
test_secrets_override_base64: ${{ secrets[inputs.test_secrets_override_key] }}
token: ${{ secrets.GITHUB_TOKEN }}
go_mod_path: ./integration-tests/go.mod
QA_AWS_REGION: ${{ secrets.QA_AWS_REGION }}
Expand All @@ -203,6 +203,12 @@ jobs:
cache_key_id: ccip-load-${{ env.MOD_CACHE_VERSION }}
cache_restore_only: "true"
should_cleanup: "true"
DEFAULT_CHAINLINK_IMAGE: ${{ env.CHAINLINK_IMAGE }}
DEFAULT_LOKI_TENANT_ID: ${{ vars.LOKI_TENANT_ID }}
DEFAULT_LOKI_ENDPOINT: ${{ secrets.LOKI_URL }}
DEFAULT_LOKI_BASIC_AUTH: ${{ secrets.LOKI_BASIC_AUTH }}
DEFAULT_GRAFANA_BASE_URL: ${{ vars.GRAFANA_URL }}
DEFAULT_GRAFANA_DASHBOARD_URL: "/d/6vjVx-1V8/ccip-long-running-tests"

# Reporting Jobs
start-slack-thread:
Expand Down

0 comments on commit c65ac4b

Please sign in to comment.