deimos-ruby 1.19.1 → 1.19.3
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:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: fe0d7f6acfcb82d19d90d45c5c53863163b4154d233a60006c1e54c252f15cf3
|
4
|
+
data.tar.gz: b037f552343e9dd83165ae3268432c99ded588dece10d98dd4fca950c1629ab0
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 393ae3ff6518c8ceca06f753e5c4f2fd4e516839e1320d90b5eb39db556887513cbf2d2b1fd787abe8d8514d3b78a9552b14e0adb8d4d3433b01e9d60df87bb4
|
7
|
+
data.tar.gz: b2f93cd56249c11d51b313ca2e10e94a0a543365c6752e7e6e6baa90658179c3082245a1fc3e1766a46ce3078e933fd4b965d8bebc66845a1dc280daeeb20e8e
|
data/CHANGELOG.md
CHANGED
@@ -7,6 +7,14 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0
|
|
7
7
|
|
8
8
|
## UNRELEASED
|
9
9
|
|
10
|
+
# 1.19.3 - 2023-03-22
|
11
|
+
|
12
|
+
- Fix: Allow `have_sent` matcher to work with schema classes.
|
13
|
+
|
14
|
+
# 1.19.2 - 2023-03-20
|
15
|
+
|
16
|
+
- Fix for saving associations where the primary key is not `id`.
|
17
|
+
|
10
18
|
# 1.19.1 - 2023-03-17
|
11
19
|
|
12
20
|
- Fix for `rails g deimos:bulk_import_id` generator.
|
@@ -137,7 +137,7 @@ module Deimos
|
|
137
137
|
# Get associated `has_one` or `has_many` records for each entity
|
138
138
|
sub_records = Array(entity.send(assoc.name))
|
139
139
|
# Set IDS from master to each of the records in `has_one` or `has_many` relation
|
140
|
-
sub_records.each { |d| d.send("#{assoc.
|
140
|
+
sub_records.each { |d| d.send("#{assoc.foreign_key}=", entity.send(assoc.active_record_primary_key)) }
|
141
141
|
sub_records
|
142
142
|
}.flatten
|
143
143
|
|
@@ -243,7 +243,7 @@ module Deimos
|
|
243
243
|
return if entities.first.respond_to?(@bulk_import_id_column)
|
244
244
|
|
245
245
|
raise "Create bulk_import_id on #{entities.first.class} and set it in `build_records` for associations." \
|
246
|
-
' Run rails g deimos:bulk_import_id {table}
|
246
|
+
' Run rails g deimos:bulk_import_id {table} to create the migration.'
|
247
247
|
end
|
248
248
|
|
249
249
|
# Fills Primary Key ID on in-memory objects.
|
data/lib/deimos/test_helpers.rb
CHANGED
@@ -143,7 +143,7 @@ module Deimos
|
|
143
143
|
Deimos::Backends::Test.sent_messages.any? do |m|
|
144
144
|
hash_matcher = RSpec::Matchers::BuiltIn::Match.new(message)
|
145
145
|
hash_matcher.send(:match,
|
146
|
-
message,
|
146
|
+
message.to_h,
|
147
147
|
m[:payload]&.with_indifferent_access) &&
|
148
148
|
topic == m[:topic] &&
|
149
149
|
(key.present? ? key == m[:key] : true) &&
|
data/lib/deimos/version.rb
CHANGED
@@ -108,7 +108,7 @@ module ActiveRecordBatchConsumerTest
|
|
108
108
|
publish_batch([{ key: 2,
|
109
109
|
payload: { test_id: 'xyz', some_int: 5, title: 'Widget Title' } }])
|
110
110
|
}.to raise_error('Create bulk_import_id on ActiveRecordBatchConsumerTest::Widget'\
|
111
|
-
' and set it in `build_records` for associations. Run rails g deimos:bulk_import_id {table}
|
111
|
+
' and set it in `build_records` for associations. Run rails g deimos:bulk_import_id {table}'\
|
112
112
|
' to create the migration.')
|
113
113
|
end
|
114
114
|
end
|
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: deimos-ruby
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 1.19.
|
4
|
+
version: 1.19.3
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Daniel Orner
|
8
8
|
autorequire:
|
9
9
|
bindir: bin
|
10
10
|
cert_chain: []
|
11
|
-
date: 2023-03-
|
11
|
+
date: 2023-03-22 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: avro_turf
|