summaryrefslogtreecommitdiff
path: root/tests/frontend/track.py
diff options
context:
space:
mode:
authorTristan Van Berkom <tristan.van.berkom@gmail.com>2020-10-26 08:53:17 +0000
committerTristan Van Berkom <tristan.van.berkom@gmail.com>2020-10-26 08:53:17 +0000
commit8a743485981b52ae916279099880fe1c2a83a59e (patch)
tree3a90d2ce8f5bce002f51267b9434a26d9e467cc7 /tests/frontend/track.py
parent1d98d140e4d60e5f6dbe3f3da7e0be3bc1743f00 (diff)
parentaee49156c9f97d47df321c25affef7e6d00d16d2 (diff)
downloadbuildstream-8a743485981b52ae916279099880fe1c2a83a59e.tar.gz
Merge branch 'tristan/conditional-subsecond-precision' into 'master'
Conditionally skip tests which require subsecond precision mtimes See merge request BuildStream/buildstream!2091
Diffstat (limited to 'tests/frontend/track.py')
-rw-r--r--tests/frontend/track.py6
1 files changed, 6 insertions, 0 deletions
diff --git a/tests/frontend/track.py b/tests/frontend/track.py
index 682ee0e98..bd8444973 100644
--- a/tests/frontend/track.py
+++ b/tests/frontend/track.py
@@ -8,6 +8,7 @@ import pytest
from buildstream.testing import create_repo, generate_project
from buildstream.testing import cli # pylint: disable=unused-import
+from buildstream.testing._utils.site import have_subsecond_mtime
from buildstream.exceptions import ErrorDomain, LoadErrorReason
from buildstream import _yaml
from tests.testutils import generate_junction
@@ -366,6 +367,11 @@ def test_no_needless_overwrite(cli, tmpdir, datafiles):
element_path = os.path.join(project, "elements")
target = "track-test-target.bst"
+ # Skip this test if we do not have support for subsecond precision mtimes
+ #
+ if not have_subsecond_mtime(project):
+ pytest.skip("Filesystem does not support subsecond mtime precision: {}".format(project))
+
# Create our repo object of the given source type with
# the dev files, and then collect the initial ref.
#