namespace.rb 370 Bytes
Newer Older
1 2 3 4 5 6 7 8 9 10
module QA
  module Runtime
    module Namespace
      extend self

      def time
        @time ||= Time.now
      end

      def name
11
        'qa-test-' + time.strftime('%d-%m-%Y-%H-%M-%S')
12
      end
13

14 15 16 17
      def path
        "#{sandbox_name}/#{name}"
      end

18
      def sandbox_name
19
        Runtime::Env.sandbox_name || 'gitlab-qa-sandbox'
20
      end
21 22 23
    end
  end
end