I hereby claim:
- I am idengager on github.
- I am idengager (https://keybase.io/idengager) on keybase.
- I have a public key ASCckg3paMpzl2Pfnh__YRwcARFhYoMuxE7d_WsLkgs3ewo
To claim this, I am signing this object:
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
describe "labels" do | |
it "should have field for comeptition name" do | |
expect(page).to have_field( | |
I18n.t('activerecord.attributes.competition.name')) | |
end | |
it "should have field for classification" do | |
expect(page).to have_field( | |
I18n.t('activerecord.attributes.competition.classification')) | |
end |
Shelly Cloud is a PaaS (Platform as a Service) hosting provider, dedicated for Ruby on Rails apps.
This tutorial assumes you have already initialized a git repository – take a look at the Github's guide if that isn't the case. If you get stuck at any point in this guide, take a look at the docs or use one of our support channels.
First, make sure your app uses one of Shelly Cloud's supported databases. Second, you are advised to use the shelly-dependecies
gem to take care of gem dependencies. Add the following lines to your Gemfile
:
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
candy_to_bring = "prince polo" | |
candy_to_bring += " and danusia" if danusia.is_in_the_shop? |
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
require 'spec_helper' | |
describe 'Create event' do | |
before do | |
stub_request(:get, "http://calendar-api.shellyapp.com/events/new?token=") | |
.to_return(status: 200, body: { message: {}.to_json }, headers: {}) | |
end | |
it 'should render new event form' do | |
visit '/events/new' |
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
require 'spec_helper' | |
describe 'Event index' do | |
context 'when user is not signed-in' do | |
before do | |
stub_request(:get, "http://localhost:9292/events?token="). | |
to_return(status: 200, body: { message: [public_event, private_event, past_event, future_event] }.to_json, headers: {}) | |
visit '/events' | |
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
require 'spec_helper' | |
describe 'User.show' do | |
include CalendarApp | |
context 'when user is not logged in' do | |
before { get 'users/non-existent-id' } | |
it 'should return HTTP 403' do | |
last_response.status.should == 403 |