Move PIT test to test module
This commit is contained in:
parent
8cfa7bc009
commit
db2814596b
@ -93,15 +93,10 @@ void hulk_start()
|
||||
|
||||
resume_interrupts();
|
||||
|
||||
/* Check that PIT millisecond interrupt is firing. */
|
||||
size_t uptime = Time.uptime();
|
||||
while (Time.uptime() <= uptime)
|
||||
{
|
||||
}
|
||||
Test.run();
|
||||
Klog.writefln("\a5HULK Initialization Complete!");
|
||||
|
||||
/* Run kernel tests. */
|
||||
Test.run();
|
||||
|
||||
/* Idle loop. */
|
||||
Time.msleep(1);
|
||||
|
@ -5,6 +5,7 @@ module hulk.test;
|
||||
|
||||
import hulk.klog;
|
||||
import hulk.list;
|
||||
import hulk.time;
|
||||
|
||||
struct Test
|
||||
{
|
||||
@ -14,10 +15,21 @@ struct Test
|
||||
public static void run()
|
||||
{
|
||||
Klog.writefln("\a3Running kernel tests");
|
||||
test_pit();
|
||||
test_list();
|
||||
Klog.writefln("\a3Kernel tests complete");
|
||||
}
|
||||
|
||||
private static void test_pit()
|
||||
{
|
||||
Klog.writefln("Testing PIT...");
|
||||
/* Check that PIT millisecond interrupt is firing. */
|
||||
size_t uptime = Time.uptime();
|
||||
while (Time.uptime() <= uptime)
|
||||
{
|
||||
}
|
||||
}
|
||||
|
||||
private static void test_list()
|
||||
{
|
||||
Klog.writefln("Testing list...");
|
||||
|
Loading…
x
Reference in New Issue
Block a user