modify documents
This commit is contained in:
@@ -31,7 +31,7 @@ class CMakeAdapter:
|
||||
|
||||
if config.cmake.configure_preset is None:
|
||||
command_cwd = root
|
||||
binary = root / ".harness/build"
|
||||
binary = config.cmake.binary_dir or root / ".harness/build"
|
||||
configure = (
|
||||
str(tools.cmake),
|
||||
"-S",
|
||||
|
||||
@@ -13,12 +13,14 @@ from .base import AdapterError
|
||||
|
||||
|
||||
def _test_argv(root: Path, command: tuple[str, ...]) -> tuple[str, ...]:
|
||||
if "/" not in command[0] and "\\" not in command[0]:
|
||||
return command
|
||||
first = Path(command[0].replace("\\", "/"))
|
||||
executable = first if first.is_absolute() else (root / first).resolve()
|
||||
if first.is_absolute():
|
||||
raise AdapterError(
|
||||
"msbuild.testCommand executable must be repository-relative"
|
||||
)
|
||||
executable = (root / first).resolve()
|
||||
try:
|
||||
executable.relative_to(root)
|
||||
executable.relative_to(root.resolve())
|
||||
except ValueError as exc:
|
||||
raise AdapterError(
|
||||
"msbuild.testCommand resolves outside the repository"
|
||||
|
||||
Reference in New Issue
Block a user