Module: Avm::Rspec::Setup::SourceGenerator
- Defined in:
- lib/avm/rspec/setup/source_generator.rb
Constant Summary collapse
- DEFAULT_TARGET_BASENAME =
'generated_app'
Instance Method Summary collapse
Instance Method Details
#avm_source(stereotype_name, options = {}) ⇒ Avm::Sources::Base
12 13 14 15 16 17 18 |
# File 'lib/avm/rspec/setup/source_generator.rb', line 12 def avm_source(stereotype_name, = {}) = .dup target_basename ||= .delete(:target_basename) || DEFAULT_TARGET_BASENAME target_path ||= .delete(:target_path) || temp_dir.join(target_basename) ::Avm::Registry.source_generators.detect(stereotype_name, target_path, ).perform ::Avm::Registry.sources.detect(target_path) end |