Topic: Can't get Rails::Test to work :-(


I'm very happy with TDD and use it whereever possible. I came across Rails::Test and hoped to make even better tests easier.
My problem is I haven't been able to run my tests ever since I made those 3 small changes to test_helper.rb :-(

At first, I simply tried running rake test:functionals but it just gives me errors like:
/Users/gitte/Projects/rtime/config/../app/controllers/billing_controller.rb:3: undefined method `layout' for BillingController:Class (NoMethodError)

It's obvious to me what the error is - it's not obvious why. Have I missed something?

My test_helper.rb looks like this:
ENV["RAILS_ENV"] = "test"
require File.expand_path(File.dirname(__FILE__) + "/../config/environment")
require 'test/rails'
require 'test_help'

class Test::Rails::TestCase
  self.use_transactional_fixtures = false
  self.use_instantiated_fixtures  = false

  # Add more helper methods to be used by all tests here...

Re: Can't get Rails::Test to work :-(

Can you post the first 10 lines of your billing_controller.rb file?