code
stringlengths
1
1.96M
language
stringclasses
1 value
#!/bin/sh # for debug purposes #SVNCMD=echo SVNCMD=svn taglib_ver=1.9.1 tag_url=^/tags/ tag_full_url=https://wdxtaglib.googlecode.com/svn/tags/ taglib_url_root=http://taglib.github.io/releases/ cpu_count=$(grep -c ^processor /proc/cpuinfo) _set_common_vars() { if test -z "$working_root"; then working_root...
Shell
#!/bin/bash source _env.sh || echo "Run me from scripts directory" time _build_release $@ || exit
Shell
#!/bin/bash source _env.sh || echo "Run me from scripts directory" _make_release $@ || exit
Shell
#!/bin/bash source _env.sh || echo "Run me from scripts directory" time _build_release_version $@ || exit
Shell
#!/bin/sh sudo apt-get update && sudo apt-get -y install mingw-w64-dev cmake
Shell
#!/bin/bash source _env.sh || echo "Run me from scripts directory" time _build_wdx $@ || exit
Shell
#!/bin/bash source _env.sh || echo "Run me from scripts directory" _make_release $@ || exit
Shell
#!/bin/bash source _env.sh || echo "Run me from scripts directory" time _download_and_build_taglib $@ || exit
Shell
#!/bin/sh sudo apt-get update && sudo apt-get -y install mingw-w64-dev cmake
Shell
#!/bin/bash source _env.sh || echo "Run me from scripts directory" time _build_release_version $@ || exit
Shell
#!/bin/bash source _env.sh || echo "Run me from scripts directory" time _build_wdx $@ || exit
Shell
#!/bin/sh # for debug purposes #SVNCMD=echo SVNCMD=svn taglib_ver=1.9.1 tag_url=^/tags/ tag_full_url=https://wdxtaglib.googlecode.com/svn/tags/ taglib_url_root=http://taglib.github.io/releases/ cpu_count=$(grep -c ^processor /proc/cpuinfo) _set_common_vars() { if test -z "$working_root"; then working_root...
Shell
#!/bin/bash source _env.sh || echo "Run me from scripts directory" time _build_release $@ || exit
Shell
#!/bin/bash source _env.sh || echo "Run me from scripts directory" time _download_and_build_taglib $@ || exit
Shell
#!/bin/sh # for debug purposes #SVNCMD=echo SVNCMD=svn taglib_ver=1.9.1 tag_url=^/tags/ tag_full_url=https://wdxtaglib.googlecode.com/svn/tags/ taglib_url_root=http://taglib.github.io/releases/ cpu_count=$(grep -c ^processor /proc/cpuinfo) _set_common_vars() { if test -z "$working_root"; then working_root...
Shell
#!/bin/bash source _env.sh || echo "Run me from scripts directory" time _build_release $@ || exit
Shell
#!/bin/bash source _env.sh || echo "Run me from scripts directory" _make_release $@ || exit
Shell
#!/bin/bash source _env.sh || echo "Run me from scripts directory" time _build_release_version $@ || exit
Shell
#!/bin/sh sudo apt-get install wget zip cmake && \ sudo apt-get --assume-yes remove mingw32 && \ sudo apt-get --assume-yes install build-essential mingw-w64 g++-mingw-w64 libz-dev
Shell
#!/bin/bash source _env.sh || echo "Run me from scripts directory" time _build_wdx $@ || exit
Shell
#!/bin/bash source _env.sh || echo "Run me from scripts directory" _make_release $@ || exit
Shell
#!/bin/bash source _env.sh || echo "Run me from scripts directory" time _download_and_build_taglib $@ || exit
Shell
#!/bin/sh sudo apt-get install wget zip cmake && \ sudo apt-get --assume-yes remove mingw32 && \ sudo apt-get --assume-yes install build-essential mingw-w64 g++-mingw-w64 libz-dev
Shell
#!/bin/bash source _env.sh || echo "Run me from scripts directory" time _build_release_version $@ || exit
Shell
#!/bin/bash source _env.sh || echo "Run me from scripts directory" time _build_wdx $@ || exit
Shell
#!/bin/sh # for debug purposes #SVNCMD=echo SVNCMD=svn taglib_ver=1.9.1 tag_url=^/tags/ tag_full_url=https://wdxtaglib.googlecode.com/svn/tags/ taglib_url_root=http://taglib.github.io/releases/ cpu_count=$(grep -c ^processor /proc/cpuinfo) _set_common_vars() { if test -z "$working_root"; then working_root...
Shell
#!/bin/sh working_root="/tmp" wdxtaglibstagedir="/tmp/wdxtaglib-stage" wdxtaglibbuilddir="/tmp/wdxtaglib-build" package="wdx_WDXTagLib_1.1.0.zip" artifact="wdxtaglib.wdx" artifact64="$artifact"64 ./build-all.sh "$wdxtaglibstagedir" "$wdxtaglibbuilddir" || exit # save package #paket lezhit ne v stage a v build papke ...
Shell
#!/bin/sh #"$working_root" "$toolchainfile" "$taglibstagedir" $with_64bit toolchainfile="$1" working_root="$2" taglibstagedir="$3" with_64bit="$4" cpu_count=$(grep -c ^processor /proc/cpuinfo) ver=1.8 package=taglib-$ver archive=$package.tar.gz url=http://taglib.github.io/releases/$archive if test ! -f "$toolchainf...
Shell
#!/bin/sh working_root="/tmp" wdxtaglibstagedir="/tmp/wdxtaglib-stage" wdxtaglibbuilddir="/tmp/wdxtaglib-build" package="wdx_WDXTagLib_1.1.0.zip" artifact="wdxtaglib.wdx" artifact64="$artifact"64 ./build-all.sh "$wdxtaglibstagedir" "$wdxtaglibbuilddir" || exit # save package #paket lezhit ne v stage a v build papke ...
Shell
#!/bin/sh wdxtaglibstagedir=$1 wdxtaglibbuilddir=$2 with_64bit=$3 # set current dir to scripts dir or run me from scripts dir directly wdxtaglib_root=$(pwd)/.. toolchainfile="$wdxtaglib_root/mk/toolchain-cross-mingw32-linux.cmake" working_root="/tmp/wdxtaglib" if test "$with_64bit" = "64"; then working_root="$work...
Shell
#!/bin/sh #"$toolchainfile" "$wdxtaglib_root" "$taglibstagedir" "$working_root" "$wdxtaglibstagedir" "$wdxtaglibbuilddir" $with_64bit toolchainfile="$1" wdxtaglib_root="$2" taglibstagedir="$3" working_root="$4" wdxtaglibstagedir="$5" wdxtaglibbuilddir="$6" with_64bit="$7" cpu_count=$(grep -c ^processor /proc/cpuinfo)...
Shell
#!/bin/sh #"$working_root" "$toolchainfile" "$taglibstagedir" $with_64bit toolchainfile="$1" working_root="$2" taglibstagedir="$3" with_64bit="$4" cpu_count=$(grep -c ^processor /proc/cpuinfo) ver=1.8 package=taglib-$ver archive=$package.tar.gz url=http://taglib.github.io/releases/$archive if test ! -f "$toolchainf...
Shell
#!/bin/sh wdxtaglibstagedir=$1 wdxtaglibbuilddir=$2 with_64bit=$3 # set current dir to scripts dir or run me from scripts dir directly wdxtaglib_root=$(pwd)/.. toolchainfile="$wdxtaglib_root/mk/toolchain-cross-mingw32-linux.cmake" working_root="/tmp/wdxtaglib" if test "$with_64bit" = "64"; then working_root="$work...
Shell
#!/bin/sh #"$toolchainfile" "$wdxtaglib_root" "$taglibstagedir" "$working_root" "$wdxtaglibstagedir" "$wdxtaglibbuilddir" $with_64bit toolchainfile="$1" wdxtaglib_root="$2" taglibstagedir="$3" working_root="$4" wdxtaglibstagedir="$5" wdxtaglibbuilddir="$6" with_64bit="$7" cpu_count=$(grep -c ^processor /proc/cpuinfo)...
Shell
#!/bin/sh working_root="/tmp" wdxtaglibstagedir="/tmp/wdxtaglib-stage" wdxtaglibbuilddir="/tmp/wdxtaglib-build" package="wdx_WDXTagLib_1.1.1.zip" artifact="wdxtaglib.wdx" artifact64="$artifact"64 rm -rf "$wdxtaglibstagedir" || exit rm -rf "$wdxtaglibbuilddir" || exit ./build-all.sh "$wdxtaglibstagedir" "$wdxtaglibbui...
Shell
#!/bin/sh #"$working_root" "$toolchainfile" "$taglibstagedir" $with_64bit toolchainfile="$1" working_root="$2" taglibstagedir="$3" with_64bit="$4" cpu_count=$(grep -c ^processor /proc/cpuinfo) ver=1.8 package=taglib-$ver archive=$package.tar.gz url=http://taglib.github.io/releases/$archive if test ! -f "$toolchainf...
Shell
#!/bin/sh working_root="/tmp" wdxtaglibstagedir="/tmp/wdxtaglib-stage" wdxtaglibbuilddir="/tmp/wdxtaglib-build" package="wdx_WDXTagLib_1.1.1.zip" artifact="wdxtaglib.wdx" artifact64="$artifact"64 rm -rf "$wdxtaglibstagedir" || exit rm -rf "$wdxtaglibbuilddir" || exit ./build-all.sh "$wdxtaglibstagedir" "$wdxtaglibbui...
Shell
#!/bin/sh wdxtaglibstagedir=$1 wdxtaglibbuilddir=$2 with_64bit=$3 # set current dir to scripts dir or run me from scripts dir directly wdxtaglib_root=$(pwd)/.. toolchainfile="$wdxtaglib_root/mk/toolchain-cross-mingw32-linux.cmake" working_root="/tmp/wdxtaglib" if test "$with_64bit" = "64"; then working_root="$work...
Shell
#!/bin/sh #"$toolchainfile" "$wdxtaglib_root" "$taglibstagedir" "$working_root" "$wdxtaglibstagedir" "$wdxtaglibbuilddir" $with_64bit toolchainfile="$1" wdxtaglib_root="$2" taglibstagedir="$3" working_root="$4" wdxtaglibstagedir="$5" wdxtaglibbuilddir="$6" with_64bit="$7" cpu_count=$(grep -c ^processor /proc/cpuinfo)...
Shell
#!/bin/sh #"$working_root" "$toolchainfile" "$taglibstagedir" $with_64bit toolchainfile="$1" working_root="$2" taglibstagedir="$3" with_64bit="$4" cpu_count=$(grep -c ^processor /proc/cpuinfo) ver=1.8 package=taglib-$ver archive=$package.tar.gz url=http://taglib.github.io/releases/$archive if test ! -f "$toolchainf...
Shell
#!/bin/sh wdxtaglibstagedir=$1 wdxtaglibbuilddir=$2 with_64bit=$3 # set current dir to scripts dir or run me from scripts dir directly wdxtaglib_root=$(pwd)/.. toolchainfile="$wdxtaglib_root/mk/toolchain-cross-mingw32-linux.cmake" working_root="/tmp/wdxtaglib" if test "$with_64bit" = "64"; then working_root="$work...
Shell
#!/bin/sh #"$toolchainfile" "$wdxtaglib_root" "$taglibstagedir" "$working_root" "$wdxtaglibstagedir" "$wdxtaglibbuilddir" $with_64bit toolchainfile="$1" wdxtaglib_root="$2" taglibstagedir="$3" working_root="$4" wdxtaglibstagedir="$5" wdxtaglibbuilddir="$6" with_64bit="$7" cpu_count=$(grep -c ^processor /proc/cpuinfo)...
Shell
#!/bin/bash source _env.sh || echo "Run me from scripts directory" _build_release $@ || exit
Shell
#!/bin/bash source _env.sh || echo "Run me from scripts directory" _download_and_build_taglib $@ || exit
Shell
#!/bin/sh # for debug purposes #SVNCMD=echo SVNCMD=svn taglib_ver=1.9.1 tag_url=^/tags/ tag_full_url=https://wdxtaglib.googlecode.com/svn/tags/ taglib_url_root=http://taglib.github.io/releases/ cpu_count=$(grep -c ^processor /proc/cpuinfo) _set_common_vars() { if test -z "$working_root"; then working_root...
Shell
#!/bin/bash source _env.sh || echo "Run me from scripts directory" _build_release $@ || exit
Shell
#!/bin/bash source _env.sh || echo "Run me from scripts directory" _make_release $@ || exit
Shell
#!/bin/bash source _env.sh || echo "Run me from scripts directory" _build_release_version $@ || exit
Shell
#!/bin/bash source _env.sh || echo "Run me from scripts directory" _build_wdx $@ || exit
Shell
#!/bin/bash source _env.sh || echo "Run me from scripts directory" _make_release $@ || exit
Shell
#!/bin/bash source _env.sh || echo "Run me from scripts directory" _download_and_build_taglib $@ || exit
Shell
#!/bin/bash source _env.sh || echo "Run me from scripts directory" _build_release_version $@ || exit
Shell
#!/bin/bash source _env.sh || echo "Run me from scripts directory" _build_wdx $@ || exit
Shell
#!/bin/sh # for debug purposes #SVNCMD=echo SVNCMD=svn taglib_ver=1.9.1 tag_url=^/tags/ tag_full_url=https://wdxtaglib.googlecode.com/svn/tags/ taglib_url_root=http://taglib.github.io/releases/ cpu_count=$(grep -c ^processor /proc/cpuinfo) _set_common_vars() { if test -z "$working_root"; then working_root...
Shell
#!/bin/bash # # Copyright 2010 Google Inc. # # Licensed under the Apache License, Version 2.0 (the "License"); # you may not use this file except in compliance with the License. # You may obtain a copy of the License at # # http://www.apache.org/licenses/LICENSE-2.0 # # Unless required by applicable law or agreed ...
Shell
#!/bin/bash #!/bin/bash if [ ! -x $ANDROID_SDK_HOME/tools/android ]; then echo android too not found echo did you set '$ANDROID_SDK_HOME'? exit -1 fi #target=android-4 #$ANDROID_SDK_HOME/tools/android update project --subprojects --target $target --path . || exit -1 # build main application #ant clean #ant de...
Shell
#!/bin/sh $THIS_SH -c ' hup() { echo "child got HUP" } trap hup HUP echo "child sleeps" sleep 1 echo "child exits" ' & child=$! sleep 0.1 # let child install handler first kill -HUP $child wait echo "parent exits"
Shell
#!/bin/sh $THIS_SH -c ' cleanup() { echo "child exits as expected" exit } trap cleanup HUP echo "child sleeps" sleep 1 echo "BAD exit from child!" ' & child=$! sleep 0.1 # let child install handler first kill -HUP $child wait echo "parent exits"
Shell
#!/bin/sh trap "echo Trapped" BADNAME TERM; echo $? kill $$ echo Ok
Shell
#!/bin/sh # Must not find us alive { sleep 2; kill -9 $$; } 2>/dev/null & sleep 1 & PID=$! # We must exit the loop in one second. # We had bug 5304: builtins never waited for exited children while kill -0 $PID >/dev/null 2>&1; do true done echo Ok
Shell
#!/bin/sh TOPDIR=$PWD test -x ash || { echo "No ./ash - creating a link to ../../busybox" ln -s ../../busybox ash } test -x printenv || gcc -O2 -o printenv printenv.c || exit $? test -x recho || gcc -O2 -o recho recho.c || exit $? test -x zecho || gcc -O2 -o zecho zecho.c || exit $? PATH="$...
Shell
#!/bin/sh # hush's stderr with leak debug enabled output=output freelist=`grep 'free 0x' "$output" | cut -d' ' -f2 | sort | uniq | xargs` grep -v free "$output" >"$output.leaked" i=8 list= for freed in $freelist; do list="$list -e $freed" test $((--i)) != 0 && continue echo Dropping $list grep -F -v...
Shell
#!/bin/sh unset LANG LANGUAGE unset LC_COLLATE unset LC_CTYPE unset LC_MONETARY unset LC_MESSAGES unset LC_NUMERIC unset LC_TIME unset LC_ALL if test ! -x hush; then if test ! -x ../../busybox; then echo "Can't run tests. Put hush binary into this directory (`pwd`)" exit 1 fi echo "No ./hush - creating a link ...
Shell
#!/bin/sh test -x msh || { echo "No ./msh - creating a link to ../../busybox" ln -s ../../busybox msh } PATH="$PWD:$PATH" # for msh export PATH THIS_SH="$PWD/msh" export THIS_SH do_test() { test -d "$1" || return 0 # echo Running tests in directory "$1" ( cd "$1" || { echo "cannot cd $1!"; exi...
Shell
#!/bin/sh # TODO: use getopt to avoid parsing options as filenames, # and to support -- and --help [ $# -ne 0 ] && DASH_I=-i sed $DASH_I -e 's/$/\r/' "$@"
Shell
#!/bin/sh cat /etc/nologin.txt 2>/dev/null || echo "This account is not available" sleep 5 exit 1
Shell
#!/bin/sh # TODO: use getopt to avoid parsing options as filenames, # and to support -- and --help for i in "$@" do sed -e '1!G;h;$!d' "$i" done
Shell
#!/bin/sh # TODO: use getopt to avoid parsing options as filenames, # and to support -- and --help [ $# -ne 0 ] && DASH_I=-i sed $DASH_I -e 's/\r$//' "$@"
Shell
#!/bin/sh # Copyright 2008 by Denys Vlasenko <vda.linux@googlemail.com> # Licensed under GPLv2, see file LICENSE in this source tree. . ./testing.sh # testing "description" "command" "result" "infile" "stdin" testing "comm test 1" "comm input -" "\t123\n""456\n""abc\n""\tdef\n" "456\nabc\n" "123\ndef\n...
Shell
#!/bin/sh # Copyright 2007 by Denys Vlasenko <vda.linux@googlemail.com> # Licensed under GPLv2, see file LICENSE in this source tree. . ./testing.sh # testing "test name" "command" "expected result" "file input" "stdin" # file input will be file called "input" # test can create a file "actual" instead of writing...
Shell
#!/bin/sh # Tests for busybox applet itself. # Copyright 2005 by Rob Landley <rob@landley.net> # Licensed under GPLv2, see file LICENSE in this source tree. . ./testing.sh HELPDUMP=`true | busybox 2>&1 | cat` # We need to test under calling the binary under other names. optional FEATURE_VERBOSE_USAGE testing "busy...
Shell
#!/bin/sh # Tests for the sourcecode base itself. # Copyright 2006 by Mike Frysinger <vapier@gentoo.org> # Licensed under GPLv2, see file LICENSE in this source tree. [ -n "$srcdir" ] || srcdir=$(pwd) . ./testing.sh # # if we don't have the sourcecode available, let's just bail # [ -s "$srcdir/../Makefile" ] || exi...
Shell
#!/bin/sh # Copyright 2008 by Denys Vlasenko # Licensed under GPLv2, see file LICENSE in this source tree. . ./testing.sh # testing "test name" "commands" "expected result" "file input" "stdin" # diff outputs date/time in the header, which should not be analysed # NB: sed has tab character in s command! TRIM_TAB="se...
Shell
#!/bin/sh # Copyright 2005 by Rob Landley <rob@landley.net> # Licensed under GPLv2, see file LICENSE in this source tree. # AUDIT: . ./testing.sh # testing "test name" "commands" "expected result" "file input" "stdin" # file input will be file called "input" # test can create a file "actual" instead of writing ...
Shell
#!/bin/sh # Copyright 2007 by Denys Vlasenko <vda.linux@googlemail.com> # Licensed under GPLv2, see file LICENSE in this source tree. . ./testing.sh test -f "$bindir/.config" && . "$bindir/.config" test "`id -u`" = 0 || { echo "SKIPPED: mount (must be root to test this)" exit 0 } if test x"$CONFIG_MKFS_MINIX" != x...
Shell
#!/bin/sh . ./md5sum.tests sha256sum 8e1d3ed57ebc130f0f72508446559eeae06451ae6d61b1e8ce46370cfb8963c3
Shell
#!/bin/sh # Tests for unzip. # Copyright 2006 Rob Landley <rob@landley.net> # Copyright 2006 Glenn McGrath # Licensed under GPLv2, see file LICENSE in this source tree. . ./testing.sh # testing "test name" "options" "expected result" "file input" "stdin" # file input will be file called "input" # test can create...
Shell
#!/bin/sh # Copyright 2009 by Denys Vlasenko <vda.linux@googlemail.com> # Licensed under GPLv2, see file LICENSE in this source tree. . ./testing.sh # testing "description" "arguments" "result" "infile" "stdin" testing "tr does not treat [] in [a-z] as special" \ "tr '[q-z]' '_Q-Z+'" \ "_QWe+" "" "[qwe]" testing...
Shell
#!/bin/sh # Copyright 2008 by Denys Vlasenko # Licensed under GPLv2, see file LICENSE in this source tree. . ./testing.sh # testing "test name" "commands" "expected result" "file input" "stdin" optional DESKTOP testing "od -b" \ "od -b" \ "\ 0000000 110 105 114 114 117 0000005 " \ "" "HELLO" SKIP= optional DESKTO...
Shell
#!/bin/sh # Copyright 2008 by Denys Vlasenko <vda.linux@googlemail.com> # Licensed under GPLv2, see file LICENSE in this source tree. . ./testing.sh COLLAPSE=$(( 0x00010000)) TRIM=$(( 0x00020000)) GREEDY=$(( 0x00040000)) MIN_DIE=$(( 0x00100000)) KEEP_COPY=$((0x00200000)) ESCAPE=$(( 0x00400000)) NORMAL=$(( ...
Shell
#!/bin/sh # Copyright 2008 by Denys Vlasenko # Licensed under GPLv2, see file LICENSE in this source tree. . ./testing.sh test x"`id -u`" = x"0" || { echo "SKIPPED: makedevs (must be root to test this)" exit 0 } unset LANG unset LC_COLLATE unset LC_ALL # ls -ln is showing date. Need to remove that, it's variable ...
Shell
#!/bin/sh . ./md5sum.tests sha512sum fe413e0f177324d1353893ca0772ceba83fd41512ba63895a0eebb703ef9feac2fb4e92b2cb430b3bda41b46b0cb4ea8307190a5cc795157cfb680a9cd635d0f
Shell
#!/bin/sh # SUSv3 compliant sed tests. # Copyright 2005 by Rob Landley <rob@landley.net> # Licensed under GPLv2, see file LICENSE in this source tree. . ./testing.sh # testing "description" "commands" "result" "infile" "stdin" # Corner cases testing "sed no files (stdin)" 'sed ""' "hello\n" "" "hello\n" testing "se...
Shell
#!/bin/sh # Copyright 2007 by Denys Vlasenko <vda.linux@googlemail.com> # Licensed under GPLv2, see file LICENSE in this source tree. . ./testing.sh # testing "description" "command" "result" "infile" "stdin" testing "awk -F case 0" "awk -F '[#]' '{ print NF }'" "" "" "" testing "awk -F case 1" "awk -F '[#]' '{ ...
Shell
#!/bin/sh # Used by both gunzip and bunzip2 tests FAILCOUNT=0 if test "${0##*/}" = "gunzip.tests"; then unpack=gunzip ext=gz elif test "${0##*/}" = "bunzip2.tests"; then unpack=bunzip2 ext=bz2 else echo "WTF? argv0='$0'" exit 1 fi bb="busybox " unset LC_ALL unset LC_MESSAGES unset LANG unset...
Shell
#!/bin/sh # Copyright 2009 by Denys Vlasenko # Licensed under GPLv2, see file LICENSE in this source tree. . ./testing.sh test -f "$bindir/.config" && . "$bindir/.config" # testing "test name" "options" "expected result" "file input" "stdin" testing "fold -s" "fold -w 7 -s" \ "123456\n\t\nasdf" \ "" ...
Shell
#!/bin/sh # Copyright 2010 by Denys Vlasenko # Licensed under GPLv2, see file LICENSE in this source tree. . ./testing.sh test -f "$bindir/.config" && . "$bindir/.config" rm -rf ls.testdir 2>/dev/null mkdir ls.testdir || exit 1 # testing "test name" "command" "expected result" "file input" "stdin" # With Unicode pr...
Shell
#!/bin/sh # Copyright 2008 by Denys Vlasenko # Licensed under GPLv2, see file LICENSE in this source tree. . ./testing.sh # testing "test name" "command" "expected result" "file input" "stdin" testing "xargs -E _ stops on underscore" \ "xargs -E _" \ "a\n" \ "" "a\n_\nb\n" testing "xargs -E ''" \ "xargs -E ''" ...
Shell
#!/bin/sh # Copyright 2007 by Denys Vlasenko <vda.linux@googlemail.com> # Licensed under GPLv2, see file LICENSE in this source tree. . ./testing.sh # testing "test name" "options" "expected result" "file input" "stdin" # file input will be file called "input" # test can create a file "actual" instead of writing...
Shell
#!/bin/sh # Copyright 2008 by Denys Vlasenko # Licensed under GPLv2, see file LICENSE in this source tree. . ./testing.sh test -f "$bindir/.config" && . "$bindir/.config" # testing "test name" "options" "expected result" "file input" "stdin" testing "unexpand case 1" "unexpand" \ "\t12345678\n" "" " 12345678...
Shell
#!/bin/sh # Copyright 2006 Bernhard Reutner-Fischer # Licensed under GPLv2 or later, see file LICENSE in this source tree. . ./testing.sh a="taskset" # testing "test name" "opts" "expected result" "file inp" "stdin" testing "taskset (get from pid 1)" "$a -p 1 >/dev/null;echo \$?" "0\n" "" "" testing "tas...
Shell
#!/bin/sh # Copyright 2010 Nokia Corporation # Written by Alexander Shishkin # Licensed under GPLv2 or later, see file LICENSE in this source tree. . ./testing.sh # testing "test name" "command(s)" "expected result" "file input" "stdin" optional FEATURE_AR_CREATE rm test.a 2>/dev/null testing "ar creates archives" ...
Shell
#!/bin/sh # Copyright 2008 by Denys Vlasenko # Licensed under GPLv2, see file LICENSE in this source tree. . ./testing.sh umask 022 # ls -ln shows date. Need to remove that, it's variable. # sed: coalesce spaces # cut: remove date # grep: remove "total NNN" lines FILTER_LS="sed 's/ */ /g' | cut -d' ' -f 1-5,9- | gr...
Shell
#!/bin/sh # SUSv3 compliant seq tests. # Copyright 2006 by Rob Landley <rob@landley.net> # Licensed under GPLv2, see file LICENSE in this source tree. # AUDIT: Full SUSv3 coverage (except internationalization). . ./testing.sh # testing "test name" "options" "expected result" "file input" "stdin" # file input will...
Shell
#!/bin/sh # Copyright 2008 by Denys Vlasenko # Licensed under GPLv2, see file LICENSE in this source tree. . ./testing.sh # Need this in order to not execute shell builtin bb="busybox " # testing "test name" "command" "expected result" "file input" "stdin" testing "printf produces no further output 1" \ "${bb}prin...
Shell
#!/bin/sh # Usage: # runtest [applet1] [applet2...] . ./testing.sh total_failed=0 # Run one old-style test. # Tests are stored in applet/testcase shell scripts. # They are run using "sh -x -e applet/testcase". # Option -e will make testcase stop on the first failed command. run_applet_testcase() { local applet="$1"...
Shell
#!/bin/sh # Copyright 2008 by Denys Vlasenko # Licensed under GPLv2, see file LICENSE in this source tree. . ./testing.sh test -f "$bindir/.config" && . "$bindir/.config" # testing "test name" "options" "expected result" "file input" "stdin" testing "expand" \ "expand" \ " 12345678 12345678\n" \ "" ...
Shell
#!/bin/sh # SUSv3 compliant sort tests. # Copyright 2005 by Rob Landley <rob@landley.net> # Licensed under GPLv2, see file LICENSE in this source tree. . ./testing.sh # The basic tests. These should work even with the small busybox. testing "sort" "sort input" "a\nb\nc\n" "c\na\nb\n" "" testing "sort #2" "sort inp...
Shell
#!/bin/sh # pidof tests. # Copyright 2005 by Bernhard Reutner-Fischer # Licensed under GPLv2, see file LICENSE in this source tree. # AUDIT: . ./testing.sh # testing "test name" "options" "expected result" "file input" "stdin" testing "pidof (exit with error)" \ "pidof veryunlikelyoccuringbinaryname ; echo \$?" "...
Shell
#!/bin/sh # unit test for uuencode to test functionality. # Copyright 2006 by Erik Hovland <erik@hovland.org> # Licensed under GPLv2, see file LICENSE in this source tree. # AUDIT: Unit tests for uuencode . ./testing.sh # testing "test name" "command(s)" "expected result" "file input" "stdin" # file input will be f...
Shell