summaryrefslogtreecommitdiff
path: root/tests/frontend/workspace.py
diff options
context:
space:
mode:
Diffstat (limited to 'tests/frontend/workspace.py')
-rw-r--r--tests/frontend/workspace.py15
1 files changed, 14 insertions, 1 deletions
diff --git a/tests/frontend/workspace.py b/tests/frontend/workspace.py
index db3db3e13..2dc8d2ab5 100644
--- a/tests/frontend/workspace.py
+++ b/tests/frontend/workspace.py
@@ -196,7 +196,8 @@ def test_list(cli, tmpdir, datafiles):
@pytest.mark.datafiles(DATA_DIR)
@pytest.mark.parametrize("kind", repo_kinds)
-def test_build(cli, tmpdir, datafiles, kind):
+@pytest.mark.parametrize("strict", [("strict"), ("non-strict")])
+def test_build(cli, tmpdir, datafiles, kind, strict):
element_name, project, workspace = open_workspace(cli, tmpdir, datafiles, kind, False)
checkout = os.path.join(str(tmpdir), 'checkout')
@@ -206,6 +207,18 @@ def test_build(cli, tmpdir, datafiles, kind):
with open(os.path.join(workspace, 'etc', 'pony.conf'), 'w') as f:
f.write("PONY='pink'")
+ # Configure strict mode
+ strict_mode = True
+ if strict != 'strict':
+ strict_mode = False
+ cli.configure({
+ 'projects': {
+ 'test': {
+ 'strict': strict_mode
+ }
+ }
+ })
+
# Build modified workspace
assert cli.get_element_state(project, element_name) == 'buildable'
assert cli.get_element_key(project, element_name) == "{:?<64}".format('')