Add missing test (#911).
All checks were successful
build / test (push) Successful in 5m8s
build / docs (push) Successful in 1m57s

This commit is contained in:
Dan Helfman 2024-10-01 09:31:03 -07:00
parent 34305d686c
commit 88b945dcb9

View File

@ -981,6 +981,29 @@ def test_run_actions_runs_export_key():
)
def test_run_actions_runs_change_passphrase():
flexmock(module).should_receive('add_custom_log_levels')
flexmock(module).should_receive('get_skip_actions').and_return([])
flexmock(module.command).should_receive('execute_hook')
flexmock(borgmatic.actions.change_passphrase).should_receive('run_change_passphrase').once()
tuple(
module.run_actions(
arguments={
'global': flexmock(dry_run=False, log_file='foo'),
'change-passphrase': flexmock(),
},
config_filename=flexmock(),
config={'repositories': []},
config_paths=[],
local_path=flexmock(),
remote_path=flexmock(),
local_borg_version=flexmock(),
repository={'path': 'repo'},
)
)
def test_run_actions_runs_delete():
flexmock(module).should_receive('add_custom_log_levels')
flexmock(module).should_receive('get_skip_actions').and_return([])