1 # This file is copied to ~/spec when you run 'ruby script/generate rspec'
2 # from the project root directory.
3 ENV["RAILS_ENV"] ||= 'test'
4 require File.expand_path(File.join(File.dirname(__FILE__),'..','config','environment'))
8 # Uncomment the next line to use webrat's matchers
9 #require 'webrat/integrations/rspec-rails'
11 # Requires supporting files with custom matchers and macros, etc,
12 # in ./support/ and its subdirectories.
13 Dir[File.expand_path(File.join(File.dirname(__FILE__),'support','**','*.rb'))].each {|f| require f}
15 Spec::Runner.configure do |config|
16 # If you're not using ActiveRecord you should remove these
17 # lines, delete config/database.yml and disable :active_record
18 # in your config/boot.rb
19 config.use_transactional_fixtures = true
20 config.use_instantiated_fixtures = false
21 config.fixture_path = RAILS_ROOT + '/spec/fixtures/'
25 # You can declare fixtures for each example_group like this:
27 # fixtures :table_a, :table_b
29 # Alternatively, if you prefer to declare them only once, you can
30 # do so right here. Just uncomment the next line and replace the fixture
31 # names with your fixtures.
33 # config.global_fixtures = :table_a, :table_b
35 # If you declare global fixtures, be aware that they will be declared
36 # for all of your examples, even those that don't use them.
38 # You can also declare which fixtures to use (for example fixtures for test/fixtures):
40 # config.fixture_path = RAILS_ROOT + '/spec/fixtures/'
44 # RSpec uses its own mocking framework by default. If you prefer to
45 # use mocha, flexmock or RR, uncomment the appropriate line:
47 # config.mock_with :mocha
48 # config.mock_with :flexmock
49 # config.mock_with :rr
53 # For more information take a look at Spec::Runner::Configuration and Spec::Runner