summaryrefslogtreecommitdiff
path: root/qa/qa/runtime/env.rb
diff options
context:
space:
mode:
Diffstat (limited to 'qa/qa/runtime/env.rb')
-rw-r--r--qa/qa/runtime/env.rb14
1 files changed, 13 insertions, 1 deletions
diff --git a/qa/qa/runtime/env.rb b/qa/qa/runtime/env.rb
index 4c4dd416093..24be4e4f978 100644
--- a/qa/qa/runtime/env.rb
+++ b/qa/qa/runtime/env.rb
@@ -63,7 +63,7 @@ module QA
end
def pipeline_from_project_name
- ci_project_name.to_s.start_with?('gitlab-qa') ? 'master' : ci_project_name
+ ci_project_name.to_s.start_with?('gitlab-qa') ? Runtime::Env.default_branch : ci_project_name
end
def additional_repository_storage
@@ -102,6 +102,10 @@ module QA
enabled?(ENV['QA_DEBUG'], default: false)
end
+ def default_branch
+ ENV['QA_DEFAULT_BRANCH'] || 'master'
+ end
+
def log_destination
ENV['QA_LOG_PATH'] || $stdout
end
@@ -395,6 +399,14 @@ module QA
ENV['DEPLOY_VERSION']
end
+ def user_agent
+ ENV['GITLAB_QA_USER_AGENT']
+ end
+
+ def geo_environment?
+ QA::Runtime::Scenario.attributes.include?(:geo_secondary_address)
+ end
+
private
def remote_grid_credentials