Use one-liners in specs where possible

This commit is contained in:
Thibault Jouan
2014-04-01 18:32:22 +00:00
parent 4cef7aeab9
commit 0c7bf69ba2
22 changed files with 35 additions and 103 deletions

View File

@@ -3,9 +3,7 @@ require 'spec_helper'
feature 'Home page' do
include UserIntegrationHelpers
background do
sign_in
end
background { sign_in }
scenario 'displays playlists' do
playlist = FactoryGirl.create(:playlist, name: 'Electro')

View File

@@ -3,9 +3,7 @@ require 'spec_helper'
feature 'Playlists' do
include UserIntegrationHelpers
background do
sign_in
end
background { sign_in }
scenario 'lists playlists' do
FactoryGirl.create(:playlist, name: 'Electro')

View File

@@ -3,9 +3,7 @@ require 'spec_helper'
feature 'Tracks' do
include UserIntegrationHelpers
background do
sign_in
end
background { sign_in }
scenario 'shows track' do
track = FactoryGirl.create(:track, name: 'Mega song')