Do common setup for the test case * Create a temporary directory for the testcase. * Treat warnings as errors. This is also set by environment variable in `Makefile` and `appveyor.yml`. * Patch options paths.
(cls)
| 60 | |
| 61 | @classmethod |
| 62 | def setUpClass(cls): |
| 63 | """Do common setup for the test case |
| 64 | |
| 65 | * Create a temporary directory for the testcase. |
| 66 | * Treat warnings as errors. |
| 67 | This is also set by environment variable in `Makefile` and |
| 68 | `appveyor.yml`. |
| 69 | * Patch options paths. |
| 70 | """ |
| 71 | warnings.simplefilter("error") |
| 72 | cls.tempdir = tempfile.mkdtemp(prefix=cls.__name__) |
| 73 | if 'BLEACHBIT_TEST_OPTIONS_DIR' not in os.environ: |
| 74 | cls._patch_options_paths() |
| 75 | bleachbit.Options.options.reset_overrides() |
| 76 | bleachbit.Options.options.set_override("first_start", False) |
| 77 | |
| 78 | @classmethod |
| 79 | def _patch_options_paths(cls): |
nothing calls this directly
no test coverage detected