|
| 1 | +name: Test Agent with Target |
| 2 | + |
| 3 | +on: |
| 4 | + workflow_dispatch: |
| 5 | + inputs: |
| 6 | + integration: |
| 7 | + required: true |
| 8 | + description: Integration (target) to test, e.g. "apache", "kafka_consumer" |
| 9 | + type: string |
| 10 | + environment: |
| 11 | + required: false |
| 12 | + description: Environment to test, e.g. "py3.12". By default runs all |
| 13 | + default: "" |
| 14 | + type: string |
| 15 | + test-py3: |
| 16 | + required: false |
| 17 | + description: Run Python 3 tests |
| 18 | + default: true |
| 19 | + type: boolean |
| 20 | + agent-image: |
| 21 | + required: false |
| 22 | + description: Agent 7 image |
| 23 | + default: "datadog/agent:7-rc" |
| 24 | + type: string |
| 25 | + agent-image-windows: |
| 26 | + required: false |
| 27 | + description: Agent 7 image on Windows |
| 28 | + default: "datadog/agent:7-rc-servercore" |
| 29 | + type: string |
| 30 | + test-py2: |
| 31 | + required: false |
| 32 | + description: Run Python 2 tests |
| 33 | + default: true |
| 34 | + type: boolean |
| 35 | + agent-image-py2: |
| 36 | + required: false |
| 37 | + description: Agent 6 image |
| 38 | + default: "datadog/agent:6-rc" |
| 39 | + type: string |
| 40 | + agent-image-windows-py2: |
| 41 | + required: false |
| 42 | + description: Agent 6 image on Windows |
| 43 | + default: "datadog/agent-dev:master-py2-win-servercore" |
| 44 | + type: string |
| 45 | + platform: |
| 46 | + required: true |
| 47 | + description: Platform to run tests on |
| 48 | + default: linux |
| 49 | + type: choice |
| 50 | + options: |
| 51 | + - linux |
| 52 | + - windows |
| 53 | + - macos |
| 54 | + |
| 55 | +jobs: |
| 56 | + test: |
| 57 | + uses: ./.github/workflows/test-target.yml |
| 58 | + with: |
| 59 | + repo: core |
| 60 | + |
| 61 | + job-name: ${{ inputs.platform }}-${{ inputs.integration }} |
| 62 | + platform: ${{ inputs.platform }} |
| 63 | + runner: ${{ inputs.platform == 'linux' && '["ubuntu-22.04"]' || inputs.platform == 'windows' && '["windows-2022"]' || '["macos-13"]' }} |
| 64 | + |
| 65 | + target: ${{ inputs.integration }} |
| 66 | + |
| 67 | + # Options |
| 68 | + test-py2: ${{ inputs.test-py2 }} |
| 69 | + test-py3: ${{ inputs.test-py3 }} |
| 70 | + agent-image: "${{ inputs.agent-image }}" |
| 71 | + agent-image-py2: "${{ inputs.agent-image-py2 }}" |
| 72 | + agent-image-windows: "${{ inputs.agent-image-windows }}" |
| 73 | + agent-image-windows-py2: "${{ inputs.agent-image-windows-py2 }}" |
| 74 | + target-env: ${{ inputs.environment }} |
| 75 | + secrets: inherit |
| 76 | + permissions: |
| 77 | + # needed for codecov in test-target.yml, allows the action to get a JWT signed by Github |
| 78 | + id-token: write |
| 79 | + # needed for compute-matrix in test-target.yml |
| 80 | + contents: read |
| 81 | + |
| 82 | + submit-traces: |
| 83 | + needs: |
| 84 | + - test |
| 85 | + if: success() || failure() |
| 86 | + |
| 87 | + uses: ./.github/workflows/submit-traces.yml |
| 88 | + secrets: inherit |
0 commit comments