diff --git a/.github/workflows/fleet_tests.yml b/.github/workflows/fleet_tests.yml new file mode 100644 index 000000000..a164b9296 --- /dev/null +++ b/.github/workflows/fleet_tests.yml @@ -0,0 +1,34 @@ +name: Waku Fleet Tests + +concurrency: + group: ${{ github.workflow }}-${{ github.event.pull_request.number || github.ref }} + cancel-in-progress: false + +on: + workflow_dispatch: + inputs: + node1: + required: true + description: "Node that usually publishes messages. Used for all tests" + type: string + default: "wakuorg/nwaku:latest" + node2: + required: true + description: "Node that usually queries for published messages. Used for all tests" + type: string + default: "wakuorg/nwaku:latest" + additional_nodes: + required: false + description: "Additional optional nodes used in e2e tests, separated by ," + type: string + default: "wakuorg/nwaku:latest,wakuorg/nwaku:latest,wakuorg/nwaku:latest" + +jobs: + test-common: + uses: ./.github/workflows/test_common.yml + secrets: inherit + with: + node1: ${{ inputs.node1 }} + node2: ${{ inputs.node2 }} + additional_nodes: ${{ inputs.additional_nodes }} + fleet_tests: true diff --git a/.github/workflows/test_common.yml b/.github/workflows/test_common.yml index bee675cf9..6cf58c938 100644 --- a/.github/workflows/test_common.yml +++ b/.github/workflows/test_common.yml @@ -22,6 +22,11 @@ on: required: false description: "Workflow caller. Used in reporting" type: string + fleet_tests: + required: false + description: "Run fleet tests only" + type: boolean + default: false env: FORCE_COLOR: "1" @@ -174,7 +179,15 @@ jobs: export PATH="$HOME/.nimble/bin:$PATH" export PYTHONPATH="$(pwd)/vendor/logos-delivery-python-bindings/waku:$PYTHONPATH" - if [ "${{ matrix.shard }}" == "16" ]; then + if [ "${{ inputs.fleet_tests }}" == "true" ]; then + if [ "${{ matrix.shard }}" == "0" ]; then + pytest --fleet -m waku_test_fleet \ + --ignore=vendor/logos-delivery-python-bindings/tests \ + --alluredir=allure-results-${{ matrix.shard }} + else + echo "Skipping shard ${{ matrix.shard }}: fleet tests run on shard 0 only" + fi + elif [ "${{ matrix.shard }}" == "16" ]; then pytest tests/relay/test_rln.py \ --ignore=vendor/logos-delivery-python-bindings/tests \ --alluredir=allure-results-${{ matrix.shard }}