Skip to content

Instantly share code, notes, and snippets.

@skwp
Created November 29, 2010 18:49
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save skwp/720357 to your computer and use it in GitHub Desktop.
Save skwp/720357 to your computer and use it in GitHub Desktop.
# load your libs
Dir[File.join(File.dirname(__FILE__),"../gems/*/lib")].each { |f| $LOAD_PATH << f }
# add all my app files to the load path so I can require 'app_file_name'
# note that this assumes all your code lives in dirs one level up from test
# if you have many subdirectories you can use a glob like "../**/*" to get all subdirs
Dir[File.join(File.dirname(__FILE__),"../*")].each {|f| $LOAD_PATH << f }
require 'test/unit'
require 'shoulda'
require 'flexmock'
require 'flexmock/test_unit'
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment