Skip to content

Commit c43b2b1

Browse files
committed
Fix test on Windows
1 parent 0c99ae2 commit c43b2b1

File tree

1 file changed

+4
-0
lines changed
  • java/ql/integration-tests/java/maven-download-failure

1 file changed

+4
-0
lines changed

java/ql/integration-tests/java/maven-download-failure/test.py

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -3,8 +3,12 @@
33
import shutil
44

55
def test(codeql, java, check_diagnostics):
6+
7+
# Avoid shutil resolving mvn to the wrapper script in the test dir:
8+
os.environ["NoDefaultCurrentDirectoryInExePath"] = "0"
69
runenv = {
710
"PATH": os.path.realpath(os.path.dirname(__file__)) + os.pathsep + os.getenv("PATH"),
811
"REAL_MVN_PATH": shutil.which("mvn"),
912
}
13+
del os.environ["NoDefaultCurrentDirectoryInExePath"]
1014
codeql.database.create(build_mode = "none", _env = runenv)

0 commit comments

Comments
 (0)