(Here's my proposed fix for this)
First, print out the test names:
$ ruby minitest.rb -v
Run options: -v --seed 58440
# Running tests:
AnotherTest#test_something = 0.00 s = F
| select substring(md5(<first salt> || proposal_id) for 8) as proposal_hash, substring(md5(<second salt> || user_id) for 8) as user_hash from selections; |
| class Thing | |
| def self.runner=(custom_runner) | |
| @runner = custom_runner | |
| end | |
| def self.runner | |
| @runner ||= new | |
| end | |
| def run(*args) |
| describe ThingController do | |
| describe "creating a thing" do | |
| action { post :create, attributes } | |
| describe "when not logged in" do | |
| it "should redirect to login" do | |
| assert_redirected_to login_path | |
| end | |
| end |
(Here's my proposed fix for this)
First, print out the test names:
$ ruby minitest.rb -v
Run options: -v --seed 58440
# Running tests:
AnotherTest#test_something = 0.00 s = F
| $LOAD_PATH.unshift File.expand_path("../lib", __FILE__) | |
| ENV["KINTAMA_EXPLICITLY_DONT_RUN"] = "true" | |
| at_exit { $reporter.show_final_results } | |
| require 'kintama' | |
| $contexts = [] | |
| class TomReporter < Kintama::Reporter::Inline | |
| def show_final_results | |
| puts | |
| puts test_summary |
| a_really_long_method_name_with_arguments "looks weird", | |
| {if: "they are indented"} | |
| "like this" | |
| but_a_shorter_one "doesn't look", | |
| "quite as weird" | |
| it_also_depends_on "how long", "the arguments", "are" | |
| and_how_many_arguments( |
| {"blog"=>{"Alice"=>2422, "Bob"=>2542, "Clare"=>2503, "Dave"=>2533}, | |
| "invoice"=>{"Alice"=>2504, "Bob"=>2493, "Clare"=>2535, "Dave"=>2468}, | |
| "fire_log"=>{"Alice"=>2488, "Bob"=>2500, "Clare"=>2479, "Dave"=>2533}} |
| #!/usr/bin/env ruby | |
| # You should ensure that the `rmagick` and `a2_printer` gems are installed. | |
| require "rubygems" | |
| require "RMagick" | |
| require "a2_printer" | |
| if ARGV.length < 2 | |
| puts "Usage: convert_image_to_bytes.rb <image_file> <output_file>" |
This script installs a patched version of ruby 1.9.3-p194 with patches for boot-time performance improvements (#66 and #68), and runtime performance improvements (#83 and #84). It also includes the new backported GC from ruby-trunk.
Huge thanks to funny-falcon for the performance patches.
| #!/usr/bin/env ruby | |
| git_changes = `git status --porcelain | awk '{print $2}'` | |
| files = [] | |
| git_changes.split.each do |file| | |
| if File.directory?(file) | |
| files += Dir["#{file}**/*"] | |
| else | |
| files << file | |
| end |