aboutsummaryrefslogtreecommitdiff
path: root/src/libexpr/tests/derived-path.cc
diff options
context:
space:
mode:
Diffstat (limited to 'src/libexpr/tests/derived-path.cc')
-rw-r--r--src/libexpr/tests/derived-path.cc9
1 files changed, 8 insertions, 1 deletions
diff --git a/src/libexpr/tests/derived-path.cc b/src/libexpr/tests/derived-path.cc
index 8210efef2..c713fe28a 100644
--- a/src/libexpr/tests/derived-path.cc
+++ b/src/libexpr/tests/derived-path.cc
@@ -37,8 +37,15 @@ RC_GTEST_FIXTURE_PROP(
prop_built_path_placeholder_round_trip,
(const StorePath & drvPath, const StorePathName & outputName))
{
+ /**
+ * We set these in tests rather than the regular globals so we don't have
+ * to worry about race conditions if the tests run concurrently.
+ */
+ ExperimentalFeatureSettings mockXpSettings;
+ mockXpSettings.set("experimental-features", "ca-derivations");
+
auto * v = state.allocValue();
- state.mkOutputString(*v, drvPath, outputName.name, std::nullopt);
+ state.mkOutputString(*v, drvPath, outputName.name, std::nullopt, mockXpSettings);
auto [d, _] = state.coerceToDerivedPathUnchecked(noPos, *v, "");
DerivedPath::Built b {
.drvPath = drvPath,