aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorD. Bohdan <dbohdan@dbohdan.com>2020-05-27 13:00:19 +0000
committerSteve Bennett <steveb@workware.net.au>2020-05-28 08:01:26 +1000
commit201a1281ecafed4c20ef478588857380a04a8497 (patch)
tree70090c602d108f2d72c9ed84b4faa17d28ac586c
parent8c123720e88580b4693de1ef192e28616f3944f7 (diff)
downloadjimtcl-201a1281ecafed4c20ef478588857380a04a8497.zip
jimtcl-201a1281ecafed4c20ef478588857380a04a8497.tar.gz
jimtcl-201a1281ecafed4c20ef478588857380a04a8497.tar.bz2
test(aio,socket,tty): match musl error messages
-rw-r--r--tests/aio.test2
-rw-r--r--tests/socket.test6
-rw-r--r--tests/tty.test2
3 files changed, 5 insertions, 5 deletions
diff --git a/tests/aio.test b/tests/aio.test
index 361acdc..4b04dbd 100644
--- a/tests/aio.test
+++ b/tests/aio.test
@@ -116,7 +116,7 @@ test aio-7.1 {close args} -constraints socket -body {
test aio-7.2 {close w on non-socket} -constraints socket -body {
$f close w
-} -returnCodes error -result {Socket operation on non-socket}
+} -returnCodes error -match regexp -result {^(Socket operation on non-socket|Not a socket)$}
test aio-7.3 {close -nodelete on non-socket} -constraints socket -body {
$f close -nodelete
diff --git a/tests/socket.test b/tests/socket.test
index 20a5f2e..f2d940f 100644
--- a/tests/socket.test
+++ b/tests/socket.test
@@ -290,7 +290,7 @@ test socket-3.3 {listen usage} -body {
test socket-3.4 {listen not a socket} -body {
set f [open [info script]]
$f listen 10
-} -returnCodes error -match glob -result {Socket operation on non-socket} -cleanup {
+} -returnCodes error -match regexp -result {^(Socket operation on non-socket|Not a socket)$} -cleanup {
$f close
}
@@ -305,14 +305,14 @@ test socket-4.2 {invalid ipv4 address} -body {
test socket-4.3 {sockname on non-socket} -body {
set f [open [info script]]
$f sockname
-} -returnCodes error -result {Socket operation on non-socket} -cleanup {
+} -returnCodes error -match regexp -result {^(Socket operation on non-socket|Not a socket)$} -cleanup {
$f close
}
test socket-4.4 {peername on non-socket} -body {
set f [open [info script]]
$f peername
-} -returnCodes error -result {Socket operation on non-socket} -cleanup {
+} -returnCodes error -match regexp -result {^(Socket operation on non-socket|Not a socket)$} -cleanup {
$f close
}
diff --git a/tests/tty.test b/tests/tty.test
index a2606ab..53bea2c 100644
--- a/tests/tty.test
+++ b/tests/tty.test
@@ -24,7 +24,7 @@ test tty-1.3 {tty bad baud} -body {
test tty-1.4 {tty bad fd} -body {
set f [open [file tempfile] w]
$f tty
-} -returnCodes error -result {Inappropriate ioctl for device} -cleanup {
+} -returnCodes error -match regexp -result {^(Inappropriate ioctl for device|Not a tty)$} -cleanup {
$f close
}