update tests
This commit is contained in:
parent
cdc28e48fb
commit
200541e964
|
|
@ -17,13 +17,12 @@ describe "Landing", :js => true, :type => :feature, :capybara_feature => true do
|
|||
let (:claimed_recording) { FactoryGirl.create(:claimed_recording) }
|
||||
|
||||
it "should render comments" do
|
||||
pending "weird error"
|
||||
# pending "weird error"
|
||||
|
||||
recording = ClaimedRecording.first
|
||||
comment = "test comment"
|
||||
timestamp = "less than a minute ago"
|
||||
url = "/recordings/#{claimed_recording.id}"
|
||||
|
||||
recording = ClaimedRecording.first
|
||||
visit url
|
||||
|
||||
fill_in "txtRecordingComment", with: comment
|
||||
|
|
|
|||
|
|
@ -14,7 +14,7 @@ describe "Landing", :js => true, :type => :feature, :capybara_feature => true do
|
|||
end
|
||||
|
||||
it "should render comments" do
|
||||
pending "weird error"
|
||||
# pending "weird error"
|
||||
|
||||
msh = MusicSessionHistory.first
|
||||
comment = "test comment"
|
||||
|
|
@ -22,6 +22,8 @@ describe "Landing", :js => true, :type => :feature, :capybara_feature => true do
|
|||
url = "/sessions/#{msh.id}"
|
||||
visit url
|
||||
|
||||
# (1) Test a user creating a comment and ensure it displays.
|
||||
|
||||
fill_in "txtSessionComment", with: comment
|
||||
find('#btnPostComment').trigger(:click)
|
||||
|
||||
|
|
@ -31,6 +33,9 @@ describe "Landing", :js => true, :type => :feature, :capybara_feature => true do
|
|||
# timestamp
|
||||
find('div', text: timestamp)
|
||||
|
||||
# (2) Test a user visiting a landing page with an existing comment.
|
||||
|
||||
# re-visit page to reload from database
|
||||
visit url
|
||||
|
||||
# comment body
|
||||
|
|
|
|||
Loading…
Reference in New Issue