summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--README13
-rwxr-xr-xapts8
-rw-r--r--tests/generic-apk5
3 files changed, 9 insertions, 17 deletions
diff --git a/README b/README
index 65ec551..554f32b 100644
--- a/README
+++ b/README
@@ -1,18 +1,9 @@
Author: Jeff Bilyk<jbilyk@gmail.com>
Contributor: Natanael Copa <ncopa@alpinelinux.org>
-Version: 0.1
+Version: 0.2
APTS is designed to allow testing of either entire repositories of apk packages
-or one by one. When an error is encountered, the program exits with an error.
+or one by one. After running, a list of failed packages is displayed onscreen. Tests can either be for one or multiple packages, and are scripts that first install needed packages, run a series of commands to insure that the contents of the package work as expected, then remove the packages.
The file missing-tests shows current packages that do not have a test file
created for them.
-
-Usage:
-
-./apts <outputfile> <package(s)>
-outputfile - any file/device that you wish to have test results output to
-package - optional list of packages to test. If none are specified, all
- packages will be tested. If a package is specified that does not
- have an associated test file, it will be installed then removed using
- apk-tools.
diff --git a/apts b/apts
index 8cb4ccb..033b11b 100755
--- a/apts
+++ b/apts
@@ -4,6 +4,7 @@
# In theory, it will work on any distribution that uses the apk-tools
# package manager
# Author: Jeff Bilyk <jbilyk@gmail.com>
+# Contributor: Natanael Copa <ncopa@alpinelinux.org>
# Version History available at http://git.alpinelinux.org/cgit/apts/
# Get file to output to
@@ -14,7 +15,7 @@ usage() {
exit 1
}
-# dont not halt on fail by default
+# do not halt on fail by default
halt_on_fail=
# default outdir is current working dir
@@ -43,6 +44,11 @@ while getopts "d:eho:" opt; do
esac
done
+# Remove trailing slash from outdir
+if ! [ $outdir == "$PWD" ]; then
+ outdir=`echo "$outdir" | sed "s,/$,,"`;
+fi
+
#remove opts so that package(s) is $@
shift $(( $OPTIND - 1 ))
diff --git a/tests/generic-apk b/tests/generic-apk
deleted file mode 100644
index 20602c3..0000000
--- a/tests/generic-apk
+++ /dev/null
@@ -1,5 +0,0 @@
- if [ $@ = "generic-apk" ];
- then exit 0;
- fi
- apk_add $@
- apk_del $@