Add spec to prove that we don't create wiki when we update project's name
This commit is contained in:
parent
4497f829d8
commit
86de1e291c
|
@ -123,6 +123,17 @@ describe Projects::UpdateService do
|
|||
end
|
||||
end
|
||||
|
||||
context 'when we update project but not enabling a wiki' do
|
||||
it 'does not try to create an empty wiki' do
|
||||
FileUtils.rm_rf(project.wiki.repository.path)
|
||||
|
||||
result = update_project(project, user, { name: 'test1' })
|
||||
|
||||
expect(result).to eq({ status: :success })
|
||||
expect(project.wiki_repository_exists?).to be false
|
||||
end
|
||||
end
|
||||
|
||||
context 'when enabling a wiki' do
|
||||
it 'creates a wiki' do
|
||||
project.project_feature.update(wiki_access_level: ProjectFeature::DISABLED)
|
||||
|
|
Loading…
Reference in New Issue