forked from viniarck/phpipam-pyclient
-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy path.gitlab-ci.yml
42 lines (34 loc) · 1.12 KB
/
.gitlab-ci.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
image: viniciusarcanjo/phpipam-pyclient-docker:dev
services:
- docker:dind
variables:
DOCKER_DRIVER: overlay2
stages:
- lint_tests
- integration_tests
lint_tests:
stage: lint_tests
script:
# find all py files excluding hidden files
- find . -type f | grep -v '/\.' | xargs ls | egrep ".py$" | xargs pylama
.integration_tests: &integration_def
stage: integration_tests
after_script:
- docker ps
- sleep 10
- docker ps
- docker exec phpipampyclient_phpipam_pyclient_1 /bin/bash -c 'python3 -m pytest tests/test_phpipam_installation.py -v'
- docker exec phpipampyclient_phpipam_pyclient_1 /bin/bash -c 'python3 -m pytest tests/test_phpipam_client.py -v'
- docker exec phpipampyclient_phpipam_pyclient_1 /bin/bash -c 'tox'
test_phpipam_latest:
<<: *integration_def
script:
- docker-compose -p phpipampyclient up -d
test_phpipam_1.3.1:
<<: *integration_def
script:
- docker-compose -p phpipampyclient -f docker-compose-1.3.1.yml up -d
test_phpipam_1.3:
<<: *integration_def
script:
- docker-compose -p phpipampyclient -f docker-compose-1.3.yml up -d