Lines Matching refs:monkeypatch

53     def keys_dir(self, tmpdir, monkeypatch):  argument
55 monkeypatch.setenv('BORG_KEYS_DIR', tmpdir)
60 def test_ssh(self, monkeypatch, keys_dir): argument
61 monkeypatch.delenv('BORG_REPO', raising=False)
97 def test_file(self, monkeypatch, keys_dir): argument
98 monkeypatch.delenv('BORG_REPO', raising=False)
105 def test_scp(self, monkeypatch, keys_dir): argument
106 monkeypatch.delenv('BORG_REPO', raising=False)
129 def test_smb(self, monkeypatch, keys_dir): argument
130 monkeypatch.delenv('BORG_REPO', raising=False)
135 def test_folder(self, monkeypatch, keys_dir): argument
136 monkeypatch.delenv('BORG_REPO', raising=False)
143 def test_long_path(self, monkeypatch, keys_dir): argument
144 monkeypatch.delenv('BORG_REPO', raising=False)
147 def test_abspath(self, monkeypatch, keys_dir): argument
148 monkeypatch.delenv('BORG_REPO', raising=False)
158 def test_relpath(self, monkeypatch, keys_dir): argument
159 monkeypatch.delenv('BORG_REPO', raising=False)
175 def test_with_colons(self, monkeypatch, keys_dir): argument
176 monkeypatch.delenv('BORG_REPO', raising=False)
196 def test_underspecified(self, monkeypatch): argument
197 monkeypatch.delenv('BORG_REPO', raising=False)
205 def test_no_slashes(self, monkeypatch): argument
206 monkeypatch.delenv('BORG_REPO', raising=False)
210 def test_canonical_path(self, monkeypatch): argument
211 monkeypatch.delenv('BORG_REPO', raising=False)
219 def test_format_path(self, monkeypatch): argument
220 monkeypatch.delenv('BORG_REPO', raising=False)
236 def test_ssh(self, monkeypatch): argument
237 monkeypatch.setenv('BORG_REPO', 'ssh://user@host:1234/some/path')
245 def test_file(self, monkeypatch): argument
246 monkeypatch.setenv('BORG_REPO', 'file:///some/path')
254 def test_scp(self, monkeypatch): argument
255 monkeypatch.setenv('BORG_REPO', 'user@host:/some/path')
263 def test_folder(self, monkeypatch): argument
264 monkeypatch.setenv('BORG_REPO', 'path')
272 def test_abspath(self, monkeypatch): argument
273 monkeypatch.setenv('BORG_REPO', '/some/absolute/path')
281 def test_relpath(self, monkeypatch): argument
282 monkeypatch.setenv('BORG_REPO', 'some/relative/path')
290 def test_with_colons(self, monkeypatch): argument
291 monkeypatch.setenv('BORG_REPO', '/abs/path:w:cols')
299 def test_no_slashes(self, monkeypatch): argument
300 monkeypatch.setenv('BORG_REPO', '/some/absolute/path')
452 def test_get_base_dir(monkeypatch): argument
454 monkeypatch.delenv('BORG_BASE_DIR', raising=False)
455 monkeypatch.delenv('HOME', raising=False)
456 monkeypatch.delenv('USER', raising=False)
458 monkeypatch.setenv('USER', 'root')
460 monkeypatch.setenv('HOME', '/var/tmp/home')
462 monkeypatch.setenv('BORG_BASE_DIR', '/var/tmp/base')
466 def test_get_config_dir(monkeypatch): argument
468 monkeypatch.delenv('BORG_CONFIG_DIR', raising=False)
469 monkeypatch.delenv('XDG_CONFIG_HOME', raising=False)
471 monkeypatch.setenv('XDG_CONFIG_HOME', '/var/tmp/.config')
473 monkeypatch.setenv('BORG_CONFIG_DIR', '/var/tmp')
477 def test_get_cache_dir(monkeypatch): argument
479 monkeypatch.delenv('BORG_CACHE_DIR', raising=False)
480 monkeypatch.delenv('XDG_CACHE_HOME', raising=False)
482 monkeypatch.setenv('XDG_CACHE_HOME', '/var/tmp/.cache')
484 monkeypatch.setenv('BORG_CACHE_DIR', '/var/tmp')
488 def test_get_keys_dir(monkeypatch): argument
490 monkeypatch.delenv('BORG_KEYS_DIR', raising=False)
491 monkeypatch.delenv('XDG_CONFIG_HOME', raising=False)
493 monkeypatch.setenv('XDG_CONFIG_HOME', '/var/tmp/.config')
495 monkeypatch.setenv('BORG_KEYS_DIR', '/var/tmp')
499 def test_get_security_dir(monkeypatch): argument
501 monkeypatch.delenv('BORG_SECURITY_DIR', raising=False)
502 monkeypatch.delenv('XDG_CONFIG_HOME', raising=False)
505 monkeypatch.setenv('XDG_CONFIG_HOME', '/var/tmp/.config')
507 monkeypatch.setenv('BORG_SECURITY_DIR', '/var/tmp')
672 def test_yes_env(monkeypatch): argument
674 monkeypatch.setenv('OVERRIDE_THIS', value)
677 monkeypatch.setenv('OVERRIDE_THIS', value)
681 def test_yes_env_default(monkeypatch): argument
683 monkeypatch.setenv('OVERRIDE_THIS', value)
734 def test_yes_env_output(capfd, monkeypatch): argument
736 monkeypatch.setenv(env_var, 'yes')
744 def test_progress_percentage_sameline(capfd, monkeypatch): argument
746 monkeypatch.setenv('COLUMNS', '4')
747 monkeypatch.setenv('LINES', '1')
765 def test_progress_percentage_step(capfd, monkeypatch): argument
767 monkeypatch.setenv('COLUMNS', '4')
768 monkeypatch.setenv('LINES', '1')