Skip to content

Commit

Permalink
small amend (better explaining test titles)
Browse files Browse the repository at this point in the history
  • Loading branch information
sebres committed Oct 31, 2024
1 parent 92a66db commit 46312b0
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions tests/clock.test
Original file line number Diff line number Diff line change
Expand Up @@ -337,15 +337,15 @@ test clock-1.4.1 "clock format - unexpected option for this sub-command" {
list [catch {clock format 0 -base 0} msg] $msg $::errorCode
} [subst {1 {bad option "-base": should be "$syntax"} {CLOCK badOption -base}}]

test clock-1.5 "clock format - bad timezone" -body {
test clock-1.5 "clock format - bad timezone (not found)" -body {
clock format 0 -format "%s" -timezone :NOWHERE
} -returnCodes 1 -result {time zone ":NOWHERE" not found} -errorCode {CLOCK badTimeZone :NOWHERE}
foreach tz [list {*}{
../UNSAFEPATH/NOWHERE UNSAFEPATH/../GMT //UNSAFEPATH/NOWHERE
zipfs:/UNSAFEPATH/NOWHERE C:/UNSAFEPATH/NOWHERE
} [list $::tcl::clock::DataDir/GMT]
] {
test clock-1.5.1 "clock format - bad timezone" -body {
test clock-1.5.1 "clock format - bad timezone (not valid - unsafe path)" -body {
clock format 0 -format "%s" -timezone $tz
} -returnCodes 1 -result "time zone \":$tz\" not valid" -errorCode [list CLOCK badTimeZone :$tz]
}
Expand Down

0 comments on commit 46312b0

Please sign in to comment.