summaryrefslogtreecommitdiffstats
path: root/tests/sys/kern
diff options
context:
space:
mode:
authorngie <ngie@FreeBSD.org>2015-10-05 03:25:30 +0000
committerngie <ngie@FreeBSD.org>2015-10-05 03:25:30 +0000
commit115d008392113efc6f844baa7cc407e9eaae63db (patch)
tree6cb521ad03ca5b254c0873d2b9f27a92482207c3 /tests/sys/kern
parenta9fe170df1126a5dccd5dea163934fb04a95b5b8 (diff)
downloadFreeBSD-src-115d008392113efc6f844baa7cc407e9eaae63db.zip
FreeBSD-src-115d008392113efc6f844baa7cc407e9eaae63db.tar.gz
Remove some paths preparing for a re-copy from head
Diffstat (limited to 'tests/sys/kern')
-rw-r--r--tests/sys/kern/execve/Makefile39
-rw-r--r--tests/sys/kern/execve/bad_interp_len4
-rw-r--r--tests/sys/kern/execve/dev_null_script4
-rw-r--r--tests/sys/kern/execve/execve_helper.c54
-rw-r--r--tests/sys/kern/execve/execve_test.sh115
-rw-r--r--tests/sys/kern/execve/good_aout.c45
-rw-r--r--tests/sys/kern/execve/good_script4
-rw-r--r--tests/sys/kern/execve/non_exist_shell4
-rw-r--r--tests/sys/kern/execve/script_arg4
-rw-r--r--tests/sys/kern/execve/script_arg_nospace4
10 files changed, 0 insertions, 277 deletions
diff --git a/tests/sys/kern/execve/Makefile b/tests/sys/kern/execve/Makefile
deleted file mode 100644
index 82c5d4b..0000000
--- a/tests/sys/kern/execve/Makefile
+++ /dev/null
@@ -1,39 +0,0 @@
-# $FreeBSD$
-
-TESTSDIR= ${TESTSBASE}/sys/kern/execve
-
-BINDIR= ${TESTSDIR}
-
-MAN=
-
-ATF_TESTS_SH+= execve_test
-
-PROGS+= good_aout
-PROGS+= execve_helper
-
-LDFLAGS.goodaout+= -static
-
-CLEANFILES+= empty
-CLEANFILES+= sparse_aout
-CLEANFILES+= trunc_aout
-
-SCRIPTS+= bad_interp_len
-SCRIPTS+= dev_null_script
-SCRIPTS+= empty
-SCRIPTS+= good_script
-SCRIPTS+= non_exist_shell
-SCRIPTS+= script_arg
-SCRIPTS+= script_arg_nospace
-SCRIPTS+= sparse_aout
-SCRIPTS+= trunc_aout
-
-empty:
- @touch $@
-
-sparse_aout:
- @truncate -s 20480 $@
-
-trunc_aout:
- @truncate -s 16 $@
-
-.include <bsd.test.mk>
diff --git a/tests/sys/kern/execve/bad_interp_len b/tests/sys/kern/execve/bad_interp_len
deleted file mode 100644
index 96c049f..0000000
--- a/tests/sys/kern/execve/bad_interp_len
+++ /dev/null
@@ -1,4 +0,0 @@
-#! 456789012345678 0123456789012345 789012345678 012345678901234 1234567890 1234567890 1234567890 1234567890 1234567890 1234567890 1234567890 1234567890 1234567890 1234567890 1234567890 1234567890 1234567890 1234567890 1234567890 1234567890 1234567890 1234567890 1234567890 1234567890 1234567890 1234567890 1234567890 1234567890 1234567890 1234567890 1234567890 1234567890 1234567890 1234567890 1234567890 1234567890 1234567890 1234567890 1234567890 1234567890 1234567890 1234567890 1234567890 1234567890 1234567890 1234567890 1234567890 1234567890 1234567890 1234567890 1234567890 1234567890 1234567890 1234567890 1234567890 1234567890 1234567890 1234567890 1234567890 1234567890 1234567890 1234567890 1234567890 1234567890 1234567890 1234567890 1234567890 1234567890 1234567890 1234567890 1234567890 1234567890 1234567890 1234567890 1234567890 1234567890 1234567890 1234567890 1234567890 1234567890 1234567890 1234567890 1234567890 1234567890 1234567890 1234567890 1234567890 1234567890 1234567890 1234567890 1234567890 1234567890 1234567890 1234567890 1234567890 1234567890 1234567890 1234567890 1234567890 1234567890 1234567890 1234567890 1234567890 1234567890 1234567890 1234567890 1234567890 1234567890 1234567890 1234567890 1234567890 1234567890 1234567890 1234567890 1234567890 1234567890 1234567890 1234567890 1234567890 1234567890 1234567890 1234567890 1234567890 1234567890 1234567890 1234567890 1234567890 1234567890 1234567890 1234567890 1234567890 1234567890 1234567890 1234567890 1234567890 1234567890
-# $FreeBSD$
-
-echo succeeded
diff --git a/tests/sys/kern/execve/dev_null_script b/tests/sys/kern/execve/dev_null_script
deleted file mode 100644
index 73b1020..0000000
--- a/tests/sys/kern/execve/dev_null_script
+++ /dev/null
@@ -1,4 +0,0 @@
-#! /dev/null
-# $FreeBSD$
-
-echo succeeded
diff --git a/tests/sys/kern/execve/execve_helper.c b/tests/sys/kern/execve/execve_helper.c
deleted file mode 100644
index 164a8f3..0000000
--- a/tests/sys/kern/execve/execve_helper.c
+++ /dev/null
@@ -1,54 +0,0 @@
-/* $NetBSD: doexec.c,v 1.8 2003/07/26 19:38:48 salo Exp $ */
-
-/*
- * Copyright (c) 1993 Christopher G. Demetriou
- * All rights reserved.
- *
- * Redistribution and use in source and binary forms, with or without
- * modification, are permitted provided that the following conditions
- * are met:
- * 1. Redistributions of source code must retain the above copyright
- * notice, this list of conditions and the following disclaimer.
- * 2. Redistributions in binary form must reproduce the above copyright
- * notice, this list of conditions and the following disclaimer in the
- * documentation and/or other materials provided with the distribution.
- * 3. All advertising materials mentioning features or use of this software
- * must display the following acknowledgement:
- * This product includes software developed for the
- * NetBSD Project. See http://www.NetBSD.org/ for
- * information about NetBSD.
- * 4. The name of the author may not be used to endorse or promote products
- * derived from this software without specific prior written permission.
- *
- * THIS SOFTWARE IS PROVIDED BY THE AUTHOR ``AS IS'' AND ANY EXPRESS OR
- * IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES
- * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED.
- * IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY DIRECT, INDIRECT,
- * INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT
- * NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
- * DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY
- * THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
- * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF
- * THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
- *
- * $FreeBSD$
- */
-
-#include <err.h>
-#include <errno.h>
-#include <stdio.h>
-#include <stdlib.h>
-#include <unistd.h>
-
-int
-main(int argc, char **argv)
-{
-
- if (argc != 2) {
- fprintf(stderr, "usage: %s <progname>\n", argv[0]);
- exit(2);
- }
-
- execve(argv[1], &argv[1], NULL);
- err(1, "");
-}
diff --git a/tests/sys/kern/execve/execve_test.sh b/tests/sys/kern/execve/execve_test.sh
deleted file mode 100644
index ef803a1..0000000
--- a/tests/sys/kern/execve/execve_test.sh
+++ /dev/null
@@ -1,115 +0,0 @@
-
-bad_interp_len_head()
-{
- atf_set "descr" "Bad interpreter length"
-}
-bad_interp_len_body()
-{
- atf_check -s exit:1 -e 'match:No such file or directory' -o empty \
- -x "cd $(atf_get_srcdir) && ./execve_helper bad_interp_len"
-}
-
-empty_head()
-{
- atf_set "descr" "Empty file"
-}
-empty_body()
-{
- atf_check -s exit:1 -e 'match:Exec format error' -o empty \
- -x "cd $(atf_get_srcdir) && ./execve_helper empty"
-}
-
-good_aout_head()
-{
- atf_set "descr" "Good a.out"
-}
-good_aout_body()
-{
- atf_check -s exit:0 -e empty -o 'match:succeeded' \
- -x "cd $(atf_get_srcdir) && ./execve_helper ./good_aout"
-}
-
-good_script_head()
-{
- atf_set "descr" "Good script"
-}
-good_script_body()
-{
- atf_check -s exit:0 -e empty -o 'match:succeeded' \
- -x "cd $(atf_get_srcdir) && ./execve_helper good_script"
-}
-
-non_exist_head()
-{
- atf_set "descr" "Non-existent file"
-}
-non_exist_body()
-{
- atf_check -s exit:1 -e 'match:No such file or directory' -o empty \
- -x "cd $(atf_get_srcdir) && ./execve_helper non_exist"
-}
-
-non_exist_shell_head()
-{
- atf_set "descr" "Non-existent shell"
-}
-non_exist_shell_body()
-{
- atf_check -s exit:1 -e 'match:No such file or directory' -o empty \
- -x "cd $(atf_get_srcdir) && ./execve_helper non_exist_shell"
-}
-
-script_arg_head()
-{
- atf_set "descr" "-x in the shebang"
-}
-script_arg_body()
-{
- atf_check -s exit:0 -e 'match:\+ echo succeeded' -o 'match:succeeded' \
- -x "cd $(atf_get_srcdir) && ./execve_helper script_arg"
-}
-
-script_arg_nospace_head()
-{
- atf_set "descr" '-x in the shebang; no space between #! and /bin/sh'
-}
-script_arg_nospace_body()
-{
- atf_check -s exit:0 -e 'match:\+ echo succeeded' -o 'match:succeeded' \
- -x "cd $(atf_get_srcdir) && ./execve_helper script_arg_nospace"
-}
-
-sparse_aout_head()
-{
- atf_set "descr" 'Sparse file'
-}
-sparse_aout_body()
-{
- atf_check -s exit:1 -e 'match:Exec format error' -o empty \
- -x "cd $(atf_get_srcdir) && ./execve_helper sparse_aout"
-}
-
-trunc_aout_head()
-{
- atf_set "descr" 'Truncated file'
-}
-trunc_aout_body()
-{
- atf_check -s exit:1 -e 'match:Exec format error' -o empty \
- -x "cd $(atf_get_srcdir) && ./execve_helper trunc_aout"
-}
-
-atf_init_test_cases()
-{
- atf_add_test_case bad_interp_len
- atf_add_test_case empty
- atf_add_test_case good_aout
- atf_add_test_case good_script
- atf_add_test_case non_exist
- atf_add_test_case non_exist_shell
- atf_add_test_case script_arg
- atf_add_test_case script_arg_nospace
- atf_add_test_case sparse_aout
- atf_add_test_case trunc_aout
-
-}
diff --git a/tests/sys/kern/execve/good_aout.c b/tests/sys/kern/execve/good_aout.c
deleted file mode 100644
index 39e9867..0000000
--- a/tests/sys/kern/execve/good_aout.c
+++ /dev/null
@@ -1,45 +0,0 @@
-/* $NetBSD: goodaout.c,v 1.8 2003/07/26 19:38:49 salo Exp $ */
-
-/*-
- * Copyright (c) 1993 Christopher G. Demetriou
- * All rights reserved.
- *
- * Redistribution and use in source and binary forms, with or without
- * modification, are permitted provided that the following conditions
- * are met:
- * 1. Redistributions of source code must retain the above copyright
- * notice, this list of conditions and the following disclaimer.
- * 2. Redistributions in binary form must reproduce the above copyright
- * notice, this list of conditions and the following disclaimer in the
- * documentation and/or other materials provided with the distribution.
- * 3. All advertising materials mentioning features or use of this software
- * must display the following acknowledgement:
- * This product includes software developed for the
- * NetBSD Project. See http://www.NetBSD.org/ for
- * information about NetBSD.
- * 4. The name of the author may not be used to endorse or promote products
- * derived from this software without specific prior written permission.
- *
- * THIS SOFTWARE IS PROVIDED BY THE AUTHOR ``AS IS'' AND ANY EXPRESS OR
- * IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES
- * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED.
- * IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY DIRECT, INDIRECT,
- * INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT
- * NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
- * DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY
- * THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
- * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF
- * THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
- *
- * $FreeBSD$
- */
-
-#include <stdio.h>
-#include <stdlib.h>
-
-int
-main(void)
-{
- printf("succeeded\n");
- exit(0);
-}
diff --git a/tests/sys/kern/execve/good_script b/tests/sys/kern/execve/good_script
deleted file mode 100644
index 11c7689..0000000
--- a/tests/sys/kern/execve/good_script
+++ /dev/null
@@ -1,4 +0,0 @@
-#!/bin/sh
-# $FreeBSD$
-
-echo succeeded
diff --git a/tests/sys/kern/execve/non_exist_shell b/tests/sys/kern/execve/non_exist_shell
deleted file mode 100644
index f9ee705..0000000
--- a/tests/sys/kern/execve/non_exist_shell
+++ /dev/null
@@ -1,4 +0,0 @@
-#! /foo/bar/baz
-# $FreeBSD$
-
-echo foo
diff --git a/tests/sys/kern/execve/script_arg b/tests/sys/kern/execve/script_arg
deleted file mode 100644
index 2700f1c..0000000
--- a/tests/sys/kern/execve/script_arg
+++ /dev/null
@@ -1,4 +0,0 @@
-#! /bin/sh -x
-# $FreeBSD$
-
-echo succeeded
diff --git a/tests/sys/kern/execve/script_arg_nospace b/tests/sys/kern/execve/script_arg_nospace
deleted file mode 100644
index 6731ad5..0000000
--- a/tests/sys/kern/execve/script_arg_nospace
+++ /dev/null
@@ -1,4 +0,0 @@
-#!/bin/sh -x
-# $FreeBSD$
-
-echo succeeded
OpenPOWER on IntegriCloud