This file contains 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
step_definition_dir = "../features/step_definitions" | |
steps = [] | |
Dir.glob(File.join(step_definition_dir,'**/*.rb')).each do |step_file| | |
File.new(step_file).read.each_line do |line| | |
next unless line =~ /^\s*(?:Given|When|Then)\s+\// | |
matches = /(Given|When|Then)\s*\/(.*)\/([imxo]*)\s*do\s*(?:$|\|(.*)\|)/.match(line).captures | |
type = matches[0] | |
matches[1] = Regexp.new(matches[1]) | |
step = matches[1].inspect | |
step = step[2..step.length-3] |
This file contains 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
PADRINO_ENV = 'test' unless defined?(PADRINO_ENV) | |
require 'rubygems' | |
require 'spork' | |
Spork.prefork do | |
# Loading more in this block will cause your tests to run faster. However, | |
# if you change any configuration or code from libraries loaded here, you'll | |
# need to restart spork for it take effect. | |
This file contains 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
# foo.rb | |
class Foo < ::Sinatra::Base | |
class << self | |
def dependencies; []; end | |
def setup_application!; end | |
end | |
get '/' do | |
'wubwub' |
This file contains 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
'use strict'; | |
/** | |
* @ngdoc function | |
* @name hlApp.controller:MainCtrl | |
* @description | |
* # MainCtrl | |
* Controller of the hlApp | |
*/ | |
angular.module('hlApp') |
This file contains 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 'set' | |
require 'active_support/concern' | |
require 'active_support/deprecation' | |
module ActiveRecord | |
module Delegation # :nodoc: | |
module DelegateCache | |
def relation_delegate_class(klass) # :nodoc: | |
@relation_delegate_cache[klass] | |
end |
This file contains 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 'guard/notifier' | |
notifiers_options = { | |
:emacs => { | |
:fontcolor => "#acbc90", | |
:default => "#1e2320", | |
:success => "#013009", | |
:failed => "#310602", | |
:pending => "#534626" | |
}, |
This file contains 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
# Aliases in this file are bash and zsh compatible | |
# Don't change. The following determines where YADR is installed. | |
yadr=$HOME/.yadr | |
alias .='pwd' | |
# Get operating system | |
platform='unknown' | |
unamestr=$(uname) | |
if [[ $unamestr == 'Linux' ]]; then | |
platform='linux' |
This file contains 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
# ~/.tmuxinator/rails.yml | |
name: rails | |
root: ~/workspace/ruby/rails/ember-cli/address-book | |
# Optional tmux socket | |
# socket_name: foo | |
# Runs before everything. Use it to start daemons etc. | |
pre: postgres, bundle install |
This file contains 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
# Aliases in this file are bash and zsh compatible # Don't change. The following determines where YADR is installed. | |
yadr=$HOME/.yadr | |
alias .='pwd' | |
# Get operating system | |
platform='unknown' | |
unamestr=$(uname) | |
if [[ $unamestr == 'Linux' ]]; then | |
platform='linux' | |
elif [[ $unamestr == 'Darwin' ]]; then | |
platform='darwin' |