File tree 3 files changed +31
-7
lines changed
tests/integration/targets
3 files changed +31
-7
lines changed Original file line number Diff line number Diff line change 10
10
jobs :
11
11
module :
12
12
name : Sanity & Unit Tests
13
+ # if: github.event_name == 'workflow_dispatch' || contains(github.event.commits.*.modified, 'plugins/') || contains(github.event.commits.*.modified, 'tests/unit/')
13
14
runs-on : ubuntu-latest
14
15
15
16
steps :
@@ -146,6 +147,22 @@ jobs:
146
147
run : |
147
148
timeout 300 bash -c 'until curl -f http://localhost:8081/service/rest/v1/status; do sleep 5; done'
148
149
150
+ - name : Get initial admin password
151
+ run : |
152
+ ADMIN_PASS=$(docker exec $(docker ps -q) cat /nexus-data/admin.password)
153
+ echo "NEXUS_ADMIN_PASSWORD=${ADMIN_PASS}" >> $GITHUB_ENV
154
+
155
+ - name : Run integration tests
156
+ run : |
157
+ cd /home/runner/.ansible/collections/ansible_collections/cloudkrafter/nexus
158
+ ansible-test integration raw_component --docker default --coverage --continue-on-error -v
159
+ env :
160
+ PY_COLORS : ' 1'
161
+ ANSIBLE_FORCE_COLOR : ' 1'
162
+ NEXUS_URL : ' http://localhost:8081'
163
+ NEXUS_USERNAME : ' admin'
164
+ NEXUS_PASSWORD : ${{ env.NEXUS_ADMIN_PASSWORD }}
165
+
149
166
- name : Generate code coverage report
150
167
run : |
151
168
cd /home/runner/.ansible/collections/ansible_collections/cloudkrafter/nexus
Original file line number Diff line number Diff line change 31
31
dest : /tmp
32
32
arch : invalid_arch
33
33
register : missing_state
34
- ignore_errors : true
35
-
36
- - name : debug
37
- debug :
38
- var : missing_state
39
34
40
35
- name : invalid
41
36
assert :
42
37
that :
43
- - download_invalid_arch is failed
44
- - download_invalid_arch,msg == "Invalid state:"
38
+ - missing_state.failed
45
39
46
40
# - name: Download Latest Nexus
47
41
# cloudkrafter.nexus.download:
Original file line number Diff line number Diff line change
1
+ - name : show env vars
2
+ debug :
3
+ var : ansible_env
4
+
5
+ # - name: Upload artifact
6
+ # cloudkrafter.nexus.raw_component:
7
+ # src: /tmp/nexus-latest.tar.gz
8
+ # dest: /nexus
9
+ # name: nexus-latest.tar.gz
10
+ # repository: https://host.docker.internal:9091/repository/raw-hosted
11
+ # username: admin
12
+ # password: changeme
13
+ # validate_certs: false
You can’t perform that action at this time.
0 commit comments