e621stream 0.0.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.
Files changed (77) hide show
  1. checksums.yaml +7 -0
  2. data/LICENSE +21 -0
  3. data/README.md +35 -0
  4. data/lib/e621stream/client/options.rb +20 -0
  5. data/lib/e621stream/client.rb +211 -0
  6. data/lib/e621stream/close_codes.rb +23 -0
  7. data/lib/e621stream/event.rb +24 -0
  8. data/lib/e621stream/events.rb +29 -0
  9. data/lib/e621stream/stream_error.rb +18 -0
  10. data/lib/e621stream/version.rb +5 -0
  11. data/lib/e621stream.rb +18 -0
  12. data/sorbet/config +6 -0
  13. data/sorbet/rbi/annotations/.gitattributes +1 -0
  14. data/sorbet/rbi/annotations/minitest.rbi +120 -0
  15. data/sorbet/rbi/annotations/rainbow.rbi +269 -0
  16. data/sorbet/rbi/gems/.gitattributes +1 -0
  17. data/sorbet/rbi/gems/ast@2.4.3.rbi +550 -0
  18. data/sorbet/rbi/gems/async-http@0.105.0.rbi +1649 -0
  19. data/sorbet/rbi/gems/async-pool@0.12.0.rbi +219 -0
  20. data/sorbet/rbi/gems/async-websocket@0.30.2.rbi +271 -0
  21. data/sorbet/rbi/gems/async@2.46.0.rbi +2193 -0
  22. data/sorbet/rbi/gems/benchmark@0.5.0.rbi +495 -0
  23. data/sorbet/rbi/gems/console@1.38.0.rbi +1552 -0
  24. data/sorbet/rbi/gems/erb@6.0.7.rbi +1581 -0
  25. data/sorbet/rbi/gems/erubi@1.13.1.rbi +153 -0
  26. data/sorbet/rbi/gems/fiber-annotation@0.2.0.rbi +62 -0
  27. data/sorbet/rbi/gems/fiber-local@1.1.0.rbi +36 -0
  28. data/sorbet/rbi/gems/fiber-storage@1.0.1.rbi +43 -0
  29. data/sorbet/rbi/gems/io-console@0.9.5.rbi +9 -0
  30. data/sorbet/rbi/gems/io-endpoint@0.19.0.rbi +1079 -0
  31. data/sorbet/rbi/gems/io-event@1.22.3.rbi +971 -0
  32. data/sorbet/rbi/gems/io-stream@0.14.0.rbi +805 -0
  33. data/sorbet/rbi/gems/json@3.1.0.rbi +1929 -0
  34. data/sorbet/rbi/gems/language_server-protocol@3.17.0.6.rbi +9 -0
  35. data/sorbet/rbi/gems/lint_roller@1.1.0.rbi +189 -0
  36. data/sorbet/rbi/gems/logger@1.7.0.rbi +896 -0
  37. data/sorbet/rbi/gems/minitest@5.27.0.rbi +1499 -0
  38. data/sorbet/rbi/gems/netrc@0.11.0.rbi +147 -0
  39. data/sorbet/rbi/gems/openssl@4.0.2.rbi +4366 -0
  40. data/sorbet/rbi/gems/parallel@2.3.0.rbi +332 -0
  41. data/sorbet/rbi/gems/parser@3.3.13.0.rbi +5146 -0
  42. data/sorbet/rbi/gems/pp@0.6.4.rbi +373 -0
  43. data/sorbet/rbi/gems/prettyprint@0.2.1.rbi +476 -0
  44. data/sorbet/rbi/gems/prism@1.9.0.rbi +42213 -0
  45. data/sorbet/rbi/gems/protocol-hpack@1.5.1.rbi +418 -0
  46. data/sorbet/rbi/gems/protocol-http1@0.41.1.rbi +894 -0
  47. data/sorbet/rbi/gems/protocol-http2@0.29.2.rbi +2277 -0
  48. data/sorbet/rbi/gems/protocol-http@0.72.1.rbi +3801 -0
  49. data/sorbet/rbi/gems/protocol-rack@0.23.0.rbi +9 -0
  50. data/sorbet/rbi/gems/protocol-url@0.19.0.rbi +9 -0
  51. data/sorbet/rbi/gems/protocol-websocket@0.21.3.rbi +1087 -0
  52. data/sorbet/rbi/gems/racc@1.8.1.rbi +169 -0
  53. data/sorbet/rbi/gems/rack@3.2.8.rbi +9 -0
  54. data/sorbet/rbi/gems/rainbow@3.1.1.rbi +362 -0
  55. data/sorbet/rbi/gems/rake@13.4.2.rbi +3127 -0
  56. data/sorbet/rbi/gems/rbi@0.5.0.rbi +5875 -0
  57. data/sorbet/rbi/gems/rbs@4.2.0.rbi +7133 -0
  58. data/sorbet/rbi/gems/rdoc@8.1.0.rbi +9 -0
  59. data/sorbet/rbi/gems/regexp_parser@2.13.1.rbi +3500 -0
  60. data/sorbet/rbi/gems/reline@0.7.0.rbi +2449 -0
  61. data/sorbet/rbi/gems/require-hooks@0.5.1.rbi +152 -0
  62. data/sorbet/rbi/gems/rexml@3.4.4.rbi +4905 -0
  63. data/sorbet/rbi/gems/rubocop-ast@1.51.0.rbi +7230 -0
  64. data/sorbet/rbi/gems/rubocop-rake@0.7.1.rbi +314 -0
  65. data/sorbet/rbi/gems/rubocop@1.92.2.rbi +69094 -0
  66. data/sorbet/rbi/gems/ruby-progressbar@1.13.0.rbi +988 -0
  67. data/sorbet/rbi/gems/rubydex@0.4.4.rbi +1620 -0
  68. data/sorbet/rbi/gems/spoom@1.8.13.rbi +7380 -0
  69. data/sorbet/rbi/gems/tapioca@0.20.0.rbi +3752 -0
  70. data/sorbet/rbi/gems/thor@1.5.0.rbi +3870 -0
  71. data/sorbet/rbi/gems/tsort@0.2.0.rbi +389 -0
  72. data/sorbet/rbi/gems/unicode-display_width@3.3.0.rbi +130 -0
  73. data/sorbet/rbi/gems/unicode-emoji@4.3.0.rbi +254 -0
  74. data/sorbet/rbi/gems/zeitwerk@2.8.3.rbi +1178 -0
  75. data/sorbet/tapioca/config.yml +13 -0
  76. data/sorbet/tapioca/require.rb +4 -0
  77. metadata +175 -0
@@ -0,0 +1,1499 @@
1
+ # typed: true
2
+
3
+ # DO NOT EDIT MANUALLY
4
+ # This is an autogenerated file for types exported from the `minitest` gem.
5
+ # Please instead update this file by running `bin/tapioca gem minitest`.
6
+
7
+
8
+ # The top-level namespace for Minitest. Also the location of the main
9
+ # runtime. See +Minitest.run+ for more information.
10
+ # :stopdoc:
11
+ #
12
+ # pkg:gem/minitest#lib/minitest/parallel.rb:3
13
+ module Minitest
14
+ class << self
15
+ # Internal run method. Responsible for telling all Runnable
16
+ # sub-classes to run.
17
+ #
18
+ # pkg:gem/minitest#lib/minitest.rb:337
19
+ def __run(reporter, options); end
20
+
21
+ # A simple hook allowing you to run a block of code after everything
22
+ # is done running. Eg:
23
+ #
24
+ # Minitest.after_run { p $debugging_info }
25
+ #
26
+ # pkg:gem/minitest#lib/minitest.rb:96
27
+ def after_run(&block); end
28
+
29
+ # pkg:gem/minitest#lib/minitest.rb:20
30
+ def allow_fork; end
31
+
32
+ # pkg:gem/minitest#lib/minitest.rb:20
33
+ def allow_fork=(_arg0); end
34
+
35
+ # Registers Minitest to run at process exit
36
+ #
37
+ # pkg:gem/minitest#lib/minitest.rb:70
38
+ def autorun; end
39
+
40
+ # pkg:gem/minitest#lib/minitest.rb:20
41
+ def backtrace_filter; end
42
+
43
+ # pkg:gem/minitest#lib/minitest.rb:20
44
+ def backtrace_filter=(_arg0); end
45
+
46
+ # pkg:gem/minitest#lib/minitest.rb:19
47
+ def cattr_accessor(name); end
48
+
49
+ # pkg:gem/minitest#lib/minitest.rb:1231
50
+ def clock_time; end
51
+
52
+ # pkg:gem/minitest#lib/minitest.rb:317
53
+ def empty_run!(options); end
54
+
55
+ # pkg:gem/minitest#lib/minitest.rb:20
56
+ def extensions; end
57
+
58
+ # pkg:gem/minitest#lib/minitest.rb:20
59
+ def extensions=(_arg0); end
60
+
61
+ # pkg:gem/minitest#lib/minitest.rb:350
62
+ def filter_backtrace(bt); end
63
+
64
+ # pkg:gem/minitest#lib/minitest.rb:20
65
+ def info_signal; end
66
+
67
+ # pkg:gem/minitest#lib/minitest.rb:20
68
+ def info_signal=(_arg0); end
69
+
70
+ # pkg:gem/minitest#lib/minitest.rb:124
71
+ def init_plugins(options); end
72
+
73
+ # pkg:gem/minitest#lib/minitest.rb:108
74
+ def load_plugins; end
75
+
76
+ # pkg:gem/minitest#lib/minitest.rb:20
77
+ def parallel_executor; end
78
+
79
+ # pkg:gem/minitest#lib/minitest.rb:20
80
+ def parallel_executor=(_arg0); end
81
+
82
+ # pkg:gem/minitest#lib/minitest.rb:142
83
+ def process_args(args = T.unsafe(nil)); end
84
+
85
+ # Register a plugin to be used. Does NOT require / load it.
86
+ #
87
+ # pkg:gem/minitest#lib/minitest.rb:103
88
+ def register_plugin(name_or_mod); end
89
+
90
+ # pkg:gem/minitest#lib/minitest.rb:20
91
+ def reporter; end
92
+
93
+ # pkg:gem/minitest#lib/minitest.rb:20
94
+ def reporter=(_arg0); end
95
+
96
+ # This is the top-level run method. Everything starts from here. It
97
+ # tells each Runnable sub-class to run, and each of those are
98
+ # responsible for doing whatever they do.
99
+ #
100
+ # The overall structure of a run looks like this:
101
+ #
102
+ # Minitest.autorun
103
+ # Minitest.run(args)
104
+ # Minitest.load_plugins
105
+ # Minitest.process_args
106
+ # Minitest.init_plugins
107
+ # Minitest.__run(reporter, options)
108
+ # Runnable.runnables.each |runnable_klass|
109
+ # runnable_klass.run(reporter, options)
110
+ # filtered_methods = runnable_methods.select {...}.reject {...}
111
+ # filtered_methods.each |runnable_method|
112
+ # runnable_klass.run_one_method(self, runnable_method, reporter)
113
+ # Minitest.run_one_method(runnable_klass, runnable_method)
114
+ # runnable_klass.new(runnable_method).run
115
+ #
116
+ # pkg:gem/minitest#lib/minitest.rb:282
117
+ def run(args = T.unsafe(nil)); end
118
+
119
+ # pkg:gem/minitest#lib/minitest.rb:1222
120
+ def run_one_method(klass, method_name); end
121
+
122
+ # pkg:gem/minitest#lib/minitest.rb:20
123
+ def seed; end
124
+
125
+ # pkg:gem/minitest#lib/minitest.rb:20
126
+ def seed=(_arg0); end
127
+ end
128
+ end
129
+
130
+ # Defines the API for Reporters. Subclass this and override whatever
131
+ # you want. Go nuts.
132
+ #
133
+ # pkg:gem/minitest#lib/minitest.rb:702
134
+ class Minitest::AbstractReporter
135
+ # pkg:gem/minitest#lib/minitest.rb:704
136
+ def initialize; end
137
+
138
+ # Did this run pass?
139
+ #
140
+ # pkg:gem/minitest#lib/minitest.rb:739
141
+ def passed?; end
142
+
143
+ # About to start running a test. This allows a reporter to show
144
+ # that it is starting or that we are in the middle of a test run.
145
+ #
146
+ # pkg:gem/minitest#lib/minitest.rb:718
147
+ def prerecord(klass, name); end
148
+
149
+ # Output and record the result of the test. Call
150
+ # {result#result_code}[rdoc-ref:Runnable#result_code] to get the
151
+ # result character string. Stores the result of the run if the run
152
+ # did not pass.
153
+ #
154
+ # pkg:gem/minitest#lib/minitest.rb:727
155
+ def record(result); end
156
+
157
+ # Outputs the summary of the run.
158
+ #
159
+ # pkg:gem/minitest#lib/minitest.rb:733
160
+ def report; end
161
+
162
+ # Starts reporting on the run.
163
+ #
164
+ # pkg:gem/minitest#lib/minitest.rb:711
165
+ def start; end
166
+
167
+ # pkg:gem/minitest#lib/minitest.rb:743
168
+ def synchronize(&block); end
169
+ end
170
+
171
+ # Represents run failures.
172
+ #
173
+ # pkg:gem/minitest#lib/minitest.rb:1035
174
+ class Minitest::Assertion < ::Exception
175
+ # pkg:gem/minitest#lib/minitest.rb:1038
176
+ def error; end
177
+
178
+ # Where was this run before an assertion was raised?
179
+ #
180
+ # pkg:gem/minitest#lib/minitest.rb:1045
181
+ def location; end
182
+
183
+ # pkg:gem/minitest#lib/minitest.rb:1053
184
+ def result_code; end
185
+
186
+ # pkg:gem/minitest#lib/minitest.rb:1057
187
+ def result_label; end
188
+ end
189
+
190
+ # pkg:gem/minitest#lib/minitest.rb:1036
191
+ Minitest::Assertion::RE = T.let(T.unsafe(nil), Regexp)
192
+
193
+ # Minitest Assertions. All assertion methods accept a +msg+ which is
194
+ # printed if the assertion fails.
195
+ #
196
+ # Protocol: Nearly everything here boils up to +assert+, which
197
+ # expects to be able to increment an instance accessor named
198
+ # +assertions+. This is not provided by Assertions and must be
199
+ # provided by the thing including Assertions. See Minitest::Runnable
200
+ # for an example.
201
+ #
202
+ # pkg:gem/minitest#lib/minitest/assertions.rb:16
203
+ module Minitest::Assertions
204
+ # pkg:gem/minitest#lib/minitest/assertions.rb:199
205
+ def _caller_uplevel; end
206
+
207
+ # pkg:gem/minitest#lib/minitest/assertions.rb:181
208
+ def _synchronize; end
209
+
210
+ # pkg:gem/minitest#lib/minitest/assertions.rb:194
211
+ def _where; end
212
+
213
+ # Fails unless +test+ is truthy.
214
+ #
215
+ # pkg:gem/minitest#lib/minitest/assertions.rb:171
216
+ def assert(test, msg = T.unsafe(nil)); end
217
+
218
+ # Fails unless +obj+ is empty.
219
+ #
220
+ # pkg:gem/minitest#lib/minitest/assertions.rb:188
221
+ def assert_empty(obj, msg = T.unsafe(nil)); end
222
+
223
+ # Fails unless <tt>exp == act</tt> printing the difference between
224
+ # the two, if possible.
225
+ #
226
+ # If there is no visible difference but the assertion fails, you
227
+ # should suspect that your #== is buggy, or your inspect output is
228
+ # missing crucial details. For nicer structural diffing, set
229
+ # Minitest::Test.make_my_diffs_pretty!
230
+ #
231
+ # For floats use assert_in_delta.
232
+ #
233
+ # See also: Minitest::Assertions.diff
234
+ #
235
+ # pkg:gem/minitest#lib/minitest/assertions.rb:220
236
+ def assert_equal(exp, act, msg = T.unsafe(nil)); end
237
+
238
+ # For comparing Floats. Fails unless +exp+ and +act+ are within +delta+
239
+ # of each other.
240
+ #
241
+ # assert_in_delta Math::PI, (22.0 / 7.0), 0.01
242
+ #
243
+ # pkg:gem/minitest#lib/minitest/assertions.rb:241
244
+ def assert_in_delta(exp, act, delta = T.unsafe(nil), msg = T.unsafe(nil)); end
245
+
246
+ # For comparing Floats. Fails unless +exp+ and +act+ have a relative
247
+ # error less than +epsilon+.
248
+ #
249
+ # pkg:gem/minitest#lib/minitest/assertions.rb:253
250
+ def assert_in_epsilon(exp, act, epsilon = T.unsafe(nil), msg = T.unsafe(nil)); end
251
+
252
+ # Fails unless +collection+ includes +obj+.
253
+ #
254
+ # pkg:gem/minitest#lib/minitest/assertions.rb:260
255
+ def assert_includes(collection, obj, msg = T.unsafe(nil)); end
256
+
257
+ # Fails unless +obj+ is an instance of +cls+.
258
+ #
259
+ # pkg:gem/minitest#lib/minitest/assertions.rb:271
260
+ def assert_instance_of(cls, obj, msg = T.unsafe(nil)); end
261
+
262
+ # Fails unless +obj+ is a kind of +cls+.
263
+ #
264
+ # pkg:gem/minitest#lib/minitest/assertions.rb:282
265
+ def assert_kind_of(cls, obj, msg = T.unsafe(nil)); end
266
+
267
+ # Fails unless +matcher+ <tt>=~</tt> +obj+.
268
+ #
269
+ # pkg:gem/minitest#lib/minitest/assertions.rb:293
270
+ def assert_match(matcher, obj, msg = T.unsafe(nil)); end
271
+
272
+ # Fails unless +obj+ is nil
273
+ #
274
+ # pkg:gem/minitest#lib/minitest/assertions.rb:305
275
+ def assert_nil(obj, msg = T.unsafe(nil)); end
276
+
277
+ # For testing with binary operators. Eg:
278
+ #
279
+ # assert_operator 5, :<=, 4
280
+ #
281
+ # pkg:gem/minitest#lib/minitest/assertions.rb:315
282
+ def assert_operator(o1, op, o2 = T.unsafe(nil), msg = T.unsafe(nil)); end
283
+
284
+ # Fails if stdout or stderr do not output the expected results.
285
+ # Pass in nil if you don't care about that streams output. Pass in
286
+ # "" if you require it to be silent. Pass in a regexp if you want
287
+ # to pattern match.
288
+ #
289
+ # assert_output(/hey/) { method_with_output }
290
+ #
291
+ # NOTE: this uses #capture_io, not #capture_subprocess_io.
292
+ #
293
+ # See also: #assert_silent
294
+ #
295
+ # pkg:gem/minitest#lib/minitest/assertions.rb:333
296
+ def assert_output(stdout = T.unsafe(nil), stderr = T.unsafe(nil)); end
297
+
298
+ # Fails unless +path+ exists.
299
+ #
300
+ # pkg:gem/minitest#lib/minitest/assertions.rb:357
301
+ def assert_path_exists(path, msg = T.unsafe(nil)); end
302
+
303
+ # For testing with pattern matching (only supported with Ruby 3.0 and later)
304
+ #
305
+ # # pass
306
+ # assert_pattern { [1,2,3] => [Integer, Integer, Integer] }
307
+ #
308
+ # # fail "length mismatch (given 3, expected 1)"
309
+ # assert_pattern { [1,2,3] => [Integer] }
310
+ #
311
+ # The bare <tt>=></tt> pattern will raise a NoMatchingPatternError on failure, which would
312
+ # normally be counted as a test error. This assertion rescues NoMatchingPatternError and
313
+ # generates a test failure. Any other exception will be raised as normal and generate a test
314
+ # error.
315
+ #
316
+ # pkg:gem/minitest#lib/minitest/assertions.rb:376
317
+ def assert_pattern; end
318
+
319
+ # For testing with predicates. Eg:
320
+ #
321
+ # assert_predicate str, :empty?
322
+ #
323
+ # This is really meant for specs and is front-ended by assert_operator:
324
+ #
325
+ # str.must_be :empty?
326
+ #
327
+ # pkg:gem/minitest#lib/minitest/assertions.rb:394
328
+ def assert_predicate(o1, op, msg = T.unsafe(nil)); end
329
+
330
+ # Fails unless the block raises one of +exp+. Returns the
331
+ # exception matched so you can check the message, attributes, etc.
332
+ #
333
+ # +exp+ takes an optional message on the end to help explain
334
+ # failures and defaults to StandardError if no exception class is
335
+ # passed. Eg:
336
+ #
337
+ # assert_raises(CustomError) { method_with_custom_error }
338
+ #
339
+ # With custom error message:
340
+ #
341
+ # assert_raises(CustomError, 'This should have raised CustomError') { method_with_custom_error }
342
+ #
343
+ # Using the returned object:
344
+ #
345
+ # error = assert_raises(CustomError) do
346
+ # raise CustomError, 'This is really bad'
347
+ # end
348
+ #
349
+ # assert_equal 'This is really bad', error.message
350
+ #
351
+ # pkg:gem/minitest#lib/minitest/assertions.rb:421
352
+ def assert_raises(*exp); end
353
+
354
+ # Fails unless +obj+ responds to +meth+.
355
+ # include_all defaults to false to match Object#respond_to?
356
+ #
357
+ # pkg:gem/minitest#lib/minitest/assertions.rb:453
358
+ def assert_respond_to(obj, meth, msg = T.unsafe(nil), include_all: T.unsafe(nil)); end
359
+
360
+ # Fails unless +exp+ and +act+ are #equal?
361
+ #
362
+ # pkg:gem/minitest#lib/minitest/assertions.rb:463
363
+ def assert_same(exp, act, msg = T.unsafe(nil)); end
364
+
365
+ # +send_ary+ is a receiver, message and arguments.
366
+ #
367
+ # Fails unless the call returns a true value
368
+ #
369
+ # pkg:gem/minitest#lib/minitest/assertions.rb:476
370
+ def assert_send(send_ary, m = T.unsafe(nil)); end
371
+
372
+ # Fails if the block outputs anything to stderr or stdout.
373
+ #
374
+ # See also: #assert_output
375
+ #
376
+ # pkg:gem/minitest#lib/minitest/assertions.rb:491
377
+ def assert_silent; end
378
+
379
+ # Fails unless the block throws +sym+
380
+ #
381
+ # pkg:gem/minitest#lib/minitest/assertions.rb:500
382
+ def assert_throws(sym, msg = T.unsafe(nil)); end
383
+
384
+ # Captures $stdout and $stderr into strings:
385
+ #
386
+ # out, err = capture_io do
387
+ # puts "Some info"
388
+ # warn "You did a bad thing"
389
+ # end
390
+ #
391
+ # assert_match %r%info%, out
392
+ # assert_match %r%bad%, err
393
+ #
394
+ # NOTE: For efficiency, this method uses StringIO and does not
395
+ # capture IO for subprocesses. Use #capture_subprocess_io for
396
+ # that.
397
+ #
398
+ # pkg:gem/minitest#lib/minitest/assertions.rb:536
399
+ def capture_io; end
400
+
401
+ # Captures $stdout and $stderr into strings, using Tempfile to
402
+ # ensure that subprocess IO is captured as well.
403
+ #
404
+ # out, err = capture_subprocess_io do
405
+ # system "echo Some info"
406
+ # system "echo You did a bad thing 1>&2"
407
+ # end
408
+ #
409
+ # assert_match %r%info%, out
410
+ # assert_match %r%bad%, err
411
+ #
412
+ # NOTE: This method is approximately 10x slower than #capture_io so
413
+ # only use it when you need to test the output of a subprocess.
414
+ #
415
+ # pkg:gem/minitest#lib/minitest/assertions.rb:569
416
+ def capture_subprocess_io; end
417
+
418
+ # Returns a diff between +exp+ and +act+. If there is no known
419
+ # diff command or if it doesn't make sense to diff the output
420
+ # (single line, short output), then it simply returns a basic
421
+ # comparison between the two.
422
+ #
423
+ # See +things_to_diff+ for more info.
424
+ #
425
+ # pkg:gem/minitest#lib/minitest/assertions.rb:57
426
+ def diff(exp, act); end
427
+
428
+ # Returns details for exception +e+
429
+ #
430
+ # pkg:gem/minitest#lib/minitest/assertions.rb:601
431
+ def exception_details(e, msg); end
432
+
433
+ # Fails after a given date (in the local time zone). This allows
434
+ # you to put time-bombs in your tests if you need to keep
435
+ # something around until a later date lest you forget about it.
436
+ #
437
+ # pkg:gem/minitest#lib/minitest/assertions.rb:617
438
+ def fail_after(y, m, d, msg); end
439
+
440
+ # Fails with +msg+.
441
+ #
442
+ # pkg:gem/minitest#lib/minitest/assertions.rb:624
443
+ def flunk(msg = T.unsafe(nil)); end
444
+
445
+ # Returns a proc that will output +msg+ along with the default message.
446
+ #
447
+ # pkg:gem/minitest#lib/minitest/assertions.rb:632
448
+ def message(msg = T.unsafe(nil), ending = T.unsafe(nil), &default); end
449
+
450
+ # This returns a human-readable version of +obj+. By default
451
+ # #inspect is called. You can override this to use #pretty_inspect
452
+ # if you want.
453
+ #
454
+ # See Minitest::Test.make_my_diffs_pretty!
455
+ #
456
+ # pkg:gem/minitest#lib/minitest/assertions.rb:127
457
+ def mu_pp(obj); end
458
+
459
+ # This returns a diff-able more human-readable version of +obj+.
460
+ # This differs from the regular mu_pp because it expands escaped
461
+ # newlines and makes hex-values (like object_ids) generic. This
462
+ # uses mu_pp to do the first pass and then cleans it up.
463
+ #
464
+ # pkg:gem/minitest#lib/minitest/assertions.rb:145
465
+ def mu_pp_for_diff(obj); end
466
+
467
+ # used for counting assertions
468
+ #
469
+ # pkg:gem/minitest#lib/minitest/assertions.rb:643
470
+ def pass(_msg = T.unsafe(nil)); end
471
+
472
+ # Fails if +test+ is truthy.
473
+ #
474
+ # pkg:gem/minitest#lib/minitest/assertions.rb:650
475
+ def refute(test, msg = T.unsafe(nil)); end
476
+
477
+ # Fails if +obj+ is empty.
478
+ #
479
+ # pkg:gem/minitest#lib/minitest/assertions.rb:658
480
+ def refute_empty(obj, msg = T.unsafe(nil)); end
481
+
482
+ # Fails if <tt>exp == act</tt>.
483
+ #
484
+ # For floats use refute_in_delta.
485
+ #
486
+ # pkg:gem/minitest#lib/minitest/assertions.rb:669
487
+ def refute_equal(exp, act, msg = T.unsafe(nil)); end
488
+
489
+ # For comparing Floats. Fails if +exp+ is within +delta+ of +act+.
490
+ #
491
+ # refute_in_delta Math::PI, (22.0 / 7.0)
492
+ #
493
+ # pkg:gem/minitest#lib/minitest/assertions.rb:681
494
+ def refute_in_delta(exp, act, delta = T.unsafe(nil), msg = T.unsafe(nil)); end
495
+
496
+ # For comparing Floats. Fails if +exp+ and +act+ have a relative error
497
+ # less than +epsilon+.
498
+ #
499
+ # pkg:gem/minitest#lib/minitest/assertions.rb:693
500
+ def refute_in_epsilon(exp, act, epsilon = T.unsafe(nil), msg = T.unsafe(nil)); end
501
+
502
+ # Fails if +collection+ includes +obj+.
503
+ #
504
+ # pkg:gem/minitest#lib/minitest/assertions.rb:700
505
+ def refute_includes(collection, obj, msg = T.unsafe(nil)); end
506
+
507
+ # Fails if +obj+ is an instance of +cls+.
508
+ #
509
+ # pkg:gem/minitest#lib/minitest/assertions.rb:711
510
+ def refute_instance_of(cls, obj, msg = T.unsafe(nil)); end
511
+
512
+ # Fails if +obj+ is a kind of +cls+.
513
+ #
514
+ # pkg:gem/minitest#lib/minitest/assertions.rb:721
515
+ def refute_kind_of(cls, obj, msg = T.unsafe(nil)); end
516
+
517
+ # Fails if +matcher+ <tt>=~</tt> +obj+.
518
+ #
519
+ # pkg:gem/minitest#lib/minitest/assertions.rb:729
520
+ def refute_match(matcher, obj, msg = T.unsafe(nil)); end
521
+
522
+ # Fails if +obj+ is nil.
523
+ #
524
+ # pkg:gem/minitest#lib/minitest/assertions.rb:739
525
+ def refute_nil(obj, msg = T.unsafe(nil)); end
526
+
527
+ # Fails if +o1+ is not +op+ +o2+. Eg:
528
+ #
529
+ # refute_operator 1, :>, 2 #=> pass
530
+ # refute_operator 1, :<, 2 #=> fail
531
+ #
532
+ # pkg:gem/minitest#lib/minitest/assertions.rb:771
533
+ def refute_operator(o1, op, o2 = T.unsafe(nil), msg = T.unsafe(nil)); end
534
+
535
+ # Fails if +path+ exists.
536
+ #
537
+ # pkg:gem/minitest#lib/minitest/assertions.rb:780
538
+ def refute_path_exists(path, msg = T.unsafe(nil)); end
539
+
540
+ # For testing with pattern matching (only supported with Ruby 3.0 and later)
541
+ #
542
+ # # pass
543
+ # refute_pattern { [1,2,3] => [String] }
544
+ #
545
+ # # fail "NoMatchingPatternError expected, but nothing was raised."
546
+ # refute_pattern { [1,2,3] => [Integer, Integer, Integer] }
547
+ #
548
+ # This assertion expects a NoMatchingPatternError exception, and will fail if none is raised. Any
549
+ # other exceptions will be raised as normal and generate a test error.
550
+ #
551
+ # pkg:gem/minitest#lib/minitest/assertions.rb:756
552
+ def refute_pattern; end
553
+
554
+ # For testing with predicates.
555
+ #
556
+ # refute_predicate str, :empty?
557
+ #
558
+ # This is really meant for specs and is front-ended by refute_operator:
559
+ #
560
+ # str.wont_be :empty?
561
+ #
562
+ # pkg:gem/minitest#lib/minitest/assertions.rb:794
563
+ def refute_predicate(o1, op, msg = T.unsafe(nil)); end
564
+
565
+ # Fails if +obj+ responds to the message +meth+.
566
+ # include_all defaults to false to match Object#respond_to?
567
+ #
568
+ # pkg:gem/minitest#lib/minitest/assertions.rb:803
569
+ def refute_respond_to(obj, meth, msg = T.unsafe(nil), include_all: T.unsafe(nil)); end
570
+
571
+ # Fails if +exp+ is the same (by object identity) as +act+.
572
+ #
573
+ # pkg:gem/minitest#lib/minitest/assertions.rb:812
574
+ def refute_same(exp, act, msg = T.unsafe(nil)); end
575
+
576
+ # Skips the current run. If run in verbose-mode, the skipped run
577
+ # gets listed at the end of the run but doesn't cause a failure
578
+ # exit code.
579
+ #
580
+ # pkg:gem/minitest#lib/minitest/assertions.rb:825
581
+ def skip(msg = T.unsafe(nil), _ignored = T.unsafe(nil)); end
582
+
583
+ # Skips the current run until a given date (in the local time
584
+ # zone). This allows you to put some fixes on hold until a later
585
+ # date, but still holds you accountable and prevents you from
586
+ # forgetting it.
587
+ #
588
+ # pkg:gem/minitest#lib/minitest/assertions.rb:837
589
+ def skip_until(y, m, d, msg); end
590
+
591
+ # Was this testcase skipped? Meant for #teardown.
592
+ #
593
+ # pkg:gem/minitest#lib/minitest/assertions.rb:846
594
+ def skipped?; end
595
+
596
+ # Returns things to diff [expect, butwas], or [nil, nil] if nothing to diff.
597
+ #
598
+ # Criterion:
599
+ #
600
+ # 1. Strings include newlines or escaped newlines, but not both.
601
+ # 2. or: String lengths are > 30 characters.
602
+ # 3. or: Strings are equal to each other (but maybe different encodings?).
603
+ # 4. and: we found a diff executable.
604
+ #
605
+ # pkg:gem/minitest#lib/minitest/assertions.rb:102
606
+ def things_to_diff(exp, act); end
607
+
608
+ class << self
609
+ # Returns the diff command to use in #diff. Tries to intelligently
610
+ # figure out what diff to use.
611
+ #
612
+ # pkg:gem/minitest#lib/minitest/assertions.rb:27
613
+ def diff; end
614
+
615
+ # Set the diff command to use in #diff.
616
+ #
617
+ # pkg:gem/minitest#lib/minitest/assertions.rb:45
618
+ def diff=(o); end
619
+ end
620
+ end
621
+
622
+ # pkg:gem/minitest#lib/minitest/assertions.rb:205
623
+ Minitest::Assertions::E = T.let(T.unsafe(nil), String)
624
+
625
+ # pkg:gem/minitest#lib/minitest/assertions.rb:17
626
+ Minitest::Assertions::UNDEFINED = T.let(T.unsafe(nil), Object)
627
+
628
+ # The standard backtrace filter for minitest.
629
+ #
630
+ # See Minitest.backtrace_filter=.
631
+ #
632
+ # pkg:gem/minitest#lib/minitest.rb:1190
633
+ class Minitest::BacktraceFilter
634
+ # pkg:gem/minitest#lib/minitest.rb:1199
635
+ def initialize(regexp = T.unsafe(nil)); end
636
+
637
+ # Filter +bt+ to something useful. Returns the whole thing if
638
+ # $DEBUG (ruby) or $MT_DEBUG (env).
639
+ #
640
+ # pkg:gem/minitest#lib/minitest.rb:1207
641
+ def filter(bt); end
642
+
643
+ # The regular expression to use to filter backtraces. Defaults to +MT_RE+.
644
+ #
645
+ # pkg:gem/minitest#lib/minitest.rb:1197
646
+ def regexp; end
647
+
648
+ # The regular expression to use to filter backtraces. Defaults to +MT_RE+.
649
+ #
650
+ # pkg:gem/minitest#lib/minitest.rb:1197
651
+ def regexp=(_arg0); end
652
+ end
653
+
654
+ # pkg:gem/minitest#lib/minitest.rb:1192
655
+ Minitest::BacktraceFilter::MT_RE = T.let(T.unsafe(nil), Regexp)
656
+
657
+ # Dispatch to multiple reporters as one.
658
+ #
659
+ # pkg:gem/minitest#lib/minitest.rb:984
660
+ class Minitest::CompositeReporter < ::Minitest::AbstractReporter
661
+ # pkg:gem/minitest#lib/minitest.rb:990
662
+ def initialize(*reporters); end
663
+
664
+ # Add another reporter to the mix.
665
+ #
666
+ # pkg:gem/minitest#lib/minitest.rb:1002
667
+ def <<(reporter); end
668
+
669
+ # pkg:gem/minitest#lib/minitest.rb:995
670
+ def io; end
671
+
672
+ # pkg:gem/minitest#lib/minitest.rb:1006
673
+ def passed?; end
674
+
675
+ # pkg:gem/minitest#lib/minitest.rb:1014
676
+ def prerecord(klass, name); end
677
+
678
+ # pkg:gem/minitest#lib/minitest.rb:1021
679
+ def record(result); end
680
+
681
+ # pkg:gem/minitest#lib/minitest.rb:1027
682
+ def report; end
683
+
684
+ # The list of reporters to dispatch to.
685
+ #
686
+ # pkg:gem/minitest#lib/minitest.rb:988
687
+ def reporters; end
688
+
689
+ # The list of reporters to dispatch to.
690
+ #
691
+ # pkg:gem/minitest#lib/minitest.rb:988
692
+ def reporters=(_arg0); end
693
+
694
+ # pkg:gem/minitest#lib/minitest.rb:1010
695
+ def start; end
696
+ end
697
+
698
+ # Compresses backtraces.
699
+ #
700
+ # pkg:gem/minitest#lib/minitest/compress.rb:5
701
+ module Minitest::Compress
702
+ # Takes a backtrace (array of strings) and compresses repeating
703
+ # cycles in it to make it more readable.
704
+ #
705
+ # pkg:gem/minitest#lib/minitest/compress.rb:11
706
+ def compress(orig); end
707
+ end
708
+
709
+ # Provides a simple set of guards that you can use in your tests
710
+ # to skip execution if it is not applicable. These methods are
711
+ # mixed into Test as both instance and class methods so you
712
+ # can use them inside or outside of the test methods.
713
+ #
714
+ # def test_something_for_mri
715
+ # skip "bug 1234" if jruby?
716
+ # # ...
717
+ # end
718
+ #
719
+ # if windows? then
720
+ # # ... lots of test methods ...
721
+ # end
722
+ #
723
+ # pkg:gem/minitest#lib/minitest.rb:1134
724
+ module Minitest::Guard
725
+ # Is this running on jruby?
726
+ #
727
+ # pkg:gem/minitest#lib/minitest.rb:1139
728
+ def jruby?(platform = T.unsafe(nil)); end
729
+
730
+ # Is this running on maglev?
731
+ #
732
+ # pkg:gem/minitest#lib/minitest.rb:1146
733
+ def maglev?(platform = T.unsafe(nil)); end
734
+
735
+ # Is this running on mri?
736
+ #
737
+ # pkg:gem/minitest#lib/minitest.rb:1156
738
+ def mri?(platform = T.unsafe(nil)); end
739
+
740
+ # Is this running on macOS?
741
+ #
742
+ # pkg:gem/minitest#lib/minitest.rb:1163
743
+ def osx?(platform = T.unsafe(nil)); end
744
+
745
+ # Is this running on rubinius?
746
+ #
747
+ # pkg:gem/minitest#lib/minitest.rb:1170
748
+ def rubinius?(platform = T.unsafe(nil)); end
749
+
750
+ # Is this running on windows?
751
+ #
752
+ # pkg:gem/minitest#lib/minitest.rb:1180
753
+ def windows?(platform = T.unsafe(nil)); end
754
+ end
755
+
756
+ # pkg:gem/minitest#lib/minitest/parallel.rb:4
757
+ module Minitest::Parallel; end
758
+
759
+ # The engine used to run multiple tests in parallel.
760
+ #
761
+ # pkg:gem/minitest#lib/minitest/parallel.rb:9
762
+ class Minitest::Parallel::Executor
763
+ # Create a parallel test executor of with +size+ workers.
764
+ #
765
+ # pkg:gem/minitest#lib/minitest/parallel.rb:19
766
+ def initialize(size); end
767
+
768
+ # Add a job to the queue
769
+ #
770
+ # pkg:gem/minitest#lib/minitest/parallel.rb:45
771
+ def <<(work); end
772
+
773
+ # Shuts down the pool of workers by signalling them to quit and
774
+ # waiting for them all to finish what they're currently working
775
+ # on.
776
+ #
777
+ # pkg:gem/minitest#lib/minitest/parallel.rb:52
778
+ def shutdown; end
779
+
780
+ # The size of the pool of workers.
781
+ #
782
+ # pkg:gem/minitest#lib/minitest/parallel.rb:14
783
+ def size; end
784
+
785
+ # Start the executor
786
+ #
787
+ # pkg:gem/minitest#lib/minitest/parallel.rb:28
788
+ def start; end
789
+ end
790
+
791
+ # pkg:gem/minitest#lib/minitest/parallel.rb:58
792
+ module Minitest::Parallel::Test
793
+ # pkg:gem/minitest#lib/minitest/parallel.rb:59
794
+ def _synchronize; end
795
+ end
796
+
797
+ # pkg:gem/minitest#lib/minitest/parallel.rb:61
798
+ module Minitest::Parallel::Test::ClassMethods
799
+ # pkg:gem/minitest#lib/minitest/parallel.rb:62
800
+ def run_one_method(klass, method_name, reporter); end
801
+
802
+ # pkg:gem/minitest#lib/minitest/parallel.rb:66
803
+ def test_order; end
804
+ end
805
+
806
+ # A very simple reporter that prints the "dots" during the run.
807
+ #
808
+ # This is added to the top-level CompositeReporter at the start of
809
+ # the run. If you want to change the output of minitest via a
810
+ # plugin, pull this out of the composite and replace it with your
811
+ # own.
812
+ #
813
+ # pkg:gem/minitest#lib/minitest.rb:774
814
+ class Minitest::ProgressReporter < ::Minitest::Reporter
815
+ # pkg:gem/minitest#lib/minitest.rb:775
816
+ def prerecord(klass, name); end
817
+
818
+ # pkg:gem/minitest#lib/minitest.rb:782
819
+ def record(result); end
820
+ end
821
+
822
+ # Shared code for anything that can get passed to a Reporter. See
823
+ # Minitest::Test & Minitest::Result.
824
+ #
825
+ # pkg:gem/minitest#lib/minitest.rb:596
826
+ module Minitest::Reportable
827
+ # pkg:gem/minitest#lib/minitest.rb:618
828
+ def class_name; end
829
+
830
+ # Did this run error?
831
+ #
832
+ # pkg:gem/minitest#lib/minitest.rb:639
833
+ def error?; end
834
+
835
+ # The location identifier of this test. Depends on a method
836
+ # existing called class_name.
837
+ #
838
+ # pkg:gem/minitest#lib/minitest.rb:613
839
+ def location; end
840
+
841
+ # Did this run pass?
842
+ #
843
+ # Note: skipped runs are not considered passing, but they don't
844
+ # cause the process to exit non-zero.
845
+ #
846
+ # pkg:gem/minitest#lib/minitest.rb:603
847
+ def passed?; end
848
+
849
+ # Returns ".", "F", or "E" based on the result of the run.
850
+ #
851
+ # pkg:gem/minitest#lib/minitest.rb:625
852
+ def result_code; end
853
+
854
+ # Was this run skipped?
855
+ #
856
+ # pkg:gem/minitest#lib/minitest.rb:632
857
+ def skipped?; end
858
+ end
859
+
860
+ # pkg:gem/minitest#lib/minitest.rb:607
861
+ Minitest::Reportable::BASE_DIR = T.let(T.unsafe(nil), String)
862
+
863
+ # AbstractReportera
864
+ #
865
+ # pkg:gem/minitest#lib/minitest.rb:750
866
+ class Minitest::Reporter < ::Minitest::AbstractReporter
867
+ # pkg:gem/minitest#lib/minitest.rb:759
868
+ def initialize(io = T.unsafe(nil), options = T.unsafe(nil)); end
869
+
870
+ # The IO used to report.
871
+ #
872
+ # pkg:gem/minitest#lib/minitest.rb:752
873
+ def io; end
874
+
875
+ # The IO used to report.
876
+ #
877
+ # pkg:gem/minitest#lib/minitest.rb:752
878
+ def io=(_arg0); end
879
+
880
+ # Command-line options for this run.
881
+ #
882
+ # pkg:gem/minitest#lib/minitest.rb:757
883
+ def options; end
884
+
885
+ # Command-line options for this run.
886
+ #
887
+ # pkg:gem/minitest#lib/minitest.rb:757
888
+ def options=(_arg0); end
889
+ end
890
+
891
+ # This represents a test result in a clean way that can be
892
+ # marshalled over a wire. Tests can do anything they want to the
893
+ # test instance and can create conditions that cause Marshal.dump to
894
+ # blow up. By using Result.from(a_test) you can be reasonably sure
895
+ # that the test result can be marshalled.
896
+ #
897
+ # pkg:gem/minitest#lib/minitest.rb:651
898
+ class Minitest::Result < ::Minitest::Runnable
899
+ include ::Minitest::Reportable
900
+
901
+ # pkg:gem/minitest#lib/minitest.rb:685
902
+ def class_name; end
903
+
904
+ # The class name of the test result.
905
+ #
906
+ # pkg:gem/minitest#lib/minitest.rb:660
907
+ def klass; end
908
+
909
+ # The class name of the test result.
910
+ #
911
+ # pkg:gem/minitest#lib/minitest.rb:660
912
+ def klass=(_arg0); end
913
+
914
+ # The location of the test method.
915
+ #
916
+ # pkg:gem/minitest#lib/minitest.rb:665
917
+ def source_location; end
918
+
919
+ # The location of the test method.
920
+ #
921
+ # pkg:gem/minitest#lib/minitest.rb:665
922
+ def source_location=(_arg0); end
923
+
924
+ # pkg:gem/minitest#lib/minitest.rb:689
925
+ def to_s; end
926
+
927
+ class << self
928
+ # Create a new test result from a Runnable instance.
929
+ #
930
+ # pkg:gem/minitest#lib/minitest.rb:670
931
+ def from(runnable); end
932
+ end
933
+ end
934
+
935
+ # Represents anything "runnable", like Test, Spec, Benchmark, or
936
+ # whatever you can dream up.
937
+ #
938
+ # Subclasses of this are automatically registered and available in
939
+ # Runnable.runnables.
940
+ #
941
+ # pkg:gem/minitest#lib/minitest.rb:363
942
+ class Minitest::Runnable
943
+ # pkg:gem/minitest#lib/minitest.rb:527
944
+ def initialize(name); end
945
+
946
+ # Number of assertions executed in this run.
947
+ #
948
+ # pkg:gem/minitest#lib/minitest.rb:367
949
+ def assertions; end
950
+
951
+ # Number of assertions executed in this run.
952
+ #
953
+ # pkg:gem/minitest#lib/minitest.rb:367
954
+ def assertions=(_arg0); end
955
+
956
+ # pkg:gem/minitest#lib/minitest.rb:523
957
+ def failure; end
958
+
959
+ # An assertion raised during the run, if any.
960
+ #
961
+ # pkg:gem/minitest#lib/minitest.rb:372
962
+ def failures; end
963
+
964
+ # An assertion raised during the run, if any.
965
+ #
966
+ # pkg:gem/minitest#lib/minitest.rb:372
967
+ def failures=(_arg0); end
968
+
969
+ # pkg:gem/minitest#lib/minitest.rb:509
970
+ def marshal_dump; end
971
+
972
+ # pkg:gem/minitest#lib/minitest.rb:519
973
+ def marshal_load(ary); end
974
+
975
+ # Metadata you attach to the test results that get sent to the reporter.
976
+ #
977
+ # Lazily initializes to a hash, to keep memory down.
978
+ #
979
+ # NOTE: this data *must* be plain (read: marshal-able) data!
980
+ # Hashes! Arrays! Strings!
981
+ #
982
+ # Sets metadata, mainly used for +Result.from+.
983
+ #
984
+ # pkg:gem/minitest#lib/minitest.rb:542
985
+ def metadata; end
986
+
987
+ # Metadata you attach to the test results that get sent to the reporter.
988
+ #
989
+ # Lazily initializes to a hash, to keep memory down.
990
+ #
991
+ # NOTE: this data *must* be plain (read: marshal-able) data!
992
+ # Hashes! Arrays! Strings!
993
+ #
994
+ # Sets metadata, mainly used for +Result.from+.
995
+ #
996
+ # pkg:gem/minitest#lib/minitest.rb:549
997
+ def metadata=(_arg0); end
998
+
999
+ # Returns true if metadata exists.
1000
+ #
1001
+ # pkg:gem/minitest#lib/minitest.rb:554
1002
+ def metadata?; end
1003
+
1004
+ # Name of the run.
1005
+ #
1006
+ # pkg:gem/minitest#lib/minitest.rb:390
1007
+ def name; end
1008
+
1009
+ # Set the name of the run.
1010
+ #
1011
+ # pkg:gem/minitest#lib/minitest.rb:397
1012
+ def name=(o); end
1013
+
1014
+ # Did this run pass?
1015
+ #
1016
+ # Note: skipped runs are not considered passing, but they don't
1017
+ # cause the process to exit non-zero.
1018
+ #
1019
+ # pkg:gem/minitest#lib/minitest.rb:571
1020
+ def passed?; end
1021
+
1022
+ # Returns a single character string to print based on the result
1023
+ # of the run. One of <tt>"."</tt>, <tt>"F"</tt>,
1024
+ # <tt>"E"</tt> or <tt>"S"</tt>.
1025
+ #
1026
+ # pkg:gem/minitest#lib/minitest.rb:580
1027
+ def result_code; end
1028
+
1029
+ # Runs a single method. Needs to return self.
1030
+ #
1031
+ # pkg:gem/minitest#lib/minitest.rb:561
1032
+ def run; end
1033
+
1034
+ # Was this run skipped? See #passed? for more information.
1035
+ #
1036
+ # pkg:gem/minitest#lib/minitest.rb:587
1037
+ def skipped?; end
1038
+
1039
+ # The time it took to run.
1040
+ #
1041
+ # pkg:gem/minitest#lib/minitest.rb:377
1042
+ def time; end
1043
+
1044
+ # The time it took to run.
1045
+ #
1046
+ # pkg:gem/minitest#lib/minitest.rb:377
1047
+ def time=(_arg0); end
1048
+
1049
+ # pkg:gem/minitest#lib/minitest.rb:379
1050
+ def time_it; end
1051
+
1052
+ class << self
1053
+ # re-open
1054
+ #
1055
+ # pkg:gem/minitest#lib/minitest.rb:1241
1056
+ def inherited(klass); end
1057
+
1058
+ # Returns all instance methods matching the pattern +re+.
1059
+ #
1060
+ # pkg:gem/minitest#lib/minitest.rb:404
1061
+ def methods_matching(re); end
1062
+
1063
+ # pkg:gem/minitest#lib/minitest.rb:479
1064
+ def on_signal(name, action); end
1065
+
1066
+ # pkg:gem/minitest#lib/minitest.rb:408
1067
+ def reset; end
1068
+
1069
+ # Responsible for running all runnable methods in a given class,
1070
+ # each in its own instance. Each instance is passed to the
1071
+ # reporter to record.
1072
+ #
1073
+ # pkg:gem/minitest#lib/minitest.rb:419
1074
+ def run(reporter, options = T.unsafe(nil)); end
1075
+
1076
+ # Runs a single method and has the reporter record the result.
1077
+ # This was considered internal API but is factored out of run so
1078
+ # that subclasses can specialize the running of an individual
1079
+ # test. See Minitest::ParallelTest::ClassMethods for an example.
1080
+ #
1081
+ # pkg:gem/minitest#lib/minitest.rb:460
1082
+ def run_one_method(klass, method_name, reporter); end
1083
+
1084
+ # Each subclass of Runnable is responsible for overriding this
1085
+ # method to return all runnable methods. See #methods_matching.
1086
+ #
1087
+ # pkg:gem/minitest#lib/minitest.rb:496
1088
+ def runnable_methods; end
1089
+
1090
+ # Returns all subclasses of Runnable.
1091
+ #
1092
+ # pkg:gem/minitest#lib/minitest.rb:503
1093
+ def runnables; end
1094
+
1095
+ # Defines the order to run tests (:random by default). Override
1096
+ # this or use a convenience method to change it for your tests.
1097
+ #
1098
+ # pkg:gem/minitest#lib/minitest.rb:469
1099
+ def test_order; end
1100
+
1101
+ # pkg:gem/minitest#lib/minitest.rb:473
1102
+ def with_info_handler(reporter, &block); end
1103
+ end
1104
+ end
1105
+
1106
+ # pkg:gem/minitest#lib/minitest.rb:477
1107
+ Minitest::Runnable::SIGNALS = T.let(T.unsafe(nil), Hash)
1108
+
1109
+ # Assertion raised when skipping a run.
1110
+ #
1111
+ # pkg:gem/minitest#lib/minitest.rb:1065
1112
+ class Minitest::Skip < ::Minitest::Assertion
1113
+ # pkg:gem/minitest#lib/minitest.rb:1066
1114
+ def result_label; end
1115
+ end
1116
+
1117
+ # A reporter that gathers statistics about a test run. Does not do
1118
+ # any IO because meant to be used as a parent class for a reporter
1119
+ # that does.
1120
+ #
1121
+ # If you want to create an entirely different type of output (eg,
1122
+ # CI, HTML, etc), this is the place to start.
1123
+ #
1124
+ # Example:
1125
+ #
1126
+ # class JenkinsCIReporter < StatisticsReporter
1127
+ # def report
1128
+ # super # Needed to calculate some statistics
1129
+ #
1130
+ # print "<testsuite "
1131
+ # print "tests='#{count}' "
1132
+ # print "failures='#{failures}' "
1133
+ # # Remaining XML...
1134
+ # end
1135
+ # end
1136
+ #
1137
+ # pkg:gem/minitest#lib/minitest.rb:810
1138
+ class Minitest::StatisticsReporter < ::Minitest::Reporter
1139
+ # pkg:gem/minitest#lib/minitest.rb:859
1140
+ def initialize(io = T.unsafe(nil), options = T.unsafe(nil)); end
1141
+
1142
+ # Total number of assertions.
1143
+ #
1144
+ # pkg:gem/minitest#lib/minitest.rb:814
1145
+ def assertions; end
1146
+
1147
+ # Total number of assertions.
1148
+ #
1149
+ # pkg:gem/minitest#lib/minitest.rb:814
1150
+ def assertions=(_arg0); end
1151
+
1152
+ # Total number of test cases.
1153
+ #
1154
+ # pkg:gem/minitest#lib/minitest.rb:819
1155
+ def count; end
1156
+
1157
+ # Total number of test cases.
1158
+ #
1159
+ # pkg:gem/minitest#lib/minitest.rb:819
1160
+ def count=(_arg0); end
1161
+
1162
+ # Total number of tests that erred.
1163
+ #
1164
+ # pkg:gem/minitest#lib/minitest.rb:847
1165
+ def errors; end
1166
+
1167
+ # Total number of tests that erred.
1168
+ #
1169
+ # pkg:gem/minitest#lib/minitest.rb:847
1170
+ def errors=(_arg0); end
1171
+
1172
+ # Total number of tests that failed.
1173
+ #
1174
+ # pkg:gem/minitest#lib/minitest.rb:842
1175
+ def failures; end
1176
+
1177
+ # Total number of tests that failed.
1178
+ #
1179
+ # pkg:gem/minitest#lib/minitest.rb:842
1180
+ def failures=(_arg0); end
1181
+
1182
+ # pkg:gem/minitest#lib/minitest.rb:873
1183
+ def passed?; end
1184
+
1185
+ # pkg:gem/minitest#lib/minitest.rb:881
1186
+ def record(result); end
1187
+
1188
+ # Report on the tracked statistics.
1189
+ #
1190
+ # pkg:gem/minitest#lib/minitest.rb:891
1191
+ def report; end
1192
+
1193
+ # An +Array+ of test cases that failed or were skipped.
1194
+ #
1195
+ # pkg:gem/minitest#lib/minitest.rb:824
1196
+ def results; end
1197
+
1198
+ # An +Array+ of test cases that failed or were skipped.
1199
+ #
1200
+ # pkg:gem/minitest#lib/minitest.rb:824
1201
+ def results=(_arg0); end
1202
+
1203
+ # Total number of tests that where skipped.
1204
+ #
1205
+ # pkg:gem/minitest#lib/minitest.rb:857
1206
+ def skips; end
1207
+
1208
+ # Total number of tests that where skipped.
1209
+ #
1210
+ # pkg:gem/minitest#lib/minitest.rb:857
1211
+ def skips=(_arg0); end
1212
+
1213
+ # pkg:gem/minitest#lib/minitest.rb:877
1214
+ def start; end
1215
+
1216
+ # Time the test run started. If available, the monotonic clock is
1217
+ # used and this is a +Float+, otherwise it's an instance of
1218
+ # +Time+.
1219
+ #
1220
+ # pkg:gem/minitest#lib/minitest.rb:831
1221
+ def start_time; end
1222
+
1223
+ # Time the test run started. If available, the monotonic clock is
1224
+ # used and this is a +Float+, otherwise it's an instance of
1225
+ # +Time+.
1226
+ #
1227
+ # pkg:gem/minitest#lib/minitest.rb:831
1228
+ def start_time=(_arg0); end
1229
+
1230
+ # Test run time. If available, the monotonic clock is used and
1231
+ # this is a +Float+, otherwise it's an instance of +Time+.
1232
+ #
1233
+ # pkg:gem/minitest#lib/minitest.rb:837
1234
+ def total_time; end
1235
+
1236
+ # Test run time. If available, the monotonic clock is used and
1237
+ # this is a +Float+, otherwise it's an instance of +Time+.
1238
+ #
1239
+ # pkg:gem/minitest#lib/minitest.rb:837
1240
+ def total_time=(_arg0); end
1241
+
1242
+ # Total number of tests that warned.
1243
+ #
1244
+ # pkg:gem/minitest#lib/minitest.rb:852
1245
+ def warnings; end
1246
+
1247
+ # Total number of tests that warned.
1248
+ #
1249
+ # pkg:gem/minitest#lib/minitest.rb:852
1250
+ def warnings=(_arg0); end
1251
+ end
1252
+
1253
+ # A reporter that prints the header, summary, and failure details at
1254
+ # the end of the run.
1255
+ #
1256
+ # This is added to the top-level CompositeReporter at the start of
1257
+ # the run. If you want to change the output of minitest via a
1258
+ # plugin, pull this out of the composite and replace it with your
1259
+ # own.
1260
+ #
1261
+ # pkg:gem/minitest#lib/minitest.rb:912
1262
+ class Minitest::SummaryReporter < ::Minitest::StatisticsReporter
1263
+ # pkg:gem/minitest#lib/minitest.rb:945
1264
+ def aggregated_results(io); end
1265
+
1266
+ # pkg:gem/minitest#lib/minitest.rb:914
1267
+ def old_sync; end
1268
+
1269
+ # pkg:gem/minitest#lib/minitest.rb:914
1270
+ def old_sync=(_arg0); end
1271
+
1272
+ # pkg:gem/minitest#lib/minitest.rb:928
1273
+ def report; end
1274
+
1275
+ # pkg:gem/minitest#lib/minitest.rb:916
1276
+ def start; end
1277
+
1278
+ # pkg:gem/minitest#lib/minitest.rb:940
1279
+ def statistics; end
1280
+
1281
+ # pkg:gem/minitest#lib/minitest.rb:965
1282
+ def summary; end
1283
+
1284
+ # pkg:gem/minitest#lib/minitest.rb:913
1285
+ def sync; end
1286
+
1287
+ # pkg:gem/minitest#lib/minitest.rb:913
1288
+ def sync=(_arg0); end
1289
+
1290
+ # pkg:gem/minitest#lib/minitest.rb:961
1291
+ def to_s; end
1292
+ end
1293
+
1294
+ # Subclass Test to create your own tests. Typically you'll want a
1295
+ # Test subclass per implementation class.
1296
+ #
1297
+ # See Minitest::Assertions
1298
+ #
1299
+ # pkg:gem/minitest#lib/minitest/test.rb:10
1300
+ class Minitest::Test < ::Minitest::Runnable
1301
+ include ::Minitest::Reportable
1302
+ include ::Minitest::Assertions
1303
+ include ::Minitest::Test::LifecycleHooks
1304
+ include ::Minitest::Guard
1305
+ extend ::Minitest::Guard
1306
+
1307
+ # LifecycleHooks
1308
+ #
1309
+ # pkg:gem/minitest#lib/minitest/test.rb:190
1310
+ def capture_exceptions; end
1311
+
1312
+ # pkg:gem/minitest#lib/minitest/test.rb:15
1313
+ def class_name; end
1314
+
1315
+ # pkg:gem/minitest#lib/minitest/test.rb:207
1316
+ def neuter_exception(e); end
1317
+
1318
+ # pkg:gem/minitest#lib/minitest/test.rb:218
1319
+ def new_exception(klass, msg, bt, kill = T.unsafe(nil)); end
1320
+
1321
+ # Runs a single test with setup/teardown hooks.
1322
+ #
1323
+ # pkg:gem/minitest#lib/minitest/test.rb:88
1324
+ def run; end
1325
+
1326
+ # pkg:gem/minitest#lib/minitest/test.rb:200
1327
+ def sanitize_exception(e); end
1328
+
1329
+ class << self
1330
+ # Call this at the top of your tests when you absolutely
1331
+ # positively need to have ordered tests. In doing so, you're
1332
+ # admitting that you suck and your tests are weak.
1333
+ #
1334
+ # pkg:gem/minitest#lib/minitest/test.rb:35
1335
+ def i_suck_and_my_tests_are_order_dependent!; end
1336
+
1337
+ # pkg:gem/minitest#lib/minitest/test.rb:26
1338
+ def io_lock; end
1339
+
1340
+ # pkg:gem/minitest#lib/minitest/test.rb:26
1341
+ def io_lock=(_arg0); end
1342
+
1343
+ # Make diffs for this Test use #pretty_inspect so that diff
1344
+ # in assert_equal can have more details. NOTE: this is much slower
1345
+ # than the regular inspect but much more usable for complex
1346
+ # objects.
1347
+ #
1348
+ # pkg:gem/minitest#lib/minitest/test.rb:48
1349
+ def make_my_diffs_pretty!; end
1350
+
1351
+ # Call this at the top of your tests (inside the +Minitest::Test+
1352
+ # subclass or +describe+ block) when you want to run your tests in
1353
+ # parallel. In doing so, you're admitting that you rule and your
1354
+ # tests are awesome.
1355
+ #
1356
+ # pkg:gem/minitest#lib/minitest/test.rb:60
1357
+ def parallelize_me!; end
1358
+
1359
+ # Returns all instance methods starting with "test_". Based on
1360
+ # #test_order, the methods are either sorted, randomized
1361
+ # (default), or run in parallel.
1362
+ #
1363
+ # pkg:gem/minitest#lib/minitest/test.rb:71
1364
+ def runnable_methods; end
1365
+ end
1366
+ end
1367
+
1368
+ # Provides before/after hooks for setup and teardown. These are
1369
+ # meant for library writers, NOT for regular test authors. See
1370
+ # #before_setup for an example.
1371
+ #
1372
+ # pkg:gem/minitest#lib/minitest/test.rb:113
1373
+ module Minitest::Test::LifecycleHooks
1374
+ # Runs before every test, after setup. This hook is meant for
1375
+ # libraries to extend minitest. It is not meant to be used by
1376
+ # test developers.
1377
+ #
1378
+ # See #before_setup for an example.
1379
+ #
1380
+ # pkg:gem/minitest#lib/minitest/test.rb:163
1381
+ def after_setup; end
1382
+
1383
+ # Runs after every test, after teardown. This hook is meant for
1384
+ # libraries to extend minitest. It is not meant to be used by
1385
+ # test developers.
1386
+ #
1387
+ # See #before_setup for an example.
1388
+ #
1389
+ # pkg:gem/minitest#lib/minitest/test.rb:187
1390
+ def after_teardown; end
1391
+
1392
+ # Runs before every test, before setup. This hook is meant for
1393
+ # libraries to extend minitest. It is not meant to be used by
1394
+ # test developers.
1395
+ #
1396
+ # As a simplistic example:
1397
+ #
1398
+ # module MyMinitestPlugin
1399
+ # def before_setup
1400
+ # super
1401
+ # # ... stuff to do before setup is run
1402
+ # end
1403
+ #
1404
+ # def after_setup
1405
+ # # ... stuff to do after setup is run
1406
+ # super
1407
+ # end
1408
+ #
1409
+ # def before_teardown
1410
+ # super
1411
+ # # ... stuff to do before teardown is run
1412
+ # end
1413
+ #
1414
+ # def after_teardown
1415
+ # # ... stuff to do after teardown is run
1416
+ # super
1417
+ # end
1418
+ # end
1419
+ #
1420
+ # class Minitest::Test
1421
+ # include MyMinitestPlugin
1422
+ # end
1423
+ #
1424
+ # pkg:gem/minitest#lib/minitest/test.rb:148
1425
+ def before_setup; end
1426
+
1427
+ # Runs after every test, before teardown. This hook is meant for
1428
+ # libraries to extend minitest. It is not meant to be used by
1429
+ # test developers.
1430
+ #
1431
+ # See #before_setup for an example.
1432
+ #
1433
+ # pkg:gem/minitest#lib/minitest/test.rb:172
1434
+ def before_teardown; end
1435
+
1436
+ # Runs before every test. Use this to set up before each test
1437
+ # run.
1438
+ #
1439
+ # pkg:gem/minitest#lib/minitest/test.rb:154
1440
+ def setup; end
1441
+
1442
+ # Runs after every test. Use this to clean up after each test
1443
+ # run.
1444
+ #
1445
+ # pkg:gem/minitest#lib/minitest/test.rb:178
1446
+ def teardown; end
1447
+ end
1448
+
1449
+ # pkg:gem/minitest#lib/minitest/test.rb:19
1450
+ Minitest::Test::PASSTHROUGH_EXCEPTIONS = T.let(T.unsafe(nil), Array)
1451
+
1452
+ # pkg:gem/minitest#lib/minitest/test.rb:21
1453
+ Minitest::Test::SETUP_METHODS = T.let(T.unsafe(nil), Array)
1454
+
1455
+ # pkg:gem/minitest#lib/minitest/test.rb:23
1456
+ Minitest::Test::TEARDOWN_METHODS = T.let(T.unsafe(nil), Array)
1457
+
1458
+ # Assertion wrapping an unexpected error that was raised during a run.
1459
+ #
1460
+ # pkg:gem/minitest#lib/minitest.rb:1074
1461
+ class Minitest::UnexpectedError < ::Minitest::Assertion
1462
+ include ::Minitest::Compress
1463
+
1464
+ # pkg:gem/minitest#lib/minitest.rb:1080
1465
+ def initialize(error); end
1466
+
1467
+ # pkg:gem/minitest#lib/minitest.rb:1093
1468
+ def backtrace; end
1469
+
1470
+ # TODO: figure out how to use `cause` instead
1471
+ #
1472
+ # pkg:gem/minitest#lib/minitest.rb:1078
1473
+ def error; end
1474
+
1475
+ # TODO: figure out how to use `cause` instead
1476
+ #
1477
+ # pkg:gem/minitest#lib/minitest.rb:1078
1478
+ def error=(_arg0); end
1479
+
1480
+ # pkg:gem/minitest#lib/minitest.rb:1099
1481
+ def message; end
1482
+
1483
+ # pkg:gem/minitest#lib/minitest.rb:1105
1484
+ def result_label; end
1485
+ end
1486
+
1487
+ # pkg:gem/minitest#lib/minitest.rb:1097
1488
+ Minitest::UnexpectedError::BASE_RE = T.let(T.unsafe(nil), Regexp)
1489
+
1490
+ # Assertion raised on warning when running in -Werror mode.
1491
+ #
1492
+ # pkg:gem/minitest#lib/minitest.rb:1113
1493
+ class Minitest::UnexpectedWarning < ::Minitest::Assertion
1494
+ # pkg:gem/minitest#lib/minitest.rb:1114
1495
+ def result_label; end
1496
+ end
1497
+
1498
+ # pkg:gem/minitest#lib/minitest.rb:13
1499
+ Minitest::VERSION = T.let(T.unsafe(nil), String)