Sha256: d07be432deb149ec0ff417c0bee947b950f95b0b24dd20b69f16473a4abfe370

Contents?: true

Size: 682 Bytes

Versions: 1

Compression:

Stored size: 682 Bytes

Contents

require 'spec_helper'

root_dir = RailsAssist::Directory.rails_root

describe 'rails helper' do
  use_helper :helper

  before :each do
    create_helper :account do
      %q{
        def help_me
        end
      }
    end
  end

  after :each do
    remove_helper :account
  end

  it "should have an account_helper file that contains an AccountHelper class with a help_me method inside" do      
    root_dir.should have_helper_file :account do |file|
      file.should have_helper_class :account do |klass|
        klass.should have_method :help_me
      end
    end

    root_dir.should have_helper :account do |klass|
      klass.should have_method :help_me
    end
  end
end

Version data entries

1 entries across 1 versions & 1 rubygems

Version Path
rails-app-spec-0.5.0 spec/rails_app_spec/matchers/artifact/helper_spec.rb