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 FactoryGirlStepHelpers | |
| def convert_human_hash_to_attribute_hash(human_hash, associations = []) | |
| HumanHashToAttributeHash.new(human_hash, associations).attributes | |
| end | |
| class HumanHashToAttributeHash | |
| attr_reader :associations | |
| def initialize(human_hash, associations) | |
| @human_hash = human_hash |
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
| require 'nokogiri' | |
| require 'open-uri' | |
| auth_token = 'AUTH_TOKEN' | |
| site = 'https://ACCOUNT_NAME.airbrake.io/projects/PROJECT_NUMBER' | |
| counts = { | |
| :staging => 0, | |
| :production => 0 | |
| } |
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
| describe 'outer', :one => { :two => 2 } do | |
| context 'inner1' do | |
| before do | |
| example.metadata[:one][:three] = 3 | |
| end | |
| it 'should have 3' do | |
| example.metadata[:one][:three].should == 3 | |
| 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
| ls -lh `mdfind -onlyin $HOME -name test.log` |
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
| require 'pivotal-tracker' | |
| TOKEN = 'API_TOKEN' | |
| PROJECT_NUM = -1 | |
| def estimate_to_hours(estimate) | |
| 2 ** estimate | |
| end | |
| PivotalTracker::Client.token = TOKEN |
NewerOlder