Skip to content

Commit 54b843a

Browse files
committed
updated tests to use f-string and skip str()'ing node
1 parent 7e244b1 commit 54b843a

File tree

1 file changed

+6
-6
lines changed

1 file changed

+6
-6
lines changed

test/implicit/changed-node.py

Lines changed: 6 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,8 @@
11
#!/usr/bin/env python
22
#
3-
# __COPYRIGHT__
3+
# MIT License
4+
#
5+
# Copyright The SCons Foundation
46
#
57
# Permission is hereby granted, free of charge, to any person obtaining
68
# a copy of this software and associated documentation files (the
@@ -20,9 +22,6 @@
2022
# LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION
2123
# OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION
2224
# WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
23-
#
24-
25-
__revision__ = "__FILE__ __REVISION__ __DATE__ __DEVELOPER__"
2625

2726
"""
2827
Verify that we don't throw an exception if a stored implicit
@@ -51,7 +50,7 @@ def lister(target, source, env):
5150
for l in os.listdir(source[0]):
5251
ofp.write(l + '\\n')
5352
else:
54-
ofp.write(str(source[0]) + '\\n')
53+
ofp.write(f'{source[0]}\\n')
5554
5655
builder = Builder(action=lister,
5756
source_factory=Dir,
@@ -76,6 +75,7 @@ def lister(target, source, env):
7675

7776

7877
test.write('SConstruct', """\
78+
DefaultEnvironment(tools=[])
7979
SetOption('implicit_cache', 1)
8080
SetOption('max_drift', 1)
8181
@@ -86,7 +86,7 @@ def lister(target, source, env):
8686
for l in os.listdir(source[0]):
8787
ofp.write(l + '\\n')
8888
else:
89-
ofp.write(str(source[0]) + '\\n')
89+
ofp.write(f'{source[0]}\\n')
9090
9191
builder = Builder(action=lister,
9292
source_factory=File)

0 commit comments

Comments
 (0)