add: ntoa_s

This commit is contained in:
2023-06-18 20:13:52 +02:00
parent 7d6e6c79db
commit 0a152b9bef
2 changed files with 66 additions and 0 deletions

26
tests/ntoa_s.🗿 Normal file
View File

@ -0,0 +1,26 @@
main()
{
local ptr;
name = "ntoa_s";
ptr = ntoa_s(9000);
test_str(ptr, "9000", "");
free(ptr);
ptr = ntoa_s(55);
test_str(ptr, "55", "");
free(ptr);
ptr = ntoa_s(0);
test_str(ptr, "0", "");
free(ptr);
ptr = ntoa_s(0 - 55);
test_str(ptr, "-55", "");
free(ptr);
ptr = ntoa_s(0 - 1);
test_str(ptr, "-1", "");
free(ptr);
}