| @@ -1,14 +1,14 @@ | | | @@ -1,14 +1,14 @@ |
1 | # $NetBSD: t_ssp.sh,v 1.7 2014/04/06 19:28:59 christos Exp $ | | 1 | # $NetBSD: t_ssp.sh,v 1.8 2023/11/10 23:03:25 christos Exp $ |
2 | # | | 2 | # |
3 | # Copyright (c) 2008 The NetBSD Foundation, Inc. | | 3 | # Copyright (c) 2008 The NetBSD Foundation, Inc. |
4 | # All rights reserved. | | 4 | # All rights reserved. |
5 | # | | 5 | # |
6 | # Redistribution and use in source and binary forms, with or without | | 6 | # Redistribution and use in source and binary forms, with or without |
7 | # modification, are permitted provided that the following conditions | | 7 | # modification, are permitted provided that the following conditions |
8 | # are met: | | 8 | # are met: |
9 | # 1. Redistributions of source code must retain the above copyright | | 9 | # 1. Redistributions of source code must retain the above copyright |
10 | # notice, this list of conditions and the following disclaimer. | | 10 | # notice, this list of conditions and the following disclaimer. |
11 | # 2. Redistributions in binary form must reproduce the above copyright | | 11 | # 2. Redistributions in binary form must reproduce the above copyright |
12 | # notice, this list of conditions and the following disclaimer in the | | 12 | # notice, this list of conditions and the following disclaimer in the |
13 | # documentation and/or other materials provided with the distribution. | | 13 | # documentation and/or other materials provided with the distribution. |
14 | # | | 14 | # |
| @@ -274,35 +274,49 @@ readlink_body() | | | @@ -274,35 +274,49 @@ readlink_body() |
274 | atf_test_case getcwd | | 274 | atf_test_case getcwd |
275 | getcwd_head() | | 275 | getcwd_head() |
276 | { | | 276 | { |
277 | atf_set "descr" "Checks getcwd(3)" | | 277 | atf_set "descr" "Checks getcwd(3)" |
278 | } | | 278 | } |
279 | getcwd_body() | | 279 | getcwd_body() |
280 | { | | 280 | { |
281 | prog="$(atf_get_srcdir)/h_getcwd" | | 281 | prog="$(atf_get_srcdir)/h_getcwd" |
282 | | | 282 | |
283 | h_pass "$prog 1024" | | 283 | h_pass "$prog 1024" |
284 | h_fail "$prog 1025" | | 284 | h_fail "$prog 1025" |
285 | } | | 285 | } |
286 | | | 286 | |
| | | 287 | atf_test_case getcwd2 |
| | | 288 | getcwd2_head() |
| | | 289 | { |
| | | 290 | atf_set "descr" "Checks getcwd(3) override" |
| | | 291 | } |
| | | 292 | getcwd2_body() |
| | | 293 | { |
| | | 294 | prog="$(atf_get_srcdir)/h_getcwd2" |
| | | 295 | |
| | | 296 | atf_check -s exit:1 -o ignore \ |
| | | 297 | -e 'match:.*getcwd failed: Function not implemented$' $prog |
| | | 298 | } |
| | | 299 | |
287 | atf_init_test_cases() | | 300 | atf_init_test_cases() |
288 | { | | 301 | { |
289 | atf_add_test_case sprintf | | 302 | atf_add_test_case sprintf |
290 | atf_add_test_case vsprintf | | 303 | atf_add_test_case vsprintf |
291 | atf_add_test_case snprintf | | 304 | atf_add_test_case snprintf |
292 | atf_add_test_case vsnprintf | | 305 | atf_add_test_case vsnprintf |
293 | atf_add_test_case gets | | 306 | atf_add_test_case gets |
294 | atf_add_test_case fgets | | 307 | atf_add_test_case fgets |
295 | atf_add_test_case memcpy | | 308 | atf_add_test_case memcpy |
296 | atf_add_test_case memmove | | 309 | atf_add_test_case memmove |
297 | atf_add_test_case memset | | 310 | atf_add_test_case memset |
298 | atf_add_test_case stpcpy | | 311 | atf_add_test_case stpcpy |
299 | atf_add_test_case stpncpy | | 312 | atf_add_test_case stpncpy |
300 | atf_add_test_case strcat | | 313 | atf_add_test_case strcat |
301 | atf_add_test_case strcpy | | 314 | atf_add_test_case strcpy |
302 | atf_add_test_case strncat | | 315 | atf_add_test_case strncat |
303 | atf_add_test_case strncpy | | 316 | atf_add_test_case strncpy |
304 | atf_add_test_case raw | | 317 | atf_add_test_case raw |
305 | atf_add_test_case read | | 318 | atf_add_test_case read |
306 | atf_add_test_case readlink | | 319 | atf_add_test_case readlink |
307 | atf_add_test_case getcwd | | 320 | atf_add_test_case getcwd |
| | | 321 | atf_add_test_case getcwd2 |
308 | } | | 322 | } |