summaryrefslogtreecommitdiffstats
path: root/test/CacheDir
diff options
context:
space:
mode:
authorWilliam Deegan <bill@baddogconsulting.com>2017-03-11 04:18:20 (GMT)
committerWilliam Deegan <bill@baddogconsulting.com>2017-03-11 04:18:20 (GMT)
commit32c43164f036af6e9f83eaf1826274fcf5332fba (patch)
tree0e6bac0c3a132ba90e6b60b1419cc9bac42c8c09 /test/CacheDir
parent886027ad490ea6ff9e8a4b5ecaa8396e24842211 (diff)
downloadSCons-32c43164f036af6e9f83eaf1826274fcf5332fba.zip
SCons-32c43164f036af6e9f83eaf1826274fcf5332fba.tar.gz
SCons-32c43164f036af6e9f83eaf1826274fcf5332fba.tar.bz2
remove rb/wb from file opens, not needed py2/3
Diffstat (limited to 'test/CacheDir')
-rw-r--r--test/CacheDir/option--cd.py6
-rw-r--r--test/CacheDir/option--cf.py6
-rw-r--r--test/CacheDir/option--cr.py6
-rw-r--r--test/CacheDir/option--cs.py12
4 files changed, 15 insertions, 15 deletions
diff --git a/test/CacheDir/option--cd.py b/test/CacheDir/option--cd.py
index b77cfeb..efcf843 100644
--- a/test/CacheDir/option--cd.py
+++ b/test/CacheDir/option--cd.py
@@ -41,10 +41,10 @@ test.subdir('cache', 'src')
test.write(['src', 'SConstruct'], """
def cat(env, source, target):
target = str(target[0])
- open('cat.out', 'ab').write(target + "\\n")
- f = open(target, "wb")
+ open('cat.out', 'a').write(target + "\\n")
+ f = open(target, "w")
for src in source:
- f.write(open(str(src), "rb").read())
+ f.write(open(str(src), "r").read())
f.close()
env = Environment(BUILDERS={'Cat':Builder(action=cat)})
env.Cat('aaa.out', 'aaa.in')
diff --git a/test/CacheDir/option--cf.py b/test/CacheDir/option--cf.py
index 6d64059..ace0df6 100644
--- a/test/CacheDir/option--cf.py
+++ b/test/CacheDir/option--cf.py
@@ -40,10 +40,10 @@ test.subdir('cache', 'src')
test.write(['src', 'SConstruct'], """
def cat(env, source, target):
target = str(target[0])
- open('cat.out', 'ab').write(target + "\\n")
- f = open(target, "wb")
+ open('cat.out', 'a').write(target + "\\n")
+ f = open(target, "w")
for src in source:
- f.write(open(str(src), "rb").read())
+ f.write(open(str(src), "r").read())
f.close()
env = Environment(BUILDERS={'Cat':Builder(action=cat)})
env.Cat('aaa.out', 'aaa.in')
diff --git a/test/CacheDir/option--cr.py b/test/CacheDir/option--cr.py
index de6bbc8..165e049 100644
--- a/test/CacheDir/option--cr.py
+++ b/test/CacheDir/option--cr.py
@@ -41,10 +41,10 @@ test.subdir('cache', 'src')
test.write(['src', 'SConstruct'], """
def cat(env, source, target):
target = str(target[0])
- open('cat.out', 'ab').write(target + "\\n")
- f = open(target, "wb")
+ open('cat.out', 'a').write(target + "\\n")
+ f = open(target, "w")
for src in source:
- f.write(open(str(src), "rb").read())
+ f.write(open(str(src), "r").read())
f.close()
env = Environment(BUILDERS={'Cat':Builder(action=cat)})
env.Cat('aaa.out', 'aaa.in')
diff --git a/test/CacheDir/option--cs.py b/test/CacheDir/option--cs.py
index 6d22814..bff585d 100644
--- a/test/CacheDir/option--cs.py
+++ b/test/CacheDir/option--cs.py
@@ -45,10 +45,10 @@ test.subdir('cache', 'src1', 'src2')
test.write(['src1', 'build.py'], r"""
import sys
-open('cat.out', 'ab').write(sys.argv[1] + "\n")
-file = open(sys.argv[1], 'wb')
+open('cat.out', 'a').write(sys.argv[1] + "\n")
+file = open(sys.argv[1], 'w')
for src in sys.argv[2:]:
- file.write(open(src, 'rb').read())
+ file.write(open(src, 'r').read())
file.close()
""")
@@ -57,10 +57,10 @@ cache = test.workpath('cache')
test.write(['src1', 'SConstruct'], """
def cat(env, source, target):
target = str(target[0])
- open('cat.out', 'ab').write(target + "\\n")
- f = open(target, "wb")
+ open('cat.out', 'a').write(target + "\\n")
+ f = open(target, "w")
for src in source:
- f.write(open(str(src), "rb").read())
+ f.write(open(str(src), "r").read())
f.close()
env = Environment(BUILDERS={'Internal':Builder(action=cat),
'External':Builder(action=r'%(_python_)s build.py $TARGET $SOURCES')})