mirror of
https://github.com/Fennix-Project/Kernel.git
synced 2025-07-10 23:09:18 +00:00
Test assert macro
This commit is contained in:
@ -19,6 +19,7 @@
|
||||
|
||||
#include <types.h>
|
||||
#include <memory.hpp>
|
||||
#include <assert.h>
|
||||
#include <debug.h>
|
||||
|
||||
__constructor void TestMacros()
|
||||
@ -63,6 +64,17 @@ __constructor void TestMacros()
|
||||
}
|
||||
}
|
||||
|
||||
{
|
||||
int a = 10;
|
||||
assert(a == 10);
|
||||
|
||||
const char *str = "Hello";
|
||||
assert(str != nullptr && str[0] == 'H');
|
||||
|
||||
bool flag = false;
|
||||
assert(!flag);
|
||||
}
|
||||
|
||||
debug("-------------------------");
|
||||
|
||||
{
|
||||
|
Reference in New Issue
Block a user