##// END OF EJS Templates
scm: add tests for .mark_for_invalidation(delete=True)
dan -
r338:85729415 default
parent child Browse files
Show More
@@ -77,6 +77,19 b' def test_mark_for_invalidation_config(ba'
77 assert kwargs['config'].__dict__ == repo._config.__dict__
77 assert kwargs['config'].__dict__ == repo._config.__dict__
78
78
79
79
80 def test_mark_for_invalidation_with_delete_updates_last_commit(backend):
81 commits = [{'message': 'A'}, {'message': 'B'}]
82 repo = backend.create_repo(commits=commits)
83 scm.ScmModel().mark_for_invalidation(repo.repo_name, delete=True)
84 assert repo.changeset_cache['revision'] == 1
85
86
87 def test_mark_for_invalidation_with_delete_updates_last_commit_empty(backend):
88 repo = backend.create_repo()
89 scm.ScmModel().mark_for_invalidation(repo.repo_name, delete=True)
90 assert repo.changeset_cache['revision'] == -1
91
92
80 def test_strip_with_multiple_heads(backend_hg):
93 def test_strip_with_multiple_heads(backend_hg):
81 commits = [
94 commits = [
82 {'message': 'A'},
95 {'message': 'A'},
General Comments 0
You need to be logged in to leave comments. Login now