aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorHans-Peter Nilsson <hp@axis.com>2004-11-22 13:00:24 +0000
committerHans-Peter Nilsson <hp@axis.com>2004-11-22 13:00:24 +0000
commita7eec87693b35bd94817259d6425e71352d8ba4e (patch)
tree7f8f6ece363cf8917038f913462e9456806e49d2
parent5519f6ea17e0a28647585aec32739d8ad8f52b12 (diff)
downloadgdb-a7eec87693b35bd94817259d6425e71352d8ba4e.zip
gdb-a7eec87693b35bd94817259d6425e71352d8ba4e.tar.gz
gdb-a7eec87693b35bd94817259d6425e71352d8ba4e.tar.bz2
* gas/all/gas.exp: Run dg-runtest for all err-*.s and warn-*.s.
* gas/all/err-1.s, gas/all/warn-1.s: New tests.
-rw-r--r--gas/testsuite/ChangeLog5
-rw-r--r--gas/testsuite/gas/all/err-1.s7
-rw-r--r--gas/testsuite/gas/all/gas.exp5
-rw-r--r--gas/testsuite/gas/all/warn-1.s7
4 files changed, 24 insertions, 0 deletions
diff --git a/gas/testsuite/ChangeLog b/gas/testsuite/ChangeLog
index 841d6fe..24d0b3c 100644
--- a/gas/testsuite/ChangeLog
+++ b/gas/testsuite/ChangeLog
@@ -1,3 +1,8 @@
+2004-11-22 Hans-Peter Nilsson <hp@axis.com>
+
+ * gas/all/gas.exp: Run dg-runtest for all err-*.s and warn-*.s.
+ * gas/all/err-1.s, gas/all/warn-1.s: New tests.
+
2004-11-18 Inderpreet Singh <inderpreetb@nioda.hcltech.com>
* gas/maxq10/call.d: Fix expected results now that bfd assembler
diff --git a/gas/testsuite/gas/all/err-1.s b/gas/testsuite/gas/all/err-1.s
new file mode 100644
index 0000000..68fbad5
--- /dev/null
+++ b/gas/testsuite/gas/all/err-1.s
@@ -0,0 +1,7 @@
+;# Test .error directive.
+;# { dg-do assemble }
+ .error "an error message" ;# { dg-error "Error: an error message" }
+ .error an error message ;# { dg-error "Error: .error argument must be a string" }
+ .error ;# { dg-error "Error: .error directive invoked in source file" }
+ .error ".error directive invoked in source file" ;# { dg-error "Error: .error directive invoked in source file" }
+ .error "" ;# { dg-error "Error: " }
diff --git a/gas/testsuite/gas/all/gas.exp b/gas/testsuite/gas/all/gas.exp
index 6b06a2b..966c112 100644
--- a/gas/testsuite/gas/all/gas.exp
+++ b/gas/testsuite/gas/all/gas.exp
@@ -194,3 +194,8 @@ if { [istarget "i*86-*-*pe*"] \
|| [istarget "i*86-*-mingw32*"] } {
gas_test "fastcall.s" "" "" "fastcall labels"
}
+
+load_lib gas-dg.exp
+dg-init
+dg-runtest [lsort [glob -nocomplain $srcdir/$subdir/err-*.s $srcdir/$subdir/warn-*.s]] "" ""
+dg-finish
diff --git a/gas/testsuite/gas/all/warn-1.s b/gas/testsuite/gas/all/warn-1.s
new file mode 100644
index 0000000..873f230
--- /dev/null
+++ b/gas/testsuite/gas/all/warn-1.s
@@ -0,0 +1,7 @@
+;# Test .warning directive.
+;# { dg-do assemble }
+ .warning "a warning message" ;# { dg-warning "Warning: a warning message" }
+ .warning a warning message ;# { dg-error "Error: .warning argument must be a string" }
+ .warning ;# { dg-warning "Warning: .warning directive invoked in source file" }
+ .warning ".warning directive invoked in source file" ;# { dg-warning "Warning: .warning directive invoked in source file" }
+ .warning "" ;# { dg-warning "Warning: " }