summaryrefslogtreecommitdiffstats
path: root/tests/sms
diff options
context:
space:
mode:
Diffstat (limited to 'tests/sms')
-rw-r--r--tests/sms/sms_test.c15
-rw-r--r--tests/sms/sms_test.ok3
2 files changed, 18 insertions, 0 deletions
diff --git a/tests/sms/sms_test.c b/tests/sms/sms_test.c
index 6df4b623..e48f9a36 100644
--- a/tests/sms/sms_test.c
+++ b/tests/sms/sms_test.c
@@ -209,6 +209,19 @@ static const struct test_case test_decode[] =
},
};
+static void test_octet_return()
+{
+ char out[256];
+ int oct, septets;
+
+ printf("Encoding some tests and printing number of septets/octets\n");
+
+ septets = gsm_7bit_encode_oct((uint8_t *) out, "test1234", &oct);
+ printf("SEPTETS: %d OCTETS: %d\n", septets, oct);
+
+ printf("Done\n");
+}
+
int main(int argc, char** argv)
{
printf("SMS testing\n");
@@ -314,6 +327,8 @@ int main(int argc, char** argv)
}
}
+ test_octet_return();
+
printf("OK\n");
return 0;
}
diff --git a/tests/sms/sms_test.ok b/tests/sms/sms_test.ok
index d0e09838..ce6cb178 100644
--- a/tests/sms/sms_test.ok
+++ b/tests/sms/sms_test.ok
@@ -1,2 +1,5 @@
SMS testing
+Encoding some tests and printing number of septets/octets
+SEPTETS: 8 OCTETS: 7
+Done
OK