Skip to content
Snippets Groups Projects
Commit 5408641b authored by Simon Rose's avatar Simon Rose
Browse files

Merge branch 'improve_tests' into 'master'

Improved tests to actually check error messages

See merge request e3/e3-require!62
parents aa9c883f f008ae2f
No related branches found
No related tags found
No related merge requests found
......@@ -22,5 +22,5 @@ endif
.PHONU: loc-check
loc-check:
ifneq (,$(findstring -loc,$(E3_MODULE_SRC_PATH)))
$(error DEPRECATED: Local source mode "-loc" has being deprecated. Please comment out the EPICS_MODULE_TAG to use local source mode.)
$(error DEPRECATED: Local source mode "-loc" has been deprecated. Please comment out the EPICS_MODULE_TAG to use local source mode.)
endif
......@@ -9,8 +9,9 @@ from .utils import run_make
indirect=True,
)
def test_loc(wrapper):
rc, _, _ = run_make(wrapper, "build", E3_MODULE_SRC_PATH="test-loc")
rc, _, errs = run_make(wrapper, "build", E3_MODULE_SRC_PATH="test-loc")
assert rc == 2
assert 'Local source mode "-loc" has been deprecated' in errs.decode("utf-8")
def test_sitelibs(wrapper):
......@@ -34,5 +35,7 @@ include $(REQUIRE_CONFIG)/RULES_VARS
def test_incorrect_module_name(wrapper):
rc, _, _ = run_make(wrapper, "build", E3_MODULE_NAME="ADCore")
module_name = "ADCore"
rc, _, errs = run_make(wrapper, "build", E3_MODULE_NAME=module_name)
assert rc == 2
assert f"E3_MODULE_NAME '{module_name}' is not valid" in errs.decode("utf-8")
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment