From f04fd9607703dce1992bcb56327a5f2a06aae55e Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?J=C3=BCrg=20Billeter?= Date: Mon, 27 Jan 2020 19:09:41 +0100 Subject: tests/integration/workspace.py: Fix test_incremental_configure... Add file to workspace directory to ensure second `bst build` is actually building the element. --- tests/integration/workspace.py | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/tests/integration/workspace.py b/tests/integration/workspace.py index 69f267273..d0608f450 100644 --- a/tests/integration/workspace.py +++ b/tests/integration/workspace.py @@ -281,7 +281,7 @@ def test_incremental_configure_commands_run_only_once(cli, datafiles): # Then we build, and check whether the configure step succeeded res = cli.run(project=project, args=["--cache-buildtrees", "always", "build", element_name]) res.assert_success() - # check that the workspace was not configured + # check that the workspace was not configured outside the sandbox assert not os.path.exists(os.path.join(workspace, "prepared")) # the configure should have been run in the sandbox, so check the buildtree @@ -295,6 +295,10 @@ def test_incremental_configure_commands_run_only_once(cli, datafiles): assert "./prepared" in files assert not "./prepared-again" in files + # Add file to workspace to trigger an (incremental) build + with open(os.path.join(workspace, "newfile"), "w"): + pass + # When we build again, the configure commands should not be # called, and we should therefore exit cleanly (the configure # commands are set to always fail after the first run) -- cgit v1.2.1