-
Notifications
You must be signed in to change notification settings - Fork 44
61 lines (50 loc) · 1.45 KB
/
tests_deb.yml
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
56
57
58
59
60
61
name: Test .deb packaging
on:
push:
branches: [ main ]
pull_request:
branches: [ main ]
permissions:
contents: read
jobs:
build:
name: "Test .deb packages"
runs-on: ubuntu-latest
steps:
- name: Check out code into the Go module directory
uses: actions/checkout@v4
with:
fetch-depth: 0
- name: Set up Go
uses: actions/setup-go@v5
with:
go-version-file: go.mod
- name: Install uv
uses: astral-sh/setup-uv@v5
with:
version: 0.5.24
enable-cache: true
cache-dependency-glob: "test/uv.lock"
- name: "Set up Python"
uses: actions/setup-python@v5
with:
python-version-file: "test/.python-version"
- name: Install the project
run: uv sync --all-extras --dev
working-directory: ./test
- name: Install functional test dependencies
run: |
sudo apt update
sudo apt install -y nftables iptables ipset build-essential debhelper devscripts fakeroot lintian
docker network create net-test
- name: Run functional tests
env:
CROWDSEC_TEST_VERSION: dev
CROWDSEC_TEST_FLAVORS: full
CROWDSEC_TEST_NETWORK: net-test
CROWDSEC_TEST_TIMEOUT: 60
PYTEST_ADDOPTS: --durations=0 -vv --color=yes
working-directory: ./test
run: |
uv run pytest ./tests/pkg/test_build_deb.py
sudo -E $(which uv) run pytest -m deb ./tests/install/no_crowdsec