This file contains hidden or 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
let g:gist_clip_command = 'pbcopy' | |
let g:gist_detect_filetype = 1 | |
let g:gist_open_browser_after_post = 1 |
This file contains hidden or 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
if ENV["SIMPLECOV"] | |
p "use simple cov" | |
require 'simplecov' | |
SimpleCov.start 'rails' | |
SimpleCov.at_exit do | |
threshold = 100 | |
SimpleCov.result.format! | |
if SimpleCov.result.covered_percent != threshold | |
puts "the threshold is #{threshold}%. the actual coverage is #{SimpleCov.result.covered_percent}%".foreground(:red) | |
exit 1 |
This file contains hidden or 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
module Presenter | |
class Person | |
attr_reader :model | |
def initialize(model) | |
@model = model | |
end | |
def gender | |
model.male? ? "Male" : "Female" | |
end |
This file contains hidden or 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
Given a user exists | |
When I send a GET request as: | |
""" | |
/users/user-id.json?api_token=your-token | |
""" | |
Then I receive a JSON response as: | |
""" | |
{ | |
user: { | |
id: user's unique identifier, |
This file contains hidden or 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
subject { Factory.build : merchant_location, pk => 12, : physical_location_se_number => "92929"} | |
describe "#create" do | |
it "sends out email" do # or whatever desc makes sense | |
Merchant::Location.should_receive(:enqueue).at_least(1).times.with(:validate_external_location, 12) | |
subject.after_create | |
end | |
end |
This file contains hidden or 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
1,(508) 333.4304 | |
2,8609339713 | |
3,347.908.5342 | |
4,615.554.4463 | |
5,209.915.5720 | |
6,919-924-3464 | |
7,917.399.8115 | |
8,718 288 2436 | |
9,716.785.2007 | |
10,480.628.5739 |
This file contains hidden or 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 | Last name | Phone | Tags | Positions | ||
---|---|---|---|---|---|---|
Baric | Schlanger | (873)986-5679 | [email protected] | cool;fun;friendly | Bartender;Waiter | |
Nicka | Lillios | 1-457-928-3838 | [email protected] | tall;bearded | Model | |
Schlanger | (373)786-5679 | [email protected] | cool;fun;friendly | Bartender;Waiter |
This file contains hidden or 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
company user id | user id | company id | name | phone number | ||
---|---|---|---|---|---|---|
544 | 640 | 7 | Victor Apaez | [email protected] | 3473577054 | |
1346 | 593 | 7 | Gregory Baldwin - 2nd String | [email protected] | 9146022344 | |
1207 | 638 | 7 | Salvador Barragan | [email protected] | 3473666995 | |
808 | 596 | 7 | Alan Beard - (2nd String) | [email protected] | 5038883378 | |
272 | 551 | 7 | Brook Bisrat - (1st String) | [email protected] | 9376842494 | |
619 | 511 | 7 | Jeremy Bite catering | [email protected] | 6462813492 | |
698 | 642 | 7 | Fransisco Bonifaz | [email protected] | 9176869705 | |
608 | 554 | 7 | Rusty Broughton - 1st String | [email protected] | 3472605264 | |
1410 | 597 | 7 | Mat Burrow - 2nd String | [email protected] | 6314556328 |