diff options
author | Eelco Dolstra <e.dolstra@tudelft.nl> | 2009-03-25T21·05+0000 |
---|---|---|
committer | Eelco Dolstra <e.dolstra@tudelft.nl> | 2009-03-25T21·05+0000 |
commit | 92f525ecf4ea8a9bd356acd1d3845074b1e5b918 (patch) | |
tree | 6d022fbd92897ad965a04571b339bad362cb9158 /tests/negative-caching.nix | |
parent | 7024a1ef076cedf4596c9f4b107e85d315242cea (diff) |
* Negative caching, i.e. caching of build failures. Disabled by
default. This is mostly useful for Hydra.
Diffstat (limited to 'tests/negative-caching.nix')
-rw-r--r-- | tests/negative-caching.nix | 21 |
1 files changed, 21 insertions, 0 deletions
diff --git a/tests/negative-caching.nix b/tests/negative-caching.nix new file mode 100644 index 000000000000..10df67a748fc --- /dev/null +++ b/tests/negative-caching.nix @@ -0,0 +1,21 @@ +with import ./config.nix; + +rec { + + fail = mkDerivation { + name = "fail"; + builder = builtins.toFile "builder.sh" "echo FAIL; exit 1"; + }; + + succeed = mkDerivation { + name = "succeed"; + builder = builtins.toFile "builder.sh" "echo SUCCEED; mkdir $out"; + }; + + depOnFail = mkDerivation { + name = "dep-on-fail"; + builder = builtins.toFile "builder.sh" "echo URGH; mkdir $out"; + inputs = [fail succeed]; + }; + +} |