Welcome to mirror list, hosted at ThFree Co, Russian Federation.

gitlab.com/gitlab-org/gitlab-foss.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
Diffstat (limited to 'qa/qa/factory/repository/push.rb')
-rw-r--r--qa/qa/factory/repository/push.rb7
1 files changed, 6 insertions, 1 deletions
diff --git a/qa/qa/factory/repository/push.rb b/qa/qa/factory/repository/push.rb
index 6e8905cde78..bd4dee4c7be 100644
--- a/qa/qa/factory/repository/push.rb
+++ b/qa/qa/factory/repository/push.rb
@@ -30,7 +30,12 @@ module QA
repository.clone
repository.configure_identity('GitLab QA', 'root@gitlab.com')
- repository.checkout(@branch_name) unless @new_branch
+ if @new_branch
+ repository.checkout_new_branch(@branch_name)
+ else
+ repository.checkout(@branch_name)
+ end
+
repository.add_file(@file_name, @file_content)
repository.commit(@commit_message)
repository.push_changes(@branch_name)