fabrication 2.15.1 → 2.15.2

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA1:
3
- metadata.gz: e9a1b1314eaefa186308758ce4b72862fc7a6394
4
- data.tar.gz: 6c971efd9a3f10dda44475fb289643991c612201
3
+ metadata.gz: 7cb941babdd5a40fe72c16cda95ab718b306de5b
4
+ data.tar.gz: 94f8213b2adff827cd7cc98edbe23670e0d8e9de
5
5
  SHA512:
6
- metadata.gz: 678b967ba7c0344a34fbd25d91ea4da5621182e4cb8f649c9a711d4fcd4a5923ed1e3feffdeb177b3ba5640a5bb1ca93f78c6ec27b793dfa20ebee0eea142e0f
7
- data.tar.gz: 1d0b1af21d5611cbb9312c54a29123acbdca7c6309d79c38f9985dc0876dcba1fe705b5d5a04ad1ee86ff28f260aeac7c9f1ad8a4b01bda5e6d65c7d1356acc9
6
+ metadata.gz: e5e176e536ec16dbc3fbf041e17c18cd0a5e9daffd5f84623b9b13735ea6cfc5a78b1cbcd699b0fb72caffc9b3b0acf6f9ad17a3e768fbde8fb37cc7460e5d0f
7
+ data.tar.gz: 0afddbc74e4f8771af760d74c67b8ae0487c369a4bb1cdc3449bc94aa47c2a7d15bfaf2498f8cac8359f3a4e078223f4f15b597b61293eda205753de39bf88ee
@@ -27,7 +27,7 @@ module Fabrication
27
27
 
28
28
  def fabricator_dir=(folders)
29
29
  puts "DEPRECATION WARNING: Fabrication::Config.fabricator_dir has been replaced by Fabrication::Config.fabricator_path"
30
- fabricator_path = folders
30
+ self.fabricator_path = folders
31
31
  end
32
32
 
33
33
  attr_writer :sequence_start
@@ -43,6 +43,8 @@ module Fabrication
43
43
  alias path_prefixes path_prefix
44
44
 
45
45
  attr_writer :register_with_steps
46
- def register_with_steps?; @register_with_steps end
46
+ def register_with_steps?
47
+ @register_with_steps ||= nil
48
+ end
47
49
  end
48
50
  end
@@ -51,7 +51,7 @@ class Fabrication::Generator::Base
51
51
  end
52
52
 
53
53
  def build_instance_with_constructor_override(callback)
54
- self._instance = instance_eval &callback
54
+ self._instance = instance_eval(&callback)
55
55
  set_attributes
56
56
  end
57
57
 
@@ -1,6 +1,7 @@
1
1
  class Fabrication::Schematic::Attribute
2
2
 
3
- attr_accessor :klass, :name, :params, :value
3
+ attr_accessor :klass, :name, :value
4
+ attr_writer :params
4
5
 
5
6
  def initialize(klass, name, value, params={}, &block)
6
7
  self.klass = klass
@@ -119,7 +119,10 @@ class Fabrication::Schematic::Definition
119
119
 
120
120
  protected
121
121
 
122
- def loaded?; !!@loaded end
122
+ def loaded?
123
+ !!(@loaded ||= nil)
124
+ end
125
+
123
126
  def load_body
124
127
  return if loaded?
125
128
  @loaded = true
@@ -8,7 +8,9 @@ class Fabrication::Schematic::Manager
8
8
  clear
9
9
  end
10
10
 
11
- def initializing?; @initializing end
11
+ def initializing?
12
+ @initializing ||= nil
13
+ end
12
14
 
13
15
  def schematics
14
16
  @schematics ||= {}
@@ -1,3 +1,3 @@
1
1
  module Fabrication
2
- VERSION = '2.15.1'
2
+ VERSION = '2.15.2'
3
3
  end
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: fabrication
3
3
  version: !ruby/object:Gem::Version
4
- version: 2.15.1
4
+ version: 2.15.2
5
5
  platform: ruby
6
6
  authors:
7
7
  - Paul Elliott
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2016-05-14 00:00:00.000000000 Z
11
+ date: 2016-05-15 00:00:00.000000000 Z
12
12
  dependencies: []
13
13
  description: Fabrication is an object generation framework for ActiveRecord, Mongoid,
14
14
  DataMapper, Sequel, or any other Ruby object.