Skip to content

Commit fd28477

Browse files
test token authenticator
1 parent d7e53ac commit fd28477

File tree

1 file changed

+45
-0
lines changed

1 file changed

+45
-0
lines changed

.github/workflows/famedly-tests.yml

Lines changed: 45 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -405,6 +405,50 @@ jobs:
405405
working-directory: synapse-invite-checker
406406
run: hatch run cov
407407

408+
token-authenticator:
409+
if: ${{ !failure() && !cancelled() }}
410+
needs:
411+
- linting-done
412+
runs-on: ubuntu-latest
413+
414+
steps:
415+
- name: Checkout synapse
416+
uses: actions/checkout@v4
417+
418+
- name: Checkout synapse-token-authenticator
419+
uses: actions/checkout@v4
420+
with:
421+
repository: famedly/synapse-token-authenticator
422+
path: synapse-token-authenticator
423+
424+
- name: Setup Python
425+
uses: actions/setup-python@v5
426+
with:
427+
python-version: "3.13"
428+
429+
- name: Install hatch
430+
run: pip install hatch
431+
432+
- name: Determine synapse git ref
433+
id: synapse-ref
434+
run: |
435+
if [ "${{ github.event_name }}" == "pull_request" ]; then
436+
echo "ref=${{ github.event.pull_request.head.ref }}" >> "$GITHUB_OUTPUT"
437+
echo "repo=${{ github.event.pull_request.head.repo.full_name }}" >> "$GITHUB_OUTPUT"
438+
else
439+
echo "ref=${{ github.ref_name }}" >> "$GITHUB_OUTPUT"
440+
echo "repo=${{ github.repository }}" >> "$GITHUB_OUTPUT"
441+
fi
442+
443+
- name: Update dependency to the current branch
444+
working-directory: synapse-token-authenticator
445+
run: |
446+
sed -i 's|matrix-synapse @ git+.*|matrix-synapse @ git+https://github.com/${{ steps.synapse-ref.outputs.repo }}.git@${{ steps.synapse-ref.outputs.ref }}|' pyproject.toml
447+
448+
- name: Run token-authenticator tests
449+
working-directory: synapse-token-authenticator
450+
run: hatch run cov
451+
408452
otlp:
409453
if: ${{ !failure() && !cancelled() }}
410454
runs-on: ubuntu-latest
@@ -432,6 +476,7 @@ jobs:
432476
- complement
433477
- cargo-test
434478
- invite-checker
479+
- token-authenticator
435480
- linting-done
436481
runs-on: ubuntu-latest
437482
steps:

0 commit comments

Comments
 (0)