mirror of
https://github.com/Abdess/retroarch_system.git
synced 2026-11-06 10:03:49 -06:00
fix: record missing data dirs in the run
main() starts each run with no notices, so the mocked run records the missing directory itself.
This commit is contained in:
1 parent
ed4580a2f7
commit
625bee35cc
1 file changed
+2
-1
@@ -174,7 +174,8 @@ class AMissingDataDirectoryFailsTheRun(unittest.TestCase):
|
|||||||
offline=True,
|
offline=True,
|
||||||
)
|
)
|
||||||
self.assertEqual(gp._MISSING_DATA_DIRS, {"assets"})
|
self.assertEqual(gp._MISSING_DATA_DIRS, {"assets"})
|
||||||
with mock.patch.object(gp, "_main", lambda held: None), \
|
# main() starts each run with no notices, so the run itself records it.
|
||||||
|
with mock.patch.object(gp, "_main", lambda held: gp._MISSING_DATA_DIRS.add("assets")), \
|
||||||
contextlib.redirect_stderr(io.StringIO()), \
|
contextlib.redirect_stderr(io.StringIO()), \
|
||||||
self.assertRaises(SystemExit) as stop:
|
self.assertRaises(SystemExit) as stop:
|
||||||
gp.main()
|
gp.main()
|
||||||
|
|||||||
Reference in new issue
Block a user