Sha256: 9fa0eb2ce46defca0fcad1eb7d91a26bcaaeaf702b1bf02aacc27e5151c8ddb4
Contents?: true
Size: 921 Bytes
Versions: 4
Compression:
Stored size: 921 Bytes
Contents
require 'spec_helper' root_dir = Rails3::Assist::Directory.rails_root describe 'controller' do use_helper :controller before :each do create_empty_tmp :controller create_controller :account do %q{ def index end } end end after :each do remove_controller :account end it "should not have an person controller file" do root_dir.should_not have_controller :person end it "should have an account_controller file that contains an AccountController class with an index method inside" do root_dir.should have_controller :account do |content| content.should have_method :index end root_dir.should have_controller_file :account do |controller_file| controller_file.should have_controller_class :account do |klass| klass.should have_method :index end end end end
Version data entries
4 entries across 4 versions & 1 rubygems