-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
1 parent
ce102e3
commit 703b991
Showing
2 changed files
with
57 additions
and
3 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,8 +1,8 @@ | ||
FactoryGirl.define do | ||
factory :paper do | ||
# title "COMPUTING MACHINERY AND INTELLIGENCE" | ||
# venue "Mind 49: 433-460" | ||
# year 1950 | ||
title "COMPUTING MACHINERY AND INTELLIGENCE" | ||
venue "Mind 49: 433-460" | ||
year 1950 | ||
# authors {build_list :author, 1} | ||
end | ||
end |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,54 @@ | ||
require 'rails_helper' | ||
|
||
describe 'Paper index page', type: :feature do | ||
it 'should render without error' do | ||
visit papers_path | ||
end | ||
|
||
it 'should show_data' do | ||
FactoryGirl.create :paper | ||
visit papers_path | ||
|
||
expect(page.text).to match(/COMPUTING MACHINERY AND INTELLIGENCE/i) | ||
end | ||
|
||
# it 'should have a link to new author' do | ||
# FactoryGirl.create :author | ||
# visit authors_path | ||
# | ||
# expect(page).to have_link('Add author') | ||
# expect(page).to have_link('Show') | ||
# end | ||
# | ||
# it 'should have a link to show author' do | ||
# FactoryGirl.create :author | ||
# visit authors_path | ||
# | ||
# expect(page).to have_link('Show') | ||
# end | ||
# | ||
# it 'should have a link to edit author' do | ||
# FactoryGirl.create :author | ||
# visit authors_path | ||
# | ||
# expect(page).to have_link('Edit') | ||
# end | ||
# | ||
# it 'should have a link to destroy author' do | ||
# FactoryGirl.create :author | ||
# visit authors_path | ||
# | ||
# expect(page).to have_link('Destroy') | ||
# end | ||
# | ||
# it 'should actually remove the author' do | ||
# FactoryGirl.create :author | ||
# visit authors_path | ||
# | ||
# expect(Author.find_by_first_name('Alan')).not_to be_nil | ||
# | ||
# click_link('Destroy') | ||
# | ||
# expect(Author.find_by_first_name('Alan')).to be_nil | ||
# end | ||
end |