diff options
author | Andrew Brooks <andrewgrantbrooks@gmail.com> | 2021-12-17 19:26:53 -0600 |
---|---|---|
committer | Andrew Brooks <andrewgrantbrooks@gmail.com> | 2021-12-17 19:26:53 -0600 |
commit | 57718902e34486288f63760faddda49ce2eecbdb (patch) | |
tree | f2e67c9132714ab4dd5027f3ac4fd2f4e5c0cf40 /nixos/tests/docker-tools.nix | |
parent | 69ffb0004a2f447c6452c33483465e454504960a (diff) |
nixos/tests/docker-tools: add test for pre-runAsRoot layer unpack order
Diffstat (limited to 'nixos/tests/docker-tools.nix')
-rw-r--r-- | nixos/tests/docker-tools.nix | 6 |
1 files changed, 6 insertions, 0 deletions
diff --git a/nixos/tests/docker-tools.nix b/nixos/tests/docker-tools.nix index 19ebed3ebd0b..8a240ddb17f2 100644 --- a/nixos/tests/docker-tools.nix +++ b/nixos/tests/docker-tools.nix @@ -215,6 +215,12 @@ import ./make-test-python.nix ({ pkgs, ... }: { f"docker run --rm ${examples.layersOrder.imageName} cat /tmp/layer{index}" ) + with subtest("Ensure layers unpacked in correct order before runAsRoot runs"): + assert "abc" in docker.succeed( + "docker load --input='${examples.layersUnpackOrder}'", + "docker run --rm ${examples.layersUnpackOrder.imageName} cat /layer-order" + ) + with subtest("Ensure environment variables are correctly inherited"): docker.succeed( "docker load --input='${examples.environmentVariables}'" |