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 "minitest/autorun" | |
| # inspired by some code from Chris Wanstrath (shared w. me by Ryan Smith) | |
| # https://gist.github.com/25455 | |
| # | |
| # heavily modified by Gregory Brown at this point.. | |
| def context(*args, &block) | |
| return super unless (name = args.first) && block |
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
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
| $ spork --bootstrap | |
| NOTE: Gem.latest_load_paths is deprecated with no replacement. It will be removed on or after 2011-10-01. | |
| Gem.latest_load_paths called from /Users/seacreature/.rvm/gems/ruby-1.9.2-p180/gems/spork-0.8.5/lib/spork.rb:112. | |
| NOTE: Gem.all_partials is deprecated with no replacement. It will be removed on or after 2011-10-01. | |
| Gem.all_partials called from /Users/seacreature/.rvm/rubies/ruby-1.9.2-p180/lib/ruby/site_ruby/1.9.1/rubygems.rb:600. | |
| undefined method `specifications' for "/Users/seacreature/.rvm/gems/ruby-1.9.2-p180":String (NoMethodError) | |
| /Users/seacreature/.rvm/rubies/ruby-1.9.2-p180/lib/ruby/site_ruby/1.9.1/rubygems.rb:425:in `block in each_load_path' | |
| /Users/seacreature/.rvm/rubies/ruby-1.9.2-p180/lib/ruby/site_ruby/1.9.1/rubygems.rb:423:in `each' | |
| /Users/seacreature/.rvm/rubies/ruby-1.9.2-p180/lib/ruby/site_ruby/1.9.1/rubygems.rb:423:in `each_load_path' | |
| /Users/seacreature/.rvm/rubies/ruby-1.9.2-p180/lib/ruby/site_ruby/1.9.1/rubygems.rb:587:in `block in latest_load_paths' |
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
| $ ack Gem | |
| features/steps/rails_steps.rb | |
| 13: FileUtils.ln_sf(ENV["BUNDLE_GEMFILE"], "Gemfile") | |
| 14: FileUtils.ln_sf(ENV["BUNDLE_GEMFILE"] + ".lock", "Gemfile.lock") | |
| features/support/bundler_helpers.rb | |
| 6: command = "env RUBYOPT= BUNDLE_GEMFILE=Gemfile bundle install" | |
| 13: gemfile_lock = dir + "/Gemfile.lock" | |
| 14: gemfile = dir + "/Gemfile" | |
| 18: puts "Gemfile #{gemfile} has changed since it was locked. Re-locking..." |
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
| seacreature:spork-testing$ spork | |
| NOTE: Gem.latest_load_paths is deprecated with no replacement. It will be removed on or after 2011-10-01. | |
| Gem.latest_load_paths called from /Users/seacreature/.rvm/gems/ruby-1.9.2-p180/gems/spork-0.8.5/lib/spork.rb:112. | |
| NOTE: Gem.all_partials is deprecated with no replacement. It will be removed on or after 2011-10-01. | |
| Gem.all_partials called from /Users/seacreature/.rvm/rubies/ruby-1.9.2-p180/lib/ruby/site_ruby/1.9.1/rubygems.rb:600. | |
| undefined method `specifications' for "/Users/seacreature/.rvm/gems/ruby-1.9.2-p180":String (NoMethodError) | |
| /Users/seacreature/.rvm/rubies/ruby-1.9.2-p180/lib/ruby/site_ruby/1.9.1/rubygems.rb:425:in `block in each_load_path' | |
| /Users/seacreature/.rvm/rubies/ruby-1.9.2-p180/lib/ruby/site_ruby/1.9.1/rubygems.rb:423:in `each' | |
| /Users/seacreature/.rvm/rubies/ruby-1.9.2-p180/lib/ruby/site_ruby/1.9.1/rubygems.rb:423:in `each_load_path' | |
| /Users/seacreature/.rvm/rubies/ruby-1.9.2-p180/lib/ruby/site_ruby/1.9.1/rubygems.rb:587:in `block in latest_load_paths' |
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 "minitest/autorun" | |
| require "set" | |
| FIXTURE_DIR = File.expand_path( | |
| File.dirname(__FILE__)+"/fixtures/") | |
| # adopted from: https://gist.github.com/839034 | |
| def context(*args, &block) | |
| return super unless (name = args.first) && block |
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
| #include<stdio.h> | |
| #if !defined(__LP64__) | |
| #define IS_64 0 | |
| #else | |
| #define IS_64 1 | |
| #endif | |
| main() | |
| { |
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 MyCollection | |
| def initialize | |
| @data = [] | |
| @data.extend(MySpecialFeatures) | |
| end | |
| def some_method | |
| @data.use_one_of_my_features | |
| 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
| # Is this a bug or just a behavior change? Know a workaround to get the 1.8 behavior in 1.9? | |
| I would even be okay with explicitly having to define inspect as long as | |
| I could get the original inspect behavior from Object back, but would prefer something simpler... | |
| ## Ruby 1.9.2 | |
| >> class A | |
| >> def initialize(x,y,z) | |
| >> @x, @y, @z = x,y,z | |
| >> 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
| class Point | |
| def initialize(x,y) | |
| @x, @y = x, y | |
| end | |
| end | |
| module Positionable | |
| attr_accessor :map | |
| def neighbors |