Skip to content

Commit 0d59c35

Browse files
committed
mbed test should now use relative paths for source and build dirs
1 parent e897b9a commit 0d59c35

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

mbed/mbed.py

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -2589,12 +2589,12 @@ def test_(toolchain=None, target=None, compile_list=False, run_list=False, compi
25892589
with cd(program.path):
25902590
# Setup the source path if not specified
25912591
if not source or len(source) == 0:
2592-
source = [program.path]
2592+
source = [os.path.relpath(program.path, orig_path)]
25932593

25942594
# Setup the build path if not specified
25952595
build_path = build
25962596
if not build_path:
2597-
build_path = os.path.join(program.path, program.build_dir, 'tests', target.upper(), tchain.upper())
2597+
build_path = os.path.join(os.path.relpath(program.path, orig_path), program.build_dir, 'tests', target.upper(), tchain.upper())
25982598

25992599
if test_spec:
26002600
# Preserve path to given test spec

0 commit comments

Comments
 (0)