From 35d44efb8b5c993f9ffa523637540c71df3c2496 Mon Sep 17 00:00:00 2001 From: 1jamie Date: Thu, 13 Aug 2026 17:44:45 -0500 Subject: [PATCH] fixes to the failing test systems --- .gitignore | 3 +++ src/import/CacheFs.lua | 4 ++++ src/import/RomImporter.lua | 2 +- tests/integration/title_checkpoint_cold_start.lua | 9 +++++++-- 4 files changed, 15 insertions(+), 3 deletions(-) diff --git a/.gitignore b/.gitignore index 084cdfbb..cbf162dd 100644 --- a/.gitignore +++ b/.gitignore @@ -75,3 +75,6 @@ mobile/ios/bundle_id.local /dist/native/ /dist/win/ /.bazinga/ + +# Local options / preferences +/options.lua* diff --git a/src/import/CacheFs.lua b/src/import/CacheFs.lua index 4c99b048..9284e394 100644 --- a/src/import/CacheFs.lua +++ b/src/import/CacheFs.lua @@ -116,6 +116,8 @@ local physfsMountFn = nil local function resolveMount() if physfsMountFn ~= nil then return physfsMountFn end physfsMountFn = false + if Platform.isUWP() then return physfsMountFn end + if love and love.filesystem and love.filesystem._mounts then return physfsMountFn end local ok, ffi = pcall(require, "ffi") if not ok then return physfsMountFn end pcall(ffi.cdef, @@ -159,6 +161,8 @@ local physfsUnmountFn = nil local function resolveUnmount() if physfsUnmountFn ~= nil then return physfsUnmountFn end physfsUnmountFn = false + if Platform.isUWP() then return physfsUnmountFn end + if love and love.filesystem and love.filesystem._mounts then return physfsUnmountFn end local ok, ffi = pcall(require, "ffi") if not ok then return physfsUnmountFn end pcall(ffi.cdef, "int PHYSFS_unmount(const char *oldDir);") diff --git a/src/import/RomImporter.lua b/src/import/RomImporter.lua index 362e0373..d37ae295 100644 --- a/src/import/RomImporter.lua +++ b/src/import/RomImporter.lua @@ -1666,7 +1666,7 @@ function RomImporter:_installMod(source) if not checkTarget and type(res) == "string" then checkTarget = { id = res } end - if checkTarget then + if checkTarget and LauncherMods.checkDependencies then local depCheck = LauncherMods.checkDependencies(checkTarget) if depCheck and depCheck.hasIssues then self._modDepResolver = depCheck diff --git a/tests/integration/title_checkpoint_cold_start.lua b/tests/integration/title_checkpoint_cold_start.lua index cfbf9c92..c16347ce 100644 --- a/tests/integration/title_checkpoint_cold_start.lua +++ b/tests/integration/title_checkpoint_cold_start.lua @@ -8,11 +8,16 @@ local function quote(value) return "'" .. tostring(value):gsub("'", "'\\''") .. "'" end +local function execOk(cmd) + local status = os.execute(cmd) + return status == 0 or status == true +end + local function full(path) return root .. "/" .. path end local fs = {} function fs.createDirectory(path) - return os.execute("mkdir -p " .. quote(full(path))) == 0 + return execOk("mkdir -p " .. quote(full(path))) end function fs.write(path, body) local parent = path:match("^(.*)/[^/]+$") @@ -34,7 +39,7 @@ function fs.remove(path) return true end function fs.getInfo(path) - if os.execute("test -d " .. quote(full(path))) == 0 then + if execOk("test -d " .. quote(full(path))) then return { type = "directory" } end local handle = io.open(full(path), "rb")