File tree Expand file tree Collapse file tree 4 files changed +98
-2
lines changed Expand file tree Collapse file tree 4 files changed +98
-2
lines changed Original file line number Diff line number Diff line change 1
1
version : 2.1
2
2
3
+ executors :
4
+ python-container :
5
+ docker :
6
+ - image : cimg/python:3.12
7
+ python-vm :
8
+ machine :
9
+ - image : ubuntu-2204:current
10
+
3
11
workflows :
4
12
ci :
5
13
jobs :
6
14
- lint
15
+ - test :
16
+ name : Python (<< matrix.python_version >>) - ArangoDB (<< matrix.arangodb_license >>, << matrix.arangodb_version >> << matrix.arangodb_config >>)
17
+ matrix :
18
+ parameters :
19
+ python_version : ["3.10"]
20
+ arangodb_config : ["single"]
21
+ arangodb_license : ["community"]
22
+ arangodb_version : ["3.12"]
7
23
8
24
jobs :
9
25
lint :
10
- docker :
11
- - image : python:latest
26
+ executor : python-container
27
+ resource_class : small
12
28
steps :
13
29
- checkout
14
30
- run :
26
42
- run :
27
43
name : Run mypy
28
44
command : mypy ./arangoasync
45
+ test :
46
+ parameters :
47
+ python_version :
48
+ type : string
49
+ arangodb_config :
50
+ type : string
51
+ arangodb_license :
52
+ type : string
53
+ arangodb_version :
54
+ type : string
55
+ executor : python-vm
56
+ steps :
57
+ - checkout
58
+ - run :
59
+ name : Setup ArangoDB
60
+ command : |
61
+ chmod +x starter.sh
62
+ ./starter.sh ${{ matrix.arangodb_config }} ${{ matrix.arangodb_license }} ${{ matrix.arangodb_version }}
63
+ - restore_cache :
64
+ key : pip-and-local-cache
65
+ - run :
66
+ name : Setup Python
67
+ command : |
68
+ pyenv --version
69
+ pyenv install -f << parameters.python_version >>
70
+ pyenv global << parameters.python_version >>
71
+ - run :
72
+ name : Install Dependencies
73
+ command : pip install -e .[dev]
74
+ - run : docker ps -a
75
+ - run : docker logs arango
76
+ - run :
77
+ name : Run pytest
78
+ command : |
79
+ mkdir test-results
80
+
81
+ args=("--junitxml=test-results/junit.xml" "--log-cli-level=DEBUG" "--host" "localhost" "--port=8529")
82
+ if [ << parameters.arangodb_config >> = "cluster" ]; then
83
+ args+=("--cluster" "--port=8539" "--port=8549")
84
+ fi
85
+
86
+ if [ << parameters.arangodb_license >> = "enterprise" ]; then
87
+ args+=("--enterprise")
88
+ fi
89
+
90
+ echo "Running pytest with args: ${args[@]}"
91
+ pytest --cov=arango --cov-report=xml --cov-report term-missing --color=yes --code-highlight=yes "${args[@]}"
92
+ - store_artifacts :
93
+ path : test-results
94
+ - store_test_results :
95
+ path : test-results
Original file line number Diff line number Diff line change
1
+ [starter]
2
+ mode = cluster
3
+ local = true
4
+ address = 0.0.0.0
5
+ port = 8528
6
+
7
+ [auth]
8
+ jwt-secret = /tests/static/keyfile
9
+
10
+ [args]
11
+ all.database.password = passwd
12
+ all.database.extended-names = true
13
+ all.log.api-enabled = true
14
+ all.javascript.allow-admin-execute = true
15
+ all.server.options-api = admin
Original file line number Diff line number Diff line change
1
+ secret
Original file line number Diff line number Diff line change
1
+ [starter]
2
+ mode = single
3
+ address = 0.0.0.0
4
+ port = 8528
5
+
6
+ [auth]
7
+ jwt-secret = /tests/static/keyfile
8
+
9
+ [args]
10
+ all.database.password = passwd
11
+ all.database.extended-names = true
12
+ all.javascript.allow-admin-execute = true
13
+ all.server.options-api = admin
You can’t perform that action at this time.
0 commit comments