From e95f4cf46ed0047083fb3825de02416ab7340feb Mon Sep 17 00:00:00 2001 From: Harald Eilertsen Date: Sat, 10 Oct 2015 14:29:57 +0200 Subject: Add parens to avoid some jEdit warnings. --- spec/registration_spec.rb | 52 +++++++++++++++++++++++------------------------ 1 file changed, 26 insertions(+), 26 deletions(-) (limited to 'spec') diff --git a/spec/registration_spec.rb b/spec/registration_spec.rb index 33df205..4b27bbe 100644 --- a/spec/registration_spec.rb +++ b/spec/registration_spec.rb @@ -18,15 +18,15 @@ describe RegistrationApp do end it 'displays the registration form' do - expect(last_response.body).to match /form id="registration-form"/ + expect(last_response.body).to match(/form id="registration-form"/) end it 'displays the add member button' do - expect(last_response.body).to match /id="add-member-button"/ + expect(last_response.body).to match(/id="add-member-button"/) end it 'displays the add song button' do - expect(last_response.body).to match /id="add-song-button"/ + expect(last_response.body).to match(/id="add-song-button"/) end end @@ -47,26 +47,26 @@ describe RegistrationApp do end it 'displays submitted data to user' do - expect(last_response).to match /Bandnavn\: Imbalance/ - expect(last_response).to match /Hjemsted\: Oslo/ - expect(last_response).to match /Webside\: http\:\/\/imbalance.no/ - expect(last_response).to match /Plateselskap\: Calculated Imperfection/ - expect(last_response).to match /Kort bio\: Thrash metal from Norway/ - - expect(last_response).to match /Kontaktperson: Harald Eilertsen/ - expect(last_response).to match /Kontaktadresse: Gamleveien 13\n1289 Snufstad/ - expect(last_response).to match /Telefon: 98765432/ - expect(last_response).to match /Epost: mail@imbalance\.no/ - - expect(last_response).to match /Harald Eilertsen, Bass\/Vocals/ - expect(last_response).to match /Welle, Drums/ - expect(last_response).to match /Thormodr, Guitar/ - - expect(last_response).to match /Bestial by Nature/ - expect(last_response).to match /Spilletid: 02:80/ - expect(last_response).to match /Utøvere: Harald Eilertsen, Thormod Steinert, Lars Welle/ - expect(last_response).to match /Låtskrivere: Harald Eilertsen, Thormod Steinert/ - expect(last_response).to match /Merknad: Rævrukkje rum kjurr!/ + expect(last_response).to match(/Bandnavn\: Imbalance/) + expect(last_response).to match(/Hjemsted\: Oslo/) + expect(last_response).to match(/Webside\: http\:\/\/imbalance.no/) + expect(last_response).to match(/Plateselskap\: Calculated Imperfection/) + expect(last_response).to match(/Kort bio\: Thrash metal from Norway/) + + expect(last_response).to match(/Kontaktperson: Harald Eilertsen/) + expect(last_response).to match(/Kontaktadresse: Gamleveien 13\n1289 Snufstad/) + expect(last_response).to match(/Telefon: 98765432/) + expect(last_response).to match(/Epost: mail@imbalance\.no/) + + expect(last_response).to match(/Harald Eilertsen, Bass\/Vocals/) + expect(last_response).to match(/Welle, Drums/) + expect(last_response).to match(/Thormodr, Guitar/) + + expect(last_response).to match(/Bestial by Nature/) + expect(last_response).to match(/Spilletid: 02:80/) + expect(last_response).to match(/Utøvere: Harald Eilertsen, Thormod Steinert, Lars Welle/) + expect(last_response).to match(/Låtskrivere: Harald Eilertsen, Thormod Steinert/) + expect(last_response).to match(/Merknad: Rævrukkje rum kjurr!/) end it "generates a PDF file" do @@ -78,7 +78,7 @@ describe RegistrationApp do message = Mail::TestMailer.deliveries.first expect(Mail::TestMailer.deliveries).not_to be_empty expect(message.to).to include('haraldei@anduin.net') - expect(message.subject).to match /Registrering av band Imbalance til Norsk Urskog/ + expect(message.subject).to match(/Registrering av band Imbalance til Norsk Urskog/) end end @@ -88,11 +88,11 @@ describe RegistrationApp do end it 'should reject request and go back to the registration form' do - expect(last_response.body).to match /form id="registration-form"/ + expect(last_response.body).to match(/form id="registration-form"/) end it 'should display an error message' do - expect(last_response.body).to include "Du må ha med minst én låt" + expect(last_response.body).to include("Du må ha med minst én låt") end end end -- cgit v1.2.3