summaryrefslogtreecommitdiff
path: root/src/test/test-stat-util.c
diff options
context:
space:
mode:
authorMartin Pitt <martinpitt@users.noreply.github.com>2017-02-19 16:15:06 +0100
committerEvgeny Vereshchagin <evvers@ya.ru>2017-02-19 18:15:06 +0300
commit8dfc2f40bf32ffd301f261cc600fd91684616561 (patch)
tree42a9b1b9032fb430b30289630d61d2209909ddcc /src/test/test-stat-util.c
parent3877500c5bc2daad0437b74eb3a7f707d413c2b0 (diff)
downloadsystemd-8dfc2f40bf32ffd301f261cc600fd91684616561.tar.gz
systemd-8dfc2f40bf32ffd301f261cc600fd91684616561.tar.bz2
systemd-8dfc2f40bf32ffd301f261cc600fd91684616561.zip
test: re-drop assumption that /run is a mount point, part 2 (#5386)
Commit cc3901613 only fixed one place, fix the other one too.
Diffstat (limited to 'src/test/test-stat-util.c')
-rw-r--r--src/test/test-stat-util.c4
1 files changed, 3 insertions, 1 deletions
diff --git a/src/test/test-stat-util.c b/src/test/test-stat-util.c
index 28ca6bc317..3ff2aadea4 100644
--- a/src/test/test-stat-util.c
+++ b/src/test/test-stat-util.c
@@ -82,7 +82,9 @@ static void test_path_check_fstype(void) {
}
static void test_path_is_temporary_fs(void) {
- assert_se(path_is_temporary_fs("/run") > 0);
+ /* run might not be a mount point in build chroots */
+ if (path_is_mount_point("/run", NULL, AT_SYMLINK_FOLLOW) > 0)
+ assert_se(path_is_temporary_fs("/run") > 0);
assert_se(path_is_temporary_fs("/proc") == 0);
assert_se(path_is_temporary_fs("/i-dont-exist") == -ENOENT);
}