Skip to content

Commit

Permalink
test
Browse files Browse the repository at this point in the history
  • Loading branch information
Benoit-MINT committed Jan 30, 2025
1 parent 51c0008 commit 57f375e
Showing 1 changed file with 19 additions and 1 deletion.
20 changes: 19 additions & 1 deletion spec/views/instructeur/dossiers/show.html.haml_spec.rb
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@
let(:current_instructeur) { create(:instructeur) }
let(:dossier) { create(:dossier, :en_construction) }
let(:statut) { { statut: 'tous' } }
let(:procedure_presentation) { double(instructeur: current_instructeur, procedure: dossier.procedure) }
let(:procedure_presentation) { double(instructeur: current_instructeur, procedure: dossier.procedure, displayed_columns: []) }

before do
sign_in(current_instructeur.user)
Expand Down Expand Up @@ -267,4 +267,22 @@
end
end
end

describe "Labels notice" do
context "Labels column is not present on procedures/show" do
it "displays the labels notice" do
within('.dropdown') do
expect(subject).to have_class("fr-notice")
end
end
end

context "Labels column is present on procedures/show" do
it "does not display the labels notice" do
within('.dropdown') do
expect(subject).not_to have_class("fr-notice")
end
end
end
end
end

0 comments on commit 57f375e

Please sign in to comment.