-
Notifications
You must be signed in to change notification settings - Fork 114
76 lines (66 loc) · 1.9 KB
/
test_matrix.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
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
---
name: "test_matrix"
on: # yamllint disable-line rule:truthy
pull_request:
branches: main
push:
branches-ignore:
- '*_test'
- '*_dev'
- '*_cloud'
paths-ignore:
- '**.md'
- 'LICENSE'
jobs:
tests:
name: Python ${{ matrix.python-version }} | Clickhouse ${{ matrix.clickhouse-version}} | Ubuntu
runs-on: ubuntu-latest
env:
TEST_SETTINGS_FILE: latest
strategy:
matrix:
python-version:
- '3.8'
- '3.9'
- '3.10'
- '3.11'
clickhouse-version:
- '22.8'
- '23.3'
- '23.5'
- '23.6'
- latest
steps:
- name: Checkout
uses: actions/checkout@v3
- name: Set environment variables
if: ${{ matrix.clickhouse-version == '22.3' }}
run: |
echo "TEST_SETTINGS_FILE=22_3" >> $GITHUB_ENV
echo "DBT_CH_TEST_CH_VERSION=22.3" >> $GITHUB_ENV
- name: Run ClickHouse Container
run: docker run
-d
-p 8123:8123
-p 9000:9000
--name clickhouse
-v /var/lib/clickhouse
-v ${{ github.workspace }}/tests/integration/test_settings_$TEST_SETTINGS_FILE.xml:/etc/clickhouse-server/users.d/test_settings.xml
--ulimit nofile=262144:262144
clickhouse/clickhouse-server:${{ matrix.clickhouse-version }}
- name: Setup Python ${{ matrix.python-version }}
uses: actions/setup-python@v4
with:
python-version: ${{ matrix.python-version }}
- name: Install requirements
run: pip3 install -r dev_requirements.txt
- name: Run HTTP tests
run: |
PYTHONPATH="${PYTHONPATH}:dbt"
pytest tests
- name: Run Native tests
env:
DBT_CH_TEST_PORT: 9000
run: |
PYTHONPATH="${PYTHONPATH}:dbt"
pytest tests