-
Notifications
You must be signed in to change notification settings - Fork 2.1k
71 lines (59 loc) · 2.11 KB
/
integration-test.yml
File metadata and controls
71 lines (59 loc) · 2.11 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
# Integration Test
#
# This workflow is used to run an integration test on demand.
# An input for the test name needs to be provided.
# TODO: check if the input is "all" , and run all, without a timeout?
name: Integration Test
on:
workflow_dispatch:
inputs:
test_name:
description: "Which integration to test."
required: true
type: string
# Workflow-level permissions - read access to repository contents
permissions:
contents: read # Required to checkout code
env:
AXIOM_TOKEN: ${{ secrets.AXIOM_TOKEN }}
TEST_APPSIGNAL_PUSH_API_KEY: ${{ secrets.TEST_APPSIGNAL_PUSH_API_KEY }}
CONTAINER_TOOL: "docker"
DD_ENV: "ci"
RUST_BACKTRACE: full
VECTOR_LOG: vector=debug
VERBOSE: true
CI: true
PROFILE: debug
jobs:
test-integration:
runs-on: ubuntu-24.04
timeout-minutes: 40
permissions:
contents: read
id-token: write
if: inputs.if || github.event_name == 'workflow_dispatch'
steps:
- name: (PR comment) Get PR branch
if: ${{ github.event_name == 'issue_comment' }}
uses: xt0rted/pull-request-comment-branch@e8b8daa837e8ea7331c0003c9c316a64c6d8b0b1 # v3.0.0
id: comment-branch
- name: (PR comment) Checkout PR branch
if: ${{ github.event_name == 'issue_comment' }}
uses: actions/checkout@de0fac2e4500dabe0009e67214ff5f5447ce83dd # v6.0.2
with:
ref: ${{ steps.comment-branch.outputs.head_ref }}
- name: Checkout branch
if: ${{ github.event_name != 'issue_comment' }}
uses: actions/checkout@de0fac2e4500dabe0009e67214ff5f5447ce83dd # v6.0.2
- uses: ./.github/actions/dd-token
- run: bash scripts/environment/prepare.sh --modules=rustup,datadog-ci
- run: make test-integration-${{ inputs.test_name }}
env:
TEST_DATADOG_API_KEY: ${{ secrets.CI_TEST_DATADOG_API_KEY }}
- name: Upload test results
run: scripts/upload-test-results.sh
if: always()
- run: make test-integration-${{ inputs.test_name }}-cleanup
if: ${{ always() }}
env:
TEST_DATADOG_API_KEY: ${{ secrets.CI_TEST_DATADOG_API_KEY }}