Class: RSpec::RailsApp::Artifact::Matchers::GenerateArtifact

Inherits:
HaveArtifact
  • Object
show all
Defined in:
lib/generator-spec/rspec/matchers/generate_artifact.rb

Instance Method Summary collapse

Constructor Details

#initialize(name, artifact_type) ⇒ GenerateArtifact

Returns a new instance of GenerateArtifact.



4
5
6
# File 'lib/generator-spec/rspec/matchers/generate_artifact.rb', line 4

def initialize(name, artifact_type)
  super name, artifact_type
end

Instance Method Details

#matches?(generator, &block) ⇒ Boolean

Returns:

  • (Boolean)


8
9
10
11
# File 'lib/generator-spec/rspec/matchers/generate_artifact.rb', line 8

def matches?(generator, &block)            
  root = Rails.root # File.join(Rails.application.config.root_dir, 'rails_app')   
  super root, &block
end