summaryrefslogtreecommitdiff
path: root/test
diff options
context:
space:
mode:
authorJoel Rosdahl <joel@rosdahl.net>2022-09-09 09:09:06 +0200
committerJoel Rosdahl <joel@rosdahl.net>2022-09-09 09:58:12 +0200
commite2840d7d4651bd52b16b06b8358ef054f8d494a9 (patch)
treea2735af7f8e3fa40ed0b418919ec9fc3afaa0d76 /test
parent1e5761e75325a8b45eb61e55d73ee92823ed4da4 (diff)
downloadccache-e2840d7d4651bd52b16b06b8358ef054f8d494a9.tar.gz
fix: Don't crash with no or nonexistent source file with base_dir
Regression in fec405539bca90ebd0992ae6606bd10eec3a64da. Fixes #1155.
Diffstat (limited to 'test')
-rw-r--r--test/suites/basedir.bash3
1 files changed, 3 insertions, 0 deletions
diff --git a/test/suites/basedir.bash b/test/suites/basedir.bash
index 5486b1e5..a5aa46e9 100644
--- a/test/suites/basedir.bash
+++ b/test/suites/basedir.bash
@@ -17,6 +17,9 @@ SUITE_basedir() {
# -------------------------------------------------------------------------
TEST "Enabled CCACHE_BASEDIR"
+ CCACHE_BASEDIR=/ $CCACHE_COMPILE --version
+ expect_stat no_input_file 1
+
cd dir1
CCACHE_BASEDIR="`pwd`" $CCACHE_COMPILE -I`pwd`/include -c src/test.c
expect_stat direct_cache_hit 0