diff options
Diffstat (limited to 'tests/isup/isup_parse_test.c')
-rw-r--r-- | tests/isup/isup_parse_test.c | 15 |
1 files changed, 15 insertions, 0 deletions
diff --git a/tests/isup/isup_parse_test.c b/tests/isup/isup_parse_test.c index 8f99cdb..721e9ce 100644 --- a/tests/isup/isup_parse_test.c +++ b/tests/isup/isup_parse_test.c @@ -41,8 +41,23 @@ static void test_cic_parsing() ASSERT(hdr->msg_type, ISUP_MSG_GRS); } +static void test_grs_parsing() +{ + static const uint8_t isup_grs[] = {3, 0, 23, 1, 1, 28}; + struct isup_msg_hdr *hdr; + int range; + + hdr = (struct isup_msg_hdr *) isup_grs; + range = isup_parse_grs(&hdr->data[0], 3); + + ASSERT(range, 28); +} + int main(int argc, char **argv) { test_cic_parsing(); + test_grs_parsing(); + + printf("All tests passed.\n"); return 0; } |