From 5b3b866960379c0755f139347e23eda4121b4b87 Mon Sep 17 00:00:00 2001 From: Joshua DeWeese Date: Wed, 13 Apr 2022 10:17:18 -0400 Subject: [PATCH] tests/unittests/tests-kernel_defines: fix typo The variable named (emphasis added) maYor is used to store the major version number, I assume major is what was intended. This patch corrects the typo. --- .../tests-kernel_defines/tests-kernel_defines.c | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) diff --git a/tests/unittests/tests-kernel_defines/tests-kernel_defines.c b/tests/unittests/tests-kernel_defines/tests-kernel_defines.c index 5ea45f820d..214cf5d128 100644 --- a/tests/unittests/tests-kernel_defines/tests-kernel_defines.c +++ b/tests/unittests/tests-kernel_defines/tests-kernel_defines.c @@ -15,10 +15,10 @@ #include "embUnit.h" #include "kernel_defines.h" -static void kernel_version_parse(uint64_t version, uint16_t *mayor, +static void kernel_version_parse(uint64_t version, uint16_t *major, uint16_t *minor, uint16_t *patch, uint16_t *extra) { - *mayor = version >> 48; + *major = version >> 48; *minor = (version >> 32) & 0xFFFF; *patch = (version >> 16) & 0xFFFF; *extra = (version >> 0) & 0xFFFF; @@ -26,16 +26,16 @@ static void kernel_version_parse(uint64_t version, uint16_t *mayor, static void test_kernel_version(void) { - uint16_t mayor, minor, patch, extra; + uint16_t major, minor, patch, extra; TEST_ASSERT(RIOT_VERSION_CODE); TEST_ASSERT(RIOT_VERSION_CODE > RIOT_VERSION_NUM(2017, 1, 3, 0)); TEST_ASSERT(RIOT_VERSION_CODE < RIOT_VERSION_NUM(2080, 10, 2, 0)); kernel_version_parse(RIOT_VERSION_NUM(2020, 7, 1, 0), - &mayor, &minor, &patch, &extra); + &major, &minor, &patch, &extra); - TEST_ASSERT_EQUAL_INT(2020, mayor); + TEST_ASSERT_EQUAL_INT(2020, major); TEST_ASSERT_EQUAL_INT(7, minor); TEST_ASSERT_EQUAL_INT(1, patch); TEST_ASSERT_EQUAL_INT(0, extra);