Class: ActiveRecord::FixtureBuilder::Builder
- Inherits:
-
Object
- Object
- ActiveRecord::FixtureBuilder::Builder
- Defined in:
- lib/active_record/fixture_builder/builder.rb
Instance Attribute Summary collapse
-
#path ⇒ Object
readonly
Returns the value of attribute path.
Instance Method Summary collapse
- #build! ⇒ Object
-
#initialize(fixture_builder, path) ⇒ Builder
constructor
A new instance of Builder.
- #inspect ⇒ Object
Constructor Details
#initialize(fixture_builder, path) ⇒ Builder
Returns a new instance of Builder.
3 4 5 |
# File 'lib/active_record/fixture_builder/builder.rb', line 3 def initialize fixture_builder, path @fixture_builder, @path = fixture_builder, path end |
Instance Attribute Details
#path ⇒ Object (readonly)
Returns the value of attribute path.
6 7 8 |
# File 'lib/active_record/fixture_builder/builder.rb', line 6 def path @path end |
Instance Method Details
#build! ⇒ Object
8 9 10 |
# File 'lib/active_record/fixture_builder/builder.rb', line 8 def build! load @path end |
#inspect ⇒ Object
12 13 14 15 |
# File 'lib/active_record/fixture_builder/builder.rb', line 12 def inspect path = @path.relative_path_from(@fixture_builder.config.fixtures_path) %[#<#{self.class} #{path.to_s}>] end |