ytdl-sub: disable test_directory_exists
`test_directory_exists` assumes the root directory is not writeable, which is host dependent.
In my case it fails with nix-portable in bwrap mode, despite me having removed the write-bit in the root root bindmount.
Full error:
```
ytdl-sub> ____________________ TestFileHandler.test_directory_exists _____________________
ytdl-sub>
ytdl-sub> self = <tests.unit.utils.test_file_handler.TestFileHandler object at 0x7ffff2bc07d0>
ytdl-sub>
ytdl-sub> . def test_directory_exists(self):
ytdl-sub> if IS_WINDOWS:
ytdl-sub> return
ytdl-sub>
ytdl-sub> assert FileHandler.is_path_writable("/tmp")
ytdl-sub> assert FileHandler.is_path_writable("/tmp/")
ytdl-sub> assert FileHandler.is_path_writable("/tmp/non-existent")
ytdl-sub> assert FileHandler.is_path_writable("/tmp/non-existent/")
ytdl-sub> assert FileHandler.is_path_writable("/tmp/non-existent/nested")
ytdl-sub>
ytdl-sub> > assert not FileHandler.is_path_writable("/lol-in-root")
ytdl-sub> E AssertionError: assert not True
ytdl-sub> E + where True = is_path_writable('/lol-in-root')
ytdl-sub> E + where is_path_writable = FileHandler.is_path_writable
ytdl-sub>
ytdl-sub> tests/unit/utils/test_file_handler.py:16: AssertionError
```
This commit is contained in:
@@ -59,6 +59,8 @@ python3Packages.buildPythonApplication (finalAttrs: {
|
||||
"test_no_config_works"
|
||||
"test_presets_run"
|
||||
"test_thumbnail"
|
||||
# fails in bwrap nix-portable sandbox
|
||||
"test_directory_exists"
|
||||
];
|
||||
|
||||
disabledTestPaths = [
|
||||
|
||||
Reference in New Issue
Block a user