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
M_ROOT]/gems/redis-3.0.7/lib/redis/client.rb:299:in `ensure_connected` | |
[GEM_ROOT]/gems/redis-3.0.7/lib/redis/client.rb:191:in `block in process` | |
[GEM_ROOT]/gems/redis-3.0.7/lib/redis/client.rb:270:in `logging` | |
[GEM_ROOT]/gems/redis-3.0.7/lib/redis/client.rb:190:in `process` | |
[GEM_ROOT]/gems/redis-3.0.7/lib/redis/client.rb:96:in `call` | |
[GEM_ROOT]/gems/redis-3.0.7/lib/redis.rb:1206:in `block in sadd` | |
[GEM_ROOT]/gems/redis-3.0.7/lib/redis.rb:37:in `block in synchronize` | |
/usr/lib64/ruby/2.0.0/monitor.rb:211:in `mon_synchronize` | |
[GEM_ROOT]/gems/redis-3.0.7/lib/redis.rb:37:in `synchronize` | |
[GEM_ROOT]/gems/redis-3.0.7/lib/redis.rb:1205:in `sadd` |
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
# Set variables for usage in the before_exec block to help ensure deploys are succesful. | |
current_path = '/data/reputation/current' | |
shared_path = '/data/reputation/shared' | |
shared_bundler_gems_path = "/data/reputation/shared/bundled_gems" | |
working_directory '/data/reputation/current/' | |
# sets the current number of worker_processes to +nr+. Each worker | |
# process will serve exactly one client at a time. You can | |
# increment or decrement this value at runtime by sending SIGTTIN | |
# or SIGTTOU respectively to the master process without reloading |
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: | |
Organization | |
has_one :plan, dependent: :destroy, inverse_of: :organization | |
validates_presence_of :name, :plan | |
Plan | |
belongs_to :organization, inverse_of: :plan | |
validates :organization, :type, presence: true |
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 "spec_helper" | |
module TimeZoneTestHelper | |
def self.included(base) | |
base.extend ClassMethods | |
end | |
module ClassMethods |
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
{ | |
"debug_info" => [], | |
"html_attributions" => [], | |
"result" => { | |
"address_components" => [ | |
[0] { | |
"long_name" => "Provo", | |
"short_name" => "Provo", | |
"types" => [ | |
[0] "locality", |
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
[15] pry(main)> details | |
{ | |
"debug_info" => [], | |
"html_attributions" => [], | |
"result" => { | |
"address_components" => [ | |
[0] { | |
"long_name" => "Monterra Apartments", | |
"short_name" => "Monterra Apartments", | |
"types" => [ |
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
class Middleware::Caring::Api | |
include HTTParty | |
#debug_output $stdout | |
base_uri 'dir.caring.com' | |
format :json | |
RESOURCE = '/api/v1/reviews/feed.json' | |
PID = 'fb0487e0' |
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
<<<<<<< HEAD | |
def self.update_location_google_places_listing(location, place_details_data) | |
business_listing = location.google_places_listing | |
business_listing.average_rating = place_details_data.result.rating | |
business_listing.url = place_details_data.result.url | |
business_listing.save | |
end | |
# @params Location location the location being updated | |
# @params String search_result the google places search api result, |
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
<<<<<<< HEAD | |
it "should update location google+ listings" do | |
location = Location.new | |
biz_listing = BusinessListing.new | |
location.stub(:google_places_listing).and_return(biz_listing) | |
biz_listing.should_receive(:save) | |
place_details = stub(:result => stub({:rating => 3, :url => "foo.com"})) | |
Search::LocationFactory.update_location_google_places_listing(location, place_details) | |
biz_listing.url.should == "foo.com" |
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
[3] pry(Location)> places_detail_search | |
#<Middleware::GooglePlaces::PlacesDetailSearch:0x007f98614c3af0 | |
@key="places-detail-searches:776aab04dfe55af47d74e006d82468d8", | |
@raw_result={"address_components"=>[{"long_name"=>"2130", "short_name"=>"2130", "types"=>["street_number"]}, {"long_name"=>"Post St", "short_name"=>"Post St", "types"=>["route"]}, {"long_name"=>"Lower Pacific Heights", "short_name"=>"Lower Pacific Heights", "types"=>["neighborhood", "political"]}, {"long_name"=>"San Francisco", "short_name"=>"SF", "types"=>["locality", "political"]}, {"long_name"=>"San Francisco", "short_name"=>"San Francisco", "types"=>["administrative_area_level_2", "political"]}, {"long_name"=>"California", "short_name"=>"CA", "types"=>["administrative_area_level_1", "political"]}, {"long_name"=>"United States", "short_name"=>"US", "types"=>["country", "political"]}, {"long_name"=>"94115", "short_name"=>"94115", "types"=>["postal_code"]}], "adr_address"=>"<span class=\"street-address\">2130 Post St</span>, <span class=\"lo |