false (746B)
- #!/usr/bin/env atf-sh
- # Copyright © 2021 Haelwenn (lanodan) Monnier <contact+system-testsuite@hacktivis.me>
- # SPDX-License-Identifier: BSD-3-Clause
- atf_test_case basic
- basic_body() {
- atf_check -s exit:1 false
- }
- atf_test_case nohelp
- nohelp_body() {
- atf_check -s exit:1 false --help
- }
- atf_test_case devfull
- devfull_body() {
- atf_check -s exit:1 false --help >/dev/full
- }
- atf_test_case closefds
- closefds_body() {
- atf_check -s exit:1 sh -c 'false --help >&-'
- atf_check -s exit:1 sh -c 'false --help 2>&-'
- atf_check -s exit:1 sh -c 'false --help <&-'
- atf_check -s exit:1 sh -c 'false --help <&- >&- 2>&-'
- }
- atf_init_test_cases() {
- atf_add_test_case basic
- atf_add_test_case nohelp
- atf_add_test_case devfull
- atf_add_test_case closefds
- }