logo

utils-std

Collection of commonly available Unix tools
commit: 4cb8965459be5328f5634814577ca745fe50ba0a
parent e03867c4144bffa78f26924e35f93a127521c411
Author: Haelwenn (lanodan) Monnier <contact@hacktivis.me>
Date:   Thu, 13 Jun 2024 14:51:46 +0200

test-cmd/true*: Change from ATF to tap.sh

Diffstat:

Mtest-cmd/Kyuafile2+-
Dtest-cmd/true25-------------------------
Atest-cmd/true.sh11+++++++++++
3 files changed, 12 insertions(+), 26 deletions(-)

diff --git a/test-cmd/Kyuafile b/test-cmd/Kyuafile @@ -18,7 +18,6 @@ atf_test_program{name="pwd", required_files=basedir.."/cmd/pwd", timeout=1} atf_test_program{name="strings", required_files=basedir.."/cmd/strings", timeout=1} atf_test_program{name="tee", required_files=basedir.."/cmd/tee", timeout=1} atf_test_program{name="touch", required_files=basedir.."/cmd/touch", timeout=3} -atf_test_program{name="true", required_files=basedir.."/cmd/true", timeout=1} atf_test_program{name="tty", required_files=basedir.."/cmd/tty", timeout=1} atf_test_program{name="unlink", required_files=basedir.."/cmd/unlink", timeout=1} tap_test_program{name="arch.sh", required_files=basedir.."/cmd/arch", timeout=1} @@ -30,4 +29,5 @@ tap_test_program{name="echo.sh", required_files=basedir.."/cmd/echo", timeout=1} tap_test_program{name="env.sh", required_files=basedir.."/cmd/env", timeout=1} tap_test_program{name="seq.sh", required_files=basedir.."/cmd/seq", timeout=1} tap_test_program{name="test.sh", required_files=basedir.."/cmd/test", timeout=2} +tap_test_program{name="true.sh", required_files=basedir.."/cmd/true", timeout=1} tap_test_program{name="uname.sh", required_files=basedir.."/cmd/uname", timeout=1} diff --git a/test-cmd/true b/test-cmd/true @@ -1,25 +0,0 @@ -#!/usr/bin/env atf-sh -# SPDX-FileCopyrightText: 2017 Haelwenn (lanodan) Monnier <contact+utils@hacktivis.me> -# SPDX-License-Identifier: MPL-2.0 - -atf_test_case basic -basic_body() { - atf_check ../cmd/true -} - -atf_test_case nohelp -nohelp_body() { - atf_check ../cmd/true --help -} - -atf_test_case devfull -devfull_body() { - atf_check ../cmd/true --help >/dev/full -} - -atf_init_test_cases() { - cd "$(atf_get_srcdir)" || exit 1 - atf_add_test_case basic - atf_add_test_case nohelp - atf_add_test_case devfull -} diff --git a/test-cmd/true.sh b/test-cmd/true.sh @@ -0,0 +1,11 @@ +#!/bin/sh +# SPDX-FileCopyrightText: 2017 Haelwenn (lanodan) Monnier <contact+utils@hacktivis.me> +# SPDX-License-Identifier: MPL-2.0 + +target="$(dirname "$0")/../cmd/true" +plans=3 +. "$(dirname "$0")/tap.sh" + +t basic '' '' +t nohelp '--help' '' +t noversion '--version' ''