Skip to content

Commit d9a7cdb

Browse files
committed
tag investigation
1 parent 2eab68a commit d9a7cdb

File tree

1 file changed

+5
-24
lines changed

1 file changed

+5
-24
lines changed

.github/workflows/test-square.yml

Lines changed: 5 additions & 24 deletions
Original file line numberDiff line numberDiff line change
@@ -317,30 +317,11 @@ jobs:
317317
token: ${{ secrets.ORG_GH_TOKEN }}
318318
fetch-depth: 0
319319
sparse-checkout: tests/ui
320-
- name: Choosing test code branch
321-
working-directory: tyk-analytics/tests/ui
322-
run: |
323-
if [[ ${{ github.event_name }} == "pull_request" ]]; then
324-
PR_BRANCH=${{ github.event.pull_request.head.ref }}
325-
TARGET_BRANCH=${{ github.event.pull_request.base.ref }}
326-
echo "Looking for PR_BRANCH:$PR_BRANCH or TARGET_BRANCH:$TARGET_BRANCH..."
327-
if git rev-parse --verify "origin/$PR_BRANCH" >/dev/null 2>&1; then
328-
echo "PR branch $PR_BRANCH exists. Checking out..."
329-
git checkout "$PR_BRANCH"
330-
elif git rev-parse --verify "origin/$TARGET_BRANCH" >/dev/null 2>&1; then
331-
echo "Target branch $TARGET_BRANCH exists. Checking out..."
332-
git checkout "$TARGET_BRANCH"
333-
fi
334-
fi
335-
if [[ ${{ github.event_name }} == "push" ]]; then
336-
PUSH_BRANCH=${{ github.ref_name }}
337-
echo "Looking for PUSH_BRANCH:$PUSH_BRANCH..."
338-
if git rev-parse --verify "origin/$PUSH_BRANCH" >/dev/null 2>&1; then
339-
echo "Push branch $PUSH_BRANCH exists. Checking out..."
340-
git checkout "$PUSH_BRANCH"
341-
fi
342-
fi
343-
echo "Current commit: $(git rev-parse HEAD)"
320+
- name: Choose test code branch
321+
uses: TykTechnologies/github-actions/.github/actions/tests/choose-test-branch@improve_choose_test_branch_action_for_tag
322+
with:
323+
test_folder: ui
324+
org_gh_token: ${{ secrets.ORG_GH_TOKEN }}
344325
- name: Install Node.js 18.16
345326
uses: actions/setup-node@v4
346327
with:

0 commit comments

Comments
 (0)