Unify :type_de_champ public/private factories
This commit is contained in:
parent
31d638ae2a
commit
0c1d529b61
32 changed files with 125 additions and 134 deletions
|
@ -1,7 +1,7 @@
|
|||
require 'spec_helper'
|
||||
|
||||
describe 'users/description/champs/date.html.haml', type: :view do
|
||||
let(:type_champ) { create(:type_de_champ_public, type_champ: :date) }
|
||||
let(:type_champ) { create(:type_de_champ, type_champ: :date) }
|
||||
|
||||
before do
|
||||
render 'users/description/champs/date.html.haml', champ: champ
|
||||
|
|
|
@ -1,7 +1,7 @@
|
|||
require 'spec_helper'
|
||||
|
||||
describe 'users/description/champs/dossier_link.html.haml', type: :view do
|
||||
let(:type_champ) { create(:type_de_champ_public, type_champ: :dossier_link) }
|
||||
let(:type_champ) { create(:type_de_champ, type_champ: :dossier_link) }
|
||||
|
||||
before do
|
||||
render 'users/description/champs/dossier_link.html.haml', champ: champ
|
||||
|
|
|
@ -1,7 +1,7 @@
|
|||
require 'spec_helper'
|
||||
|
||||
describe 'users/description/champs/engagement.html.haml', type: :view do
|
||||
let(:type_champ) { create(:type_de_champ_public, type_champ: :engagement) }
|
||||
let(:type_champ) { create(:type_de_champ, type_champ: :engagement) }
|
||||
|
||||
subject { render 'users/description/champs/engagement.html.haml', champ: champ }
|
||||
|
||||
|
|
|
@ -1,5 +1,5 @@
|
|||
describe 'users/description/champs/render_list_champs.html.haml', type: :view do
|
||||
let(:type_champ) { create(:type_de_champ_public, :checkbox) }
|
||||
let(:type_champ) { create(:type_de_champ, :checkbox) }
|
||||
|
||||
context "with any champ" do
|
||||
let!(:champ) { create(:champ, type_de_champ: type_champ, value: nil) }
|
||||
|
@ -40,7 +40,7 @@ describe 'users/description/champs/render_list_champs.html.haml', type: :view do
|
|||
end
|
||||
|
||||
context 'with a dossier_link' do
|
||||
let(:type_champ) { create(:type_de_champ_public, type_champ: :dossier_link) }
|
||||
let(:type_champ) { create(:type_de_champ, type_champ: :dossier_link) }
|
||||
let!(:champ) { create(:champ, type_de_champ: type_champ, value: nil) }
|
||||
|
||||
before do
|
||||
|
|
|
@ -1,7 +1,7 @@
|
|||
require 'spec_helper'
|
||||
|
||||
describe 'users/description/champs/yes_no.html.haml', type: :view do
|
||||
let(:type_champ) { create(:type_de_champ_public, type_champ: :yes_no) }
|
||||
let(:type_champ) { create(:type_de_champ, type_champ: :yes_no) }
|
||||
|
||||
before do
|
||||
render 'users/description/champs/yes_no.html.haml', champ: champ
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue