diff options
Diffstat (limited to 'test/emitter.py')
-rw-r--r-- | test/emitter.py | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/test/emitter.py b/test/emitter.py index 78de13e..7712d3a 100644 --- a/test/emitter.py +++ b/test/emitter.py @@ -42,7 +42,8 @@ SConscript('var2/SConscript') test.write('src/SConscript',""" def build(target, source, env): for t in target: - open(str(t), "wt").write(str(t)) + with open(str(t), "wt") as f: + f.write(str(t)) def emitter(target, source, env): target.append(str(target[0])+".foo") |