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
{"first_name":"Tomek","last_name":"K","avatar_url":null,"short_address":"Brandenburg, Germany","user_url":"/users/user5-el","pending_friendships":[{"agripoints":0,"avatar_content_type":null,"avatar_file_name":null,"avatar_file_size":null,"avatar_updated_at":null,"confirmation_reminder":false,"created_at":"2013-06-11T14:17:51Z","deals_newsletter":false,"email":"user5@agricircle.com","first_name":"User5","id":20,"language":"English","last_name":"El","newsletter":false,"slug":"user5-el","terms_of_service":true,"title":"Mr","updated_at":"2013-06-11T14:17:51Z","user_type":"Farmer","website":"http:\\codequest.com"}]} |
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
context "Validates presence of either start time or open time" do | |
setup do | |
@user = FactoryGirl.create(:user) | |
@account = FactoryGirl.create(:account, user: @user) | |
@location = FactoryGirl.create(:location, account: @account) | |
end | |
should "not be valid without open time or start time " do | |
event = FactoryGirl.build(:event, fb_id: '12345', account: @account, location: @location, start_at: nil, open_at: nil, end_at: Time.now + 1.hour) | |
assert !event.valid? |
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
context "Validates presence of either start time or open time" do | |
setup do | |
@user = FactoryGirl.create(:user) | |
@account = FactoryGirl.create(:account, user: @user) | |
@location = FactoryGirl.create(:location, account: @account) | |
end | |
should "not be valid without open time or start time " do | |
event = FactoryGirl.build(:event, fb_id: '12345', account: @account, location: @location, start_at: nil, open_at: nil, end_at: Time.now + 1.hour) | |
assert !event.valid? |
NewerOlder