2013-05-27 20:04:31 +00:00
|
|
|
require 'spec_helper'
|
|
|
|
|
|
|
|
feature "User's profile" do
|
|
|
|
|
|
|
|
let!(:user) { create(:user) }
|
|
|
|
let!(:asciicast) { create(:asciicast, :user => user, :title => 'Tricks!') }
|
|
|
|
|
|
|
|
scenario 'Visiting' do
|
|
|
|
visit profile_path(user)
|
|
|
|
|
2013-08-14 14:30:49 +00:00
|
|
|
expect(page).to have_content(/Asciicasts by #{user.nickname}/i)
|
2013-05-27 20:04:31 +00:00
|
|
|
expect(page).to have_content('1 asciicasts')
|
|
|
|
expect(page).to have_link('Tricks!')
|
|
|
|
expect(page).to have_selector('.supplimental .play-button')
|
|
|
|
end
|
|
|
|
|
|
|
|
end
|