summaryrefslogtreecommitdiff
path: root/qa/qa/scenario/test/instance.rb
blob: 993bbd723a34890ccc361a9a0d6bb29061c1401e (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
module QA
  module Scenario
    module Test
      ##
      # Base class for running the suite against any GitLab instance,
      # including staging and on-premises installation.
      #
      class Instance < Template
        include Bootable
        extend Taggable

        tags :core

        def perform(address, *files)
          Runtime::Scenario.define(:gitlab_address, address)

          ##
          # Perform before hooks, which are different for CE and EE
          #
          Runtime::Release.perform_before_hooks

          Specs::Runner.perform do |specs|
            specs.tty = true
            specs.tags = self.class.focus
            specs.files = files.any? ? files : 'qa/specs/features'
          end
        end
      end
    end
  end
end