CI: uv lock check. Pre-test workflow.
This commit is contained in:
parent
d4d190ac2b
commit
c7a2138966
3 changed files with 37 additions and 1 deletions
5
.github/actions/cognee_setup/action.yml
vendored
5
.github/actions/cognee_setup/action.yml
vendored
|
|
@ -10,6 +10,10 @@ inputs:
|
||||||
description: "Additional extra dependencies to install (space-separated)"
|
description: "Additional extra dependencies to install (space-separated)"
|
||||||
required: false
|
required: false
|
||||||
default: ""
|
default: ""
|
||||||
|
rebuild-lockfile:
|
||||||
|
description: "Whether to rebuild the uv lockfile"
|
||||||
|
required: false
|
||||||
|
default: "false"
|
||||||
|
|
||||||
runs:
|
runs:
|
||||||
using: "composite"
|
using: "composite"
|
||||||
|
|
@ -26,6 +30,7 @@ runs:
|
||||||
enable-cache: true
|
enable-cache: true
|
||||||
|
|
||||||
- name: Rebuild uv lockfile
|
- name: Rebuild uv lockfile
|
||||||
|
if: ${{ inputs.rebuild-lockfile == 'true' }}
|
||||||
shell: bash
|
shell: bash
|
||||||
run: |
|
run: |
|
||||||
rm uv.lock
|
rm uv.lock
|
||||||
|
|
|
||||||
25
.github/workflows/pre_test.yml
vendored
Normal file
25
.github/workflows/pre_test.yml
vendored
Normal file
|
|
@ -0,0 +1,25 @@
|
||||||
|
on:
|
||||||
|
workflow_call:
|
||||||
|
inputs:
|
||||||
|
python-version:
|
||||||
|
required: false
|
||||||
|
type: string
|
||||||
|
default: '3.11.x'
|
||||||
|
|
||||||
|
jobs:
|
||||||
|
check-uv-lock:
|
||||||
|
name: Validate uv lockfile and project metadata
|
||||||
|
runs-on: ubuntu-22.04
|
||||||
|
steps:
|
||||||
|
- name: Check out repository
|
||||||
|
uses: actions/checkout@v4
|
||||||
|
with:
|
||||||
|
fetch-depth: 0
|
||||||
|
|
||||||
|
- name: Install uv
|
||||||
|
uses: astral-sh/setup-uv@v4
|
||||||
|
with:
|
||||||
|
enable-cache: true
|
||||||
|
|
||||||
|
- name: Validate uv lockfile and project metadata
|
||||||
|
run: uv lock --check || { echo "'uv lock --check' failed."; echo "Run 'uv lock' and push your changes."; exit 1; }
|
||||||
8
.github/workflows/test_suites.yml
vendored
8
.github/workflows/test_suites.yml
vendored
|
|
@ -18,15 +18,21 @@ env:
|
||||||
RUNTIME__LOG_LEVEL: ERROR
|
RUNTIME__LOG_LEVEL: ERROR
|
||||||
ENV: 'dev'
|
ENV: 'dev'
|
||||||
|
|
||||||
jobs:
|
jobs:
|
||||||
|
pre-test:
|
||||||
|
name: basic checks
|
||||||
|
uses: ./.github/workflows/pre_test.yml
|
||||||
|
|
||||||
basic-tests:
|
basic-tests:
|
||||||
name: Basic Tests
|
name: Basic Tests
|
||||||
uses: ./.github/workflows/basic_tests.yml
|
uses: ./.github/workflows/basic_tests.yml
|
||||||
|
needs: [ pre-test ]
|
||||||
secrets: inherit
|
secrets: inherit
|
||||||
|
|
||||||
e2e-tests:
|
e2e-tests:
|
||||||
name: End-to-End Tests
|
name: End-to-End Tests
|
||||||
uses: ./.github/workflows/e2e_tests.yml
|
uses: ./.github/workflows/e2e_tests.yml
|
||||||
|
needs: [ pre-test ]
|
||||||
secrets: inherit
|
secrets: inherit
|
||||||
|
|
||||||
distributed-tests:
|
distributed-tests:
|
||||||
|
|
|
||||||
Loading…
Add table
Reference in a new issue