File tree Expand file tree Collapse file tree 2 files changed +9
-4
lines changed
arduino-core/src/processing/app Expand file tree Collapse file tree 2 files changed +9
-4
lines changed Original file line number Diff line number Diff line change 103103
104104 <junit printsummary =" yes" dir =" ${ work.dir } " fork =" true" >
105105 <jvmarg value =" -Djava.library.path=${ java.additional.library.path } " />
106+ <jvmarg value =" -DWORK_DIR=." />
106107 <classpath >
107108 <pathelement location =" bin" />
108109 <pathelement location =" test-bin" />
Original file line number Diff line number Diff line change @@ -168,10 +168,14 @@ static public File getContentFile(String name) {
168168 File path = new File (System .getProperty ("user.dir" ));
169169
170170 if (OSUtils .isMacOS ()) {
171- try {
172- path = new File (BaseNoGui .class .getProtectionDomain ().getCodeSource ().getLocation ().toURI ().getPath ()).getParentFile ();
173- } catch (URISyntaxException e ) {
174- throw new RuntimeException (e );
171+ if (System .getProperty ("WORK_DIR" ) != null ) {
172+ path = new File (System .getProperty ("WORK_DIR" ));
173+ } else {
174+ try {
175+ path = new File (BaseNoGui .class .getProtectionDomain ().getCodeSource ().getLocation ().toURI ().getPath ()).getParentFile ();
176+ } catch (URISyntaxException e ) {
177+ throw new RuntimeException (e );
178+ }
175179 }
176180 }
177181
You can’t perform that action at this time.
0 commit comments