diff options
author | Leah Neukirchen <leah@vuxu.org> | 2022-03-01 19:12:04 +0100 |
---|---|---|
committer | Leah Neukirchen <leah@vuxu.org> | 2022-03-01 19:12:04 +0100 |
commit | e800d5f8199b860ac8e1b151bf715eb951aeb28f (patch) | |
tree | d597bed9ca0097151bc37b7de341b0c30ef2ed59 | |
parent | aaa744cbf633b70e183796e69008cae1923dab00 (diff) | |
download | libste-e800d5f8199b860ac8e1b151bf715eb951aeb28f.tar.gz libste-e800d5f8199b860ac8e1b151bf715eb951aeb28f.tar.xz libste-e800d5f8199b860ac8e1b151bf715eb951aeb28f.zip |
add explicit test for dst==end
-rw-r--r-- | tests.c | 6 |
1 files changed, 5 insertions, 1 deletions
diff --git a/tests.c b/tests.c index 9255a70..306a693 100644 --- a/tests.c +++ b/tests.c @@ -16,7 +16,7 @@ is(char *desc, int ok) int main() { - printf("1..39\n"); + printf("1..40\n"); printf("# stecpy\n"); @@ -54,6 +54,10 @@ main() is("empty append works", strlen(buf) == 3); is("return value is unchanged", pos == prevpos); + pos = buf; + pos = stecpy(pos, end, "xyz"); + pos = stecpy(pos, pos, "foo"); + is("final append works", strlen(buf) == 3); printf("# steprn\n"); |