BigW Consortium Gitlab

builds_spec.rb 669 Bytes
Newer Older
1 2 3 4 5 6 7 8 9 10 11 12 13
require 'spec_helper'

feature 'project commit builds' do
  given(:project) { create(:project) }

  background do
    user = create(:user)
    project.team << [user, :master]
    login_as(user)
  end

  context 'when no builds triggered yet' do
    background do
14
      create(:ci_pipeline, project: project,
Kamil Trzcinski committed
15 16
                           sha: project.commit.sha,
                           ref: 'master')
17 18 19 20 21 22 23 24 25 26
    end

    scenario 'user views commit builds page' do
      visit builds_namespace_project_commit_path(project.namespace,
                                                 project, project.commit.sha)

      expect(page).to have_content('Builds')
    end
  end
end