nonnative 1.103.0 → 1.105.0

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
  SHA256:
3
- metadata.gz: b620fc0c074cd4709b3662d7d6189ab9d129727b61edb658766ac63ef7b3a7c3
4
- data.tar.gz: 596ab87a301257e2df795ce9aab8f2791c67f4267b0c17af91e2158ac9077845
3
+ metadata.gz: e593258652f5f9e9cd3589b76671686a910993a6c95a88c858ac2c47cb2e55e1
4
+ data.tar.gz: db1f47ee5351d9158a6250fa6534d57712231cdfc713c313782bcafac573d746
5
5
  SHA512:
6
- metadata.gz: 2dba6c48cb42ce5e85762e05b859572b3dd28dbaa5548d855c4087bdf16702bc0783bb981ca3696256a2a711f646ff008bae6cd27db7f12be3159ba24789cde9
7
- data.tar.gz: 50ed055d4e1550088cd8be0995442cf51a488aa0193dca21e49aa93da1bf88fbd082dc391fd9a1e3aeda65586a8243a545e6f83c36c696d0ce71335bea7397cd
6
+ metadata.gz: c889bae024b9de59f418d7d91b779fbb1e8338ebcb6a7e8b55bb030d2f6bea5211fff0b3c4cfa663f99e25a5d4f3d280dd6a95cc3bab25a77a042d4c6d231468
7
+ data.tar.gz: e1bf01dd532917746d21966df7ac2aefc43f55c7dea69a7d0e9586801275622a4218cda4b3822f1537cc53e3e96cb79a41179ac146cc3773f2cb6e8aae4c64d1
data/.circleci/config.yml CHANGED
@@ -3,7 +3,7 @@ version: 2.1
3
3
  jobs:
4
4
  build:
5
5
  docker:
6
- - image: alexfalkowski/ruby:1.33
6
+ - image: alexfalkowski/ruby:1.35
7
7
  working_directory: ~/nonnative
8
8
  steps:
9
9
  - checkout
@@ -31,7 +31,7 @@ jobs:
31
31
  resource_class: large
32
32
  release:
33
33
  docker:
34
- - image: alexfalkowski/release:3.22
34
+ - image: alexfalkowski/release:3.24
35
35
  working_directory: ~/nonnative
36
36
  steps:
37
37
  - checkout
data/CHANGELOG.md CHANGED
@@ -6,6 +6,17 @@ The format is based on [Keep a Changelog](https://keepachangelog.com/en/1.0.0/),
6
6
 
7
7
  ## Unreleased
8
8
 
9
+ ## [v1.105.0](https://github.com/alexfalkowski/nonnative/releases/tag/v1.105.0) - 2025-06-16
10
+
11
+ - [`54850d0`](https://github.com/alexfalkowski/nonnative/commit/54850d088a6d8100ad8fd9b4804d9945f16ede43) feat(cucumber): update to v10.0.0 (#585)
12
+ - [`d77bc43`](https://github.com/alexfalkowski/nonnative/commit/d77bc4377ca2c448734e7f26cd43490e8bdc2452) build(deps): bump bin from `fc61209` to `c9044eb` (#584)
13
+ - [`911a39c`](https://github.com/alexfalkowski/nonnative/commit/911a39c8f00c72321b076a1d59d3077f9652bdbc) build(deps): bump bin from `255c12c` to `fc61209` (#579)
14
+
15
+ ## [v1.104.0](https://github.com/alexfalkowski/nonnative/releases/tag/v1.104.0) - 2025-06-09
16
+
17
+ - [`834596d`](https://github.com/alexfalkowski/nonnative/commit/834596d18be24b990238c3abcd0cefbced1132e9) feat(observability): prefix with name (#578)
18
+ - [`e169924`](https://github.com/alexfalkowski/nonnative/commit/e169924fc0a1d31414951dc426bab97bb836f9ea) test(deps): bump ruby-lsp from 0.23.24 to 0.24.1 (#577)
19
+
9
20
  ## [v1.103.0](https://github.com/alexfalkowski/nonnative/releases/tag/v1.103.0) - 2025-06-06
10
21
 
11
22
  - [`2e2b7e4`](https://github.com/alexfalkowski/nonnative/commit/2e2b7e46a6005a265bb00baa600bdc0e954486f3) feat(socket): use predicate method (#576)
data/Gemfile.lock CHANGED
@@ -1,10 +1,10 @@
1
1
  PATH
2
2
  remote: .
3
3
  specs:
4
- nonnative (1.103.0)
4
+ nonnative (1.105.0)
5
5
  concurrent-ruby (>= 1, < 2)
6
6
  config (>= 5, < 6)
7
- cucumber (>= 7, < 10)
7
+ cucumber (>= 7, < 11)
8
8
  get_process_mem (>= 1, < 2)
9
9
  grpc (>= 1, < 2)
10
10
  puma (>= 6, < 7)
@@ -19,40 +19,40 @@ GEM
19
19
  remote: https://rubygems.org/
20
20
  specs:
21
21
  ast (2.4.3)
22
- base64 (0.2.0)
22
+ base64 (0.3.0)
23
23
  benchmark-malloc (0.2.0)
24
24
  benchmark-perf (0.6.0)
25
25
  benchmark-trend (0.4.0)
26
- bigdecimal (3.1.9)
26
+ bigdecimal (3.2.2)
27
27
  builder (3.3.0)
28
28
  concurrent-ruby (1.3.5)
29
29
  config (5.5.2)
30
30
  deep_merge (~> 1.2, >= 1.2.1)
31
31
  ostruct
32
- cucumber (9.2.1)
32
+ cucumber (10.0.0)
33
+ base64 (~> 0.2)
33
34
  builder (~> 3.2)
34
35
  cucumber-ci-environment (> 9, < 11)
35
- cucumber-core (> 13, < 14)
36
- cucumber-cucumber-expressions (~> 17.0)
37
- cucumber-gherkin (> 24, < 28)
36
+ cucumber-core (> 15, < 17)
37
+ cucumber-cucumber-expressions (> 17, < 19)
38
38
  cucumber-html-formatter (> 20.3, < 22)
39
- cucumber-messages (> 19, < 25)
40
39
  diff-lcs (~> 1.5)
40
+ logger (~> 1.6)
41
41
  mini_mime (~> 1.1)
42
42
  multi_test (~> 1.1)
43
- sys-uname (~> 1.2)
43
+ sys-uname (~> 1.3)
44
44
  cucumber-ci-environment (10.0.1)
45
- cucumber-core (13.0.3)
46
- cucumber-gherkin (>= 27, < 28)
47
- cucumber-messages (>= 20, < 23)
45
+ cucumber-core (15.1.0)
46
+ cucumber-gherkin (> 27, < 31)
47
+ cucumber-messages (> 26, < 29)
48
48
  cucumber-tag-expressions (> 5, < 7)
49
- cucumber-cucumber-expressions (17.1.0)
49
+ cucumber-cucumber-expressions (18.0.1)
50
50
  bigdecimal
51
- cucumber-gherkin (27.0.0)
52
- cucumber-messages (>= 19.1.4, < 23)
53
- cucumber-html-formatter (21.9.0)
51
+ cucumber-gherkin (30.0.4)
52
+ cucumber-messages (> 25, < 28)
53
+ cucumber-html-formatter (21.10.1)
54
54
  cucumber-messages (> 19, < 28)
55
- cucumber-messages (22.0.0)
55
+ cucumber-messages (27.2.0)
56
56
  cucumber-tag-expressions (6.1.2)
57
57
  deep_merge (1.2.2)
58
58
  diff-lcs (1.6.2)
@@ -63,10 +63,10 @@ GEM
63
63
  get_process_mem (1.0.0)
64
64
  bigdecimal (>= 2.0)
65
65
  ffi (~> 1.0)
66
- google-protobuf (4.31.0-x86_64-darwin)
66
+ google-protobuf (4.31.1-x86_64-darwin)
67
67
  bigdecimal
68
68
  rake (>= 13)
69
- google-protobuf (4.31.0-x86_64-linux-gnu)
69
+ google-protobuf (4.31.1-x86_64-linux-gnu)
70
70
  bigdecimal
71
71
  rake (>= 13)
72
72
  googleapis-common-protos-types (1.20.0)
@@ -87,7 +87,7 @@ GEM
87
87
  mime-types (3.7.0)
88
88
  logger
89
89
  mime-types-data (~> 3.2025, >= 3.2025.0507)
90
- mime-types-data (3.2025.0514)
90
+ mime-types-data (3.2025.0610)
91
91
  mini_mime (1.1.5)
92
92
  multi_test (1.1.0)
93
93
  mustermann (3.0.3)
@@ -112,7 +112,7 @@ GEM
112
112
  base64 (>= 0.1.0)
113
113
  rack (>= 3.0.0)
114
114
  rainbow (3.1.1)
115
- rake (13.2.1)
115
+ rake (13.3.0)
116
116
  rbs (3.9.4)
117
117
  logger
118
118
  regexp_parser (2.10.0)
@@ -123,7 +123,7 @@ GEM
123
123
  netrc (~> 0.8)
124
124
  retriable (3.1.2)
125
125
  rexml (3.4.1)
126
- rspec (3.13.0)
126
+ rspec (3.13.1)
127
127
  rspec-core (~> 3.13.0)
128
128
  rspec-expectations (~> 3.13.0)
129
129
  rspec-mocks (~> 3.13.0)
@@ -132,18 +132,18 @@ GEM
132
132
  benchmark-perf (~> 0.6)
133
133
  benchmark-trend (~> 0.4)
134
134
  rspec (>= 3.0)
135
- rspec-core (3.13.3)
135
+ rspec-core (3.13.4)
136
136
  rspec-support (~> 3.13.0)
137
137
  rspec-expectations (3.13.5)
138
138
  diff-lcs (>= 1.2.0, < 2.0)
139
139
  rspec-support (~> 3.13.0)
140
- rspec-mocks (3.13.4)
140
+ rspec-mocks (3.13.5)
141
141
  diff-lcs (>= 1.2.0, < 2.0)
142
142
  rspec-support (~> 3.13.0)
143
143
  rspec-support (3.13.4)
144
144
  rspec-wait (1.0.1)
145
145
  rspec (>= 3.4)
146
- rubocop (1.76.0)
146
+ rubocop (1.76.1)
147
147
  json (~> 2.3)
148
148
  language_server-protocol (~> 3.17.0.2)
149
149
  lint_roller (~> 1.1.0)
@@ -154,10 +154,10 @@ GEM
154
154
  rubocop-ast (>= 1.45.0, < 2.0)
155
155
  ruby-progressbar (~> 1.7)
156
156
  unicode-display_width (>= 2.4.0, < 4.0)
157
- rubocop-ast (1.45.0)
157
+ rubocop-ast (1.45.1)
158
158
  parser (>= 3.3.7.2)
159
159
  prism (~> 1.4)
160
- ruby-lsp (0.23.24)
160
+ ruby-lsp (0.24.1)
161
161
  language_server-protocol (~> 3.17.0)
162
162
  prism (>= 1.2, < 2.0)
163
163
  rbs (>= 3, < 5)
@@ -180,7 +180,7 @@ GEM
180
180
  rack-protection (= 4.1.1)
181
181
  rack-session (>= 2.0.0, < 3)
182
182
  tilt (~> 2.0)
183
- sorbet-runtime (0.5.12155)
183
+ sorbet-runtime (0.5.12176)
184
184
  sys-uname (1.3.1)
185
185
  ffi (~> 1.1)
186
186
  tilt (2.6.0)
data/README.md CHANGED
@@ -25,17 +25,22 @@ gem 'nonnative'
25
25
 
26
26
  And then execute:
27
27
 
28
- $ bundle
28
+ ```bash
29
+ bundle
30
+ ```
29
31
 
30
32
  Or install it yourself as:
31
33
 
32
- $ gem install nonnative
34
+ ```bash
35
+ gem install nonnative
36
+ ```
33
37
 
34
38
  ## Usage
35
39
 
36
40
  Configure nonnative with the following:
37
41
 
38
42
  - The version of the configuration (1.0).
43
+ - The name of the service.
39
44
  - The URL of the service.
40
45
  - A log file.
41
46
  - Process, Server or Service that you want to start.
@@ -49,6 +54,7 @@ Configure nonnative with the following:
49
54
  ### Strategy
50
55
 
51
56
  The strategy can be one of the following values:
57
+
52
58
  - startup - When we include `nonnative/startup`, it will start it once.
53
59
  - before - When we tag our features with `@startup` it will start and stop after the scenario.
54
60
  - manual - When we tag our features with `@manual` it will stop after the scenario.
@@ -64,6 +70,7 @@ require 'nonnative'
64
70
 
65
71
  Nonnative.configure do |config|
66
72
  config.version = '1.0'
73
+ config.name = 'test'
67
74
  config.url = 'http://localhost:4567'
68
75
  config.log = 'nonnative.log'
69
76
 
@@ -95,6 +102,7 @@ Setup it up through configuration:
95
102
 
96
103
  ```yaml
97
104
  version: "1.0"
105
+ name: test
98
106
  url: http://localhost:4567
99
107
  log: nonnative.log
100
108
  processes:
@@ -176,6 +184,7 @@ require 'nonnative'
176
184
 
177
185
  Nonnative.configure do |config|
178
186
  config.version = '1.0'
187
+ config.name = 'test'
179
188
  config.url = 'http://localhost:4567'
180
189
  config.log = 'nonnative.log'
181
190
 
@@ -201,6 +210,7 @@ Setup it up through configuration:
201
210
 
202
211
  ```yaml
203
212
  version: "1.0"
213
+ name: test
204
214
  url: http://localhost:4567
205
215
  log: nonnative.log
206
216
  servers:
@@ -257,6 +267,7 @@ require 'nonnative'
257
267
 
258
268
  Nonnative.configure do |config|
259
269
  config.version = '1.0'
270
+ config.name = 'test'
260
271
  config.url = 'http://localhost:4567'
261
272
  config.log = 'nonnative.log'
262
273
 
@@ -274,6 +285,7 @@ Setup it up through configuration:
274
285
 
275
286
  ```yaml
276
287
  version: "1.0"
288
+ name: test
277
289
  url: http://localhost:4567
278
290
  log: nonnative.log
279
291
  servers:
@@ -320,6 +332,7 @@ require 'nonnative'
320
332
 
321
333
  Nonnative.configure do |config|
322
334
  config.version = '1.0'
335
+ config.name = 'test'
323
336
  config.url = 'http://localhost:4567'
324
337
  config.log = 'nonnative.log'
325
338
 
@@ -337,6 +350,7 @@ Setup it up through configuration:
337
350
 
338
351
  ```yaml
339
352
  version: "1.0"
353
+ name: test
340
354
  url: http://localhost:4567
341
355
  log: nonnative.log
342
356
  servers:
@@ -387,6 +401,7 @@ require 'nonnative'
387
401
 
388
402
  Nonnative.configure do |config|
389
403
  config.version = '1.0'
404
+ config.name = 'test'
390
405
  config.url = 'http://localhost:4567'
391
406
  config.log = 'nonnative.log'
392
407
 
@@ -404,6 +419,7 @@ Setup it up through configuration:
404
419
 
405
420
  ```yaml
406
421
  version: "1.0"
422
+ name: test
407
423
  url: http://localhost:4567
408
424
  log: nonnative.log
409
425
  servers:
@@ -436,6 +452,7 @@ require 'nonnative'
436
452
 
437
453
  Nonnative.configure do |config|
438
454
  config.version = '1.0'
455
+ config.name = 'test'
439
456
  config.url = 'http://localhost:4567'
440
457
  config.log = 'nonnative.log'
441
458
 
@@ -455,6 +472,7 @@ Setup it up through configuration:
455
472
 
456
473
  ```yaml
457
474
  version: "1.0"
475
+ name: test
458
476
  url: http://localhost:4567
459
477
  log: nonnative.log
460
478
  processes:
@@ -479,10 +497,11 @@ end
479
497
  #### Proxies
480
498
 
481
499
  We allow different proxies to be configured. These proxies can be used to simulate all kind of situations. The proxies that can be configured are:
500
+
482
501
  - `none` (this is the default)
483
502
  - `fault_injection`
484
503
 
485
- ##### Processes
504
+ ##### Proxies Processes
486
505
 
487
506
  Setup it up programmatically:
488
507
 
@@ -491,6 +510,7 @@ require 'nonnative'
491
510
 
492
511
  Nonnative.configure do |config|
493
512
  config.version = '1.0'
513
+ config.name = 'test'
494
514
  config.url = 'http://localhost:4567'
495
515
  config.log = 'nonnative.log'
496
516
 
@@ -512,6 +532,7 @@ Setup it up through configuration:
512
532
 
513
533
  ```yaml
514
534
  version: "1.0"
535
+ name: test
515
536
  url: http://localhost:4567
516
537
  log: nonnative.log
517
538
  processes:
@@ -525,7 +546,7 @@ processes:
525
546
  delay: 5
526
547
  ```
527
548
 
528
- ##### Servers
549
+ ##### Proxies Servers
529
550
 
530
551
  Setup it up programmatically:
531
552
 
@@ -534,6 +555,7 @@ require 'nonnative'
534
555
 
535
556
  Nonnative.configure do |config|
536
557
  config.version = '1.0'
558
+ config.name = 'test'
537
559
  config.url = 'http://localhost:4567'
538
560
  config.log = 'nonnative.log'
539
561
 
@@ -555,6 +577,7 @@ Setup it up through configuration:
555
577
 
556
578
  ```yaml
557
579
  version: "1.0"
580
+ name: test
558
581
  url: http://localhost:4567
559
582
  log: nonnative.log
560
583
  servers:
@@ -568,7 +591,7 @@ servers:
568
591
  delay: 5
569
592
  ```
570
593
 
571
- ##### Services
594
+ ##### Proxies Services
572
595
 
573
596
  Setup it up programmatically:
574
597
 
@@ -577,6 +600,7 @@ require 'nonnative'
577
600
 
578
601
  Nonnative.configure do |config|
579
602
  config.version = '1.0'
603
+ config.name = 'test'
580
604
  config.url = 'http://localhost:4567'
581
605
  config.log = 'nonnative.log'
582
606
  config.wait = 1
@@ -599,6 +623,7 @@ Setup it up through configuration:
599
623
 
600
624
  ```yaml
601
625
  version: "1.0"
626
+ name: test
602
627
  url: http://localhost:4567
603
628
  log: nonnative.log
604
629
  wait: 1
@@ -616,11 +641,12 @@ services:
616
641
  ##### Fault Injection
617
642
 
618
643
  The `fault_injection` proxy allows you to simulate failures by injecting them. We currently support the following:
644
+
619
645
  - `close_all` - Closes the socket as soon as it connects.
620
646
  - `delay` - This delays the communication between the connection. Default is 2 secs can be configured through options.
621
647
  - `invalid_data` - This takes the input and rearranges it to produce invalid data.
622
648
 
623
- ###### Processes
649
+ ###### Fault Injection Processes
624
650
 
625
651
  Setup it up programmatically:
626
652
 
@@ -639,7 +665,7 @@ Given I set the proxy for process 'process_1' to 'close_all'
639
665
  Then I should reset the proxy for process 'process_1'
640
666
  ```
641
667
 
642
- ###### Servers
668
+ ###### Fault Injection Servers
643
669
 
644
670
  Setup it up programmatically:
645
671
 
@@ -658,7 +684,7 @@ Given I set the proxy for server 'server_1' to 'close_all'
658
684
  Then I should reset the proxy for server 'server_1'
659
685
  ```
660
686
 
661
- ###### Services
687
+ ###### Fault Injection Services
662
688
 
663
689
  Setup it up programmatically:
664
690
 
@@ -691,7 +717,7 @@ package main
691
717
  import "testing"
692
718
 
693
719
  func TestFeatures(t *testing.T) {
694
- main()
720
+ main()
695
721
  }
696
722
  ```
697
723
 
@@ -713,6 +739,7 @@ Setup it up through configuration:
713
739
 
714
740
  ```yaml
715
741
  version: "1.0"
742
+ name: test
716
743
  url: http://localhost:4567
717
744
  log: nonnative.log
718
745
  processes:
@@ -8,12 +8,13 @@ module Nonnative
8
8
  @services = []
9
9
  end
10
10
 
11
- attr_accessor :version, :url, :log, :processes, :servers, :services
11
+ attr_accessor :name, :version, :url, :log, :processes, :servers, :services
12
12
 
13
13
  def load_file(path)
14
14
  cfg = Nonnative.configurations(path)
15
15
 
16
16
  self.version = cfg.version
17
+ self.name = cfg.name
17
18
  self.url = cfg.url
18
19
  self.log = cfg.log
19
20
 
@@ -4,7 +4,7 @@ module Nonnative
4
4
  class HTTPClient
5
5
  def initialize(host)
6
6
  @host = host
7
- @expections = [
7
+ @exceptions = [
8
8
  RestClient::Exceptions::Timeout,
9
9
  RestClient::ServerBrokeConnection
10
10
  ]
@@ -13,7 +13,7 @@ module Nonnative
13
13
  protected
14
14
 
15
15
  def with_retry(tries, wait, &)
16
- Retriable.retriable(tries: tries, base_interval: wait, on: expections, &)
16
+ Retriable.retriable(tries: tries, base_interval: wait, on: exceptions, &)
17
17
  end
18
18
 
19
19
  def get(pathname, opts = {})
@@ -46,11 +46,11 @@ module Nonnative
46
46
 
47
47
  private
48
48
 
49
- attr_reader :host, :expections
49
+ attr_reader :host, :exceptions
50
50
 
51
51
  def with_exception
52
52
  yield
53
- rescue *expections => e
53
+ rescue *exceptions => e
54
54
  raise e
55
55
  rescue RestClient::Exception => e
56
56
  e.response
@@ -3,19 +3,25 @@
3
3
  module Nonnative
4
4
  class Observability < Nonnative::HTTPClient
5
5
  def health(opts = {})
6
- get('healthz', opts)
6
+ get("#{name}/healthz", opts)
7
7
  end
8
8
 
9
9
  def liveness(opts = {})
10
- get('livez', opts)
10
+ get("#{name}/livez", opts)
11
11
  end
12
12
 
13
13
  def readiness(opts = {})
14
- get('readyz', opts)
14
+ get("#{name}/readyz", opts)
15
15
  end
16
16
 
17
17
  def metrics(opts = {})
18
- get('metrics', opts)
18
+ get("#{name}/metrics", opts)
19
+ end
20
+
21
+ protected
22
+
23
+ def name
24
+ Nonnative.configuration.name
19
25
  end
20
26
  end
21
27
  end
@@ -1,5 +1,5 @@
1
1
  # frozen_string_literal: true
2
2
 
3
3
  module Nonnative
4
- VERSION = '1.103.0'
4
+ VERSION = '1.105.0'
5
5
  end
data/nonnative.gemspec CHANGED
@@ -26,7 +26,7 @@ Gem::Specification.new do |spec|
26
26
 
27
27
  spec.add_dependency 'concurrent-ruby', '>= 1', '< 2'
28
28
  spec.add_dependency 'config', '>= 5', '< 6'
29
- spec.add_dependency 'cucumber', '>= 7', '< 10'
29
+ spec.add_dependency 'cucumber', '>= 7', '< 11'
30
30
  spec.add_dependency 'get_process_mem', '>= 1', '< 2'
31
31
  spec.add_dependency 'grpc', '>= 1', '< 2'
32
32
  spec.add_dependency 'puma', '>= 6', '< 7'
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: nonnative
3
3
  version: !ruby/object:Gem::Version
4
- version: 1.103.0
4
+ version: 1.105.0
5
5
  platform: ruby
6
6
  authors:
7
7
  - Alejandro Falkowski
@@ -58,7 +58,7 @@ dependencies:
58
58
  version: '7'
59
59
  - - "<"
60
60
  - !ruby/object:Gem::Version
61
- version: '10'
61
+ version: '11'
62
62
  type: :runtime
63
63
  prerelease: false
64
64
  version_requirements: !ruby/object:Gem::Requirement
@@ -68,7 +68,7 @@ dependencies:
68
68
  version: '7'
69
69
  - - "<"
70
70
  - !ruby/object:Gem::Version
71
- version: '10'
71
+ version: '11'
72
72
  - !ruby/object:Gem::Dependency
73
73
  name: get_process_mem
74
74
  requirement: !ruby/object:Gem::Requirement