|
13 | 13 |
|
14 | 14 | matrix:
|
15 | 15 | include:
|
16 |
| - - name: "Python 3.6 - Netbox 2.5" |
| 16 | + - name: "Python 3.6 - Netbox 2.5 - Ansible 2.9RC4" |
17 | 17 | python: 3.6
|
18 |
| - env: PYTHON_VER=3.6 VERSION=v2.5 |
| 18 | + env: PYTHON_VER=3.6 VERSION=v2.5 ANSIBLE_VER=2.9.0rc4 |
19 | 19 | install:
|
20 |
| - - pip install -U pip |
21 |
| - - pip install pytest==4.6.5 pytest-mock pytest-xdist jinja2 PyYAML black==19.3b0 |
22 |
| - - pip install pynetbox==4.0.6 cryptography codecov |
23 |
| - - pip install jmespath |
24 |
| - - cd ../../ |
25 |
| - # This is due to ansible-test only being available within devel branch |
26 |
| - - git clone https://github.com/ansible/ansible.git |
27 |
| - - cd ansible |
28 |
| - - git checkout stable-2.9 |
29 |
| - - source hacking/env-setup |
30 | 20 | - cd ..
|
31 | 21 | # Setup netbox container for integration testing
|
32 |
| - - git clone https://github.com/netbox-community/netbox-docker.git |
| 22 | + - git clone https://github.com/FragmentedPacket/netbox-docker.git |
33 | 23 | - cd netbox-docker
|
34 |
| - - docker-compose --verbose pull |
35 |
| - - docker-compose --verbose up -d |
| 24 | + - git checkout startup-dcim-interfaces-2.5 |
| 25 | + - docker-compose pull |
| 26 | + - docker-compose up -d |
36 | 27 | - cd ..
|
37 |
| - |
38 |
| - before_script: |
39 |
| - - mkdir -p ~/ansible_collections/$COLLECTION_NAMESPACE |
40 |
| - - cp -R FragmentedPacket/$COLLECTION_NAME ~/ansible_collections/$COLLECTION_NAMESPACE/$COLLECTION_NAME |
41 |
| - - cd ~/ansible_collections/$COLLECTION_NAMESPACE/$COLLECTION_NAME |
42 |
| - - ansible-galaxy collection build . |
43 |
| - - ansible-galaxy collection install $COLLECTION_NAMESPACE-$COLLECTION_NAME-$COLLECTION_VERSION.tar.gz -p /home/travis/.ansible/collections |
44 |
| - |
45 |
| - script: |
46 |
| - - ansible-test units --python $PYTHON_VER -v |
47 |
| - - black . --check |
48 |
| - - timeout 300 bash -c 'while [[ "$(curl -s -o /dev/null -w ''%{http_code}'' localhost:32768)" != "200" ]]; do echo "waiting for Netbox"; sleep 5; done' || false |
49 |
| - - python tests/integration/netbox-deploy.py |
50 |
| - - ansible-playbook tests/integration/integration-tests.yml -v |
| 28 | + - pip install -U pip |
| 29 | + - pip install pytest==4.6.5 pytest-mock pytest-xdist jinja2 PyYAML black==19.3b0 |
| 30 | + - pip install pynetbox==4.0.6 cryptography codecov jmespath ansible==$ANSIBLE_VER |
51 | 31 |
|
52 |
| - - name: "Python 3.6 - Netbox 2.6" |
| 32 | + - name: "Python 3.6 - Netbox Latest - Ansible Devel" |
53 | 33 | python: 3.6
|
54 |
| - env: PYTHON_VER=3.6 VERSION=v2.6 |
| 34 | + env: PYTHON_VER=3.6 |
55 | 35 | install:
|
| 36 | + - cd .. |
| 37 | + # Setup netbox container for integration testing |
| 38 | + - git clone https://github.com/netbox-community/netbox-docker.git |
| 39 | + - cd netbox-docker |
| 40 | + - docker-compose pull |
| 41 | + - docker-compose up -d |
| 42 | + - cd .. |
56 | 43 | - pip install -U pip
|
57 | 44 | - pip install pytest==4.6.5 pytest-mock pytest-xdist jinja2 PyYAML black==19.3b0
|
58 |
| - - pip install pynetbox==4.0.6 cryptography |
59 |
| - - pip install jmespath |
60 |
| - - cd ../../ |
| 45 | + - pip install pynetbox==4.0.6 cryptography jmespath |
61 | 46 | # This is due to ansible-test only being available within devel branch
|
62 | 47 | - git clone https://github.com/ansible/ansible.git
|
63 | 48 | - cd ansible
|
64 |
| - - git checkout stable-2.9 |
65 | 49 | - source hacking/env-setup
|
66 |
| - - cd .. |
67 |
| - # Setup netbox container for integration testing |
68 |
| - - git clone https://github.com/netbox-community/netbox-docker.git |
69 |
| - - cd netbox-docker |
70 |
| - - docker-compose --verbose pull |
71 |
| - - docker-compose --verbose up -d |
72 |
| - - cd .. |
| 50 | + - cd .. |
| 51 | + |
| 52 | +before_script: |
| 53 | + - mkdir -p ~/ansible_collections/$COLLECTION_NAMESPACE |
| 54 | + - cp -R $COLLECTION_NAME ~/ansible_collections/$COLLECTION_NAMESPACE/$COLLECTION_NAME |
| 55 | + - cd ~/ansible_collections/$COLLECTION_NAMESPACE/$COLLECTION_NAME |
| 56 | + - ansible-galaxy collection build . |
| 57 | + - ansible-galaxy collection install $COLLECTION_NAMESPACE-$COLLECTION_NAME-$COLLECTION_VERSION.tar.gz -p /home/travis/.ansible/collections |
73 | 58 |
|
74 |
| - before_script: |
75 |
| - - mkdir -p ~/ansible_collections/$COLLECTION_NAMESPACE |
76 |
| - - cp -R FragmentedPacket/$COLLECTION_NAME ~/ansible_collections/$COLLECTION_NAMESPACE/$COLLECTION_NAME |
77 |
| - - cd ~/ansible_collections/$COLLECTION_NAMESPACE/$COLLECTION_NAME |
78 |
| - - ansible-galaxy collection build . |
79 |
| - - ansible-galaxy collection install $COLLECTION_NAMESPACE-$COLLECTION_NAME-$COLLECTION_VERSION.tar.gz -p /home/travis/.ansible/collections |
80 |
| - |
81 |
| - script: |
82 |
| - - ansible-test units --python $PYTHON_VER -v |
83 |
| - - black . --check |
84 |
| - - timeout 300 bash -c 'while [[ "$(curl -s -o /dev/null -w ''%{http_code}'' localhost:32768)" != "200" ]]; do echo "waiting for Netbox"; sleep 5; done' || false |
85 |
| - - python tests/integration/netbox-deploy.py |
86 |
| - - ansible-playbook tests/integration/integration-tests.yml -v |
| 59 | +script: |
| 60 | + - ansible-test units --python $PYTHON_VER -v |
| 61 | + - black . --check |
| 62 | + - timeout 300 bash -c 'while [[ "$(curl -s -o /dev/null -w ''%{http_code}'' localhost:32768)" != "200" ]]; do echo "waiting for Netbox"; sleep 5; done' || false |
| 63 | + - python tests/integration/netbox-deploy.py |
| 64 | + - ansible-playbook tests/integration/integration-tests.yml -v |
0 commit comments