Files
Cornelius Riemenschneider 321820e758 Java: Rename integration test directories.
We are no longer bound to the platform-specific directories, so simplify the test organization.
If you don't want this change, just skip merging this PR. It's purely optional.

I kept the platform-specific directories around under `kotlin`,
but you could also easily merge all these together if you find them unhelpful.
I'll leave that change to you.
2024-08-30 10:28:25 +02:00

16 lines
532 B
Python

import commands
import pathlib
def test(codeql, java_full):
fake_kotlin_classes = pathlib.Path("fake-kotlinc-classes")
fake_kotlin_classes.mkdir()
for source_file in pathlib.Path("fake-kotlinc-source").rglob("*.java"):
commands.run(
f"javac {source_file.relative_to("fake-kotlinc-source")} -d {fake_kotlin_classes.absolute()}",
_cwd="fake-kotlinc-source",
)
codeql.database.create(
command=[f"java -cp {fake_kotlin_classes} driver.Main"], _assert_failure=True
)