blob: c9a5aa9a67c2632abe7d062bcef345823e71fb9d (
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
34
35
|
# frozen_string_literal: true
require 'spec_helper'
describe Projects::CommitController, '(JavaScript fixtures)', type: :controller do
include JavaScriptFixturesHelpers
let_it_be(:project) { create(:project, :repository) }
let_it_be(:user) { create(:user) }
let(:commit) { project.commit("master") }
render_views
before(:all) do
clean_frontend_fixtures('commit/')
end
before do
project.add_maintainer(user)
sign_in(user)
allow(SecureRandom).to receive(:hex).and_return('securerandomhex:thereisnospoon')
end
it 'commit/show.html' do
params = {
namespace_id: project.namespace,
project_id: project,
id: commit.id
}
get :show, params: params
expect(response).to be_successful
end
end
|