ruby-lsp-rake 0.1.1 → 0.1.2

Sign up to get free protection for your applications and to get access to all the features.
Files changed (42) hide show
  1. checksums.yaml +4 -4
  2. data/README.md +0 -14
  3. data/lib/ruby/lsp/rake/version.rb +2 -1
  4. data/lib/ruby/lsp/rake.rb +1 -0
  5. data/lib/ruby_lsp/ruby_lsp_rake/addon.rb +4 -2
  6. data/lib/ruby_lsp/ruby_lsp_rake/hover.rb +2 -1
  7. data/lib/ruby_lsp/ruby_lsp_rake/indexing_enhancement.rb +7 -4
  8. data/sorbet/config +4 -0
  9. data/sorbet/rbi/annotations/.gitattributes +1 -0
  10. data/sorbet/rbi/annotations/minitest.rbi +119 -0
  11. data/sorbet/rbi/annotations/rainbow.rbi +269 -0
  12. data/sorbet/rbi/gems/.gitattributes +1 -0
  13. data/sorbet/rbi/gems/ast@2.4.2.rbi +585 -0
  14. data/sorbet/rbi/gems/erubi@1.13.0.rbi +150 -0
  15. data/sorbet/rbi/gems/json@2.8.2.rbi +1901 -0
  16. data/sorbet/rbi/gems/language_server-protocol@3.17.0.3.rbi +14238 -0
  17. data/sorbet/rbi/gems/logger@1.6.1.rbi +920 -0
  18. data/sorbet/rbi/gems/minitest@5.25.2.rbi +2209 -0
  19. data/sorbet/rbi/gems/netrc@0.11.0.rbi +159 -0
  20. data/sorbet/rbi/gems/parallel@1.26.3.rbi +291 -0
  21. data/sorbet/rbi/gems/parser@3.3.6.0.rbi +5519 -0
  22. data/sorbet/rbi/gems/prism@1.2.0.rbi +39085 -0
  23. data/sorbet/rbi/gems/racc@1.8.1.rbi +162 -0
  24. data/sorbet/rbi/gems/rainbow@3.1.1.rbi +403 -0
  25. data/sorbet/rbi/gems/rake@13.2.1.rbi +3028 -0
  26. data/sorbet/rbi/gems/rbi@0.2.1.rbi +4535 -0
  27. data/sorbet/rbi/gems/rbs@3.6.1.rbi +6857 -0
  28. data/sorbet/rbi/gems/regexp_parser@2.9.2.rbi +3772 -0
  29. data/sorbet/rbi/gems/rubocop-ast@1.36.2.rbi +7570 -0
  30. data/sorbet/rbi/gems/rubocop@1.69.0.rbi +59347 -0
  31. data/sorbet/rbi/gems/ruby-lsp@0.22.1.rbi +6119 -0
  32. data/sorbet/rbi/gems/ruby-progressbar@1.13.0.rbi +1318 -0
  33. data/sorbet/rbi/gems/spoom@1.5.0.rbi +4932 -0
  34. data/sorbet/rbi/gems/tapioca@0.16.5.rbi +3598 -0
  35. data/sorbet/rbi/gems/thor@1.3.2.rbi +4378 -0
  36. data/sorbet/rbi/gems/unicode-display_width@3.1.2.rbi +130 -0
  37. data/sorbet/rbi/gems/unicode-emoji@4.0.4.rbi +251 -0
  38. data/sorbet/rbi/gems/yard-sorbet@0.9.0.rbi +435 -0
  39. data/sorbet/rbi/gems/yard@0.9.37.rbi +18379 -0
  40. data/sorbet/tapioca/config.yml +13 -0
  41. data/sorbet/tapioca/require.rb +11 -0
  42. metadata +36 -2
@@ -0,0 +1,2209 @@
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
+ # Kernel extensions for minitest
9
+ #
10
+ # source://minitest/lib/minitest/spec.rb#46
11
+ module Kernel
12
+ private
13
+
14
+ # Describe a series of expectations for a given target +desc+.
15
+ #
16
+ # Defines a test class subclassing from either Minitest::Spec or
17
+ # from the surrounding describe's class. The surrounding class may
18
+ # subclass Minitest::Spec manually in order to easily share code:
19
+ #
20
+ # class MySpec < Minitest::Spec
21
+ # # ... shared code ...
22
+ # end
23
+ #
24
+ # class TestStuff < MySpec
25
+ # it "does stuff" do
26
+ # # shared code available here
27
+ # end
28
+ # describe "inner stuff" do
29
+ # it "still does stuff" do
30
+ # # ...and here
31
+ # end
32
+ # end
33
+ # end
34
+ #
35
+ # For more information on getting started with writing specs, see:
36
+ #
37
+ # http://www.rubyinside.com/a-minitestspec-tutorial-elegant-spec-style-testing-that-comes-with-ruby-5354.html
38
+ #
39
+ # For some suggestions on how to improve your specs, try:
40
+ #
41
+ # https://betterspecs.org
42
+ #
43
+ # but do note that several items there are debatable or specific to
44
+ # rspec.
45
+ #
46
+ # For more information about expectations, see Minitest::Expectations.
47
+ #
48
+ # source://minitest/lib/minitest/spec.rb#82
49
+ def describe(desc, *additional_desc, &block); end
50
+ end
51
+
52
+ # The top-level namespace for Minitest. Also the location of the main
53
+ # runtime. See +Minitest.run+ for more information.
54
+ #
55
+ # source://minitest/lib/minitest/parallel.rb#1
56
+ module Minitest
57
+ class << self
58
+ # Internal run method. Responsible for telling all Runnable
59
+ # sub-classes to run.
60
+ #
61
+ # source://minitest/lib/minitest.rb#323
62
+ def __run(reporter, options); end
63
+
64
+ # A simple hook allowing you to run a block of code after everything
65
+ # is done running. Eg:
66
+ #
67
+ # Minitest.after_run { p $debugging_info }
68
+ #
69
+ # source://minitest/lib/minitest.rb#97
70
+ def after_run(&block); end
71
+
72
+ # source://minitest/lib/minitest.rb#20
73
+ def allow_fork; end
74
+
75
+ # source://minitest/lib/minitest.rb#20
76
+ def allow_fork=(_arg0); end
77
+
78
+ # Registers Minitest to run at process exit
79
+ #
80
+ # source://minitest/lib/minitest.rb#70
81
+ def autorun; end
82
+
83
+ # source://minitest/lib/minitest.rb#20
84
+ def backtrace_filter; end
85
+
86
+ # source://minitest/lib/minitest.rb#20
87
+ def backtrace_filter=(_arg0); end
88
+
89
+ # source://minitest/lib/minitest.rb#19
90
+ def cattr_accessor(name); end
91
+
92
+ # source://minitest/lib/minitest.rb#1216
93
+ def clock_time; end
94
+
95
+ # source://minitest/lib/minitest.rb#303
96
+ def empty_run!(options); end
97
+
98
+ # source://minitest/lib/minitest.rb#20
99
+ def extensions; end
100
+
101
+ # source://minitest/lib/minitest.rb#20
102
+ def extensions=(_arg0); end
103
+
104
+ # source://minitest/lib/minitest.rb#336
105
+ def filter_backtrace(bt); end
106
+
107
+ # source://minitest/lib/minitest.rb#20
108
+ def info_signal; end
109
+
110
+ # source://minitest/lib/minitest.rb#20
111
+ def info_signal=(_arg0); end
112
+
113
+ # source://minitest/lib/minitest.rb#125
114
+ def init_plugins(options); end
115
+
116
+ # source://minitest/lib/minitest.rb#109
117
+ def load_plugins; end
118
+
119
+ # source://minitest/lib/minitest.rb#20
120
+ def parallel_executor; end
121
+
122
+ # source://minitest/lib/minitest.rb#20
123
+ def parallel_executor=(_arg0); end
124
+
125
+ # source://minitest/lib/minitest.rb#143
126
+ def process_args(args = T.unsafe(nil)); end
127
+
128
+ # Register a plugin to be used. Does NOT require / load it.
129
+ #
130
+ # source://minitest/lib/minitest.rb#104
131
+ def register_plugin(name_or_mod); end
132
+
133
+ # source://minitest/lib/minitest.rb#20
134
+ def reporter; end
135
+
136
+ # source://minitest/lib/minitest.rb#20
137
+ def reporter=(_arg0); end
138
+
139
+ # This is the top-level run method. Everything starts from here. It
140
+ # tells each Runnable sub-class to run, and each of those are
141
+ # responsible for doing whatever they do.
142
+ #
143
+ # The overall structure of a run looks like this:
144
+ #
145
+ # Minitest.autorun
146
+ # Minitest.run(args)
147
+ # Minitest.load_plugins
148
+ # Minitest.process_args
149
+ # Minitest.init_plugins
150
+ # Minitest.__run(reporter, options)
151
+ # Runnable.runnables.each
152
+ # runnable_klass.run(reporter, options)
153
+ # self.runnable_methods.each
154
+ # self.run_one_method(self, runnable_method, reporter)
155
+ # Minitest.run_one_method(klass, runnable_method)
156
+ # klass.new(runnable_method).run
157
+ #
158
+ # source://minitest/lib/minitest.rb#269
159
+ def run(args = T.unsafe(nil)); end
160
+
161
+ # source://minitest/lib/minitest.rb#1207
162
+ def run_one_method(klass, method_name); end
163
+
164
+ # source://minitest/lib/minitest.rb#20
165
+ def seed; end
166
+
167
+ # source://minitest/lib/minitest.rb#20
168
+ def seed=(_arg0); end
169
+ end
170
+ end
171
+
172
+ # Defines the API for Reporters. Subclass this and override whatever
173
+ # you want. Go nuts.
174
+ #
175
+ # source://minitest/lib/minitest.rb#687
176
+ class Minitest::AbstractReporter
177
+ # @return [AbstractReporter] a new instance of AbstractReporter
178
+ #
179
+ # source://minitest/lib/minitest.rb#689
180
+ def initialize; end
181
+
182
+ # Did this run pass?
183
+ #
184
+ # @return [Boolean]
185
+ #
186
+ # source://minitest/lib/minitest.rb#724
187
+ def passed?; end
188
+
189
+ # About to start running a test. This allows a reporter to show
190
+ # that it is starting or that we are in the middle of a test run.
191
+ #
192
+ # source://minitest/lib/minitest.rb#703
193
+ def prerecord(klass, name); end
194
+
195
+ # Output and record the result of the test. Call
196
+ # {result#result_code}[rdoc-ref:Runnable#result_code] to get the
197
+ # result character string. Stores the result of the run if the run
198
+ # did not pass.
199
+ #
200
+ # source://minitest/lib/minitest.rb#712
201
+ def record(result); end
202
+
203
+ # Outputs the summary of the run.
204
+ #
205
+ # source://minitest/lib/minitest.rb#718
206
+ def report; end
207
+
208
+ # Starts reporting on the run.
209
+ #
210
+ # source://minitest/lib/minitest.rb#696
211
+ def start; end
212
+
213
+ # source://minitest/lib/minitest.rb#728
214
+ def synchronize(&block); end
215
+ end
216
+
217
+ # Represents run failures.
218
+ #
219
+ # source://minitest/lib/minitest.rb#1020
220
+ class Minitest::Assertion < ::Exception
221
+ # source://minitest/lib/minitest.rb#1023
222
+ def error; end
223
+
224
+ # Where was this run before an assertion was raised?
225
+ #
226
+ # source://minitest/lib/minitest.rb#1030
227
+ def location; end
228
+
229
+ # source://minitest/lib/minitest.rb#1038
230
+ def result_code; end
231
+
232
+ # source://minitest/lib/minitest.rb#1042
233
+ def result_label; end
234
+ end
235
+
236
+ # source://minitest/lib/minitest.rb#1021
237
+ Minitest::Assertion::RE = T.let(T.unsafe(nil), Regexp)
238
+
239
+ # Minitest Assertions. All assertion methods accept a +msg+ which is
240
+ # printed if the assertion fails.
241
+ #
242
+ # Protocol: Nearly everything here boils up to +assert+, which
243
+ # expects to be able to increment an instance accessor named
244
+ # +assertions+. This is not provided by Assertions and must be
245
+ # provided by the thing including Assertions. See Minitest::Runnable
246
+ # for an example.
247
+ #
248
+ # source://minitest/lib/minitest/assertions.rb#16
249
+ module Minitest::Assertions
250
+ # source://minitest/lib/minitest/assertions.rb#181
251
+ def _synchronize; end
252
+
253
+ # source://minitest/lib/minitest/assertions.rb#194
254
+ def _where; end
255
+
256
+ # Fails unless +test+ is truthy.
257
+ #
258
+ # source://minitest/lib/minitest/assertions.rb#171
259
+ def assert(test, msg = T.unsafe(nil)); end
260
+
261
+ # Fails unless +obj+ is empty.
262
+ #
263
+ # source://minitest/lib/minitest/assertions.rb#188
264
+ def assert_empty(obj, msg = T.unsafe(nil)); end
265
+
266
+ # Fails unless <tt>exp == act</tt> printing the difference between
267
+ # the two, if possible.
268
+ #
269
+ # If there is no visible difference but the assertion fails, you
270
+ # should suspect that your #== is buggy, or your inspect output is
271
+ # missing crucial details. For nicer structural diffing, set
272
+ # Minitest::Test.make_my_diffs_pretty!
273
+ #
274
+ # For floats use assert_in_delta.
275
+ #
276
+ # See also: Minitest::Assertions.diff
277
+ #
278
+ # source://minitest/lib/minitest/assertions.rb#214
279
+ def assert_equal(exp, act, msg = T.unsafe(nil)); end
280
+
281
+ # For comparing Floats. Fails unless +exp+ and +act+ are within +delta+
282
+ # of each other.
283
+ #
284
+ # assert_in_delta Math::PI, (22.0 / 7.0), 0.01
285
+ #
286
+ # source://minitest/lib/minitest/assertions.rb#235
287
+ def assert_in_delta(exp, act, delta = T.unsafe(nil), msg = T.unsafe(nil)); end
288
+
289
+ # For comparing Floats. Fails unless +exp+ and +act+ have a relative
290
+ # error less than +epsilon+.
291
+ #
292
+ # source://minitest/lib/minitest/assertions.rb#247
293
+ def assert_in_epsilon(exp, act, epsilon = T.unsafe(nil), msg = T.unsafe(nil)); end
294
+
295
+ # Fails unless +collection+ includes +obj+.
296
+ #
297
+ # source://minitest/lib/minitest/assertions.rb#254
298
+ def assert_includes(collection, obj, msg = T.unsafe(nil)); end
299
+
300
+ # Fails unless +obj+ is an instance of +cls+.
301
+ #
302
+ # source://minitest/lib/minitest/assertions.rb#265
303
+ def assert_instance_of(cls, obj, msg = T.unsafe(nil)); end
304
+
305
+ # Fails unless +obj+ is a kind of +cls+.
306
+ #
307
+ # source://minitest/lib/minitest/assertions.rb#276
308
+ def assert_kind_of(cls, obj, msg = T.unsafe(nil)); end
309
+
310
+ # Fails unless +matcher+ <tt>=~</tt> +obj+.
311
+ #
312
+ # source://minitest/lib/minitest/assertions.rb#287
313
+ def assert_match(matcher, obj, msg = T.unsafe(nil)); end
314
+
315
+ # Assert that the mock verifies correctly.
316
+ #
317
+ # source://minitest/lib/minitest/mock.rb#253
318
+ def assert_mock(mock); end
319
+
320
+ # Fails unless +obj+ is nil
321
+ #
322
+ # source://minitest/lib/minitest/assertions.rb#299
323
+ def assert_nil(obj, msg = T.unsafe(nil)); end
324
+
325
+ # For testing with binary operators. Eg:
326
+ #
327
+ # assert_operator 5, :<=, 4
328
+ #
329
+ # source://minitest/lib/minitest/assertions.rb#309
330
+ def assert_operator(o1, op, o2 = T.unsafe(nil), msg = T.unsafe(nil)); end
331
+
332
+ # Fails if stdout or stderr do not output the expected results.
333
+ # Pass in nil if you don't care about that streams output. Pass in
334
+ # "" if you require it to be silent. Pass in a regexp if you want
335
+ # to pattern match.
336
+ #
337
+ # assert_output(/hey/) { method_with_output }
338
+ #
339
+ # NOTE: this uses #capture_io, not #capture_subprocess_io.
340
+ #
341
+ # See also: #assert_silent
342
+ #
343
+ # source://minitest/lib/minitest/assertions.rb#327
344
+ def assert_output(stdout = T.unsafe(nil), stderr = T.unsafe(nil)); end
345
+
346
+ # Fails unless +path+ exists.
347
+ #
348
+ # source://minitest/lib/minitest/assertions.rb#351
349
+ def assert_path_exists(path, msg = T.unsafe(nil)); end
350
+
351
+ # For testing with pattern matching (only supported with Ruby 3.0 and later)
352
+ #
353
+ # # pass
354
+ # assert_pattern { [1,2,3] => [Integer, Integer, Integer] }
355
+ #
356
+ # # fail "length mismatch (given 3, expected 1)"
357
+ # assert_pattern { [1,2,3] => [Integer] }
358
+ #
359
+ # The bare <tt>=></tt> pattern will raise a NoMatchingPatternError on failure, which would
360
+ # normally be counted as a test error. This assertion rescues NoMatchingPatternError and
361
+ # generates a test failure. Any other exception will be raised as normal and generate a test
362
+ # error.
363
+ #
364
+ # @raise [NotImplementedError]
365
+ #
366
+ # source://minitest/lib/minitest/assertions.rb#370
367
+ def assert_pattern; end
368
+
369
+ # For testing with predicates. Eg:
370
+ #
371
+ # assert_predicate str, :empty?
372
+ #
373
+ # This is really meant for specs and is front-ended by assert_operator:
374
+ #
375
+ # str.must_be :empty?
376
+ #
377
+ # source://minitest/lib/minitest/assertions.rb#391
378
+ def assert_predicate(o1, op, msg = T.unsafe(nil)); end
379
+
380
+ # Fails unless the block raises one of +exp+. Returns the
381
+ # exception matched so you can check the message, attributes, etc.
382
+ #
383
+ # +exp+ takes an optional message on the end to help explain
384
+ # failures and defaults to StandardError if no exception class is
385
+ # passed. Eg:
386
+ #
387
+ # assert_raises(CustomError) { method_with_custom_error }
388
+ #
389
+ # With custom error message:
390
+ #
391
+ # assert_raises(CustomError, 'This should have raised CustomError') { method_with_custom_error }
392
+ #
393
+ # Using the returned object:
394
+ #
395
+ # error = assert_raises(CustomError) do
396
+ # raise CustomError, 'This is really bad'
397
+ # end
398
+ #
399
+ # assert_equal 'This is really bad', error.message
400
+ #
401
+ # source://minitest/lib/minitest/assertions.rb#418
402
+ def assert_raises(*exp); end
403
+
404
+ # Fails unless +obj+ responds to +meth+.
405
+ # include_all defaults to false to match Object#respond_to?
406
+ #
407
+ # source://minitest/lib/minitest/assertions.rb#450
408
+ def assert_respond_to(obj, meth, msg = T.unsafe(nil), include_all: T.unsafe(nil)); end
409
+
410
+ # Fails unless +exp+ and +act+ are #equal?
411
+ #
412
+ # source://minitest/lib/minitest/assertions.rb#460
413
+ def assert_same(exp, act, msg = T.unsafe(nil)); end
414
+
415
+ # +send_ary+ is a receiver, message and arguments.
416
+ #
417
+ # Fails unless the call returns a true value
418
+ #
419
+ # source://minitest/lib/minitest/assertions.rb#473
420
+ def assert_send(send_ary, m = T.unsafe(nil)); end
421
+
422
+ # Fails if the block outputs anything to stderr or stdout.
423
+ #
424
+ # See also: #assert_output
425
+ #
426
+ # source://minitest/lib/minitest/assertions.rb#488
427
+ def assert_silent; end
428
+
429
+ # Fails unless the block throws +sym+
430
+ #
431
+ # source://minitest/lib/minitest/assertions.rb#497
432
+ def assert_throws(sym, msg = T.unsafe(nil)); end
433
+
434
+ # Captures $stdout and $stderr into strings:
435
+ #
436
+ # out, err = capture_io do
437
+ # puts "Some info"
438
+ # warn "You did a bad thing"
439
+ # end
440
+ #
441
+ # assert_match %r%info%, out
442
+ # assert_match %r%bad%, err
443
+ #
444
+ # NOTE: For efficiency, this method uses StringIO and does not
445
+ # capture IO for subprocesses. Use #capture_subprocess_io for
446
+ # that.
447
+ #
448
+ # source://minitest/lib/minitest/assertions.rb#538
449
+ def capture_io; end
450
+
451
+ # Captures $stdout and $stderr into strings, using Tempfile to
452
+ # ensure that subprocess IO is captured as well.
453
+ #
454
+ # out, err = capture_subprocess_io do
455
+ # system "echo Some info"
456
+ # system "echo You did a bad thing 1>&2"
457
+ # end
458
+ #
459
+ # assert_match %r%info%, out
460
+ # assert_match %r%bad%, err
461
+ #
462
+ # NOTE: This method is approximately 10x slower than #capture_io so
463
+ # only use it when you need to test the output of a subprocess.
464
+ #
465
+ # source://minitest/lib/minitest/assertions.rb#571
466
+ def capture_subprocess_io; end
467
+
468
+ # Returns a diff between +exp+ and +act+. If there is no known
469
+ # diff command or if it doesn't make sense to diff the output
470
+ # (single line, short output), then it simply returns a basic
471
+ # comparison between the two.
472
+ #
473
+ # See +things_to_diff+ for more info.
474
+ #
475
+ # source://minitest/lib/minitest/assertions.rb#57
476
+ def diff(exp, act); end
477
+
478
+ # Returns details for exception +e+
479
+ #
480
+ # source://minitest/lib/minitest/assertions.rb#603
481
+ def exception_details(e, msg); end
482
+
483
+ # Fails after a given date (in the local time zone). This allows
484
+ # you to put time-bombs in your tests if you need to keep
485
+ # something around until a later date lest you forget about it.
486
+ #
487
+ # source://minitest/lib/minitest/assertions.rb#619
488
+ def fail_after(y, m, d, msg); end
489
+
490
+ # Fails with +msg+.
491
+ #
492
+ # source://minitest/lib/minitest/assertions.rb#626
493
+ def flunk(msg = T.unsafe(nil)); end
494
+
495
+ # Returns a proc that will output +msg+ along with the default message.
496
+ #
497
+ # source://minitest/lib/minitest/assertions.rb#634
498
+ def message(msg = T.unsafe(nil), ending = T.unsafe(nil), &default); end
499
+
500
+ # This returns a human-readable version of +obj+. By default
501
+ # #inspect is called. You can override this to use #pretty_inspect
502
+ # if you want.
503
+ #
504
+ # See Minitest::Test.make_my_diffs_pretty!
505
+ #
506
+ # source://minitest/lib/minitest/assertions.rb#127
507
+ def mu_pp(obj); end
508
+
509
+ # This returns a diff-able more human-readable version of +obj+.
510
+ # This differs from the regular mu_pp because it expands escaped
511
+ # newlines and makes hex-values (like object_ids) generic. This
512
+ # uses mu_pp to do the first pass and then cleans it up.
513
+ #
514
+ # source://minitest/lib/minitest/assertions.rb#145
515
+ def mu_pp_for_diff(obj); end
516
+
517
+ # used for counting assertions
518
+ #
519
+ # source://minitest/lib/minitest/assertions.rb#645
520
+ def pass(_msg = T.unsafe(nil)); end
521
+
522
+ # Fails if +test+ is truthy.
523
+ #
524
+ # source://minitest/lib/minitest/assertions.rb#652
525
+ def refute(test, msg = T.unsafe(nil)); end
526
+
527
+ # Fails if +obj+ is empty.
528
+ #
529
+ # source://minitest/lib/minitest/assertions.rb#660
530
+ def refute_empty(obj, msg = T.unsafe(nil)); end
531
+
532
+ # Fails if <tt>exp == act</tt>.
533
+ #
534
+ # For floats use refute_in_delta.
535
+ #
536
+ # source://minitest/lib/minitest/assertions.rb#671
537
+ def refute_equal(exp, act, msg = T.unsafe(nil)); end
538
+
539
+ # For comparing Floats. Fails if +exp+ is within +delta+ of +act+.
540
+ #
541
+ # refute_in_delta Math::PI, (22.0 / 7.0)
542
+ #
543
+ # source://minitest/lib/minitest/assertions.rb#683
544
+ def refute_in_delta(exp, act, delta = T.unsafe(nil), msg = T.unsafe(nil)); end
545
+
546
+ # For comparing Floats. Fails if +exp+ and +act+ have a relative error
547
+ # less than +epsilon+.
548
+ #
549
+ # source://minitest/lib/minitest/assertions.rb#695
550
+ def refute_in_epsilon(a, b, epsilon = T.unsafe(nil), msg = T.unsafe(nil)); end
551
+
552
+ # Fails if +collection+ includes +obj+.
553
+ #
554
+ # source://minitest/lib/minitest/assertions.rb#702
555
+ def refute_includes(collection, obj, msg = T.unsafe(nil)); end
556
+
557
+ # Fails if +obj+ is an instance of +cls+.
558
+ #
559
+ # source://minitest/lib/minitest/assertions.rb#713
560
+ def refute_instance_of(cls, obj, msg = T.unsafe(nil)); end
561
+
562
+ # Fails if +obj+ is a kind of +cls+.
563
+ #
564
+ # source://minitest/lib/minitest/assertions.rb#723
565
+ def refute_kind_of(cls, obj, msg = T.unsafe(nil)); end
566
+
567
+ # Fails if +matcher+ <tt>=~</tt> +obj+.
568
+ #
569
+ # source://minitest/lib/minitest/assertions.rb#731
570
+ def refute_match(matcher, obj, msg = T.unsafe(nil)); end
571
+
572
+ # Fails if +obj+ is nil.
573
+ #
574
+ # source://minitest/lib/minitest/assertions.rb#741
575
+ def refute_nil(obj, msg = T.unsafe(nil)); end
576
+
577
+ # Fails if +o1+ is not +op+ +o2+. Eg:
578
+ #
579
+ # refute_operator 1, :>, 2 #=> pass
580
+ # refute_operator 1, :<, 2 #=> fail
581
+ #
582
+ # source://minitest/lib/minitest/assertions.rb#776
583
+ def refute_operator(o1, op, o2 = T.unsafe(nil), msg = T.unsafe(nil)); end
584
+
585
+ # Fails if +path+ exists.
586
+ #
587
+ # source://minitest/lib/minitest/assertions.rb#785
588
+ def refute_path_exists(path, msg = T.unsafe(nil)); end
589
+
590
+ # For testing with pattern matching (only supported with Ruby 3.0 and later)
591
+ #
592
+ # # pass
593
+ # refute_pattern { [1,2,3] => [String] }
594
+ #
595
+ # # fail "NoMatchingPatternError expected, but nothing was raised."
596
+ # refute_pattern { [1,2,3] => [Integer, Integer, Integer] }
597
+ #
598
+ # This assertion expects a NoMatchingPatternError exception, and will fail if none is raised. Any
599
+ # other exceptions will be raised as normal and generate a test error.
600
+ #
601
+ # @raise [NotImplementedError]
602
+ #
603
+ # source://minitest/lib/minitest/assertions.rb#758
604
+ def refute_pattern; end
605
+
606
+ # For testing with predicates.
607
+ #
608
+ # refute_predicate str, :empty?
609
+ #
610
+ # This is really meant for specs and is front-ended by refute_operator:
611
+ #
612
+ # str.wont_be :empty?
613
+ #
614
+ # source://minitest/lib/minitest/assertions.rb#799
615
+ def refute_predicate(o1, op, msg = T.unsafe(nil)); end
616
+
617
+ # Fails if +obj+ responds to the message +meth+.
618
+ # include_all defaults to false to match Object#respond_to?
619
+ #
620
+ # source://minitest/lib/minitest/assertions.rb#808
621
+ def refute_respond_to(obj, meth, msg = T.unsafe(nil), include_all: T.unsafe(nil)); end
622
+
623
+ # Fails if +exp+ is the same (by object identity) as +act+.
624
+ #
625
+ # source://minitest/lib/minitest/assertions.rb#817
626
+ def refute_same(exp, act, msg = T.unsafe(nil)); end
627
+
628
+ # Skips the current run. If run in verbose-mode, the skipped run
629
+ # gets listed at the end of the run but doesn't cause a failure
630
+ # exit code.
631
+ #
632
+ # @raise [Minitest::Skip]
633
+ #
634
+ # source://minitest/lib/minitest/assertions.rb#830
635
+ def skip(msg = T.unsafe(nil), _ignored = T.unsafe(nil)); end
636
+
637
+ # Skips the current run until a given date (in the local time
638
+ # zone). This allows you to put some fixes on hold until a later
639
+ # date, but still holds you accountable and prevents you from
640
+ # forgetting it.
641
+ #
642
+ # source://minitest/lib/minitest/assertions.rb#842
643
+ def skip_until(y, m, d, msg); end
644
+
645
+ # Was this testcase skipped? Meant for #teardown.
646
+ #
647
+ # @return [Boolean]
648
+ #
649
+ # source://minitest/lib/minitest/assertions.rb#851
650
+ def skipped?; end
651
+
652
+ # Returns things to diff [expect, butwas], or [nil, nil] if nothing to diff.
653
+ #
654
+ # Criterion:
655
+ #
656
+ # 1. Strings include newlines or escaped newlines, but not both.
657
+ # 2. or: String lengths are > 30 characters.
658
+ # 3. or: Strings are equal to each other (but maybe different encodings?).
659
+ # 4. and: we found a diff executable.
660
+ #
661
+ # source://minitest/lib/minitest/assertions.rb#102
662
+ def things_to_diff(exp, act); end
663
+
664
+ class << self
665
+ # Returns the diff command to use in #diff. Tries to intelligently
666
+ # figure out what diff to use.
667
+ #
668
+ # source://minitest/lib/minitest/assertions.rb#27
669
+ def diff; end
670
+
671
+ # Set the diff command to use in #diff.
672
+ #
673
+ # source://minitest/lib/minitest/assertions.rb#45
674
+ def diff=(o); end
675
+ end
676
+ end
677
+
678
+ # source://minitest/lib/minitest/assertions.rb#199
679
+ Minitest::Assertions::E = T.let(T.unsafe(nil), String)
680
+
681
+ # source://minitest/lib/minitest/assertions.rb#17
682
+ Minitest::Assertions::UNDEFINED = T.let(T.unsafe(nil), Object)
683
+
684
+ # The standard backtrace filter for minitest.
685
+ #
686
+ # See Minitest.backtrace_filter=.
687
+ #
688
+ # source://minitest/lib/minitest.rb#1175
689
+ class Minitest::BacktraceFilter
690
+ # @return [BacktraceFilter] a new instance of BacktraceFilter
691
+ #
692
+ # source://minitest/lib/minitest.rb#1184
693
+ def initialize(regexp = T.unsafe(nil)); end
694
+
695
+ # Filter +bt+ to something useful. Returns the whole thing if
696
+ # $DEBUG (ruby) or $MT_DEBUG (env).
697
+ #
698
+ # source://minitest/lib/minitest.rb#1192
699
+ def filter(bt); end
700
+
701
+ # The regular expression to use to filter backtraces. Defaults to +MT_RE+.
702
+ #
703
+ # source://minitest/lib/minitest.rb#1182
704
+ def regexp; end
705
+
706
+ # The regular expression to use to filter backtraces. Defaults to +MT_RE+.
707
+ #
708
+ # source://minitest/lib/minitest.rb#1182
709
+ def regexp=(_arg0); end
710
+ end
711
+
712
+ # source://minitest/lib/minitest.rb#1177
713
+ Minitest::BacktraceFilter::MT_RE = T.let(T.unsafe(nil), Regexp)
714
+
715
+ # Dispatch to multiple reporters as one.
716
+ #
717
+ # source://minitest/lib/minitest.rb#969
718
+ class Minitest::CompositeReporter < ::Minitest::AbstractReporter
719
+ # @return [CompositeReporter] a new instance of CompositeReporter
720
+ #
721
+ # source://minitest/lib/minitest.rb#975
722
+ def initialize(*reporters); end
723
+
724
+ # Add another reporter to the mix.
725
+ #
726
+ # source://minitest/lib/minitest.rb#987
727
+ def <<(reporter); end
728
+
729
+ # source://minitest/lib/minitest.rb#980
730
+ def io; end
731
+
732
+ # @return [Boolean]
733
+ #
734
+ # source://minitest/lib/minitest.rb#991
735
+ def passed?; end
736
+
737
+ # source://minitest/lib/minitest.rb#999
738
+ def prerecord(klass, name); end
739
+
740
+ # source://minitest/lib/minitest.rb#1006
741
+ def record(result); end
742
+
743
+ # source://minitest/lib/minitest.rb#1012
744
+ def report; end
745
+
746
+ # The list of reporters to dispatch to.
747
+ #
748
+ # source://minitest/lib/minitest.rb#973
749
+ def reporters; end
750
+
751
+ # The list of reporters to dispatch to.
752
+ #
753
+ # source://minitest/lib/minitest.rb#973
754
+ def reporters=(_arg0); end
755
+
756
+ # source://minitest/lib/minitest.rb#995
757
+ def start; end
758
+ end
759
+
760
+ # Compresses backtraces.
761
+ #
762
+ # source://minitest/lib/minitest/compress.rb#5
763
+ module Minitest::Compress
764
+ # Takes a backtrace (array of strings) and compresses repeating
765
+ # cycles in it to make it more readable.
766
+ #
767
+ # source://minitest/lib/minitest/compress.rb#11
768
+ def compress(orig); end
769
+ end
770
+
771
+ # source://minitest/lib/minitest/spec.rb#41
772
+ class Minitest::Expectation < ::Struct
773
+ def ctx; end
774
+ def ctx=(_); end
775
+
776
+ # source://minitest/lib/minitest/spec.rb#25
777
+ def must_be(*args, **_arg1); end
778
+
779
+ # source://minitest/lib/minitest/spec.rb#25
780
+ def must_be_close_to(*args, **_arg1); end
781
+
782
+ # source://minitest/lib/minitest/spec.rb#25
783
+ def must_be_empty(*args, **_arg1); end
784
+
785
+ # source://minitest/lib/minitest/spec.rb#25
786
+ def must_be_instance_of(*args, **_arg1); end
787
+
788
+ # source://minitest/lib/minitest/spec.rb#25
789
+ def must_be_kind_of(*args, **_arg1); end
790
+
791
+ # source://minitest/lib/minitest/spec.rb#25
792
+ def must_be_nil(*args, **_arg1); end
793
+
794
+ # source://minitest/lib/minitest/spec.rb#25
795
+ def must_be_same_as(*args, **_arg1); end
796
+
797
+ # source://minitest/lib/minitest/spec.rb#25
798
+ def must_be_silent(*args, **_arg1); end
799
+
800
+ # source://minitest/lib/minitest/spec.rb#25
801
+ def must_be_within_delta(*args, **_arg1); end
802
+
803
+ # source://minitest/lib/minitest/spec.rb#25
804
+ def must_be_within_epsilon(*args, **_arg1); end
805
+
806
+ # source://minitest/lib/minitest/spec.rb#25
807
+ def must_equal(*args, **_arg1); end
808
+
809
+ # source://minitest/lib/minitest/spec.rb#25
810
+ def must_include(*args, **_arg1); end
811
+
812
+ # source://minitest/lib/minitest/spec.rb#25
813
+ def must_match(*args, **_arg1); end
814
+
815
+ # source://minitest/lib/minitest/spec.rb#25
816
+ def must_output(*args, **_arg1); end
817
+
818
+ # source://minitest/lib/minitest/spec.rb#25
819
+ def must_pattern_match(*args, **_arg1); end
820
+
821
+ # source://minitest/lib/minitest/spec.rb#25
822
+ def must_raise(*args, **_arg1); end
823
+
824
+ # source://minitest/lib/minitest/spec.rb#25
825
+ def must_respond_to(*args, **_arg1); end
826
+
827
+ # source://minitest/lib/minitest/spec.rb#25
828
+ def must_throw(*args, **_arg1); end
829
+
830
+ # source://minitest/lib/minitest/spec.rb#25
831
+ def path_must_exist(*args, **_arg1); end
832
+
833
+ # source://minitest/lib/minitest/spec.rb#25
834
+ def path_wont_exist(*args, **_arg1); end
835
+
836
+ def target; end
837
+ def target=(_); end
838
+
839
+ # source://minitest/lib/minitest/spec.rb#25
840
+ def wont_be(*args, **_arg1); end
841
+
842
+ # source://minitest/lib/minitest/spec.rb#25
843
+ def wont_be_close_to(*args, **_arg1); end
844
+
845
+ # source://minitest/lib/minitest/spec.rb#25
846
+ def wont_be_empty(*args, **_arg1); end
847
+
848
+ # source://minitest/lib/minitest/spec.rb#25
849
+ def wont_be_instance_of(*args, **_arg1); end
850
+
851
+ # source://minitest/lib/minitest/spec.rb#25
852
+ def wont_be_kind_of(*args, **_arg1); end
853
+
854
+ # source://minitest/lib/minitest/spec.rb#25
855
+ def wont_be_nil(*args, **_arg1); end
856
+
857
+ # source://minitest/lib/minitest/spec.rb#25
858
+ def wont_be_same_as(*args, **_arg1); end
859
+
860
+ # source://minitest/lib/minitest/spec.rb#25
861
+ def wont_be_within_delta(*args, **_arg1); end
862
+
863
+ # source://minitest/lib/minitest/spec.rb#25
864
+ def wont_be_within_epsilon(*args, **_arg1); end
865
+
866
+ # source://minitest/lib/minitest/spec.rb#25
867
+ def wont_equal(*args, **_arg1); end
868
+
869
+ # source://minitest/lib/minitest/spec.rb#25
870
+ def wont_include(*args, **_arg1); end
871
+
872
+ # source://minitest/lib/minitest/spec.rb#25
873
+ def wont_match(*args, **_arg1); end
874
+
875
+ # source://minitest/lib/minitest/spec.rb#25
876
+ def wont_pattern_match(*args, **_arg1); end
877
+
878
+ # source://minitest/lib/minitest/spec.rb#25
879
+ def wont_respond_to(*args, **_arg1); end
880
+
881
+ class << self
882
+ def [](*_arg0); end
883
+ def inspect; end
884
+ def keyword_init?; end
885
+ def members; end
886
+ def new(*_arg0); end
887
+ end
888
+ end
889
+
890
+ # It's where you hide your "assertions".
891
+ #
892
+ # Please note, because of the way that expectations are implemented,
893
+ # all expectations (eg must_equal) are dependent upon a thread local
894
+ # variable +:current_spec+. If your specs rely on mixing threads into
895
+ # the specs themselves, you're better off using assertions or the new
896
+ # _(value) wrapper. For example:
897
+ #
898
+ # it "should still work in threads" do
899
+ # my_threaded_thingy do
900
+ # (1+1).must_equal 2 # bad
901
+ # assert_equal 2, 1+1 # good
902
+ # _(1 + 1).must_equal 2 # good
903
+ # value(1 + 1).must_equal 2 # good, also #expect
904
+ # _ { 1 + "1" }.must_raise TypeError # good
905
+ # end
906
+ # end
907
+ #
908
+ # source://minitest/lib/minitest/expectations.rb#20
909
+ module Minitest::Expectations
910
+ # source://minitest/lib/minitest/spec.rb#15
911
+ def must_be(*args, **_arg1); end
912
+
913
+ # source://minitest/lib/minitest/spec.rb#15
914
+ def must_be_close_to(*args, **_arg1); end
915
+
916
+ # source://minitest/lib/minitest/spec.rb#15
917
+ def must_be_empty(*args, **_arg1); end
918
+
919
+ # source://minitest/lib/minitest/spec.rb#15
920
+ def must_be_instance_of(*args, **_arg1); end
921
+
922
+ # source://minitest/lib/minitest/spec.rb#15
923
+ def must_be_kind_of(*args, **_arg1); end
924
+
925
+ # source://minitest/lib/minitest/spec.rb#15
926
+ def must_be_nil(*args, **_arg1); end
927
+
928
+ # source://minitest/lib/minitest/spec.rb#15
929
+ def must_be_same_as(*args, **_arg1); end
930
+
931
+ # source://minitest/lib/minitest/spec.rb#15
932
+ def must_be_silent(*args, **_arg1); end
933
+
934
+ # source://minitest/lib/minitest/spec.rb#15
935
+ def must_be_within_delta(*args, **_arg1); end
936
+
937
+ # source://minitest/lib/minitest/spec.rb#15
938
+ def must_be_within_epsilon(*args, **_arg1); end
939
+
940
+ # source://minitest/lib/minitest/spec.rb#15
941
+ def must_equal(*args, **_arg1); end
942
+
943
+ # source://minitest/lib/minitest/spec.rb#15
944
+ def must_include(*args, **_arg1); end
945
+
946
+ # source://minitest/lib/minitest/spec.rb#15
947
+ def must_match(*args, **_arg1); end
948
+
949
+ # source://minitest/lib/minitest/spec.rb#15
950
+ def must_output(*args, **_arg1); end
951
+
952
+ # source://minitest/lib/minitest/spec.rb#15
953
+ def must_pattern_match(*args, **_arg1); end
954
+
955
+ # source://minitest/lib/minitest/spec.rb#15
956
+ def must_raise(*args, **_arg1); end
957
+
958
+ # source://minitest/lib/minitest/spec.rb#15
959
+ def must_respond_to(*args, **_arg1); end
960
+
961
+ # source://minitest/lib/minitest/spec.rb#15
962
+ def must_throw(*args, **_arg1); end
963
+
964
+ # source://minitest/lib/minitest/spec.rb#15
965
+ def path_must_exist(*args, **_arg1); end
966
+
967
+ # source://minitest/lib/minitest/spec.rb#15
968
+ def path_wont_exist(*args, **_arg1); end
969
+
970
+ # source://minitest/lib/minitest/spec.rb#15
971
+ def wont_be(*args, **_arg1); end
972
+
973
+ # source://minitest/lib/minitest/spec.rb#15
974
+ def wont_be_close_to(*args, **_arg1); end
975
+
976
+ # source://minitest/lib/minitest/spec.rb#15
977
+ def wont_be_empty(*args, **_arg1); end
978
+
979
+ # source://minitest/lib/minitest/spec.rb#15
980
+ def wont_be_instance_of(*args, **_arg1); end
981
+
982
+ # source://minitest/lib/minitest/spec.rb#15
983
+ def wont_be_kind_of(*args, **_arg1); end
984
+
985
+ # source://minitest/lib/minitest/spec.rb#15
986
+ def wont_be_nil(*args, **_arg1); end
987
+
988
+ # source://minitest/lib/minitest/spec.rb#15
989
+ def wont_be_same_as(*args, **_arg1); end
990
+
991
+ # source://minitest/lib/minitest/spec.rb#15
992
+ def wont_be_within_delta(*args, **_arg1); end
993
+
994
+ # source://minitest/lib/minitest/spec.rb#15
995
+ def wont_be_within_epsilon(*args, **_arg1); end
996
+
997
+ # source://minitest/lib/minitest/spec.rb#15
998
+ def wont_equal(*args, **_arg1); end
999
+
1000
+ # source://minitest/lib/minitest/spec.rb#15
1001
+ def wont_include(*args, **_arg1); end
1002
+
1003
+ # source://minitest/lib/minitest/spec.rb#15
1004
+ def wont_match(*args, **_arg1); end
1005
+
1006
+ # source://minitest/lib/minitest/spec.rb#15
1007
+ def wont_pattern_match(*args, **_arg1); end
1008
+
1009
+ # source://minitest/lib/minitest/spec.rb#15
1010
+ def wont_respond_to(*args, **_arg1); end
1011
+ end
1012
+
1013
+ # Provides a simple set of guards that you can use in your tests
1014
+ # to skip execution if it is not applicable. These methods are
1015
+ # mixed into Test as both instance and class methods so you
1016
+ # can use them inside or outside of the test methods.
1017
+ #
1018
+ # def test_something_for_mri
1019
+ # skip "bug 1234" if jruby?
1020
+ # # ...
1021
+ # end
1022
+ #
1023
+ # if windows? then
1024
+ # # ... lots of test methods ...
1025
+ # end
1026
+ #
1027
+ # source://minitest/lib/minitest.rb#1119
1028
+ module Minitest::Guard
1029
+ # Is this running on jruby?
1030
+ #
1031
+ # @return [Boolean]
1032
+ #
1033
+ # source://minitest/lib/minitest.rb#1124
1034
+ def jruby?(platform = T.unsafe(nil)); end
1035
+
1036
+ # Is this running on maglev?
1037
+ #
1038
+ # @return [Boolean]
1039
+ #
1040
+ # source://minitest/lib/minitest.rb#1131
1041
+ def maglev?(platform = T.unsafe(nil)); end
1042
+
1043
+ # Is this running on mri?
1044
+ #
1045
+ # @return [Boolean]
1046
+ #
1047
+ # source://minitest/lib/minitest.rb#1141
1048
+ def mri?(platform = T.unsafe(nil)); end
1049
+
1050
+ # Is this running on macOS?
1051
+ #
1052
+ # @return [Boolean]
1053
+ #
1054
+ # source://minitest/lib/minitest.rb#1148
1055
+ def osx?(platform = T.unsafe(nil)); end
1056
+
1057
+ # Is this running on rubinius?
1058
+ #
1059
+ # @return [Boolean]
1060
+ #
1061
+ # source://minitest/lib/minitest.rb#1155
1062
+ def rubinius?(platform = T.unsafe(nil)); end
1063
+
1064
+ # Is this running on windows?
1065
+ #
1066
+ # @return [Boolean]
1067
+ #
1068
+ # source://minitest/lib/minitest.rb#1165
1069
+ def windows?(platform = T.unsafe(nil)); end
1070
+ end
1071
+
1072
+ # A simple and clean mock object framework.
1073
+ #
1074
+ # All mock objects are an instance of Mock
1075
+ #
1076
+ # source://minitest/lib/minitest/mock.rb#10
1077
+ class Minitest::Mock
1078
+ # @return [Mock] a new instance of Mock
1079
+ #
1080
+ # source://minitest/lib/minitest/mock.rb#53
1081
+ def initialize(delegator = T.unsafe(nil)); end
1082
+
1083
+ # source://minitest/lib/minitest/mock.rb#34
1084
+ def ===(*args, **kwargs, &b); end
1085
+
1086
+ # source://minitest/lib/minitest/mock.rb#125
1087
+ def __call(name, data); end
1088
+
1089
+ def __respond_to?(*_arg0); end
1090
+
1091
+ # source://minitest/lib/minitest/mock.rb#34
1092
+ def class(*args, **kwargs, &b); end
1093
+
1094
+ # Expect that method +name+ is called, optionally with +args+ (and
1095
+ # +kwargs+ or a +blk+), and returns +retval+.
1096
+ #
1097
+ # @mock.expect(:meaning_of_life, 42)
1098
+ # @mock.meaning_of_life # => 42
1099
+ #
1100
+ # @mock.expect(:do_something_with, true, [some_obj, true])
1101
+ # @mock.do_something_with(some_obj, true) # => true
1102
+ #
1103
+ # @mock.expect(:do_something_else, true) do |a1, a2|
1104
+ # a1 == "buggs" && a2 == :bunny
1105
+ # end
1106
+ #
1107
+ # +args+ is compared to the expected args using case equality (ie, the
1108
+ # '===' operator), allowing for less specific expectations.
1109
+ #
1110
+ # @mock.expect(:uses_any_string, true, [String])
1111
+ # @mock.uses_any_string("foo") # => true
1112
+ # @mock.verify # => true
1113
+ #
1114
+ # @mock.expect(:uses_one_string, true, ["foo"])
1115
+ # @mock.uses_one_string("bar") # => raises MockExpectationError
1116
+ #
1117
+ # If a method will be called multiple times, specify a new expect for each one.
1118
+ # They will be used in the order you define them.
1119
+ #
1120
+ # @mock.expect(:ordinal_increment, 'first')
1121
+ # @mock.expect(:ordinal_increment, 'second')
1122
+ #
1123
+ # @mock.ordinal_increment # => 'first'
1124
+ # @mock.ordinal_increment # => 'second'
1125
+ # @mock.ordinal_increment # => raises MockExpectationError "No more expects available for :ordinal_increment"
1126
+ #
1127
+ # source://minitest/lib/minitest/mock.rb#96
1128
+ def expect(name, retval, args = T.unsafe(nil), **kwargs, &blk); end
1129
+
1130
+ # source://minitest/lib/minitest/mock.rb#34
1131
+ def inspect(*args, **kwargs, &b); end
1132
+
1133
+ # source://minitest/lib/minitest/mock.rb#34
1134
+ def instance_eval(*args, **kwargs, &b); end
1135
+
1136
+ # source://minitest/lib/minitest/mock.rb#34
1137
+ def instance_variables(*args, **kwargs, &b); end
1138
+
1139
+ # source://minitest/lib/minitest/mock.rb#155
1140
+ def method_missing(sym, *args, **kwargs, &block); end
1141
+
1142
+ # source://minitest/lib/minitest/mock.rb#34
1143
+ def object_id(*args, **kwargs, &b); end
1144
+
1145
+ # source://minitest/lib/minitest/mock.rb#34
1146
+ def public_send(*args, **kwargs, &b); end
1147
+
1148
+ # @return [Boolean]
1149
+ #
1150
+ # source://minitest/lib/minitest/mock.rb#241
1151
+ def respond_to?(sym, include_private = T.unsafe(nil)); end
1152
+
1153
+ # source://minitest/lib/minitest/mock.rb#34
1154
+ def send(*args, **kwargs, &b); end
1155
+
1156
+ # source://minitest/lib/minitest/mock.rb#34
1157
+ def to_s(*args, **kwargs, &b); end
1158
+
1159
+ # Verify that all methods were called as expected. Raises
1160
+ # +MockExpectationError+ if the mock object was not called as
1161
+ # expected.
1162
+ #
1163
+ # source://minitest/lib/minitest/mock.rb#145
1164
+ def verify; end
1165
+
1166
+ private
1167
+
1168
+ # source://minitest/lib/minitest/mock.rb#34
1169
+ def respond_to_missing?(*args, **kwargs, &b); end
1170
+ end
1171
+
1172
+ # source://minitest/lib/minitest/parallel.rb#2
1173
+ module Minitest::Parallel; end
1174
+
1175
+ # The engine used to run multiple tests in parallel.
1176
+ #
1177
+ # source://minitest/lib/minitest/parallel.rb#7
1178
+ class Minitest::Parallel::Executor
1179
+ # Create a parallel test executor of with +size+ workers.
1180
+ #
1181
+ # @return [Executor] a new instance of Executor
1182
+ #
1183
+ # source://minitest/lib/minitest/parallel.rb#17
1184
+ def initialize(size); end
1185
+
1186
+ # Add a job to the queue
1187
+ #
1188
+ # source://minitest/lib/minitest/parallel.rb#43
1189
+ def <<(work); end
1190
+
1191
+ # Shuts down the pool of workers by signalling them to quit and
1192
+ # waiting for them all to finish what they're currently working
1193
+ # on.
1194
+ #
1195
+ # source://minitest/lib/minitest/parallel.rb#50
1196
+ def shutdown; end
1197
+
1198
+ # The size of the pool of workers.
1199
+ #
1200
+ # source://minitest/lib/minitest/parallel.rb#12
1201
+ def size; end
1202
+
1203
+ # Start the executor
1204
+ #
1205
+ # source://minitest/lib/minitest/parallel.rb#26
1206
+ def start; end
1207
+ end
1208
+
1209
+ # source://minitest/lib/minitest/parallel.rb#56
1210
+ module Minitest::Parallel::Test
1211
+ # source://minitest/lib/minitest/parallel.rb#57
1212
+ def _synchronize; end
1213
+ end
1214
+
1215
+ # source://minitest/lib/minitest/parallel.rb#59
1216
+ module Minitest::Parallel::Test::ClassMethods
1217
+ # source://minitest/lib/minitest/parallel.rb#60
1218
+ def run_one_method(klass, method_name, reporter); end
1219
+
1220
+ # source://minitest/lib/minitest/parallel.rb#64
1221
+ def test_order; end
1222
+ end
1223
+
1224
+ # A very simple reporter that prints the "dots" during the run.
1225
+ #
1226
+ # This is added to the top-level CompositeReporter at the start of
1227
+ # the run. If you want to change the output of minitest via a
1228
+ # plugin, pull this out of the composite and replace it with your
1229
+ # own.
1230
+ #
1231
+ # source://minitest/lib/minitest.rb#759
1232
+ class Minitest::ProgressReporter < ::Minitest::Reporter
1233
+ # source://minitest/lib/minitest.rb#760
1234
+ def prerecord(klass, name); end
1235
+
1236
+ # source://minitest/lib/minitest.rb#767
1237
+ def record(result); end
1238
+ end
1239
+
1240
+ # Shared code for anything that can get passed to a Reporter. See
1241
+ # Minitest::Test & Minitest::Result.
1242
+ #
1243
+ # source://minitest/lib/minitest.rb#581
1244
+ module Minitest::Reportable
1245
+ # @raise [NotImplementedError]
1246
+ #
1247
+ # source://minitest/lib/minitest.rb#603
1248
+ def class_name; end
1249
+
1250
+ # Did this run error?
1251
+ #
1252
+ # @return [Boolean]
1253
+ #
1254
+ # source://minitest/lib/minitest.rb#624
1255
+ def error?; end
1256
+
1257
+ # The location identifier of this test. Depends on a method
1258
+ # existing called class_name.
1259
+ #
1260
+ # source://minitest/lib/minitest.rb#598
1261
+ def location; end
1262
+
1263
+ # Did this run pass?
1264
+ #
1265
+ # Note: skipped runs are not considered passing, but they don't
1266
+ # cause the process to exit non-zero.
1267
+ #
1268
+ # @return [Boolean]
1269
+ #
1270
+ # source://minitest/lib/minitest.rb#588
1271
+ def passed?; end
1272
+
1273
+ # Returns ".", "F", or "E" based on the result of the run.
1274
+ #
1275
+ # source://minitest/lib/minitest.rb#610
1276
+ def result_code; end
1277
+
1278
+ # Was this run skipped?
1279
+ #
1280
+ # @return [Boolean]
1281
+ #
1282
+ # source://minitest/lib/minitest.rb#617
1283
+ def skipped?; end
1284
+ end
1285
+
1286
+ # source://minitest/lib/minitest.rb#592
1287
+ Minitest::Reportable::BASE_DIR = T.let(T.unsafe(nil), String)
1288
+
1289
+ # source://minitest/lib/minitest.rb#735
1290
+ class Minitest::Reporter < ::Minitest::AbstractReporter
1291
+ # @return [Reporter] a new instance of Reporter
1292
+ #
1293
+ # source://minitest/lib/minitest.rb#744
1294
+ def initialize(io = T.unsafe(nil), options = T.unsafe(nil)); end
1295
+
1296
+ # The IO used to report.
1297
+ #
1298
+ # source://minitest/lib/minitest.rb#737
1299
+ def io; end
1300
+
1301
+ # The IO used to report.
1302
+ #
1303
+ # source://minitest/lib/minitest.rb#737
1304
+ def io=(_arg0); end
1305
+
1306
+ # Command-line options for this run.
1307
+ #
1308
+ # source://minitest/lib/minitest.rb#742
1309
+ def options; end
1310
+
1311
+ # Command-line options for this run.
1312
+ #
1313
+ # source://minitest/lib/minitest.rb#742
1314
+ def options=(_arg0); end
1315
+ end
1316
+
1317
+ # This represents a test result in a clean way that can be
1318
+ # marshalled over a wire. Tests can do anything they want to the
1319
+ # test instance and can create conditions that cause Marshal.dump to
1320
+ # blow up. By using Result.from(a_test) you can be reasonably sure
1321
+ # that the test result can be marshalled.
1322
+ #
1323
+ # source://minitest/lib/minitest.rb#636
1324
+ class Minitest::Result < ::Minitest::Runnable
1325
+ include ::Minitest::Reportable
1326
+
1327
+ # source://minitest/lib/minitest.rb#670
1328
+ def class_name; end
1329
+
1330
+ # The class name of the test result.
1331
+ #
1332
+ # source://minitest/lib/minitest.rb#645
1333
+ def klass; end
1334
+
1335
+ # The class name of the test result.
1336
+ #
1337
+ # source://minitest/lib/minitest.rb#645
1338
+ def klass=(_arg0); end
1339
+
1340
+ # The location of the test method.
1341
+ #
1342
+ # source://minitest/lib/minitest.rb#650
1343
+ def source_location; end
1344
+
1345
+ # The location of the test method.
1346
+ #
1347
+ # source://minitest/lib/minitest.rb#650
1348
+ def source_location=(_arg0); end
1349
+
1350
+ # source://minitest/lib/minitest.rb#674
1351
+ def to_s; end
1352
+
1353
+ class << self
1354
+ # Create a new test result from a Runnable instance.
1355
+ #
1356
+ # source://minitest/lib/minitest.rb#655
1357
+ def from(runnable); end
1358
+ end
1359
+ end
1360
+
1361
+ # re-open
1362
+ #
1363
+ # source://minitest/lib/minitest.rb#349
1364
+ class Minitest::Runnable
1365
+ # @return [Runnable] a new instance of Runnable
1366
+ #
1367
+ # source://minitest/lib/minitest.rb#512
1368
+ def initialize(name); end
1369
+
1370
+ # Number of assertions executed in this run.
1371
+ #
1372
+ # source://minitest/lib/minitest.rb#353
1373
+ def assertions; end
1374
+
1375
+ # Number of assertions executed in this run.
1376
+ #
1377
+ # source://minitest/lib/minitest.rb#353
1378
+ def assertions=(_arg0); end
1379
+
1380
+ # source://minitest/lib/minitest.rb#508
1381
+ def failure; end
1382
+
1383
+ # An assertion raised during the run, if any.
1384
+ #
1385
+ # source://minitest/lib/minitest.rb#358
1386
+ def failures; end
1387
+
1388
+ # An assertion raised during the run, if any.
1389
+ #
1390
+ # source://minitest/lib/minitest.rb#358
1391
+ def failures=(_arg0); end
1392
+
1393
+ # source://minitest/lib/minitest.rb#494
1394
+ def marshal_dump; end
1395
+
1396
+ # source://minitest/lib/minitest.rb#504
1397
+ def marshal_load(ary); end
1398
+
1399
+ # Metadata you attach to the test results that get sent to the reporter.
1400
+ #
1401
+ # Lazily initializes to a hash, to keep memory down.
1402
+ #
1403
+ # NOTE: this data *must* be plain (read: marshal-able) data!
1404
+ # Hashes! Arrays! Strings!
1405
+ #
1406
+ # source://minitest/lib/minitest.rb#527
1407
+ def metadata; end
1408
+
1409
+ # Sets metadata, mainly used for +Result.from+.
1410
+ #
1411
+ # source://minitest/lib/minitest.rb#534
1412
+ def metadata=(_arg0); end
1413
+
1414
+ # Returns true if metadata exists.
1415
+ #
1416
+ # @return [Boolean]
1417
+ #
1418
+ # source://minitest/lib/minitest.rb#539
1419
+ def metadata?; end
1420
+
1421
+ # Name of the run.
1422
+ #
1423
+ # source://minitest/lib/minitest.rb#376
1424
+ def name; end
1425
+
1426
+ # Set the name of the run.
1427
+ #
1428
+ # source://minitest/lib/minitest.rb#383
1429
+ def name=(o); end
1430
+
1431
+ # Did this run pass?
1432
+ #
1433
+ # Note: skipped runs are not considered passing, but they don't
1434
+ # cause the process to exit non-zero.
1435
+ #
1436
+ # @raise [NotImplementedError]
1437
+ # @return [Boolean]
1438
+ #
1439
+ # source://minitest/lib/minitest.rb#556
1440
+ def passed?; end
1441
+
1442
+ # Returns a single character string to print based on the result
1443
+ # of the run. One of <tt>"."</tt>, <tt>"F"</tt>,
1444
+ # <tt>"E"</tt> or <tt>"S"</tt>.
1445
+ #
1446
+ # @raise [NotImplementedError]
1447
+ #
1448
+ # source://minitest/lib/minitest.rb#565
1449
+ def result_code; end
1450
+
1451
+ # Runs a single method. Needs to return self.
1452
+ #
1453
+ # @raise [NotImplementedError]
1454
+ #
1455
+ # source://minitest/lib/minitest.rb#546
1456
+ def run; end
1457
+
1458
+ # Was this run skipped? See #passed? for more information.
1459
+ #
1460
+ # @raise [NotImplementedError]
1461
+ # @return [Boolean]
1462
+ #
1463
+ # source://minitest/lib/minitest.rb#572
1464
+ def skipped?; end
1465
+
1466
+ # The time it took to run.
1467
+ #
1468
+ # source://minitest/lib/minitest.rb#363
1469
+ def time; end
1470
+
1471
+ # The time it took to run.
1472
+ #
1473
+ # source://minitest/lib/minitest.rb#363
1474
+ def time=(_arg0); end
1475
+
1476
+ # source://minitest/lib/minitest.rb#365
1477
+ def time_it; end
1478
+
1479
+ class << self
1480
+ # source://minitest/lib/minitest.rb#1226
1481
+ def inherited(klass); end
1482
+
1483
+ # Returns all instance methods matching the pattern +re+.
1484
+ #
1485
+ # source://minitest/lib/minitest.rb#390
1486
+ def methods_matching(re); end
1487
+
1488
+ # source://minitest/lib/minitest.rb#464
1489
+ def on_signal(name, action); end
1490
+
1491
+ # source://minitest/lib/minitest.rb#394
1492
+ def reset; end
1493
+
1494
+ # Responsible for running all runnable methods in a given class,
1495
+ # each in its own instance. Each instance is passed to the
1496
+ # reporter to record.
1497
+ #
1498
+ # source://minitest/lib/minitest.rb#405
1499
+ def run(reporter, options = T.unsafe(nil)); end
1500
+
1501
+ # Runs a single method and has the reporter record the result.
1502
+ # This was considered internal API but is factored out of run so
1503
+ # that subclasses can specialize the running of an individual
1504
+ # test. See Minitest::ParallelTest::ClassMethods for an example.
1505
+ #
1506
+ # source://minitest/lib/minitest.rb#445
1507
+ def run_one_method(klass, method_name, reporter); end
1508
+
1509
+ # Each subclass of Runnable is responsible for overriding this
1510
+ # method to return all runnable methods. See #methods_matching.
1511
+ #
1512
+ # @raise [NotImplementedError]
1513
+ #
1514
+ # source://minitest/lib/minitest.rb#481
1515
+ def runnable_methods; end
1516
+
1517
+ # Returns all subclasses of Runnable.
1518
+ #
1519
+ # source://minitest/lib/minitest.rb#488
1520
+ def runnables; end
1521
+
1522
+ # Defines the order to run tests (:random by default). Override
1523
+ # this or use a convenience method to change it for your tests.
1524
+ #
1525
+ # source://minitest/lib/minitest.rb#454
1526
+ def test_order; end
1527
+
1528
+ # source://minitest/lib/minitest.rb#458
1529
+ def with_info_handler(reporter, &block); end
1530
+ end
1531
+ end
1532
+
1533
+ # source://minitest/lib/minitest.rb#462
1534
+ Minitest::Runnable::SIGNALS = T.let(T.unsafe(nil), Hash)
1535
+
1536
+ # Assertion raised when skipping a run.
1537
+ #
1538
+ # source://minitest/lib/minitest.rb#1050
1539
+ class Minitest::Skip < ::Minitest::Assertion
1540
+ # source://minitest/lib/minitest.rb#1051
1541
+ def result_label; end
1542
+ end
1543
+
1544
+ # Minitest::Spec -- The faster, better, less-magical spec framework!
1545
+ #
1546
+ # For a list of expectations, see Minitest::Expectations.
1547
+ #
1548
+ # source://minitest/lib/minitest/spec.rb#107
1549
+ class Minitest::Spec < ::Minitest::Test
1550
+ include ::Minitest::Spec::DSL::InstanceMethods
1551
+ extend ::Minitest::Spec::DSL
1552
+
1553
+ # @return [Spec] a new instance of Spec
1554
+ #
1555
+ # source://minitest/lib/minitest/spec.rb#113
1556
+ def initialize(name); end
1557
+
1558
+ class << self
1559
+ # source://minitest/lib/minitest/spec.rb#109
1560
+ def current; end
1561
+ end
1562
+ end
1563
+
1564
+ # Oh look! A Minitest::Spec::DSL module! Eat your heart out DHH.
1565
+ #
1566
+ # source://minitest/lib/minitest/spec.rb#121
1567
+ module Minitest::Spec::DSL
1568
+ # Define an 'after' action. Inherits the way normal methods should.
1569
+ #
1570
+ # NOTE: +type+ is ignored and is only there to make porting easier.
1571
+ #
1572
+ # Equivalent to Minitest::Test#teardown.
1573
+ #
1574
+ # source://minitest/lib/minitest/spec.rb#206
1575
+ def after(_type = T.unsafe(nil), &block); end
1576
+
1577
+ # Define a 'before' action. Inherits the way normal methods should.
1578
+ #
1579
+ # NOTE: +type+ is ignored and is only there to make porting easier.
1580
+ #
1581
+ # Equivalent to Minitest::Test#setup.
1582
+ #
1583
+ # source://minitest/lib/minitest/spec.rb#192
1584
+ def before(_type = T.unsafe(nil), &block); end
1585
+
1586
+ # source://minitest/lib/minitest/spec.rb#175
1587
+ def children; end
1588
+
1589
+ # source://minitest/lib/minitest/spec.rb#271
1590
+ def create(name, desc); end
1591
+
1592
+ # source://minitest/lib/minitest/spec.rb#292
1593
+ def desc; end
1594
+
1595
+ # source://minitest/lib/minitest/spec.rb#171
1596
+ def describe_stack; end
1597
+
1598
+ # Define an expectation with name +desc+. Name gets morphed to a
1599
+ # proper test method name. For some freakish reason, people who
1600
+ # write specs don't like class inheritance, so this goes way out of
1601
+ # its way to make sure that expectations aren't inherited.
1602
+ #
1603
+ # This is also aliased to #specify and doesn't require a +desc+ arg.
1604
+ #
1605
+ # Hint: If you _do_ want inheritance, use minitest/test. You can mix
1606
+ # and match between assertions and expectations as much as you want.
1607
+ #
1608
+ # source://minitest/lib/minitest/spec.rb#224
1609
+ def it(desc = T.unsafe(nil), &block); end
1610
+
1611
+ # Essentially, define an accessor for +name+ with +block+.
1612
+ #
1613
+ # Why use let instead of def? I honestly don't know.
1614
+ #
1615
+ # @raise [ArgumentError]
1616
+ #
1617
+ # source://minitest/lib/minitest/spec.rb#248
1618
+ def let(name, &block); end
1619
+
1620
+ # source://minitest/lib/minitest/spec.rb#284
1621
+ def name; end
1622
+
1623
+ # source://minitest/lib/minitest/spec.rb#179
1624
+ def nuke_test_methods!; end
1625
+
1626
+ # Register a new type of spec that matches the spec's description.
1627
+ # This method can take either a Regexp and a spec class or a spec
1628
+ # class and a block that takes the description and returns true if
1629
+ # it matches.
1630
+ #
1631
+ # Eg:
1632
+ #
1633
+ # register_spec_type(/Controller$/, Minitest::Spec::Rails)
1634
+ #
1635
+ # or:
1636
+ #
1637
+ # register_spec_type(Minitest::Spec::RailsModel) do |desc|
1638
+ # desc.superclass == ActiveRecord::Base
1639
+ # end
1640
+ #
1641
+ # source://minitest/lib/minitest/spec.rb#147
1642
+ def register_spec_type(*args, &block); end
1643
+
1644
+ # Figure out the spec class to use based on a spec's description. Eg:
1645
+ #
1646
+ # spec_type("BlahController") # => Minitest::Spec::Rails
1647
+ #
1648
+ # source://minitest/lib/minitest/spec.rb#161
1649
+ def spec_type(desc, *additional); end
1650
+
1651
+ # Define an expectation with name +desc+. Name gets morphed to a
1652
+ # proper test method name. For some freakish reason, people who
1653
+ # write specs don't like class inheritance, so this goes way out of
1654
+ # its way to make sure that expectations aren't inherited.
1655
+ #
1656
+ # This is also aliased to #specify and doesn't require a +desc+ arg.
1657
+ #
1658
+ # Hint: If you _do_ want inheritance, use minitest/test. You can mix
1659
+ # and match between assertions and expectations as much as you want.
1660
+ #
1661
+ # source://minitest/lib/minitest/spec.rb#224
1662
+ def specify(desc = T.unsafe(nil), &block); end
1663
+
1664
+ # Another lazy man's accessor generator. Made even more lazy by
1665
+ # setting the name for you to +subject+.
1666
+ #
1667
+ # source://minitest/lib/minitest/spec.rb#267
1668
+ def subject(&block); end
1669
+
1670
+ # source://minitest/lib/minitest/spec.rb#288
1671
+ def to_s; end
1672
+
1673
+ class << self
1674
+ # source://minitest/lib/minitest/spec.rb#336
1675
+ def extended(obj); end
1676
+ end
1677
+ end
1678
+
1679
+ # Rdoc... why are you so dumb?
1680
+ #
1681
+ # source://minitest/lib/minitest/spec.rb#298
1682
+ module Minitest::Spec::DSL::InstanceMethods
1683
+ # Takes a value or a block and returns a value monad that has
1684
+ # all of Expectations methods available to it.
1685
+ #
1686
+ # _(1 + 1).must_equal 2
1687
+ #
1688
+ # And for blocks:
1689
+ #
1690
+ # _ { 1 + "1" }.must_raise TypeError
1691
+ #
1692
+ # This method of expectation-based testing is preferable to
1693
+ # straight-expectation methods (on Object) because it stores its
1694
+ # test context, bypassing our hacky use of thread-local variables.
1695
+ #
1696
+ # NOTE: At some point, the methods on Object will be deprecated
1697
+ # and then removed.
1698
+ #
1699
+ # It is also aliased to #value and #expect for your aesthetic
1700
+ # pleasure:
1701
+ #
1702
+ # _(1 + 1).must_equal 2
1703
+ # value(1 + 1).must_equal 2
1704
+ # expect(1 + 1).must_equal 2
1705
+ #
1706
+ # source://minitest/lib/minitest/spec.rb#323
1707
+ def _(value = T.unsafe(nil), &block); end
1708
+
1709
+ # source://minitest/lib/minitest/spec.rb#330
1710
+ def before_setup; end
1711
+
1712
+ # Takes a value or a block and returns a value monad that has
1713
+ # all of Expectations methods available to it.
1714
+ #
1715
+ # _(1 + 1).must_equal 2
1716
+ #
1717
+ # And for blocks:
1718
+ #
1719
+ # _ { 1 + "1" }.must_raise TypeError
1720
+ #
1721
+ # This method of expectation-based testing is preferable to
1722
+ # straight-expectation methods (on Object) because it stores its
1723
+ # test context, bypassing our hacky use of thread-local variables.
1724
+ #
1725
+ # NOTE: At some point, the methods on Object will be deprecated
1726
+ # and then removed.
1727
+ #
1728
+ # It is also aliased to #value and #expect for your aesthetic
1729
+ # pleasure:
1730
+ #
1731
+ # _(1 + 1).must_equal 2
1732
+ # value(1 + 1).must_equal 2
1733
+ # expect(1 + 1).must_equal 2
1734
+ #
1735
+ # source://minitest/lib/minitest/spec.rb#323
1736
+ def expect(value = T.unsafe(nil), &block); end
1737
+
1738
+ # Takes a value or a block and returns a value monad that has
1739
+ # all of Expectations methods available to it.
1740
+ #
1741
+ # _(1 + 1).must_equal 2
1742
+ #
1743
+ # And for blocks:
1744
+ #
1745
+ # _ { 1 + "1" }.must_raise TypeError
1746
+ #
1747
+ # This method of expectation-based testing is preferable to
1748
+ # straight-expectation methods (on Object) because it stores its
1749
+ # test context, bypassing our hacky use of thread-local variables.
1750
+ #
1751
+ # NOTE: At some point, the methods on Object will be deprecated
1752
+ # and then removed.
1753
+ #
1754
+ # It is also aliased to #value and #expect for your aesthetic
1755
+ # pleasure:
1756
+ #
1757
+ # _(1 + 1).must_equal 2
1758
+ # value(1 + 1).must_equal 2
1759
+ # expect(1 + 1).must_equal 2
1760
+ #
1761
+ # source://minitest/lib/minitest/spec.rb#323
1762
+ def value(value = T.unsafe(nil), &block); end
1763
+ end
1764
+
1765
+ # Contains pairs of matchers and Spec classes to be used to
1766
+ # calculate the superclass of a top-level describe. This allows for
1767
+ # automatically customizable spec types.
1768
+ #
1769
+ # See: register_spec_type and spec_type
1770
+ #
1771
+ # source://minitest/lib/minitest/spec.rb#129
1772
+ Minitest::Spec::DSL::TYPES = T.let(T.unsafe(nil), Array)
1773
+
1774
+ # source://minitest/lib/minitest/spec.rb#343
1775
+ Minitest::Spec::TYPES = T.let(T.unsafe(nil), Array)
1776
+
1777
+ # A reporter that gathers statistics about a test run. Does not do
1778
+ # any IO because meant to be used as a parent class for a reporter
1779
+ # that does.
1780
+ #
1781
+ # If you want to create an entirely different type of output (eg,
1782
+ # CI, HTML, etc), this is the place to start.
1783
+ #
1784
+ # Example:
1785
+ #
1786
+ # class JenkinsCIReporter < StatisticsReporter
1787
+ # def report
1788
+ # super # Needed to calculate some statistics
1789
+ #
1790
+ # print "<testsuite "
1791
+ # print "tests='#{count}' "
1792
+ # print "failures='#{failures}' "
1793
+ # # Remaining XML...
1794
+ # end
1795
+ # end
1796
+ #
1797
+ # source://minitest/lib/minitest.rb#795
1798
+ class Minitest::StatisticsReporter < ::Minitest::Reporter
1799
+ # @return [StatisticsReporter] a new instance of StatisticsReporter
1800
+ #
1801
+ # source://minitest/lib/minitest.rb#844
1802
+ def initialize(io = T.unsafe(nil), options = T.unsafe(nil)); end
1803
+
1804
+ # Total number of assertions.
1805
+ #
1806
+ # source://minitest/lib/minitest.rb#799
1807
+ def assertions; end
1808
+
1809
+ # Total number of assertions.
1810
+ #
1811
+ # source://minitest/lib/minitest.rb#799
1812
+ def assertions=(_arg0); end
1813
+
1814
+ # Total number of test cases.
1815
+ #
1816
+ # source://minitest/lib/minitest.rb#804
1817
+ def count; end
1818
+
1819
+ # Total number of test cases.
1820
+ #
1821
+ # source://minitest/lib/minitest.rb#804
1822
+ def count=(_arg0); end
1823
+
1824
+ # Total number of tests that erred.
1825
+ #
1826
+ # source://minitest/lib/minitest.rb#832
1827
+ def errors; end
1828
+
1829
+ # Total number of tests that erred.
1830
+ #
1831
+ # source://minitest/lib/minitest.rb#832
1832
+ def errors=(_arg0); end
1833
+
1834
+ # Total number of tests that failed.
1835
+ #
1836
+ # source://minitest/lib/minitest.rb#827
1837
+ def failures; end
1838
+
1839
+ # Total number of tests that failed.
1840
+ #
1841
+ # source://minitest/lib/minitest.rb#827
1842
+ def failures=(_arg0); end
1843
+
1844
+ # @return [Boolean]
1845
+ #
1846
+ # source://minitest/lib/minitest.rb#858
1847
+ def passed?; end
1848
+
1849
+ # source://minitest/lib/minitest.rb#866
1850
+ def record(result); end
1851
+
1852
+ # Report on the tracked statistics.
1853
+ #
1854
+ # source://minitest/lib/minitest.rb#876
1855
+ def report; end
1856
+
1857
+ # An +Array+ of test cases that failed or were skipped.
1858
+ #
1859
+ # source://minitest/lib/minitest.rb#809
1860
+ def results; end
1861
+
1862
+ # An +Array+ of test cases that failed or were skipped.
1863
+ #
1864
+ # source://minitest/lib/minitest.rb#809
1865
+ def results=(_arg0); end
1866
+
1867
+ # Total number of tests that where skipped.
1868
+ #
1869
+ # source://minitest/lib/minitest.rb#842
1870
+ def skips; end
1871
+
1872
+ # Total number of tests that where skipped.
1873
+ #
1874
+ # source://minitest/lib/minitest.rb#842
1875
+ def skips=(_arg0); end
1876
+
1877
+ # source://minitest/lib/minitest.rb#862
1878
+ def start; end
1879
+
1880
+ # Time the test run started. If available, the monotonic clock is
1881
+ # used and this is a +Float+, otherwise it's an instance of
1882
+ # +Time+.
1883
+ #
1884
+ # source://minitest/lib/minitest.rb#816
1885
+ def start_time; end
1886
+
1887
+ # Time the test run started. If available, the monotonic clock is
1888
+ # used and this is a +Float+, otherwise it's an instance of
1889
+ # +Time+.
1890
+ #
1891
+ # source://minitest/lib/minitest.rb#816
1892
+ def start_time=(_arg0); end
1893
+
1894
+ # Test run time. If available, the monotonic clock is used and
1895
+ # this is a +Float+, otherwise it's an instance of +Time+.
1896
+ #
1897
+ # source://minitest/lib/minitest.rb#822
1898
+ def total_time; end
1899
+
1900
+ # Test run time. If available, the monotonic clock is used and
1901
+ # this is a +Float+, otherwise it's an instance of +Time+.
1902
+ #
1903
+ # source://minitest/lib/minitest.rb#822
1904
+ def total_time=(_arg0); end
1905
+
1906
+ # Total number of tests that warned.
1907
+ #
1908
+ # source://minitest/lib/minitest.rb#837
1909
+ def warnings; end
1910
+
1911
+ # Total number of tests that warned.
1912
+ #
1913
+ # source://minitest/lib/minitest.rb#837
1914
+ def warnings=(_arg0); end
1915
+ end
1916
+
1917
+ # A reporter that prints the header, summary, and failure details at
1918
+ # the end of the run.
1919
+ #
1920
+ # This is added to the top-level CompositeReporter at the start of
1921
+ # the run. If you want to change the output of minitest via a
1922
+ # plugin, pull this out of the composite and replace it with your
1923
+ # own.
1924
+ #
1925
+ # source://minitest/lib/minitest.rb#897
1926
+ class Minitest::SummaryReporter < ::Minitest::StatisticsReporter
1927
+ # source://minitest/lib/minitest.rb#930
1928
+ def aggregated_results(io); end
1929
+
1930
+ # source://minitest/lib/minitest.rb#899
1931
+ def old_sync; end
1932
+
1933
+ # source://minitest/lib/minitest.rb#899
1934
+ def old_sync=(_arg0); end
1935
+
1936
+ # source://minitest/lib/minitest.rb#913
1937
+ def report; end
1938
+
1939
+ # source://minitest/lib/minitest.rb#901
1940
+ def start; end
1941
+
1942
+ # source://minitest/lib/minitest.rb#925
1943
+ def statistics; end
1944
+
1945
+ # source://minitest/lib/minitest.rb#950
1946
+ def summary; end
1947
+
1948
+ # source://minitest/lib/minitest.rb#898
1949
+ def sync; end
1950
+
1951
+ # source://minitest/lib/minitest.rb#898
1952
+ def sync=(_arg0); end
1953
+
1954
+ # source://minitest/lib/minitest.rb#946
1955
+ def to_s; end
1956
+ end
1957
+
1958
+ # Subclass Test to create your own tests. Typically you'll want a
1959
+ # Test subclass per implementation class.
1960
+ #
1961
+ # See Minitest::Assertions
1962
+ #
1963
+ # source://minitest/lib/minitest/test.rb#10
1964
+ class Minitest::Test < ::Minitest::Runnable
1965
+ include ::Minitest::Assertions
1966
+ include ::Minitest::Reportable
1967
+ include ::Minitest::Test::LifecycleHooks
1968
+ include ::Minitest::Guard
1969
+ extend ::Minitest::Guard
1970
+
1971
+ # LifecycleHooks
1972
+ #
1973
+ # source://minitest/lib/minitest/test.rb#189
1974
+ def capture_exceptions; end
1975
+
1976
+ # source://minitest/lib/minitest/test.rb#15
1977
+ def class_name; end
1978
+
1979
+ # source://minitest/lib/minitest/test.rb#206
1980
+ def neuter_exception(e); end
1981
+
1982
+ # source://minitest/lib/minitest/test.rb#217
1983
+ def new_exception(klass, msg, bt, kill = T.unsafe(nil)); end
1984
+
1985
+ # Runs a single test with setup/teardown hooks.
1986
+ #
1987
+ # source://minitest/lib/minitest/test.rb#87
1988
+ def run; end
1989
+
1990
+ # source://minitest/lib/minitest/test.rb#199
1991
+ def sanitize_exception(e); end
1992
+
1993
+ class << self
1994
+ # Call this at the top of your tests when you absolutely
1995
+ # positively need to have ordered tests. In doing so, you're
1996
+ # admitting that you suck and your tests are weak.
1997
+ #
1998
+ # source://minitest/lib/minitest/test.rb#35
1999
+ def i_suck_and_my_tests_are_order_dependent!; end
2000
+
2001
+ # Returns the value of attribute io_lock.
2002
+ #
2003
+ # source://minitest/lib/minitest/test.rb#26
2004
+ def io_lock; end
2005
+
2006
+ # Sets the attribute io_lock
2007
+ #
2008
+ # @param value the value to set the attribute io_lock to.
2009
+ #
2010
+ # source://minitest/lib/minitest/test.rb#26
2011
+ def io_lock=(_arg0); end
2012
+
2013
+ # Make diffs for this Test use #pretty_inspect so that diff
2014
+ # in assert_equal can have more details. NOTE: this is much slower
2015
+ # than the regular inspect but much more usable for complex
2016
+ # objects.
2017
+ #
2018
+ # source://minitest/lib/minitest/test.rb#48
2019
+ def make_my_diffs_pretty!; end
2020
+
2021
+ # Call this at the top of your tests (inside the +Minitest::Test+
2022
+ # subclass or +describe+ block) when you want to run your tests in
2023
+ # parallel. In doing so, you're admitting that you rule and your
2024
+ # tests are awesome.
2025
+ #
2026
+ # source://minitest/lib/minitest/test.rb#60
2027
+ def parallelize_me!; end
2028
+
2029
+ # Returns all instance methods starting with "test_". Based on
2030
+ # #test_order, the methods are either sorted, randomized
2031
+ # (default), or run in parallel.
2032
+ #
2033
+ # source://minitest/lib/minitest/test.rb#70
2034
+ def runnable_methods; end
2035
+ end
2036
+ end
2037
+
2038
+ # Provides before/after hooks for setup and teardown. These are
2039
+ # meant for library writers, NOT for regular test authors. See
2040
+ # #before_setup for an example.
2041
+ #
2042
+ # source://minitest/lib/minitest/test.rb#112
2043
+ module Minitest::Test::LifecycleHooks
2044
+ # Runs before every test, after setup. This hook is meant for
2045
+ # libraries to extend minitest. It is not meant to be used by
2046
+ # test developers.
2047
+ #
2048
+ # See #before_setup for an example.
2049
+ #
2050
+ # source://minitest/lib/minitest/test.rb#162
2051
+ def after_setup; end
2052
+
2053
+ # Runs after every test, after teardown. This hook is meant for
2054
+ # libraries to extend minitest. It is not meant to be used by
2055
+ # test developers.
2056
+ #
2057
+ # See #before_setup for an example.
2058
+ #
2059
+ # source://minitest/lib/minitest/test.rb#186
2060
+ def after_teardown; end
2061
+
2062
+ # Runs before every test, before setup. This hook is meant for
2063
+ # libraries to extend minitest. It is not meant to be used by
2064
+ # test developers.
2065
+ #
2066
+ # As a simplistic example:
2067
+ #
2068
+ # module MyMinitestPlugin
2069
+ # def before_setup
2070
+ # super
2071
+ # # ... stuff to do before setup is run
2072
+ # end
2073
+ #
2074
+ # def after_setup
2075
+ # # ... stuff to do after setup is run
2076
+ # super
2077
+ # end
2078
+ #
2079
+ # def before_teardown
2080
+ # super
2081
+ # # ... stuff to do before teardown is run
2082
+ # end
2083
+ #
2084
+ # def after_teardown
2085
+ # # ... stuff to do after teardown is run
2086
+ # super
2087
+ # end
2088
+ # end
2089
+ #
2090
+ # class Minitest::Test
2091
+ # include MyMinitestPlugin
2092
+ # end
2093
+ #
2094
+ # source://minitest/lib/minitest/test.rb#147
2095
+ def before_setup; end
2096
+
2097
+ # Runs after every test, before teardown. This hook is meant for
2098
+ # libraries to extend minitest. It is not meant to be used by
2099
+ # test developers.
2100
+ #
2101
+ # See #before_setup for an example.
2102
+ #
2103
+ # source://minitest/lib/minitest/test.rb#171
2104
+ def before_teardown; end
2105
+
2106
+ # Runs before every test. Use this to set up before each test
2107
+ # run.
2108
+ #
2109
+ # source://minitest/lib/minitest/test.rb#153
2110
+ def setup; end
2111
+
2112
+ # Runs after every test. Use this to clean up after each test
2113
+ # run.
2114
+ #
2115
+ # source://minitest/lib/minitest/test.rb#177
2116
+ def teardown; end
2117
+ end
2118
+
2119
+ # source://minitest/lib/minitest/test.rb#19
2120
+ Minitest::Test::PASSTHROUGH_EXCEPTIONS = T.let(T.unsafe(nil), Array)
2121
+
2122
+ # source://minitest/lib/minitest/test.rb#21
2123
+ Minitest::Test::SETUP_METHODS = T.let(T.unsafe(nil), Array)
2124
+
2125
+ # source://minitest/lib/minitest/test.rb#23
2126
+ Minitest::Test::TEARDOWN_METHODS = T.let(T.unsafe(nil), Array)
2127
+
2128
+ # Assertion wrapping an unexpected error that was raised during a run.
2129
+ #
2130
+ # source://minitest/lib/minitest.rb#1059
2131
+ class Minitest::UnexpectedError < ::Minitest::Assertion
2132
+ include ::Minitest::Compress
2133
+
2134
+ # @return [UnexpectedError] a new instance of UnexpectedError
2135
+ #
2136
+ # source://minitest/lib/minitest.rb#1065
2137
+ def initialize(error); end
2138
+
2139
+ # source://minitest/lib/minitest.rb#1078
2140
+ def backtrace; end
2141
+
2142
+ # TODO: figure out how to use `cause` instead
2143
+ #
2144
+ # source://minitest/lib/minitest.rb#1063
2145
+ def error; end
2146
+
2147
+ # TODO: figure out how to use `cause` instead
2148
+ #
2149
+ # source://minitest/lib/minitest.rb#1063
2150
+ def error=(_arg0); end
2151
+
2152
+ # source://minitest/lib/minitest.rb#1084
2153
+ def message; end
2154
+
2155
+ # source://minitest/lib/minitest.rb#1090
2156
+ def result_label; end
2157
+ end
2158
+
2159
+ # source://minitest/lib/minitest.rb#1082
2160
+ Minitest::UnexpectedError::BASE_RE = T.let(T.unsafe(nil), Regexp)
2161
+
2162
+ # Assertion raised on warning when running in -Werror mode.
2163
+ #
2164
+ # source://minitest/lib/minitest.rb#1098
2165
+ class Minitest::UnexpectedWarning < ::Minitest::Assertion
2166
+ # source://minitest/lib/minitest.rb#1099
2167
+ def result_label; end
2168
+ end
2169
+
2170
+ # source://minitest/lib/minitest.rb#13
2171
+ Minitest::VERSION = T.let(T.unsafe(nil), String)
2172
+
2173
+ # source://minitest/lib/minitest/mock.rb#1
2174
+ class MockExpectationError < ::StandardError; end
2175
+
2176
+ # source://minitest/lib/minitest/spec.rb#3
2177
+ class Module
2178
+ # source://minitest/lib/minitest/spec.rb#4
2179
+ def infect_an_assertion(meth, new_name, dont_flip = T.unsafe(nil)); end
2180
+ end
2181
+
2182
+ # source://minitest/lib/minitest/spec.rb#348
2183
+ class Object < ::BasicObject
2184
+ include ::Kernel
2185
+ include ::PP::ObjectMixin
2186
+ include ::Minitest::Expectations
2187
+
2188
+ # Add a temporary stubbed method replacing +name+ for the duration
2189
+ # of the +block+. If +val_or_callable+ responds to #call, then it
2190
+ # returns the result of calling it, otherwise returns the value
2191
+ # as-is. If stubbed method yields a block, +block_args+ will be
2192
+ # passed along. Cleans up the stub at the end of the +block+. The
2193
+ # method +name+ must exist before stubbing.
2194
+ #
2195
+ # def test_stale_eh
2196
+ # obj_under_test = Something.new
2197
+ # refute obj_under_test.stale?
2198
+ #
2199
+ # Time.stub :now, Time.at(0) do
2200
+ # assert obj_under_test.stale?
2201
+ # end
2202
+ # end
2203
+ # --
2204
+ # NOTE: keyword args in callables are NOT checked for correctness
2205
+ # against the existing method. Too many edge cases to be worth it.
2206
+ #
2207
+ # source://minitest/lib/minitest/mock.rb#283
2208
+ def stub(name, val_or_callable, *block_args, **block_kwargs, &block); end
2209
+ end