lobbying_disclosure_client 0.0.1

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