satisfactory 0.3.0 → 0.3.2

Sign up to get free protection for your applications and to get access to all the features.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA256:
3
- metadata.gz: 5f92a6520f9da8ca43a99ca37697bfc84c56ae52f78a35bab4b8b74a2c369bb0
4
- data.tar.gz: ddf946cf48f563c8153ce34410e2bbf4dc625d4b7f455fed4dc06d8d11188d63
3
+ metadata.gz: 915da7628e8d2a2a45e1fd5a42276a127504b185c249059b9ca49e82b7ebbbfb
4
+ data.tar.gz: 0cd34777d16800c60f06d110cae144aedd917bedaa97547d05f3a5fe9b227598
5
5
  SHA512:
6
- metadata.gz: 59fba38663b4c69a4e3689a6122d6ad6a99f78ec9d4102a8242c23fe216dc554a6ba8ac6eb69aad6402eba42e6bb530989a26e1317ea1c602a0fad0259432583
7
- data.tar.gz: aa609786510b01445fce671750ec1a713fe2312fe555cc449761a727ee15197ff7d3248153cdbd9a492dfa4a178a380353ea5f713ab4490c134f1cbca1275f84
6
+ metadata.gz: 346c97b449dee22e38d1317d0d1be607575d5c041c019a87a65032367a6827a3b8d2269e72809cf608b194e41bd0b2c33945ee94bb88b558347d1921a580657b
7
+ data.tar.gz: 67194694a40952bb2001868189d1e58d1f3ff4028b8a84832104dfb6371871ce76acb7cfe7074d0cb64ada111073dcedd215d64dbc054f000e16a064ea1079fb
data/CHANGELOG.md CHANGED
@@ -1,5 +1,28 @@
1
1
  ## [Unreleased]
2
2
 
3
+ ## [0.3.2] - 2023-01-24
4
+
5
+ - Add some missing proxy methods
6
+
7
+ ## [0.3.1] - 2023-01-18
8
+
9
+ - Fix associations bug
10
+
11
+ ## [0.3.0] - 2022-12-22
12
+
13
+ - Fix some API inconsistencies
14
+ - Add a starter acceptance test (with dummy Rails application)
15
+
16
+ ## [0.2.1] - 2022-12-19
17
+
18
+ - Fix a clashing executable name by not packaging any
19
+
20
+ ## [0.2.0] - 2022-12-19
21
+
22
+ - Main functionality implemented
23
+ - Documentation added
24
+ - Licence added
25
+
3
26
  ## [0.1.0] - 2022-12-09
4
27
 
5
28
  - Initial release
@@ -47,6 +47,7 @@ module Satisfactory
47
47
  def and_same(upstream_type)
48
48
  Satisfactory::UpstreamRecordFinder.new(upstream:).find(upstream_type)
49
49
  end
50
+ alias return_to and_same
50
51
 
51
52
  # @api private
52
53
  def build
@@ -149,7 +149,7 @@ module Satisfactory
149
149
 
150
150
  # @return [ApplicationRecord]
151
151
  def reify(method)
152
- FactoryBot.public_send(method, factory_name, *traits, attributes.merge(associations.transform_values(&:build)))
152
+ FactoryBot.public_send(method, factory_name, *traits, provided_associations.merge(attributes))
153
153
  end
154
154
 
155
155
  def associations_plan
@@ -208,5 +208,9 @@ module Satisfactory
208
208
 
209
209
  associations[name].last
210
210
  end
211
+
212
+ def provided_associations
213
+ associations.transform_values(&:build).compact_blank
214
+ end
211
215
  end
212
216
  end
@@ -18,7 +18,11 @@ module Satisfactory
18
18
  # Delegates to the upstream record.
19
19
  # @return (see Satisfactory::Record#with_new)
20
20
  # @see Satisfactory::Record#with_new
21
- delegate :create, :with_new, to: :upstream
21
+ # @!method to_plan
22
+ # Delegates to the upstream record.
23
+ # @return (see Satisfactory::Record#with_new)
24
+ # @see Satisfactory::Record#with_new
25
+ delegate :create, :with_new, :to_plan, to: :upstream
22
26
 
23
27
  # Find the upstream record of the given type.
24
28
  #
@@ -1,3 +1,3 @@
1
1
  module Satisfactory
2
- VERSION = "0.3.0".freeze
2
+ VERSION = "0.3.2".freeze
3
3
  end
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: satisfactory
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.3.0
4
+ version: 0.3.2
5
5
  platform: ruby
6
6
  authors:
7
7
  - Elliot Crosby-McCullough
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2022-12-22 00:00:00.000000000 Z
11
+ date: 2023-01-24 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: factory_bot_rails
@@ -46,7 +46,7 @@ homepage: https://github.com/SmartCasual/satisfactory
46
46
  licenses:
47
47
  - CC-BY-NC-SA-4.0
48
48
  metadata:
49
- changelog_uri: https://github.com/SmartCasual/satisfactory/blob/v0.3.0/CHANGELOG.md
49
+ changelog_uri: https://github.com/SmartCasual/satisfactory/blob/v0.3.2/CHANGELOG.md
50
50
  homepage_uri: https://github.com/SmartCasual/satisfactory
51
51
  source_code_uri: https://github.com/SmartCasual/satisfactory
52
52
  rubygems_mfa_required: 'true'