Merge ~vultaire/charm-graylog:makefile-reworks into ~graylog-charmers/charm-graylog:master

Proposed by Paul Goins
Status: Merged
Approved by: Xav Paice
Approved revision: 44fb9f6723be5f5e3d89493b8f14134b7e461b2a
Merged at revision: 5a7990ff5200455b399237aa85e772fb133482be
Proposed branch: ~vultaire/charm-graylog:makefile-reworks
Merge into: ~graylog-charmers/charm-graylog:master
Prerequisite: ~vultaire/charm-graylog:adding-zaza-tests
Diff against target: 81 lines (+15/-9)
5 files modified
Makefile (+9/-4)
tests/README.md (+3/-2)
tests/__init__.py (+1/-1)
tests/bundles/overlays/local-charm-overlay.yaml.j2 (+1/-1)
tox.ini (+1/-1)
Reviewer Review Type Date Requested Status
Xav Paice (community) Approve
Canonical IS Reviewers Pending
Review via email: mp+379029@code.launchpad.net

Commit message

Rework Makefile for deprecated settings

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
🤖 Canonical IS Merge Bot (canonical-is-mergebot) wrote :

Unable to determine commit message from repository - please click "Set commit message" and enter the commit message manually.

Revision history for this message
Xav Paice (xavpaice) wrote :

can we please get this rebased against master? Lots of merge conflicts at present.

review: Needs Fixing
Revision history for this message
Xav Paice (xavpaice) wrote :

Tested, failing to connect to port 9001 for graylog3 which is known, and fixed in a later MP. LGTM otherwise, approving.

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

Change has no commit message, setting status to needs review.

Revision history for this message
🤖 Canonical IS Merge Bot (canonical-is-mergebot) wrote :

Change successfully merged at revision 5a7990ff5200455b399237aa85e772fb133482be

Preview Diff

[H/L] Next/Prev Comment, [J/K] Next/Prev File, [N/P] Next/Prev Hunk
diff --git a/Makefile b/Makefile
index ded904d..c713ed5 100644
--- a/Makefile
+++ b/Makefile
@@ -1,5 +1,10 @@
1BUILDDEST:=$(if $(JUJU_REPOSITORY),$(JUJU_REPOSITORY),"../graylog-built")1# Set charm build directory via CHARM_BUILD_DIR.
2BUILTCHARMDIR:="$(BUILDDEST)/builds/graylog"2# JUJU_REPOSITORY is here purely for backwards compatibility.
3# If not specified, CHARM_BUILD_DIR will default to ../graylog-built/builds
4
5JUJU_REPOSITORY:=$(if $(JUJU_REPOSITORY),$(JUJU_REPOSITORY),../graylog-built)
6CHARM_BUILD_DIR:=$(if $(CHARM_BUILD_DIR),$(CHARM_BUILD_DIR),$(JUJU_REPOSITORY)/builds)
7BUILTCHARMDIR:=$(CHARM_BUILD_DIR)/graylog
38
4all: unittest9all: unittest
510
@@ -36,12 +41,12 @@ unittest: sysdeps lint
3641
37.PHONY: charmbuild42.PHONY: charmbuild
38charmbuild:43charmbuild:
39 charm build --output-dir $(BUILDDEST) --report --force44 CHARM_BUILD_DIR="$(CHARM_BUILD_DIR)" charm build --report --force
4045
41.PHONY: functional46.PHONY: functional
42functional: charmbuild47functional: charmbuild
43 @echo "Running functional tests..."48 @echo "Running functional tests..."
44 @tox -e func49 @CHARM_BUILD_DIR="$(CHARM_BUILD_DIR)" tox -e func
4550
46.PHONY: charmrelease51.PHONY: charmrelease
47charmrelease:52charmrelease:
diff --git a/tests/README.md b/tests/README.md
index 50a965f..5c8697d 100644
--- a/tests/README.md
+++ b/tests/README.md
@@ -1,7 +1,8 @@
1# How to run functional tests1# How to run functional tests
22
31. export JUJU_REPOSITORY=<directory for built charms>31. export CHARM_BUILD_DIR=<directory for built charms>
42. Optional: export MODEL_SETTINGS=<semicolon-separated list of "juju model-config" settings>42. Optional: export MODEL_SETTINGS=<semicolon-separated list of
5 "juju model-config" settings>
53. From the repository root, run: make test63. From the repository root, run: make test
67
7NOTE: If you are behind a proxy, be sure to export a MODEL_SETTINGS variable as8NOTE: If you are behind a proxy, be sure to export a MODEL_SETTINGS variable as
diff --git a/tests/__init__.py b/tests/__init__.py
index 9abea7a..d7058c8 100644
--- a/tests/__init__.py
+++ b/tests/__init__.py
@@ -8,6 +8,6 @@ def _add_path(path):
8 sys.path.insert(1, path)8 sys.path.insert(1, path)
99
1010
11built_charm = pathlib.Path(os.environ["JUJU_REPOSITORY"]) / "builds/graylog"11built_charm = pathlib.Path(os.environ["CHARM_BUILD_DIR"]) / "graylog"
12# Need to avoid importing c.l.graylog as it wants charmhelpers etc.12# Need to avoid importing c.l.graylog as it wants charmhelpers etc.
13_add_path(str(built_charm / "lib/charms/layer/graylog"))13_add_path(str(built_charm / "lib/charms/layer/graylog"))
diff --git a/tests/bundles/overlays/local-charm-overlay.yaml.j2 b/tests/bundles/overlays/local-charm-overlay.yaml.j2
index d74aac1..e78574f 100644
--- a/tests/bundles/overlays/local-charm-overlay.yaml.j2
+++ b/tests/bundles/overlays/local-charm-overlay.yaml.j2
@@ -1,3 +1,3 @@
1applications:1applications:
2 {{ charm_name }}:2 {{ charm_name }}:
3 charm: "{{ JUJU_REPOSITORY }}/builds/{{ charm_name }}"3 charm: "{{ CHARM_BUILD_DIR }}/{{ charm_name }}"
diff --git a/tox.ini b/tox.ini
index a44fa4a..09f7d69 100644
--- a/tox.ini
+++ b/tox.ini
@@ -19,7 +19,7 @@ commands = functest-run-suite --keep-model
19deps = -r{toxinidir}/tests/requirements.txt19deps = -r{toxinidir}/tests/requirements.txt
20passenv =20passenv =
21 HOME21 HOME
22 JUJU_REPOSITORY22 CHARM_BUILD_DIR
23 MODEL_SETTINGS23 MODEL_SETTINGS
2424
25[testenv:lint]25[testenv:lint]

Subscribers

People subscribed via source and target branches

to all changes: