debian-mirror-gitlab/spec/frontend/fixtures/test_report.rb

31 lines
919 B
Ruby
Raw Normal View History

2020-01-01 13:55:28 +05:30
# frozen_string_literal: true
require "spec_helper"
2020-06-23 00:09:42 +05:30
RSpec.describe Projects::PipelinesController, "(JavaScript fixtures)", type: :controller do
2020-01-01 13:55:28 +05:30
include JavaScriptFixturesHelpers
let(:namespace) { create(:namespace, name: "frontend-fixtures") }
let(:project) { create(:project, :repository, namespace: namespace, path: "pipelines-project") }
let(:commit) { create(:commit, project: project) }
let(:user) { create(:user, developer_projects: [project], email: commit.author_email) }
let(:pipeline) { create(:ci_pipeline, :with_test_reports, project: project, user: user) }
render_views
before do
sign_in(user)
2020-05-24 23:13:21 +05:30
stub_feature_flags(junit_pipeline_view: project)
2020-01-01 13:55:28 +05:30
end
it "pipelines/test_report.json" do
get :test_report, params: {
namespace_id: project.namespace,
project_id: project,
id: pipeline.id
}, format: :json
expect(response).to be_successful
end
end