test: make the Windows-hosted suite portable
VoidBuildSystem CI / 1 · Requirements (push) Successful in 8s
VoidBuildSystem CI / 2A · Linux build (debug) (push) Successful in 2m30s
VoidBuildSystem CI / 2B · Windows Wine build (debug) (push) Successful in 1m51s
VoidBuildSystem CI / 2A · Linux build (sanitizers) (push) Successful in 3m21s
VoidBuildSystem CI / 2B · Windows Wine build (relwithdebinfo) (push) Successful in 3m38s
VoidBuildSystem CI / 2A · Linux build (relwithdebinfo) (push) Successful in 5m4s
VoidBuildSystem CI / 3B · Windows Wine test (debug) (push) Failing after 30s
VoidBuildSystem CI / 3B · Windows Wine test (relwithdebinfo) (push) Failing after 33s
VoidBuildSystem CI / 3A · Linux test (sanitizers) (push) Successful in 1m2s
VoidBuildSystem CI / 4B · Windows package (debug) (push) Successful in 24s
VoidBuildSystem CI / 4B · Windows package (relwithdebinfo) (push) Successful in 39s
VoidBuildSystem CI / 3A · Linux test (debug) (push) Successful in 5m42s
VoidBuildSystem CI / 3A · Linux test (relwithdebinfo) (push) Successful in 5m30s
VoidBuildSystem CI / 4A · Linux package (debug) (push) Successful in 1m7s
VoidBuildSystem CI / 4A · Linux package (sanitizers) (push) Successful in 1m10s
VoidBuildSystem CI / 4A · Linux package (relwithdebinfo) (push) Successful in 1m14s
VoidBuildSystem CI / 5 · Release (push) Skipped

- locate the vbs binary as vbs.exe on Windows (the .exe suffix was
  missing, so every test that spawns the CLI failed immediately);
- skip the POSIX permission-bit assertion on Windows (ACLs);
- skip the symlink checks when the host cannot create symlinks;
- skip compiler-spawning tests under Wine, which cannot execute the
  Linux-hosted compiler from a Windows process.
This commit is contained in:
faumaray committed 2026-12-06 08:09:38 +03:00
1 parent bd486c802c
commit adb7b4effe
4 files changed
+63 -9

No files matched your search

+13 -4
View File
@@ -94,14 +94,23 @@ void write_raw_tar(const std::filesystem::path &tar_path,
std::filesystem::path locate_vbs_binary() {
std::error_code ec;
// Windows executables carry the .exe suffix.
const auto find_in = [&ec](const std::filesystem::path &dir) -> std::filesystem::path {
for (const auto *name : {"vbs", "vbs.exe"}) {
const auto candidate = dir / name;
if (std::filesystem::exists(candidate, ec)) {
return candidate;
}
}
return {};
};
if (const auto self_exe = Platform::current_executable_path(); self_exe) {
const auto sibling = self_exe->parent_path() / "vbs";
if (std::filesystem::exists(sibling, ec)) {
return sibling;
if (auto found = find_in(self_exe->parent_path()); !found.empty()) {
return found;
}
}
if (!Bootstrap::binary_dir.empty()) {
return std::filesystem::path{Bootstrap::binary_dir} / "bin" / "vbs";
return find_in(std::filesystem::path{Bootstrap::binary_dir} / "bin");
}
return {};
}