diff options
author | Lin Jen-Shin <godfat@godfat.org> | 2016-12-07 22:37:43 +0800 |
---|---|---|
committer | Lin Jen-Shin <godfat@godfat.org> | 2016-12-07 22:37:43 +0800 |
commit | 5ecd0c81af85476c2328d3836cc68b17ebd5a8a6 (patch) | |
tree | ca4896ab211f3de60f9ca9a8a19b8db288b5146f /spec/models | |
parent | 6ae1a73cfdad4b98176bb99846042d4378119de2 (diff) | |
download | gitlab-ce-5ecd0c81af85476c2328d3836cc68b17ebd5a8a6.tar.gz |
Commit outside the hooks if possible:
So we still commit outside the hooks, and only
update ref inside the hooks. There are only two
exceptions:
* Whenever it's adding a tag. We can't add a tag
without committing, unfortunately. See !7700
* Whenever source project is in another repository.
We'll need to fetch ref otherwise commits can't be made.
See the whole discussion starting from:
https://gitlab.com/gitlab-org/gitlab-ce/merge_requests/7237#note_19210942
Diffstat (limited to 'spec/models')
-rw-r--r-- | spec/models/repository_spec.rb | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/spec/models/repository_spec.rb b/spec/models/repository_spec.rb index e3ec4c85a74..ebd05c946cc 100644 --- a/spec/models/repository_spec.rb +++ b/spec/models/repository_spec.rb @@ -695,7 +695,7 @@ describe Repository, models: true do user, repository.path_to_repo, old_rev, - old_rev, + new_rev, 'refs/heads/feature'). and_yield(service).and_return(true) end |