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

commit_message.rb « shared « file « page « qa « qa - gitlab.com/gitlab-org/gitlab-foss.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
blob: 4c25e8a480be87a911219551b4cf83f0a1591d1c (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
32
33
# frozen_string_literal: true

module QA
  module Page
    module File
      module Shared
        module CommitMessage
          extend QA::Page::PageConcern

          def self.included(base)
            super

            base.view 'app/views/shared/_commit_message_container.html.haml' do
              element :commit_message_field
            end

            base.view 'app/views/projects/commits/_commit.html.haml' do
              element :commit_content
            end
          end

          def add_commit_message(message)
            fill_element(:commit_message_field, message)
          end

          def has_commit_message?(text)
            has_element?(:commit_content, text: text)
          end
        end
      end
    end
  end
end