zpp
Zephyr C++20 Framework
main.cpp File Reference
#include <zephyr/ztest.h>
#include <zephyr/kernel.h>
#include <zpp/heap.hpp>
#include <zpp/fmt.hpp>
Include dependency graph for main.cpp:

Go to the source code of this file.

Functions

 ZTEST_SUITE (zpp_heap_tests, NULL, NULL, NULL, NULL, NULL)
 
 ZTEST (zpp_heap_tests, test_heap)
 

Function Documentation

◆ ZTEST()

ZTEST ( zpp_heap_tests  ,
test_heap   
)

Definition at line 23 of file main.cpp.

24 {
25  auto p = g_heap.allocate(1);
26 
27  zassert_not_null(p, "");
28 
29  g_heap.deallocate(p);
30 
31  p = g_heap.allocate(128);
32 
33  zassert_not_null(p, "");
34 
35  g_heap.deallocate(p);
36 }

◆ ZTEST_SUITE()

ZTEST_SUITE ( zpp_heap_tests  ,
NULL  ,
NULL  ,
NULL  ,
NULL  ,
NULL   
)