summaryrefslogtreecommitdiff
path: root/tests
diff options
context:
space:
mode:
Diffstat (limited to 'tests')
-rw-r--r--tests/ChangeLog9
-rwxr-xr-xtests/run_make_tests.pl4
-rw-r--r--tests/scripts/features/errors24
-rw-r--r--tests/scripts/features/parallelism2
-rw-r--r--tests/scripts/functions/wildcard10
-rw-r--r--tests/scripts/targets/FORCE11
-rw-r--r--tests/scripts/targets/PHONY11
-rw-r--r--tests/scripts/targets/SILENT11
8 files changed, 30 insertions, 52 deletions
diff --git a/tests/ChangeLog b/tests/ChangeLog
index 9320597..480d2fc 100644
--- a/tests/ChangeLog
+++ b/tests/ChangeLog
@@ -1,3 +1,12 @@
+2005-12-12 Paul D. Smith <psmith@gnu.org>
+
+ * scripts/features/parallelism, scripts/functions/wildcard,
+ scripts/targets/FORCE, scripts/targets/PHONY,
+ scripts/targets/SILENT: Use the default setting for
+ $delete_command. Fixes bug #15085.
+
+ * run_make_tests.pl (get_this_pwd) [VMS]: Use -no_ask with delete_file.
+
2005-12-11 Paul D. Smith <psmith@gnu.org>
* scripts/misc/general4: Test implicit rules with '$' in the
diff --git a/tests/run_make_tests.pl b/tests/run_make_tests.pl
index d51b72a..b7614e2 100755
--- a/tests/run_make_tests.pl
+++ b/tests/run_make_tests.pl
@@ -183,11 +183,11 @@ sub print_help
}
sub get_this_pwd {
- $delete_command = "rm";
+ $delete_command = 'rm -f';
if ($has_POSIX) {
$__pwd = POSIX::getcwd();
} elsif ($vos) {
- $delete_command = "delete_file";
+ $delete_command = "delete_file -no_ask";
$__pwd = `++(current_dir)`;
} else {
# No idea... just try using pwd as a last resort.
diff --git a/tests/scripts/features/errors b/tests/scripts/features/errors
index 253f50f..e372fe0 100644
--- a/tests/scripts/features/errors
+++ b/tests/scripts/features/errors
@@ -1,3 +1,5 @@
+# -*-perl-*-
+
$description = "The following tests the -i option and the '-' in front of \n"
."commands to test that make ignores errors in these commands\n"
."and continues processing.";
@@ -14,11 +16,11 @@ $details = "This test runs two makes. The first runs on a target with a \n"
if ($vos)
{
- $delete_command = "delete_file";
+ $rm_command = "delete_file";
}
else
{
- $delete_command = "rm";
+ $rm_command = "rm";
}
open(MAKEFILE,"> $makefile");
@@ -26,11 +28,11 @@ open(MAKEFILE,"> $makefile");
# The Contents of the MAKEFILE ...
print MAKEFILE "clean:\n"
- ."\t-$delete_command cleanit\n"
- ."\t$delete_command foo\n"
+ ."\t-$rm_command cleanit\n"
+ ."\t$rm_command foo\n"
."clean2: \n"
- ."\t$delete_command cleanit\n"
- ."\t$delete_command foo\n";
+ ."\t$rm_command cleanit\n"
+ ."\t$rm_command foo\n";
# END of Contents of MAKEFILE
@@ -39,16 +41,16 @@ close(MAKEFILE);
&touch("foo");
unlink("cleanit");
-$cleanit_error = `sh -c "$delete_command cleanit 2>&1"`;
+$cleanit_error = `sh -c "$rm_command cleanit 2>&1"`;
$delete_error_code = $? >> 8;
# TEST #1
# -------
-$answer = "$delete_command cleanit\n"
+$answer = "$rm_command cleanit\n"
. $cleanit_error
."$make_name: [clean] Error $delete_error_code (ignored)\n"
- ."$delete_command foo\n";
+ ."$rm_command foo\n";
&run_make_with_options($makefile,"",&get_logfile);
@@ -72,10 +74,10 @@ if (!$vos)
# TEST #2
# -------
-$answer = "$delete_command cleanit\n"
+$answer = "$rm_command cleanit\n"
. $cleanit_error
."$make_name: [clean2] Error $delete_error_code (ignored)\n"
- ."$delete_command foo\n";
+ ."$rm_command foo\n";
&run_make_with_options($makefile,"clean2 -i",&get_logfile);
diff --git a/tests/scripts/features/parallelism b/tests/scripts/features/parallelism
index c75f436..6bde30f 100644
--- a/tests/scripts/features/parallelism
+++ b/tests/scripts/features/parallelism
@@ -18,11 +18,9 @@ if (!$parallel_jobs) {
}
if ($vos) {
- $delete_command = "delete_file -no_ask";
$sleep_command = "sleep -seconds";
}
else {
- $delete_command = "rm -f";
$sleep_command = "sleep";
}
diff --git a/tests/scripts/functions/wildcard b/tests/scripts/functions/wildcard
index d7a50aa..d61384e 100644
--- a/tests/scripts/functions/wildcard
+++ b/tests/scripts/functions/wildcard
@@ -13,16 +13,6 @@ test echo's all files which match '?.example' and
[a-z0-9].example. Lastly we clean up all of the files using
the '*' wildcard as in the first test";
-if ($vos)
-{
- $delete_command = "delete_file -no_ask";
-}
-else
-{
- $delete_command = "rm";
-}
-
-
open(MAKEFILE,"> $makefile");
# The Contents of the MAKEFILE ...
diff --git a/tests/scripts/targets/FORCE b/tests/scripts/targets/FORCE
index befb326..eb8f251 100644
--- a/tests/scripts/targets/FORCE
+++ b/tests/scripts/targets/FORCE
@@ -1,16 +1,9 @@
+# -*-perl-*-
+
$description = "The following tests rules without Commands or Dependencies.";
$details = "If the rule ...\n";
-if ($vos)
-{
- $delete_command = "delete_file";
-}
-else
-{
- $delete_command = "rm";
-}
-
open(MAKEFILE,"> $makefile");
# The Contents of the MAKEFILE ...
diff --git a/tests/scripts/targets/PHONY b/tests/scripts/targets/PHONY
index dd46b3f..c8e2110 100644
--- a/tests/scripts/targets/PHONY
+++ b/tests/scripts/targets/PHONY
@@ -1,3 +1,5 @@
+# -*-perl-*-
+
$description = "The following tests the use of a PHONY target. It makes\n"
."sure that the rules under a target get executed even if\n"
."a filename of the same name of the target exists in the\n"
@@ -8,15 +10,6 @@ $details = "This makefile in this test declares the target clean to be a \n"
."directory. Although this file exists, the rule under the target\n"
."clean should still execute because of it's phony status.";
-if ($vos)
-{
- $delete_command = "delete_file";
-}
-else
-{
- $delete_command = "rm";
-}
-
$example = "EXAMPLE_FILE";
open(MAKEFILE,"> $makefile");
diff --git a/tests/scripts/targets/SILENT b/tests/scripts/targets/SILENT
index 5f9a1db..4bb0a0f 100644
--- a/tests/scripts/targets/SILENT
+++ b/tests/scripts/targets/SILENT
@@ -1,3 +1,5 @@
+# -*-perl-*-
+
$description = "The following tests the special target .SILENT. By simply\n"
."mentioning this as a target, it tells make not to print\n"
."commands before executing them.";
@@ -5,15 +7,6 @@ $description = "The following tests the special target .SILENT. By simply\n"
$details = "This test is the same as the clean test except that it should\n"
."not echo its command before deleting the specified file.\n";
-if ($vos)
-{
- $delete_command = "delete_file";
-}
-else
-{
- $delete_command = "rm";
-}
-
$example = "EXAMPLE_FILE";
open(MAKEFILE,"> $makefile");