karafka-testing 2.3.0 → 2.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: 7234ba09684afa8617cf8c3f335462e418dbe1369792949d189029f9ec22e40c
4
- data.tar.gz: '0861af20657686d3f7b3b0f99453959df567eb2b91f5ba1e60c23416e272633a'
3
+ metadata.gz: 4932859009198b689571ee03c117e5255efbba52deb34874c689577cd456bf47
4
+ data.tar.gz: a83d1892a15392beb4889d77f642c2368b9a57a07073e9ce6ae4f884ad6ba61c
5
5
  SHA512:
6
- metadata.gz: a210c2545d78aa92c4b9fd554f7d9687268d39e9ccd86ca5ebe8f94de55a295226e5c10126e948b11a769695baecbfaee183aa2318a1ce9a3e8aa4f0e8136791
7
- data.tar.gz: 1f6365ee9adec3023b077c073c74ed10e66271d00ebd656eeb54bc12f912a981583f3e10e113bff530fa3a4dc3994ee95d4b95e93347f7576d6efa186ee0ff7b
6
+ metadata.gz: 0c99a0ece8c0ae1e2b46541148236b86ce26f1652c6e3cd82e4d3158ed42797b67019a4ec79db3c21efbc9a8e65e53e7e07cc6effa876190b5377dbd1cf2a8f2
7
+ data.tar.gz: d422ab991a2cfa2796e8dff02d9902c19f3d64e8f6d4d269283468abfbb0c20569f699faeef4f78dac440662ab94fea7da293361a7f824ba5219070358e6c1fa
checksums.yaml.gz.sig CHANGED
Binary file
data/CHANGELOG.md CHANGED
@@ -1,5 +1,13 @@
1
1
  # Karafka Test gem changelog
2
2
 
3
+ ## 2.3.2 (2024-04-03)
4
+ - [Enhancement] Support `Minitest::Spec`.
5
+
6
+ ## 2.3.1 (2024-03-07)
7
+ - [Enhancement] Prevent usage of testing when Karafka is not loaded.
8
+ - [Enhancement] Prevent usage of testing when Karafka is not initialized.
9
+ - [Fix] Same CG multiplexing topic builder fails with `TopicInManyConsumerGroupsError`.
10
+
3
11
  ## 2.3.0 (2024-01-26)
4
12
  - [Maintenance] Release matching Karafka `2.3.0` release.
5
13
 
data/Gemfile.lock CHANGED
@@ -1,7 +1,7 @@
1
1
  PATH
2
2
  remote: .
3
3
  specs:
4
- karafka-testing (2.3.0)
4
+ karafka-testing (2.3.2)
5
5
  karafka (>= 2.3.0, < 2.4.0)
6
6
  waterdrop (>= 2.6.12)
7
7
 
@@ -9,22 +9,22 @@ GEM
9
9
  remote: https://rubygems.org/
10
10
  specs:
11
11
  ffi (1.16.3)
12
- karafka (2.3.0)
12
+ karafka (2.3.3)
13
13
  karafka-core (>= 2.3.0, < 2.4.0)
14
14
  waterdrop (>= 2.6.12, < 3.0.0)
15
15
  zeitwerk (~> 2.3)
16
16
  karafka-core (2.3.0)
17
17
  karafka-rdkafka (>= 0.14.8, < 0.15.0)
18
- karafka-rdkafka (0.14.8)
18
+ karafka-rdkafka (0.14.10)
19
19
  ffi (~> 1.15)
20
20
  mini_portile2 (~> 2.6)
21
21
  rake (> 12)
22
22
  mini_portile2 (2.8.5)
23
23
  rake (13.1.0)
24
- waterdrop (2.6.12)
24
+ waterdrop (2.6.14)
25
25
  karafka-core (>= 2.2.3, < 3.0.0)
26
26
  zeitwerk (~> 2.3)
27
- zeitwerk (2.6.12)
27
+ zeitwerk (2.6.13)
28
28
 
29
29
  PLATFORMS
30
30
  ruby
@@ -34,4 +34,4 @@ DEPENDENCIES
34
34
  karafka-testing!
35
35
 
36
36
  BUNDLED WITH
37
- 2.5.5
37
+ 2.5.6
@@ -16,17 +16,25 @@ module Karafka
16
16
  # Adds all the needed extra functionalities to the minitest group
17
17
  # @param base [Class] Minitest example group we want to extend
18
18
  def included(base)
19
- base.class_eval do
20
- setup do
21
- @karafka = Karafka::Testing::Minitest::Proxy.new(self)
22
- @_karafka_consumer_messages = []
23
- @_karafka_consumer_client = Karafka::Testing::SpecConsumerClient.new
24
- @_karafka_producer_client = Karafka::Testing::SpecProducerClient.new(self)
19
+ eval_flow = lambda do
20
+ @karafka = Karafka::Testing::Minitest::Proxy.new(self)
21
+ @_karafka_consumer_messages = []
22
+ @_karafka_consumer_client = Karafka::Testing::SpecConsumerClient.new
23
+ @_karafka_producer_client = Karafka::Testing::SpecProducerClient.new(self)
25
24
 
26
- @_karafka_consumer_messages.clear
27
- @_karafka_producer_client.reset
25
+ @_karafka_consumer_messages.clear
26
+ @_karafka_producer_client.reset
28
27
 
29
- Karafka.producer.stubs(:client).returns(@_karafka_producer_client)
28
+ Karafka.producer.stubs(:client).returns(@_karafka_producer_client)
29
+ end
30
+
31
+ if base.to_s == 'Minitest::Spec'
32
+ base.class_eval do
33
+ before(&eval_flow)
34
+ end
35
+ else
36
+ base.class_eval do
37
+ setup(&eval_flow)
30
38
  end
31
39
  end
32
40
  end
@@ -4,6 +4,6 @@
4
4
  module Karafka
5
5
  module Testing
6
6
  # Current version of gem. It should match Karafka framework version
7
- VERSION = '2.3.0'
7
+ VERSION = '2.3.2'
8
8
  end
9
9
  end
data.tar.gz.sig CHANGED
Binary file
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: karafka-testing
3
3
  version: !ruby/object:Gem::Version
4
- version: 2.3.0
4
+ version: 2.3.2
5
5
  platform: ruby
6
6
  authors:
7
7
  - Maciej Mensfeld
@@ -35,7 +35,7 @@ cert_chain:
35
35
  AnG1dJU+yL2BK7vaVytLTstJME5mepSZ46qqIJXMuWob/YPDmVaBF39TDSG9e34s
36
36
  msG3BiCqgOgHAnL23+CN3Rt8MsuRfEtoTKpJVcCfoEoNHOkc
37
37
  -----END CERTIFICATE-----
38
- date: 2024-01-26 00:00:00.000000000 Z
38
+ date: 2024-04-11 00:00:00.000000000 Z
39
39
  dependencies:
40
40
  - !ruby/object:Gem::Dependency
41
41
  name: karafka
metadata.gz.sig CHANGED
Binary file