Add tests files

This commit is contained in:
Quentin Legot
2023-04-04 20:55:27 +02:00
parent 99b0128cfe
commit a001e45c3f
5 changed files with 39 additions and 1 deletions

View File

@ -0,0 +1,16 @@
PROGRAMS = halt prints
build: $(PROGRAMS)
dumps: halt.dump prints.dump
tests: halt.guac prints.guac
clean:
$(RM) halt.o halt prints prints.o
TOPDIR = ../..
include $(TOPDIR)/Makefile.tests
$(PROGRAMS): % : $(USERLIB)/sys.o $(USERLIB)/libnachos.o %.o

View File

@ -0,0 +1,7 @@
#include "userlib/syscall.h"
int main() {
Shutdown();
return 0;
}

View File

@ -0,0 +1,10 @@
#include "userlib/syscall.h"
#include "userlib/libnachos.h"
int main() {
n_printf("Hello World 1");
n_printf("Hello World 2");
n_printf("Hello World 3");
n_printf("Hello World 4");
return 0;
}