summaryrefslogtreecommitdiffstats
path: root/tests/source.test
diff options
context:
space:
mode:
authordkf <donal.k.fellows@manchester.ac.uk>2012-02-20 11:55:56 (GMT)
committerdkf <donal.k.fellows@manchester.ac.uk>2012-02-20 11:55:56 (GMT)
commit400babcc66dc63cb96cb3b3e2bc1df6dc6ad1a7e (patch)
tree11d74b34ec646e5494c3647b1369a71ba3496dc2 /tests/source.test
parent7815b5521b369211fa4115cb7ccfa8710a7c2066 (diff)
downloadtcl-400babcc66dc63cb96cb3b3e2bc1df6dc6ad1a7e.zip
tcl-400babcc66dc63cb96cb3b3e2bc1df6dc6ad1a7e.tar.gz
tcl-400babcc66dc63cb96cb3b3e2bc1df6dc6ad1a7e.tar.bz2
Make test clearer to future maintainers.
Diffstat (limited to 'tests/source.test')
-rw-r--r--tests/source.test8
1 files changed, 4 insertions, 4 deletions
diff --git a/tests/source.test b/tests/source.test
index 5774a97..1e5b732 100644
--- a/tests/source.test
+++ b/tests/source.test
@@ -121,16 +121,16 @@ test source-2.6 {source error conditions} -setup {
test source-2.7 {utf-8 with BOM} -setup {
set sourcefile [makeFile {} source.file]
set saveencoding [encoding system]
+} -body {
encoding system utf-8
set out [open $sourcefile w]
puts $out "\ufffeset y new-y"
close $out
-} -body {
- set y old-y
+ set y old-y
source $sourcefile
- set y
+ return $y
} -cleanup {
- removeFile source.file
+ removeFile $sourcefile
encoding system $saveencoding
} -result {new-y}