tests/bash: test rsync
The clang bash seems to be bad.
This commit is contained in:
parent
7b5a74d549
commit
301214c0cb
|
@ -10,7 +10,7 @@ let Init = Genode.Init
|
||||||
|
|
||||||
let Child = Init.Child
|
let Child = Init.Child
|
||||||
|
|
||||||
in λ(params : { bash : Text, coreutils : Text }) →
|
in λ(params : { bash : Text, coreutils : Text, path : Text }) →
|
||||||
let init =
|
let init =
|
||||||
Init::{
|
Init::{
|
||||||
, verbose = True
|
, verbose = True
|
||||||
|
@ -64,8 +64,11 @@ in λ(params : { bash : Text, coreutils : Text }) →
|
||||||
, VFS.inline
|
, VFS.inline
|
||||||
"script.sh"
|
"script.sh"
|
||||||
''
|
''
|
||||||
bash --version
|
sleep 1
|
||||||
bash -c "bash --version"
|
sleep --version
|
||||||
|
echo "foo"
|
||||||
|
echo "bar" | cat
|
||||||
|
rsync --version
|
||||||
''
|
''
|
||||||
]
|
]
|
||||||
]
|
]
|
||||||
|
@ -108,8 +111,8 @@ in λ(params : { bash : Text, coreutils : Text }) →
|
||||||
, binary = "${params.bash}/bin/bash"
|
, binary = "${params.bash}/bin/bash"
|
||||||
, exitPropagate = True
|
, exitPropagate = True
|
||||||
, resources = Genode.Init.Resources::{
|
, resources = Genode.Init.Resources::{
|
||||||
, caps = 256
|
, caps = 1024
|
||||||
, ram = Genode.units.MiB 8
|
, ram = Genode.units.MiB 32
|
||||||
}
|
}
|
||||||
, routes =
|
, routes =
|
||||||
Prelude.List.map
|
Prelude.List.map
|
||||||
|
@ -150,15 +153,13 @@ in λ(params : { bash : Text, coreutils : Text }) →
|
||||||
{ stdin = "/dev/null"
|
{ stdin = "/dev/null"
|
||||||
, stdout = "/dev/log"
|
, stdout = "/dev/log"
|
||||||
, stderr = "/dev/log"
|
, stderr = "/dev/log"
|
||||||
, pipe = "/dev/pipe"
|
, pipe = "/dev/pipes"
|
||||||
, rtc = "/dev/rtc"
|
, rtc = "/dev/rtc"
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
, VFS.vfs [ VFS.fs VFS.FS::{ label = "root" } ]
|
, VFS.vfs [ VFS.fs VFS.FS::{ label = "root" } ]
|
||||||
, env "TERM" "screen"
|
, env "TERM" "screen"
|
||||||
, env
|
, env "PATH" params.path
|
||||||
"PATH"
|
|
||||||
"${params.coreutils}/bin:${params.bash}/bin"
|
|
||||||
, arg "bash"
|
, arg "bash"
|
||||||
, arg "/script.sh"
|
, arg "/script.sh"
|
||||||
]
|
]
|
||||||
|
|
|
@ -3,18 +3,24 @@
|
||||||
machine = { pkgs, ... }: {
|
machine = { pkgs, ... }: {
|
||||||
genode.init.children.bash = {
|
genode.init.children.bash = {
|
||||||
configFile = pkgs.writeText "bash.child.dhall" ''
|
configFile = pkgs.writeText "bash.child.dhall" ''
|
||||||
${
|
${./bash.dhall}
|
||||||
./bash.dhall
|
{ bash = "${pkgs.genodePackages.bash}"
|
||||||
} { bash = "${pkgs.genodePackages.bash}", coreutils = "${pkgs.coreutils}" }
|
, coreutils = "${pkgs.genodePackages.coreutils}"
|
||||||
|
, path = "${
|
||||||
|
with pkgs;
|
||||||
|
(lib.makeSearchPathOutput "bin" "bin" [ bash coreutils rsync ])
|
||||||
|
}"
|
||||||
|
}
|
||||||
'';
|
'';
|
||||||
inputs = with pkgs.genodePackages; [
|
inputs = [ pkgs.genodePackages.bash pkgs.rsync ]
|
||||||
bash
|
|
||||||
|
++ (with pkgs.genodePackages; [
|
||||||
cached_fs_rom
|
cached_fs_rom
|
||||||
libc
|
libc
|
||||||
posix
|
posix
|
||||||
vfs
|
vfs
|
||||||
vfs_pipe
|
vfs_pipe
|
||||||
];
|
]);
|
||||||
};
|
};
|
||||||
};
|
};
|
||||||
testScript = ''
|
testScript = ''
|
||||||
|
|
Loading…
Reference in New Issue
Block a user