Reduce CE/EE diff in spec/controllers/projects/imports_controller_spec.rb
Signed-off-by: Rémy Coutable <remy@rymai.me>
This commit is contained in:
parent
53e30e1528
commit
ee9e4d4652
1 changed files with 6 additions and 12 deletions
|
@ -2,16 +2,15 @@ require 'spec_helper'
|
|||
|
||||
describe Projects::ImportsController do
|
||||
let(:user) { create(:user) }
|
||||
let(:project) { create(:project) }
|
||||
|
||||
before do
|
||||
sign_in(user)
|
||||
project.add_master(user)
|
||||
end
|
||||
|
||||
describe 'GET #show' do
|
||||
context 'when repository does not exists' do
|
||||
let(:project) { create(:project) }
|
||||
|
||||
before do
|
||||
sign_in(user)
|
||||
project.add_master(user)
|
||||
end
|
||||
|
||||
it 'renders template' do
|
||||
get :show, namespace_id: project.namespace.to_param, project_id: project
|
||||
|
||||
|
@ -28,11 +27,6 @@ describe Projects::ImportsController do
|
|||
context 'when repository exists' do
|
||||
let(:project) { create(:project_empty_repo, import_url: 'https://github.com/vim/vim.git') }
|
||||
|
||||
before do
|
||||
sign_in(user)
|
||||
project.add_master(user)
|
||||
end
|
||||
|
||||
context 'when import is in progress' do
|
||||
before do
|
||||
project.update_attribute(:import_status, :started)
|
||||
|
|
Loading…
Reference in a new issue