summaryrefslogtreecommitdiffstats
path: root/tests/bitfield_tests.c
diff options
context:
space:
mode:
authorChristopher Peplin <chris.peplin@rhubarbtech.com>2013-12-29 11:44:03 -0500
committerChristopher Peplin <chris.peplin@rhubarbtech.com>2013-12-29 11:44:03 -0500
commita855335e3ad18a9d0094357eb39622448f8649a9 (patch)
tree0c00ced6710ee783febd34d8e28d7f3140031a87 /tests/bitfield_tests.c
parent6830d35b449141305f137f78f09c2b879bfb9b33 (diff)
Standardize argument ordering for bitfield functions.
Diffstat (limited to 'tests/bitfield_tests.c')
-rw-r--r--tests/bitfield_tests.c10
1 files changed, 5 insertions, 5 deletions
diff --git a/tests/bitfield_tests.c b/tests/bitfield_tests.c
index e2304ea0..00a28a36 100644
--- a/tests/bitfield_tests.c
+++ b/tests/bitfield_tests.c
@@ -193,9 +193,9 @@ END_TEST
START_TEST (test_get_byte)
{
uint8_t data[4] = {0x12, 0x34, 0x56, 0x78};
- uint8_t result = getByte(0, data, sizeof(data));
+ uint8_t result = getByte(data, sizeof(data), 0);
ck_assert_int_eq(result, 0x12);
- result = getByte(3, data, sizeof(data));
+ result = getByte(data, sizeof(data), 3);
ck_assert_int_eq(result, 0x78);
}
END_TEST
@@ -203,11 +203,11 @@ END_TEST
START_TEST (test_get_nibble)
{
uint8_t data[4] = {0x12, 0x34, 0x56, 0x78};
- uint8_t result = getNibble(0, data, sizeof(data));
+ uint8_t result = getNibble(data, sizeof(data), 0);
ck_assert_int_eq(result, 0x1);
- result = getNibble(1, data, sizeof(data));
+ result = getNibble(data, sizeof(data), 1);
ck_assert_int_eq(result, 0x2);
- result = getNibble(2, data, sizeof(data));
+ result = getNibble(data, sizeof(data), 2);
ck_assert_int_eq(result, 0x3);
}
END_TEST