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
# Based on https://gist.github.com/1718985 | |
# Usage: | |
# 1) Put in spec/support/rspec_retries.rb | |
# 2) Call from spec_helper.rb: "RSpec::Retries.setup(config)" | |
# 3) Change around filter to suit your needs. | |
# Example output: | |
# .............. | |
# |
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
-------------------------------------------------- | |
lib/foo.rb:22:in `save' | |
# foo.book | |
>> REQUEST: | |
{ | |
"CashBook_Book": { | |
"cashBookHandle": { | |
"Number": "14" |
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
diff --git a/gc.c b/gc.c | |
--- a/gc.c | |
+++ b/gc.c | |
@@ -416,7 +416,6 @@ | |
malloc_limit_ptr = getenv("RUBY_GC_MALLOC_LIMIT"); | |
if (malloc_limit_ptr != NULL) { | |
int malloc_limit_i = atoi(malloc_limit_ptr); | |
- printf("malloc_limit=%d (%d)\n", malloc_limit_i, initial_malloc_limit); | |
if (malloc_limit_i > 0) { | |
initial_malloc_limit = malloc_limit_i; |
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/bin/env ruby | |
require 'rubygems' | |
require 'pivotal-tracker' | |
class String | |
ANSI_COLORS = [:black, :red, :green, :yellow, :blue, :magenta, :cyan, :white] | |
def colorize(color) | |
num = ANSI_COLORS.index(color) or raise("Bad color #{ color }") | |
"\e[3#{ num }m" + self + "\e[0m" |
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/bin/env ruby | |
require 'rubygems' | |
require 'xmpp4r' | |
require 'xmpp4r/muc/helper/simplemucclient' | |
# Most of this is borrowed from https://gist.github.com/941931 | |
# Added support for multiple rooms and external handling of messages. | |
# We want the MUC functionality to just handle shit for us. Unfortunately we | |
# have to override/repeat the join method in order to add the directive that |
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
# http://gist.github.com/gists/593755 (fork of http://gist.github.com/485785) | |
require 'spec/runner/formatter/progress_bar_formatter' | |
class FailuresDuringRunFormatter < Spec::Runner::Formatter::ProgressBarFormatter | |
def example_failed(example, counter, failure) | |
super # show the 'F' in progress | |
dump_failure(counter, failure) | |
end | |
end | |
class Spec::Runner::Reporter |