add unit test
This commit is contained in:
parent
b36e11d3ca
commit
3bc2c12f47
|
@ -494,10 +494,10 @@ def test_run_actions_adds_log_file_to_hook_context():
|
|||
expected = flexmock()
|
||||
flexmock(borgmatic.actions.create).should_receive('run_create').with_args(
|
||||
config_filename=object,
|
||||
repository={'path': 'repo'},
|
||||
repository={'path': 'repo', 'label': ''},
|
||||
config={'repositories': []},
|
||||
config_paths=[],
|
||||
hook_context={'repository': 'repo', 'repositories': '', 'log_file': 'foo'},
|
||||
hook_context={'repository': 'repo', 'label': '', 'repositories': '', 'log_file': 'foo'},
|
||||
local_borg_version=object,
|
||||
create_arguments=object,
|
||||
global_arguments=object,
|
||||
|
@ -515,7 +515,7 @@ def test_run_actions_adds_log_file_to_hook_context():
|
|||
local_path=flexmock(),
|
||||
remote_path=flexmock(),
|
||||
local_borg_version=flexmock(),
|
||||
repository={'path': 'repo'},
|
||||
repository={'path': 'repo', 'label': ''},
|
||||
)
|
||||
)
|
||||
assert result == (expected,)
|
||||
|
|
Loading…
Reference in New Issue
Block a user