-
Notifications
You must be signed in to change notification settings - Fork 7
55 lines (47 loc) · 1.53 KB
/
tests.yaml
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
# name: Run Tests
# on:
# pull_request:
# types: [opened, reopened, ready_for_review, synchronize]
# branches:
# - dev
# - staging
# - main
# jobs:
# tests:
# if: github.event.pull_request.draft == false
# runs-on: self-hosted
# strategy:
# matrix:
# python-version: ["3.10", "3.11", "3.12"]
# steps:
# - name: Checkout
# uses: actions/checkout@v4
# with:
# fetch-depth: 0
# - name: Setup Python
# uses: actions/setup-python@v5.1.1
# with:
# python-version: ${{ matrix.python-version }}
# - name: Create uv virtualenv
# run: |
# python -m pip install uv
# uv venv .venv
# echo "VIRTUAL_ENV=.venv" >> $GITHUB_ENV
# echo "$PWD/.venv/bin" >> $GITHUB_PATH
# - name: Install dependencies
# run: uv pip install nox pytest prisma
# - name: Generate Prisma client
# run: |
# # Add the command to generate the Prisma client here
# prisma generate
# - name: Get latest git tag
# id: get_tag
# run: |
# echo "Attempting to get the latest git tag..."
# git_tag=$(git describe --tags --abbrev=0 2>/dev/null || echo "1.0.0")
# echo "GIT_TAG=$git_tag" >> $GITHUB_ENV
# - name: Run tests using shared session
# run: nox -s tests_session --python=${{ matrix.python-version }}
# env:
# GIT_TAG: ${{ env.GIT_TAG }}
# DOJO_API_BASE_URL: http://example.com