Commit d631056c authored by Grzegorz Bizon's avatar Grzegorz Bizon

Do not add EE license if not set in GitLab QA tests

parent 30ae11c7
......@@ -3,13 +3,13 @@ module QA
module Scenario
module License
class Add < QA::Scenario::Template
def perform
def perform(license)
QA::Page::Main::Entry.act { sign_in_using_credentials }
QA::Page::Main::Menu.act { go_to_admin_area }
QA::Page::Admin::Menu.act { go_to_license }
EE::Page::Admin::License.act do
add_new_license(ENV['EE_LICENSE']) if no_license?
EE::Page::Admin::License.act(license) do |key|
add_new_license(key) if no_license?
end
QA::Page::Main::Menu.act { sign_out }
......
......@@ -2,12 +2,15 @@ module QA
module EE
module Strategy
extend self
def extend_autoloads!
require 'qa/ee'
end
def perform_before_hooks
EE::Scenario::License::Add.perform
return unless ENV['EE_LICENSE']
EE::Scenario::License::Add.perform(ENV['EE_LICENSE'])
rescue
Capybara::Screenshot.screenshot_and_save_page
raise
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment