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 "with nested collateral" do | |
let(:parent) { create :collateral, attachment: hotplay } | |
before do | |
HotplayViewer.create(user: user, hotplay: hotplay) | |
get :index, format: :json | |
end | |
it { assert_response :success } | |
it { response.headers["Content-Type"].must_include "application/json" } |
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
history | awk '{a[$2]++}END{for(i in a){print a[i] " " i}}' | sort -rn | head -15 |
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
function _git_prompt() { | |
local git_status="`git status -unormal 2>&1`" | |
if ! [[ "$git_status" =~ Not\ a\ git\ repo ]]; then | |
if [[ "$git_status" =~ nothing\ to\ commit ]]; then | |
local ansi=42 | |
elif [[ "$git_status" =~ nothing\ added\ to\ commit\ but\ untracked\ files\ present ]]; then | |
local ansi=43 | |
else | |
local ansi=45 | |
fi |
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
FAIL WeedMapsAPI::V1::DispensaryDetailCall::with a clean index#test_0001_returns dispensary details (0.00s) | |
--- expected | |
+++ actual | |
@@ -1,3 +1,3 @@ | |
{:z=>105, :n=>"Dr. Greenthumb Garden Supply 142", :i=>0, :distance=>13, :hits=>0, :a=>"175 River Terrace Fremont Ca 94539", :phone=>"555-555-1142", :rating=>0.0, :y=>-121.9674, :x=>37.5770843, :h=>"10am - 10pm", :d=>"4g eighths, Referrals - free eighth", :link=>"http://example.com/dispensaries/xxx", :kinds=>"2 sativa 1 indica", :photos=>[], :reviews=>[{:z=>63, :name=>"username508", :i=>"", :title=>"This is a cool place.", :r=>5, :comments=>"And I like it.\r | |
-", :when=>"May 5th, 2013"}, {:z=>62, :name=>"username507", :i=>"", :title=>"This is a cool place.", :r=>5, :comments=>"And I like it.\r | |
-", :when=>"May 5th, 2013"}]} | |
+", :when=>"May 6th, 2013"}, {:z=>62, :name=>"username507", :i=>"", :title=>"This is a cool place.", :r=>5, :comments=>"And I like it.\r | |
+", :when=>"May 6th, 2013"}]} | |
(eval):8:in `must_equal' |
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
guard "minitest", all_on_start: false, rerun: false do | |
# with Minitest::Spec | |
watch(%r|^test/(.*)_test\.rb|) | |
watch(%r|^lib/(.*)([^/]+)\.rb|) { |m| "test/#{m[1]}#{m[2]}_test.rb" } | |
watch(%r|^test/minitest_helper\.rb|) { "test" } | |
watch(%r|^test/support/|) { "test" } | |
# Rails 3.2 | |
watch(%r|^app/controllers/(.*)\.rb|) { |m| "test/controllers/#{m[1]}_test.rb" } | |
watch(%r|^app/mailers/(.*)\.rb|) { |m| "test/mailers/#{m[1]}_test.rb" } |
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
guard "minitest", all_on_start: false, rerun: false do | |
# with Minitest::Spec | |
watch(%r|^test/(.*)_test\.rb|) | |
watch(%r|^lib/(.*)([^/]+)\.rb|) { |m| "test/#{m[1]}#{m[2]}_test.rb" } | |
watch(%r|^test/minitest_helper\.rb|) { "test" } | |
watch(%r|^test/support/|) { "test" } | |
# Rails 3.2 | |
watch(%r|^app/controllers/(.*)\.rb|) { |m| "test/controllers/#{m[1]}_test.rb" } | |
watch(%r|^app/mailers/(.*)\.rb|) { |m| "test/mailers/#{m[1]}_test.rb" } |
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
modelName = $('#review_filter').val() || "dispensary" | |
$('#review_filter_query').attr("placeholder","#{modelName.capitalize}") | |
$('#review_filter_query').attr("data-autocomplete", "/admin/reviews/autocomplete_#{modelName}_name") | |
$.fn.capitalize -> | |
$.each this, -> | |
caps = this.value | |
caps = caps.charAt(0).toUpperCase() + caps.slice(1) | |
this.value = caps | |
return this |
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
platform: &platform | |
<% if RUBY_PLATFORM == "java" %> | |
adapter: jdbcpostgresql | |
<% else %> | |
adapter: postgresql | |
<% end %> | |
default: &default | |
<<: *platform | |
username: dreamr |
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
. /usr/local/etc/bash_completion.d/git-prompt.sh | |
. /usr/local/etc/bash_completion.d/git-completion.bash | |
export PS1='\[\033[01;32m\]\h\[\033[01;34m\] \w\[\033[31m\] $(__git_ps1 "(%s)") \[\033[01;34m\]$\[\033[00m\] ' |
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
guard "minitest", all_on_start: false, rerun: false do | |
# with Minitest::Spec | |
watch(%r|^test/(.*)_test\.rb|) | |
watch(%r|^lib/(.*)([^/]+)\.rb|) { |m| "test/#{m[1]}#{m[2]}_test.rb" } | |
watch(%r|^test/minitest_helper\.rb|) { "test" } | |
watch(%r|^test/support/|) { "test" } | |
# Rails 3.2 | |
watch(%r|^app/controllers/(.*)\.rb|) { |m| "test/controllers/#{m[1]}_test.rb" } | |
watch(%r|^app/mailers/(.*)\.rb|) { |m| "test/mailers/#{m[1]}_test.rb" } |