summaryrefslogtreecommitdiffstats
path: root/test
diff options
context:
space:
mode:
authorgrbd <garlicbready@googlemail.com>2017-08-04 09:57:11 (GMT)
committergrbd <garlicbready@googlemail.com>2017-08-04 09:57:11 (GMT)
commit334b9d54cf6810f55ffb14c2c42a03ac1f2ab433 (patch)
treeda0c2b593cb426dd6e45e5063dec822d995d0db7 /test
parent89091bfadcb56defc897acfa9753470e1eead6a2 (diff)
downloadSCons-334b9d54cf6810f55ffb14c2c42a03ac1f2ab433.zip
SCons-334b9d54cf6810f55ffb14c2c42a03ac1f2ab433.tar.gz
SCons-334b9d54cf6810f55ffb14c2c42a03ac1f2ab433.tar.bz2
Added fixes for docs / nested test for use of sys.path in toolpath
Diffstat (limited to 'test')
-rw-r--r--test/toolpath/nested/image/SConstruct6
1 files changed, 5 insertions, 1 deletions
diff --git a/test/toolpath/nested/image/SConstruct b/test/toolpath/nested/image/SConstruct
index 78ae21d..a7c6ceb 100644
--- a/test/toolpath/nested/image/SConstruct
+++ b/test/toolpath/nested/image/SConstruct
@@ -39,6 +39,10 @@ dir_path = Dir('.').srcnode().abspath
dir_path = os.path.join(dir_path, 'Libs')
sys.path.append(dir_path)
+searchpaths = []
+for item in sys.path:
+ if os.path.isdir(item): searchpaths.append(item)
+
toollist = ['tools_example.Toolpath_TestTool1',
'tools_example.Toolpath_TestTool2',
'tools_example.subdir1.Toolpath_TestTool1_1',
@@ -47,7 +51,7 @@ toollist = ['tools_example.Toolpath_TestTool1',
'tools_example.subdir1.subdir2.Toolpath_TestTool2_2',
]
-env3 = Environment(tools=toollist, toolpath=sys.path)
+env3 = Environment(tools=toollist, toolpath=searchpaths)
print("env3['Toolpath_TestTool1'] =", env3.get('Toolpath_TestTool1'))
print("env3['Toolpath_TestTool2'] =", env3.get('Toolpath_TestTool2'))
print("env3['Toolpath_TestTool1_1'] =", env3.get('Toolpath_TestTool1_1'))