Make tests public. Rewrite most tests. Add tests.
[pintos-anon] / src / tests / userprog / create-exists.c
1 #include <syscall.h>
2 #include "tests/lib.h"
3 #include "tests/main.h"
4
5 void
6 test_main (void) 
7 {
8   CHECK (create ("quux.dat", 0), "create quux.dat");
9   CHECK (create ("warble.dat", 0), "create warble.dat");
10   CHECK (!create ("quux.dat", 0), "try to re-create quux.dat");
11   CHECK (create ("baffle.dat", 0), "create baffle.dat");
12   CHECK (!create ("warble.dat", 0), "try to re-create quux.dat");
13 }