From: Steve Klabnik Date: 2011-03-03T22:42:13+09:00 Subject: Re: How to stop a file from being required --0016e64c349854e3bf049d943258 Content-Type: text/plain; charset=ISO-8859-1 The only place this gets tricky is if you load a file from two different paths. So, a test_helper.rb for example $ ls test_helper.rb some_test.rb foo | `foo_test.rb In some_test: require 'test_helper' in foo_test require '../test_helper' Now it'll load the test_helper twice, because those two strings are different. The solution: require "File.expand_path(test_helper)" --0016e64c349854e3bf049d943258--