aboutsummaryrefslogtreecommitdiff
path: root/02-usart/tests/test_memory.c
diff options
context:
space:
mode:
authorJosh Rahm <joshuarahm@gmail.com>2020-11-21 21:57:14 -0700
committerJosh Rahm <joshuarahm@gmail.com>2020-11-21 21:57:14 -0700
commit822c68c74ebc3ac3694f87d516f1e91f2ce1d0fe (patch)
tree709b480c0d0283501c2376713f6b495c32292520 /02-usart/tests/test_memory.c
parentb073c19f9ec330423fa07c66d1c0604883044f6b (diff)
downloadstm32l4-822c68c74ebc3ac3694f87d516f1e91f2ce1d0fe.tar.gz
stm32l4-822c68c74ebc3ac3694f87d516f1e91f2ce1d0fe.tar.bz2
stm32l4-822c68c74ebc3ac3694f87d516f1e91f2ce1d0fe.zip
Fix mem.c to use the address of DATA_SEGMENT_START instead of the value
Diffstat (limited to '02-usart/tests/test_memory.c')
-rw-r--r--02-usart/tests/test_memory.c10
1 files changed, 10 insertions, 0 deletions
diff --git a/02-usart/tests/test_memory.c b/02-usart/tests/test_memory.c
index e68977a..1b88ad1 100644
--- a/02-usart/tests/test_memory.c
+++ b/02-usart/tests/test_memory.c
@@ -72,6 +72,8 @@ TEST(memory, halloc)
ASSERT_CHAIN(test4, test5);
wipeout_halloc();
+
+ return 0;
}
struct UNEVEN_STRUCT {
@@ -102,6 +104,8 @@ TEST(memory, uneven_halloc)
ASSERT_EQ(V(test1) + 12, test2);
wipeout_halloc();
+
+ return 0;
}
TEST(memory, halloc_free)
@@ -149,6 +153,8 @@ TEST(memory, halloc_free)
ASSERT_EQ((*halloc_start >> 1) * 4, MAX_HEAP_SIZE - 4);
wipeout_halloc();
+
+ return 0;
}
TEST(memory, halloc_free_alloc2)
@@ -224,6 +230,8 @@ TEST(memory, consistency_stress)
ASSERT_TRUE(false);
}
ASSERT_EQ((*halloc_start >> 1) * 4, MAX_HEAP_SIZE - 4);
+
+ return 0;
}
TEST(memory, halloc_free_alloc)
@@ -248,4 +256,6 @@ TEST(memory, halloc_free_alloc)
// Test 2 was large enough to accomodate 3 smaller structs.
ASSERT_EQ(V(test7), V(test2));
ASSERT_EQ(V(test8), V(test2) + sizeof(*test7) + 4);
+
+ return 0;
}