Sha256: 08810b4f2a54642170ad9cdd7cf91e31fedd19493c431ccc1e70ca040ef27789

Contents?: true

Size: 812 Bytes

Versions: 1

Compression:

Stored size: 812 Bytes

Contents

require 'spec_helper'

describe "User Profile" do

  before do
    # FactoryGirl.create(:user)
    # FactoryGirl.create(:archivist)
    # FactoryGirl.create(:curator)
    sign_in :curator
  end

  it "should be displayed" do
    click_link "curator1@example.com"
    page.should have_content "Edit Your Profile"
  end

  it "should be editable" do
    click_link "curator1@example.com"
    click_link "Edit Your Profile"
    fill_in 'user_twitter_handle', with: 'curatorOfData'
    click_button 'Save Profile'
    page.should have_content "Your profile has been updated"
    page.should have_content "curatorOfData"
  end

  it "should display all users" do
    click_link "curator1@example.com"
    click_link "View Users"
    page.should have_xpath("//td/a[@href='/users/curator1@example-dot-com']")
  end
end

Version data entries

1 entries across 1 versions & 1 rubygems

Version Path
sufia-3.4.0 spec/features/users_spec.rb