Merge ~mertkirpici/charm-juju-local:topic/juju-3.1 into charm-juju-local:master

Proposed by Mert Kirpici
Status: Merged
Approved by: Erhan Sunar
Approved revision: 438a94768bbbcb251e2cf8453cd58da0f497d78a
Merged at revision: 3d15251e721c36877a7b8b8761e97c11b180020f
Proposed branch: ~mertkirpici/charm-juju-local:topic/juju-3.1
Merge into: charm-juju-local:master
Diff against target: 195 lines (+28/-14)
9 files modified
Makefile (+5/-2)
dev/null (+0/-1)
tests/functional/requirements.txt (+0/-3)
tests/functional/tests/bundles/bionic.yaml (+1/-0)
tests/functional/tests/bundles/focal-juju3.yaml (+1/-0)
tests/functional/tests/bundles/focal.yaml (+1/-0)
tests/functional/tests/bundles/jammy-juju3.yaml (+1/-0)
tests/functional/tests/bundles/jammy.yaml (+1/-0)
tox.ini (+18/-8)
Reviewer Review Type Date Requested Status
Erhan Sunar (community) Approve
Andrea Ieri Approve
Eric Chen Needs Information
🤖 prod-jenkaas-bootstack (community) continuous-integration Approve
Review via email: mp+450788@code.launchpad.net

Commit message

chore: add juju 3.1 support for functests

To post a comment you must log in.
Revision history for this message
🤖 Canonical IS Merge Bot (canonical-is-mergebot) wrote :

This merge proposal is being monitored by mergebot. Change the status to Approved to merge.

Revision history for this message
🤖 prod-jenkaas-bootstack (prod-jenkaas-bootstack) wrote :
review: Approve (continuous-integration)
Revision history for this message
Mert Kirpici (mertkirpici) wrote :
Revision history for this message
Andrea Ieri (aieri) wrote :

Generally +1, just one comment in-line.

Revision history for this message
Eric Chen (eric-chen) :
review: Needs Information
Revision history for this message
Mert Kirpici (mertkirpici) :
Revision history for this message
Andrea Ieri (aieri) wrote :

LGTM

review: Approve
Revision history for this message
Erhan Sunar (esunar) :
review: Approve
Revision history for this message
🤖 Canonical IS Merge Bot (canonical-is-mergebot) wrote :

Change successfully merged at revision 3d15251e721c36877a7b8b8761e97c11b180020f

Preview Diff

[H/L] Next/Prev Comment, [J/K] Next/Prev File, [N/P] Next/Prev Hunk
1diff --git a/Makefile b/Makefile
2index ed84e3a..c50103a 100644
3--- a/Makefile
4+++ b/Makefile
5@@ -23,7 +23,10 @@ unittests:
6 test: lint functional
7
8 functional: build
9- @JUJU_REPOSITORY=$(JUJU_REPOSITORY) tox -e functional
10+ @JUJU_REPOSITORY=$(JUJU_REPOSITORY) tox -e func
11+
12+functional31: build
13+ @JUJU_REPOSITORY=$(JUJU_REPOSITORY) tox -e func31
14
15 build:
16 @echo "Building charm to base directory $(JUJU_REPOSITORY)"
17@@ -40,5 +43,5 @@ clean:
18 @$(RM) $(JUJU_REPOSITORY)/$(CHARM_NAME).charm
19
20 # The targets below don't depend on a file
21-.PHONY: lint test functional build release clean help
22+.PHONY: lint test functional functional31 build release clean help
23
24diff --git a/tests/bundles/bionic.yaml b/tests/bundles/bionic.yaml
25deleted file mode 120000
26index f81f6ff..0000000
27--- a/tests/bundles/bionic.yaml
28+++ /dev/null
29@@ -1 +0,0 @@
30-base.yaml
31\ No newline at end of file
32diff --git a/tests/bundles/focal-juju3.yaml b/tests/bundles/focal-juju3.yaml
33deleted file mode 120000
34index f81f6ff..0000000
35--- a/tests/bundles/focal-juju3.yaml
36+++ /dev/null
37@@ -1 +0,0 @@
38-base.yaml
39\ No newline at end of file
40diff --git a/tests/bundles/focal.yaml b/tests/bundles/focal.yaml
41deleted file mode 120000
42index f81f6ff..0000000
43--- a/tests/bundles/focal.yaml
44+++ /dev/null
45@@ -1 +0,0 @@
46-base.yaml
47\ No newline at end of file
48diff --git a/tests/bundles/jammy-juju3.yaml b/tests/bundles/jammy-juju3.yaml
49deleted file mode 120000
50index f81f6ff..0000000
51--- a/tests/bundles/jammy-juju3.yaml
52+++ /dev/null
53@@ -1 +0,0 @@
54-base.yaml
55\ No newline at end of file
56diff --git a/tests/bundles/jammy.yaml b/tests/bundles/jammy.yaml
57deleted file mode 120000
58index f81f6ff..0000000
59--- a/tests/bundles/jammy.yaml
60+++ /dev/null
61@@ -1 +0,0 @@
62-base.yaml
63\ No newline at end of file
64diff --git a/test-requirements.txt b/tests/functional/requirements.txt
65similarity index 66%
66rename from test-requirements.txt
67rename to tests/functional/requirements.txt
68index 8ea7c1c..845ceb1 100644
69--- a/test-requirements.txt
70+++ b/tests/functional/requirements.txt
71@@ -1,4 +1 @@
72-# zaza
73-git+https://github.com/openstack-charmers/zaza.git#egg=zaza
74 git+https://github.com/openstack-charmers/zaza-openstack-tests.git#egg=zaza.openstack
75-
76diff --git a/tests/__init__.py b/tests/functional/tests/__init__.py
77similarity index 100%
78rename from tests/__init__.py
79rename to tests/functional/tests/__init__.py
80diff --git a/tests/bundles/base.yaml b/tests/functional/tests/bundles/base.yaml
81similarity index 100%
82rename from tests/bundles/base.yaml
83rename to tests/functional/tests/bundles/base.yaml
84diff --git a/tests/functional/tests/bundles/bionic.yaml b/tests/functional/tests/bundles/bionic.yaml
85new file mode 120000
86index 0000000..f81f6ff
87--- /dev/null
88+++ b/tests/functional/tests/bundles/bionic.yaml
89@@ -0,0 +1 @@
90+base.yaml
91\ No newline at end of file
92diff --git a/tests/functional/tests/bundles/focal-juju3.yaml b/tests/functional/tests/bundles/focal-juju3.yaml
93new file mode 120000
94index 0000000..f81f6ff
95--- /dev/null
96+++ b/tests/functional/tests/bundles/focal-juju3.yaml
97@@ -0,0 +1 @@
98+base.yaml
99\ No newline at end of file
100diff --git a/tests/functional/tests/bundles/focal.yaml b/tests/functional/tests/bundles/focal.yaml
101new file mode 120000
102index 0000000..f81f6ff
103--- /dev/null
104+++ b/tests/functional/tests/bundles/focal.yaml
105@@ -0,0 +1 @@
106+base.yaml
107\ No newline at end of file
108diff --git a/tests/functional/tests/bundles/jammy-juju3.yaml b/tests/functional/tests/bundles/jammy-juju3.yaml
109new file mode 120000
110index 0000000..f81f6ff
111--- /dev/null
112+++ b/tests/functional/tests/bundles/jammy-juju3.yaml
113@@ -0,0 +1 @@
114+base.yaml
115\ No newline at end of file
116diff --git a/tests/functional/tests/bundles/jammy.yaml b/tests/functional/tests/bundles/jammy.yaml
117new file mode 120000
118index 0000000..f81f6ff
119--- /dev/null
120+++ b/tests/functional/tests/bundles/jammy.yaml
121@@ -0,0 +1 @@
122+base.yaml
123\ No newline at end of file
124diff --git a/tests/bundles/overlays/bionic.yaml.j2 b/tests/functional/tests/bundles/overlays/bionic.yaml.j2
125similarity index 100%
126rename from tests/bundles/overlays/bionic.yaml.j2
127rename to tests/functional/tests/bundles/overlays/bionic.yaml.j2
128diff --git a/tests/bundles/overlays/focal-juju3.yaml.j2 b/tests/functional/tests/bundles/overlays/focal-juju3.yaml.j2
129similarity index 100%
130rename from tests/bundles/overlays/focal-juju3.yaml.j2
131rename to tests/functional/tests/bundles/overlays/focal-juju3.yaml.j2
132diff --git a/tests/bundles/overlays/focal.yaml.j2 b/tests/functional/tests/bundles/overlays/focal.yaml.j2
133similarity index 100%
134rename from tests/bundles/overlays/focal.yaml.j2
135rename to tests/functional/tests/bundles/overlays/focal.yaml.j2
136diff --git a/tests/bundles/overlays/jammy-juju3.yaml.j2 b/tests/functional/tests/bundles/overlays/jammy-juju3.yaml.j2
137similarity index 100%
138rename from tests/bundles/overlays/jammy-juju3.yaml.j2
139rename to tests/functional/tests/bundles/overlays/jammy-juju3.yaml.j2
140diff --git a/tests/bundles/overlays/jammy.yaml.j2 b/tests/functional/tests/bundles/overlays/jammy.yaml.j2
141similarity index 100%
142rename from tests/bundles/overlays/jammy.yaml.j2
143rename to tests/functional/tests/bundles/overlays/jammy.yaml.j2
144diff --git a/tests/bundles/overlays/local-charm-overlay.yaml.j2 b/tests/functional/tests/bundles/overlays/local-charm-overlay.yaml.j2
145similarity index 100%
146rename from tests/bundles/overlays/local-charm-overlay.yaml.j2
147rename to tests/functional/tests/bundles/overlays/local-charm-overlay.yaml.j2
148diff --git a/tests/tests.yaml b/tests/functional/tests/tests.yaml
149similarity index 100%
150rename from tests/tests.yaml
151rename to tests/functional/tests/tests.yaml
152diff --git a/tests/tests_juju_local.py b/tests/functional/tests/tests_juju_local.py
153similarity index 100%
154rename from tests/tests_juju_local.py
155rename to tests/functional/tests/tests_juju_local.py
156diff --git a/tox.ini b/tox.ini
157index 73bddd1..03605df 100644
158--- a/tox.ini
159+++ b/tox.ini
160@@ -5,17 +5,27 @@ skip_missing_interpreters = True
161
162 [testenv]
163 basepython = python3
164-setenv =
165- PYTHONPATH = .
166-
167-[testenv:functional]
168-commands =
169- functest-run-suite --keep-faulty-model
170-deps = -r{toxinidir}/test-requirements.txt
171 passenv =
172 HOME
173- JUJU_REPOSITORY
174 OS_*
175+ JUJU_REPOSITORY
176+
177+setenv =
178+ PYTHONPATH = .
179+
180+[testenv:func]
181+changedir = {toxinidir}/tests/functional
182+deps =
183+ -r {toxinidir}/tests/functional/requirements.txt
184+ git+https://github.com/openstack-charmers/zaza.git#egg=zaza
185+commands = functest-run-suite --keep-faulty-model {posargs}
186+
187+[testenv:func31]
188+changedir = {toxinidir}/tests/functional
189+deps =
190+ -r {toxinidir}/tests/functional/requirements.txt
191+ git+https://github.com/esunar/zaza.git@fix-normalise_action_results#egg=zaza[juju-31]
192+commands = functest-run-suite --keep-faulty-model {posargs}
193
194 [testenv:func-smoke]
195 commands =

Subscribers

People subscribed via source and target branches

to all changes: