aboutsummaryrefslogtreecommitdiff
path: root/src/tests/utests
diff options
context:
space:
mode:
authorAlex Auvolat <alex.auvolat@ens.fr>2015-02-24 16:58:33 +0100
committerAlex Auvolat <alex.auvolat@ens.fr>2015-02-24 16:58:33 +0100
commit150dd5f860a5f22a8c3bcc1bf3a1f2e36dcf6fd8 (patch)
treee92a633a780104617483fd9fd379238299affabd /src/tests/utests
parentfa8a840c6dfc9eb737ef5d777f066b05eb8d9544 (diff)
downloadkogata-150dd5f860a5f22a8c3bcc1bf3a1f2e36dcf6fd8.tar.gz
kogata-150dd5f860a5f22a8c3bcc1bf3a1f2e36dcf6fd8.zip
Change VFS a bit : the root directory of a fs is now a pointer. Fix tests.
Diffstat (limited to 'src/tests/utests')
-rw-r--r--src/tests/utests/fs1/test.c3
-rwxr-xr-xsrc/tests/utests/run_qemu_test.sh2
2 files changed, 3 insertions, 2 deletions
diff --git a/src/tests/utests/fs1/test.c b/src/tests/utests/fs1/test.c
index 247373d..7d6afd6 100644
--- a/src/tests/utests/fs1/test.c
+++ b/src/tests/utests/fs1/test.c
@@ -8,8 +8,9 @@
int main(int argc, char **argv) {
dbg_print("Hello, world! from user process.\n");
- fd_t f = open("dev:/", FM_READDIR);
+ fd_t f = open("io:/", FM_READDIR);
dbg_printf("openned /: %d\n", f);
+ ASSERT(f != 0);
dirent_t x;
while (readdir(f, &x)) {
dbg_printf("- '%s' %p %d\n", x.name, x.st.type, x.st.size);
diff --git a/src/tests/utests/run_qemu_test.sh b/src/tests/utests/run_qemu_test.sh
index 68cf498..ea5166e 100755
--- a/src/tests/utests/run_qemu_test.sh
+++ b/src/tests/utests/run_qemu_test.sh
@@ -9,7 +9,7 @@ if [ $1 = 'watchdog' ]; then
exit 0
fi
-(qemu-system-i386 -kernel ../../../kernel/kernel.bin -initrd init.bin -serial stdio -m 16 -display none & echo $! >pid &
+(qemu-system-i386 -kernel ../../../kernel/kernel.bin -append 'init=io:/mod/init.bin' -initrd init.bin -serial stdio -m 16 -display none & echo $! >pid &
$0 watchdog) \
| tee >(grep -m 1 "TEST-" >result; kill -INT `cat pid`; kill -TERM `cat pid2`) \