Skip to content

PR Checks for trunk-merge/pr-119944/98335937-b05c-404b-a5c5-20e128870d52 #170664

PR Checks for trunk-merge/pr-119944/98335937-b05c-404b-a5c5-20e128870d52

PR Checks for trunk-merge/pr-119944/98335937-b05c-404b-a5c5-20e128870d52 #170664

Workflow file for this run

# trunk-ignore-all(semgrep/yaml.github-actions.security.third-party-action-not-pinned-to-commit-sha.third-party-action-not-pinned-to-commit-sha)
name: PR Testing
run-name: PR Checks for ${{ github.ref_name }}
on:
pull_request: {}
push:
branches:
- trunk-merge/**
jobs:
test:
name: run tests to validate pr
runs-on: ubicloud
env:
BRANCH_NAME: ${{ github.head_ref || github.ref_name }}
steps:
- name: Checkout code
uses: actions/checkout@v4
- uses: robinraju/release-downloader@v1.9
with:
repository: trunk-io/mergequeue-tool
latest: true
tarBall: true
preRelease: true
extract: true
- name: Determine is_merge
id: check_is_merge
run: |
if [[ ${GITHUB_EVENT_NAME} == "push" && (${GITHUB_REF_NAME} == trunk-merge/* || ${GITHUB_REF_NAME} == trunk-merge-beta/*) || "${{ github.event.pull_request.title }}" == trunk-merge/* ]]; then
echo "on_merge=true" >> $GITHUB_OUTPUT
else
echo "on_merge=false" >> $GITHUB_OUTPUT
fi
- name: run tests
id: test
# only actually run the test if we're on the merge branch
# so we can simulate delay and flakiness
if: steps.check_is_merge.outputs.on_merge == 'true'
run: |
./mq test-sim
env:
IS_MERGE: ${{ steps.check_is_merge.outputs.on_merge }}