about summary refs log tree commit diff
path: root/third_party/nix/tests/parallel.nix
diff options
context:
space:
mode:
Diffstat (limited to 'third_party/nix/tests/parallel.nix')
-rw-r--r--third_party/nix/tests/parallel.nix19
1 files changed, 19 insertions, 0 deletions
diff --git a/third_party/nix/tests/parallel.nix b/third_party/nix/tests/parallel.nix
new file mode 100644
index 000000000000..23f142059f58
--- /dev/null
+++ b/third_party/nix/tests/parallel.nix
@@ -0,0 +1,19 @@
+{sleepTime ? 3}:
+
+with import ./config.nix;
+
+let
+
+  mkDrv = text: inputs: mkDerivation {
+    name = "parallel";
+    builder = ./parallel.builder.sh;
+    inherit text inputs shared sleepTime;
+  };
+
+  a = mkDrv "a" [];
+  b = mkDrv "b" [a];
+  c = mkDrv "c" [a];
+  d = mkDrv "d" [a];
+  e = mkDrv "e" [b c d];
+
+in e