active_cached_resource 0.0.1.pre
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +7 -0
- data/.rspec +3 -0
- data/.rubocop.yml +22 -0
- data/.standard.yml +2 -0
- data/CHANGELOG.md +5 -0
- data/README.md +45 -0
- data/Rakefile +21 -0
- data/example/consumer/.dockerignore +41 -0
- data/example/consumer/.gitattributes +9 -0
- data/example/consumer/.gitignore +36 -0
- data/example/consumer/.kamal/hooks/docker-setup.sample +3 -0
- data/example/consumer/.kamal/hooks/post-deploy.sample +14 -0
- data/example/consumer/.kamal/hooks/post-proxy-reboot.sample +3 -0
- data/example/consumer/.kamal/hooks/pre-build.sample +51 -0
- data/example/consumer/.kamal/hooks/pre-connect.sample +47 -0
- data/example/consumer/.kamal/hooks/pre-deploy.sample +109 -0
- data/example/consumer/.kamal/hooks/pre-proxy-reboot.sample +3 -0
- data/example/consumer/.kamal/secrets +17 -0
- data/example/consumer/Dockerfile +65 -0
- data/example/consumer/Gemfile +17 -0
- data/example/consumer/Rakefile +6 -0
- data/example/consumer/app/controllers/application_controller.rb +2 -0
- data/example/consumer/app/controllers/concerns/.keep +0 -0
- data/example/consumer/app/jobs/application_job.rb +7 -0
- data/example/consumer/app/mailers/application_mailer.rb +4 -0
- data/example/consumer/app/models/application_record.rb +3 -0
- data/example/consumer/app/models/concerns/.keep +0 -0
- data/example/consumer/app/models/person.rb +9 -0
- data/example/consumer/app/views/layouts/mailer.html.erb +13 -0
- data/example/consumer/app/views/layouts/mailer.text.erb +1 -0
- data/example/consumer/bin/brakeman +7 -0
- data/example/consumer/bin/bundle +109 -0
- data/example/consumer/bin/dev +2 -0
- data/example/consumer/bin/docker-entrypoint +14 -0
- data/example/consumer/bin/jobs +6 -0
- data/example/consumer/bin/kamal +27 -0
- data/example/consumer/bin/rails +4 -0
- data/example/consumer/bin/rake +4 -0
- data/example/consumer/bin/rubocop +8 -0
- data/example/consumer/bin/setup +34 -0
- data/example/consumer/bin/thrust +5 -0
- data/example/consumer/config/application.rb +20 -0
- data/example/consumer/config/boot.rb +3 -0
- data/example/consumer/config/cache.yml +16 -0
- data/example/consumer/config/credentials.yml.enc +1 -0
- data/example/consumer/config/database.yml +14 -0
- data/example/consumer/config/deploy.yml +116 -0
- data/example/consumer/config/environment.rb +5 -0
- data/example/consumer/config/environments/development.rb +64 -0
- data/example/consumer/config/environments/production.rb +85 -0
- data/example/consumer/config/environments/test.rb +50 -0
- data/example/consumer/config/initializers/cors.rb +16 -0
- data/example/consumer/config/initializers/filter_parameter_logging.rb +8 -0
- data/example/consumer/config/initializers/inflections.rb +16 -0
- data/example/consumer/config/locales/en.yml +31 -0
- data/example/consumer/config/puma.rb +41 -0
- data/example/consumer/config/queue.yml +18 -0
- data/example/consumer/config/recurring.yml +10 -0
- data/example/consumer/config/routes.rb +10 -0
- data/example/consumer/config.ru +6 -0
- data/example/consumer/db/cache_schema.rb +14 -0
- data/example/consumer/db/queue_schema.rb +129 -0
- data/example/consumer/db/seeds.rb +0 -0
- data/example/consumer/lib/tasks/.keep +0 -0
- data/example/consumer/log/.keep +0 -0
- data/example/consumer/public/robots.txt +1 -0
- data/example/consumer/script/.keep +0 -0
- data/example/consumer/storage/.keep +0 -0
- data/example/consumer/tmp/.keep +0 -0
- data/example/consumer/tmp/cache/.keep +0 -0
- data/example/consumer/tmp/pids/.keep +0 -0
- data/example/consumer/tmp/storage/.keep +0 -0
- data/example/consumer/vendor/.keep +0 -0
- data/example/provider/.dockerignore +41 -0
- data/example/provider/.gitattributes +9 -0
- data/example/provider/.gitignore +32 -0
- data/example/provider/.kamal/hooks/docker-setup.sample +3 -0
- data/example/provider/.kamal/hooks/post-deploy.sample +14 -0
- data/example/provider/.kamal/hooks/post-proxy-reboot.sample +3 -0
- data/example/provider/.kamal/hooks/pre-build.sample +51 -0
- data/example/provider/.kamal/hooks/pre-connect.sample +47 -0
- data/example/provider/.kamal/hooks/pre-deploy.sample +109 -0
- data/example/provider/.kamal/hooks/pre-proxy-reboot.sample +3 -0
- data/example/provider/.kamal/secrets +17 -0
- data/example/provider/Dockerfile +65 -0
- data/example/provider/Gemfile +14 -0
- data/example/provider/Rakefile +6 -0
- data/example/provider/app/controllers/application_controller.rb +2 -0
- data/example/provider/app/controllers/concerns/.keep +0 -0
- data/example/provider/app/controllers/people_controller.rb +68 -0
- data/example/provider/app/jobs/application_job.rb +7 -0
- data/example/provider/app/mailers/application_mailer.rb +4 -0
- data/example/provider/app/models/address.rb +3 -0
- data/example/provider/app/models/application_record.rb +3 -0
- data/example/provider/app/models/company.rb +3 -0
- data/example/provider/app/models/concerns/.keep +0 -0
- data/example/provider/app/models/person.rb +6 -0
- data/example/provider/app/views/layouts/mailer.html.erb +13 -0
- data/example/provider/app/views/layouts/mailer.text.erb +1 -0
- data/example/provider/bin/brakeman +7 -0
- data/example/provider/bin/bundle +109 -0
- data/example/provider/bin/dev +2 -0
- data/example/provider/bin/docker-entrypoint +14 -0
- data/example/provider/bin/jobs +6 -0
- data/example/provider/bin/kamal +27 -0
- data/example/provider/bin/rails +4 -0
- data/example/provider/bin/rake +4 -0
- data/example/provider/bin/rubocop +8 -0
- data/example/provider/bin/setup +34 -0
- data/example/provider/bin/thrust +5 -0
- data/example/provider/config/application.rb +44 -0
- data/example/provider/config/boot.rb +3 -0
- data/example/provider/config/cache.yml +16 -0
- data/example/provider/config/credentials.yml.enc +1 -0
- data/example/provider/config/database.yml +20 -0
- data/example/provider/config/deploy.yml +116 -0
- data/example/provider/config/environment.rb +5 -0
- data/example/provider/config/environments/development.rb +64 -0
- data/example/provider/config/environments/production.rb +85 -0
- data/example/provider/config/environments/test.rb +50 -0
- data/example/provider/config/initializers/cors.rb +16 -0
- data/example/provider/config/initializers/filter_parameter_logging.rb +8 -0
- data/example/provider/config/initializers/inflections.rb +16 -0
- data/example/provider/config/locales/en.yml +31 -0
- data/example/provider/config/puma.rb +41 -0
- data/example/provider/config/queue.yml +18 -0
- data/example/provider/config/recurring.yml +10 -0
- data/example/provider/config/routes.rb +4 -0
- data/example/provider/config.ru +6 -0
- data/example/provider/db/cache_schema.rb +14 -0
- data/example/provider/db/migrate/20241202183937_create_people.rb +11 -0
- data/example/provider/db/migrate/20241202183955_create_addresses.rb +13 -0
- data/example/provider/db/migrate/20241202184017_create_companies.rb +14 -0
- data/example/provider/db/queue_schema.rb +129 -0
- data/example/provider/db/schema.rb +47 -0
- data/example/provider/db/seeds.rb +18 -0
- data/example/provider/lib/tasks/.keep +0 -0
- data/example/provider/log/.keep +0 -0
- data/example/provider/public/robots.txt +1 -0
- data/example/provider/script/.keep +0 -0
- data/example/provider/storage/.keep +0 -0
- data/example/provider/tmp/.keep +0 -0
- data/example/provider/tmp/pids/.keep +0 -0
- data/example/provider/tmp/storage/.keep +0 -0
- data/example/provider/vendor/.keep +0 -0
- data/lib/active_cached_resource/caching.rb +176 -0
- data/lib/active_cached_resource/caching_strategies/active_support_cache.rb +31 -0
- data/lib/active_cached_resource/caching_strategies/base.rb +114 -0
- data/lib/active_cached_resource/caching_strategies/sql_cache.rb +32 -0
- data/lib/active_cached_resource/configuration.rb +50 -0
- data/lib/active_cached_resource/logger.rb +22 -0
- data/lib/active_cached_resource/model.rb +33 -0
- data/lib/active_cached_resource/version.rb +12 -0
- data/lib/active_cached_resource.rb +64 -0
- data/lib/activeresource/.gitignore +15 -0
- data/lib/activeresource/README.md +283 -0
- data/lib/activeresource/examples/performance.rb +72 -0
- data/lib/activeresource/lib/active_resource/active_job_serializer.rb +26 -0
- data/lib/activeresource/lib/active_resource/associations/builder/association.rb +32 -0
- data/lib/activeresource/lib/active_resource/associations/builder/belongs_to.rb +16 -0
- data/lib/activeresource/lib/active_resource/associations/builder/has_many.rb +14 -0
- data/lib/activeresource/lib/active_resource/associations/builder/has_one.rb +14 -0
- data/lib/activeresource/lib/active_resource/associations.rb +175 -0
- data/lib/activeresource/lib/active_resource/base.rb +1741 -0
- data/lib/activeresource/lib/active_resource/callbacks.rb +22 -0
- data/lib/activeresource/lib/active_resource/collection.rb +214 -0
- data/lib/activeresource/lib/active_resource/connection.rb +298 -0
- data/lib/activeresource/lib/active_resource/custom_methods.rb +129 -0
- data/lib/activeresource/lib/active_resource/exceptions.rb +98 -0
- data/lib/activeresource/lib/active_resource/formats/json_format.rb +28 -0
- data/lib/activeresource/lib/active_resource/formats/xml_format.rb +27 -0
- data/lib/activeresource/lib/active_resource/formats.rb +24 -0
- data/lib/activeresource/lib/active_resource/http_mock.rb +386 -0
- data/lib/activeresource/lib/active_resource/inheriting_hash.rb +34 -0
- data/lib/activeresource/lib/active_resource/log_subscriber.rb +26 -0
- data/lib/activeresource/lib/active_resource/railtie.rb +31 -0
- data/lib/activeresource/lib/active_resource/reflection.rb +78 -0
- data/lib/activeresource/lib/active_resource/schema.rb +60 -0
- data/lib/activeresource/lib/active_resource/singleton.rb +111 -0
- data/lib/activeresource/lib/active_resource/threadsafe_attributes.rb +65 -0
- data/lib/activeresource/lib/active_resource/validations.rb +176 -0
- data/lib/activeresource/lib/active_resource.rb +49 -0
- data/lib/activeresource/lib/activeresource.rb +3 -0
- data/lib/activeresource/test/abstract_unit.rb +153 -0
- data/lib/activeresource/test/cases/active_job_serializer_test.rb +53 -0
- data/lib/activeresource/test/cases/association_test.rb +104 -0
- data/lib/activeresource/test/cases/associations/builder/belongs_to_test.rb +42 -0
- data/lib/activeresource/test/cases/associations/builder/has_many_test.rb +28 -0
- data/lib/activeresource/test/cases/associations/builder/has_one_test.rb +28 -0
- data/lib/activeresource/test/cases/authorization_test.rb +276 -0
- data/lib/activeresource/test/cases/base/custom_methods_test.rb +155 -0
- data/lib/activeresource/test/cases/base/equality_test.rb +53 -0
- data/lib/activeresource/test/cases/base/load_test.rb +249 -0
- data/lib/activeresource/test/cases/base/schema_test.rb +428 -0
- data/lib/activeresource/test/cases/base_errors_test.rb +129 -0
- data/lib/activeresource/test/cases/base_test.rb +1622 -0
- data/lib/activeresource/test/cases/callbacks_test.rb +155 -0
- data/lib/activeresource/test/cases/collection_test.rb +172 -0
- data/lib/activeresource/test/cases/connection_test.rb +357 -0
- data/lib/activeresource/test/cases/finder_test.rb +217 -0
- data/lib/activeresource/test/cases/format_test.rb +137 -0
- data/lib/activeresource/test/cases/http_mock_test.rb +213 -0
- data/lib/activeresource/test/cases/inheritence_test.rb +19 -0
- data/lib/activeresource/test/cases/inheriting_hash_test.rb +25 -0
- data/lib/activeresource/test/cases/log_subscriber_test.rb +63 -0
- data/lib/activeresource/test/cases/reflection_test.rb +65 -0
- data/lib/activeresource/test/cases/validations_test.rb +78 -0
- data/lib/activeresource/test/fixtures/address.rb +20 -0
- data/lib/activeresource/test/fixtures/beast.rb +16 -0
- data/lib/activeresource/test/fixtures/comment.rb +5 -0
- data/lib/activeresource/test/fixtures/customer.rb +5 -0
- data/lib/activeresource/test/fixtures/inventory.rb +14 -0
- data/lib/activeresource/test/fixtures/person.rb +15 -0
- data/lib/activeresource/test/fixtures/pet.rb +6 -0
- data/lib/activeresource/test/fixtures/post.rb +5 -0
- data/lib/activeresource/test/fixtures/product.rb +11 -0
- data/lib/activeresource/test/fixtures/project.rb +19 -0
- data/lib/activeresource/test/fixtures/proxy.rb +6 -0
- data/lib/activeresource/test/fixtures/sound.rb +11 -0
- data/lib/activeresource/test/fixtures/street_address.rb +6 -0
- data/lib/activeresource/test/fixtures/subscription_plan.rb +7 -0
- data/lib/activeresource/test/fixtures/weather.rb +21 -0
- data/lib/activeresource/test/setter_trap.rb +28 -0
- data/lib/activeresource/test/singleton_test.rb +138 -0
- data/lib/activeresource/test/threadsafe_attributes_test.rb +91 -0
- data/lib/generators/active_cached_resource/install_generator.rb +31 -0
- data/lib/generators/active_cached_resource/templates/migration.erb +16 -0
- data/sorbet/config +4 -0
- data/sorbet/rbi/annotations/.gitattributes +1 -0
- data/sorbet/rbi/annotations/activemodel.rbi +89 -0
- data/sorbet/rbi/annotations/activesupport.rbi +457 -0
- data/sorbet/rbi/annotations/minitest.rbi +119 -0
- data/sorbet/rbi/annotations/rainbow.rbi +269 -0
- data/sorbet/rbi/dsl/.gitattributes +1 -0
- data/sorbet/rbi/dsl/active_support/callbacks.rbi +21 -0
- data/sorbet/rbi/gems/.gitattributes +1 -0
- data/sorbet/rbi/gems/actioncable@8.0.0.rbi +252 -0
- data/sorbet/rbi/gems/actionmailbox@8.0.0.rbi +9 -0
- data/sorbet/rbi/gems/actionmailer@8.0.0.rbi +9 -0
- data/sorbet/rbi/gems/actionpack@8.0.0.rbi +20909 -0
- data/sorbet/rbi/gems/actiontext@8.0.0.rbi +9 -0
- data/sorbet/rbi/gems/actionview@8.0.0.rbi +16207 -0
- data/sorbet/rbi/gems/activejob@8.0.0.rbi +9 -0
- data/sorbet/rbi/gems/activemodel-serializers-xml@1.0.3.rbi +166 -0
- data/sorbet/rbi/gems/activemodel@8.0.0.rbi +6857 -0
- data/sorbet/rbi/gems/activerecord@8.0.0.rbi +42896 -0
- data/sorbet/rbi/gems/activeresource@6.1.4.rbi +3944 -0
- data/sorbet/rbi/gems/activestorage@8.0.0.rbi +9 -0
- data/sorbet/rbi/gems/activesupport@8.0.0.rbi +21251 -0
- data/sorbet/rbi/gems/ast@2.4.2.rbi +585 -0
- data/sorbet/rbi/gems/base64@0.2.0.rbi +509 -0
- data/sorbet/rbi/gems/benchmark@0.4.0.rbi +618 -0
- data/sorbet/rbi/gems/bigdecimal@3.1.8.rbi +78 -0
- data/sorbet/rbi/gems/builder@3.3.0.rbi +9 -0
- data/sorbet/rbi/gems/bump@0.10.0.rbi +169 -0
- data/sorbet/rbi/gems/byebug@11.1.3.rbi +3607 -0
- data/sorbet/rbi/gems/coderay@1.1.3.rbi +3427 -0
- data/sorbet/rbi/gems/concurrent-ruby@1.3.4.rbi +11645 -0
- data/sorbet/rbi/gems/connection_pool@2.4.1.rbi +9 -0
- data/sorbet/rbi/gems/crass@1.0.6.rbi +623 -0
- data/sorbet/rbi/gems/date@3.4.0.rbi +75 -0
- data/sorbet/rbi/gems/diff-lcs@1.5.1.rbi +1131 -0
- data/sorbet/rbi/gems/docile@1.4.1.rbi +377 -0
- data/sorbet/rbi/gems/drb@2.2.1.rbi +1347 -0
- data/sorbet/rbi/gems/erubi@1.13.0.rbi +150 -0
- data/sorbet/rbi/gems/globalid@1.2.1.rbi +9 -0
- data/sorbet/rbi/gems/i18n@1.14.6.rbi +2359 -0
- data/sorbet/rbi/gems/io-console@0.7.2.rbi +9 -0
- data/sorbet/rbi/gems/json@2.8.2.rbi +1901 -0
- data/sorbet/rbi/gems/language_server-protocol@3.17.0.3.rbi +14238 -0
- data/sorbet/rbi/gems/lint_roller@1.1.0.rbi +240 -0
- data/sorbet/rbi/gems/logger@1.6.1.rbi +920 -0
- data/sorbet/rbi/gems/loofah@2.23.1.rbi +1081 -0
- data/sorbet/rbi/gems/mail@2.8.1.rbi +9 -0
- data/sorbet/rbi/gems/marcel@1.0.4.rbi +9 -0
- data/sorbet/rbi/gems/method_source@1.1.0.rbi +304 -0
- data/sorbet/rbi/gems/mini_mime@1.1.5.rbi +9 -0
- data/sorbet/rbi/gems/minitest@5.25.2.rbi +1547 -0
- data/sorbet/rbi/gems/net-imap@0.5.1.rbi +9 -0
- data/sorbet/rbi/gems/net-pop@0.1.2.rbi +9 -0
- data/sorbet/rbi/gems/net-protocol@0.2.2.rbi +292 -0
- data/sorbet/rbi/gems/net-smtp@0.5.0.rbi +9 -0
- data/sorbet/rbi/gems/netrc@0.11.0.rbi +159 -0
- data/sorbet/rbi/gems/nio4r@2.7.4.rbi +9 -0
- data/sorbet/rbi/gems/nokogiri@1.16.7.rbi +7311 -0
- data/sorbet/rbi/gems/parallel@1.26.3.rbi +291 -0
- data/sorbet/rbi/gems/parser@3.3.6.0.rbi +5519 -0
- data/sorbet/rbi/gems/prism@1.2.0.rbi +39085 -0
- data/sorbet/rbi/gems/pry-byebug@3.10.1.rbi +1151 -0
- data/sorbet/rbi/gems/pry@0.14.2.rbi +10076 -0
- data/sorbet/rbi/gems/psych@5.2.0.rbi +1785 -0
- data/sorbet/rbi/gems/racc@1.8.1.rbi +162 -0
- data/sorbet/rbi/gems/rack-session@2.0.0.rbi +727 -0
- data/sorbet/rbi/gems/rack-test@2.1.0.rbi +747 -0
- data/sorbet/rbi/gems/rack@3.1.8.rbi +4905 -0
- data/sorbet/rbi/gems/rackup@2.2.1.rbi +230 -0
- data/sorbet/rbi/gems/rails-dom-testing@2.2.0.rbi +758 -0
- data/sorbet/rbi/gems/rails-html-sanitizer@1.6.0.rbi +785 -0
- data/sorbet/rbi/gems/rails@8.0.0.rbi +9 -0
- data/sorbet/rbi/gems/railties@8.0.0.rbi +6287 -0
- data/sorbet/rbi/gems/rainbow@3.1.1.rbi +403 -0
- data/sorbet/rbi/gems/rake@13.2.1.rbi +3091 -0
- data/sorbet/rbi/gems/rbi@0.2.1.rbi +4535 -0
- data/sorbet/rbi/gems/rdoc@6.8.1.rbi +12572 -0
- data/sorbet/rbi/gems/regexp_parser@2.9.2.rbi +3772 -0
- data/sorbet/rbi/gems/reline@0.5.12.rbi +2416 -0
- data/sorbet/rbi/gems/rexml@3.3.9.rbi +4858 -0
- data/sorbet/rbi/gems/rspec-core@3.13.2.rbi +11287 -0
- data/sorbet/rbi/gems/rspec-expectations@3.13.3.rbi +8183 -0
- data/sorbet/rbi/gems/rspec-mocks@3.13.2.rbi +5341 -0
- data/sorbet/rbi/gems/rspec-support@3.13.1.rbi +1630 -0
- data/sorbet/rbi/gems/rspec@3.13.0.rbi +83 -0
- data/sorbet/rbi/gems/rubocop-ast@1.36.1.rbi +7303 -0
- data/sorbet/rbi/gems/rubocop-performance@1.21.1.rbi +9 -0
- data/sorbet/rbi/gems/rubocop@1.65.1.rbi +58170 -0
- data/sorbet/rbi/gems/ruby-progressbar@1.13.0.rbi +1318 -0
- data/sorbet/rbi/gems/securerandom@0.3.2.rbi +395 -0
- data/sorbet/rbi/gems/simplecov-html@0.13.1.rbi +225 -0
- data/sorbet/rbi/gems/simplecov@0.22.0.rbi +2149 -0
- data/sorbet/rbi/gems/simplecov_json_formatter@0.1.4.rbi +9 -0
- data/sorbet/rbi/gems/spoom@1.5.0.rbi +4932 -0
- data/sorbet/rbi/gems/standard-custom@1.0.2.rbi +9 -0
- data/sorbet/rbi/gems/standard-performance@1.4.0.rbi +9 -0
- data/sorbet/rbi/gems/standard@1.40.0.rbi +929 -0
- data/sorbet/rbi/gems/stringio@3.1.2.rbi +9 -0
- data/sorbet/rbi/gems/tapioca@0.16.4.rbi +3597 -0
- data/sorbet/rbi/gems/thor@1.3.2.rbi +4378 -0
- data/sorbet/rbi/gems/timeout@0.4.2.rbi +151 -0
- data/sorbet/rbi/gems/tzinfo@2.0.6.rbi +5918 -0
- data/sorbet/rbi/gems/unicode-display_width@2.6.0.rbi +66 -0
- data/sorbet/rbi/gems/uri@1.0.2.rbi +2377 -0
- data/sorbet/rbi/gems/useragent@0.16.10.rbi +9 -0
- data/sorbet/rbi/gems/websocket-driver@0.7.6.rbi +9 -0
- data/sorbet/rbi/gems/websocket-extensions@0.1.5.rbi +9 -0
- data/sorbet/rbi/gems/yard-sorbet@0.9.0.rbi +435 -0
- data/sorbet/rbi/gems/yard@0.9.37.rbi +18504 -0
- data/sorbet/rbi/gems/zeitwerk@2.7.1.rbi +9 -0
- data/sorbet/tapioca/config.yml +13 -0
- data/sorbet/tapioca/require.rb +12 -0
- metadata +543 -0
@@ -0,0 +1,395 @@
|
|
1
|
+
# typed: false
|
2
|
+
|
3
|
+
# DO NOT EDIT MANUALLY
|
4
|
+
# This is an autogenerated file for types exported from the `securerandom` gem.
|
5
|
+
# Please instead update this file by running `bin/tapioca gem securerandom`.
|
6
|
+
|
7
|
+
|
8
|
+
class Random::Base
|
9
|
+
include ::Random::Formatter
|
10
|
+
extend ::Random::Formatter
|
11
|
+
|
12
|
+
def initialize(*_arg0); end
|
13
|
+
|
14
|
+
def bytes(_arg0); end
|
15
|
+
def rand(*_arg0); end
|
16
|
+
def seed; end
|
17
|
+
end
|
18
|
+
|
19
|
+
# == \Random number formatter.
|
20
|
+
#
|
21
|
+
# Formats generated random numbers in many manners. When <tt>'random/formatter'</tt>
|
22
|
+
# is required, several methods are added to empty core module <tt>Random::Formatter</tt>,
|
23
|
+
# making them available as Random's instance and module methods.
|
24
|
+
#
|
25
|
+
# Standard library SecureRandom is also extended with the module, and the methods
|
26
|
+
# described below are available as a module methods in it.
|
27
|
+
#
|
28
|
+
# === Examples
|
29
|
+
#
|
30
|
+
# Generate random hexadecimal strings:
|
31
|
+
#
|
32
|
+
# require 'random/formatter'
|
33
|
+
#
|
34
|
+
# prng = Random.new
|
35
|
+
# prng.hex(10) #=> "52750b30ffbc7de3b362"
|
36
|
+
# prng.hex(10) #=> "92b15d6c8dc4beb5f559"
|
37
|
+
# prng.hex(13) #=> "39b290146bea6ce975c37cfc23"
|
38
|
+
# # or just
|
39
|
+
# Random.hex #=> "1aed0c631e41be7f77365415541052ee"
|
40
|
+
#
|
41
|
+
# Generate random base64 strings:
|
42
|
+
#
|
43
|
+
# prng.base64(10) #=> "EcmTPZwWRAozdA=="
|
44
|
+
# prng.base64(10) #=> "KO1nIU+p9DKxGg=="
|
45
|
+
# prng.base64(12) #=> "7kJSM/MzBJI+75j8"
|
46
|
+
# Random.base64(4) #=> "bsQ3fQ=="
|
47
|
+
#
|
48
|
+
# Generate random binary strings:
|
49
|
+
#
|
50
|
+
# prng.random_bytes(10) #=> "\016\t{\370g\310pbr\301"
|
51
|
+
# prng.random_bytes(10) #=> "\323U\030TO\234\357\020\a\337"
|
52
|
+
# Random.random_bytes(6) #=> "\xA1\xE6Lr\xC43"
|
53
|
+
#
|
54
|
+
# Generate alphanumeric strings:
|
55
|
+
#
|
56
|
+
# prng.alphanumeric(10) #=> "S8baxMJnPl"
|
57
|
+
# prng.alphanumeric(10) #=> "aOxAg8BAJe"
|
58
|
+
# Random.alphanumeric #=> "TmP9OsJHJLtaZYhP"
|
59
|
+
#
|
60
|
+
# Generate UUIDs:
|
61
|
+
#
|
62
|
+
# prng.uuid #=> "2d931510-d99f-494a-8c67-87feb05e1594"
|
63
|
+
# prng.uuid #=> "bad85eb9-0713-4da7-8d36-07a8e4b00eab"
|
64
|
+
# Random.uuid #=> "f14e0271-de96-45cc-8911-8910292a42cd"
|
65
|
+
#
|
66
|
+
# All methods are available in the standard library SecureRandom, too:
|
67
|
+
#
|
68
|
+
# SecureRandom.hex #=> "05b45376a30c67238eb93b16499e50cf"
|
69
|
+
#
|
70
|
+
# source://securerandom//lib/random/formatter.rb#55
|
71
|
+
module Random::Formatter
|
72
|
+
# Generate a random alphanumeric string.
|
73
|
+
#
|
74
|
+
# The argument _n_ specifies the length, in characters, of the alphanumeric
|
75
|
+
# string to be generated.
|
76
|
+
# The argument _chars_ specifies the character list which the result is
|
77
|
+
# consist of.
|
78
|
+
#
|
79
|
+
# If _n_ is not specified or is nil, 16 is assumed.
|
80
|
+
# It may be larger in the future.
|
81
|
+
#
|
82
|
+
# The result may contain A-Z, a-z and 0-9, unless _chars_ is specified.
|
83
|
+
#
|
84
|
+
# require 'random/formatter'
|
85
|
+
#
|
86
|
+
# Random.alphanumeric #=> "2BuBuLf3WfSKyQbR"
|
87
|
+
# # or
|
88
|
+
# prng = Random.new
|
89
|
+
# prng.alphanumeric(10) #=> "i6K93NdqiH"
|
90
|
+
#
|
91
|
+
# Random.alphanumeric(4, chars: [*"0".."9"]) #=> "2952"
|
92
|
+
# # or
|
93
|
+
# prng = Random.new
|
94
|
+
# prng.alphanumeric(10, chars: [*"!".."/"]) #=> ",.,++%/''."
|
95
|
+
#
|
96
|
+
# source://securerandom//lib/random/formatter.rb#368
|
97
|
+
def alphanumeric(n = T.unsafe(nil), chars: T.unsafe(nil)); end
|
98
|
+
|
99
|
+
# Generate a random base64 string.
|
100
|
+
#
|
101
|
+
# The argument _n_ specifies the length, in bytes, of the random number
|
102
|
+
# to be generated. The length of the result string is about 4/3 of _n_.
|
103
|
+
#
|
104
|
+
# If _n_ is not specified or is nil, 16 is assumed.
|
105
|
+
# It may be larger in the future.
|
106
|
+
#
|
107
|
+
# The result may contain A-Z, a-z, 0-9, "+", "/" and "=".
|
108
|
+
#
|
109
|
+
# require 'random/formatter'
|
110
|
+
#
|
111
|
+
# Random.base64 #=> "/2BuBuLf3+WfSKyQbRcc/A=="
|
112
|
+
# # or
|
113
|
+
# prng = Random.new
|
114
|
+
# prng.base64 #=> "6BbW0pxO0YENxn38HMUbcQ=="
|
115
|
+
#
|
116
|
+
# See RFC 3548 for the definition of base64.
|
117
|
+
#
|
118
|
+
# source://securerandom//lib/random/formatter.rb#115
|
119
|
+
def base64(n = T.unsafe(nil)); end
|
120
|
+
|
121
|
+
# Generate a random hexadecimal string.
|
122
|
+
#
|
123
|
+
# The argument _n_ specifies the length, in bytes, of the random number to be generated.
|
124
|
+
# The length of the resulting hexadecimal string is twice of _n_.
|
125
|
+
#
|
126
|
+
# If _n_ is not specified or is nil, 16 is assumed.
|
127
|
+
# It may be larger in the future.
|
128
|
+
#
|
129
|
+
# The result may contain 0-9 and a-f.
|
130
|
+
#
|
131
|
+
# require 'random/formatter'
|
132
|
+
#
|
133
|
+
# Random.hex #=> "eb693ec8252cd630102fd0d0fb7c3485"
|
134
|
+
# # or
|
135
|
+
# prng = Random.new
|
136
|
+
# prng.hex #=> "91dc3bfb4de5b11d029d376634589b61"
|
137
|
+
#
|
138
|
+
# source://securerandom//lib/random/formatter.rb#93
|
139
|
+
def hex(n = T.unsafe(nil)); end
|
140
|
+
|
141
|
+
# Generate a random binary string.
|
142
|
+
#
|
143
|
+
# The argument _n_ specifies the length of the result string.
|
144
|
+
#
|
145
|
+
# If _n_ is not specified or is nil, 16 is assumed.
|
146
|
+
# It may be larger in future.
|
147
|
+
#
|
148
|
+
# The result may contain any byte: "\x00" - "\xff".
|
149
|
+
#
|
150
|
+
# require 'random/formatter'
|
151
|
+
#
|
152
|
+
# Random.random_bytes #=> "\xD8\\\xE0\xF4\r\xB2\xFC*WM\xFF\x83\x18\xF45\xB6"
|
153
|
+
# # or
|
154
|
+
# prng = Random.new
|
155
|
+
# prng.random_bytes #=> "m\xDC\xFC/\a\x00Uf\xB2\xB2P\xBD\xFF6S\x97"
|
156
|
+
#
|
157
|
+
# source://securerandom//lib/random/formatter.rb#72
|
158
|
+
def random_bytes(n = T.unsafe(nil)); end
|
159
|
+
|
160
|
+
# Generate a random URL-safe base64 string.
|
161
|
+
#
|
162
|
+
# The argument _n_ specifies the length, in bytes, of the random number
|
163
|
+
# to be generated. The length of the result string is about 4/3 of _n_.
|
164
|
+
#
|
165
|
+
# If _n_ is not specified or is nil, 16 is assumed.
|
166
|
+
# It may be larger in the future.
|
167
|
+
#
|
168
|
+
# The boolean argument _padding_ specifies the padding.
|
169
|
+
# If it is false or nil, padding is not generated.
|
170
|
+
# Otherwise padding is generated.
|
171
|
+
# By default, padding is not generated because "=" may be used as a URL delimiter.
|
172
|
+
#
|
173
|
+
# The result may contain A-Z, a-z, 0-9, "-" and "_".
|
174
|
+
# "=" is also used if _padding_ is true.
|
175
|
+
#
|
176
|
+
# require 'random/formatter'
|
177
|
+
#
|
178
|
+
# Random.urlsafe_base64 #=> "b4GOKm4pOYU_-BOXcrUGDg"
|
179
|
+
# # or
|
180
|
+
# prng = Random.new
|
181
|
+
# prng.urlsafe_base64 #=> "UZLdOkzop70Ddx-IJR0ABg"
|
182
|
+
#
|
183
|
+
# prng.urlsafe_base64(nil, true) #=> "i0XQ-7gglIsHGV2_BNPrdQ=="
|
184
|
+
# prng.urlsafe_base64(nil, true) #=> "-M8rLhr7JEpJlqFGUMmOxg=="
|
185
|
+
#
|
186
|
+
# See RFC 3548 for the definition of URL-safe base64.
|
187
|
+
#
|
188
|
+
# source://securerandom//lib/random/formatter.rb#146
|
189
|
+
def urlsafe_base64(n = T.unsafe(nil), padding = T.unsafe(nil)); end
|
190
|
+
|
191
|
+
# Generate a random v4 UUID (Universally Unique IDentifier).
|
192
|
+
#
|
193
|
+
# require 'random/formatter'
|
194
|
+
#
|
195
|
+
# Random.uuid #=> "2d931510-d99f-494a-8c67-87feb05e1594"
|
196
|
+
# Random.uuid #=> "bad85eb9-0713-4da7-8d36-07a8e4b00eab"
|
197
|
+
# # or
|
198
|
+
# prng = Random.new
|
199
|
+
# prng.uuid #=> "62936e70-1815-439b-bf89-8492855a7e6b"
|
200
|
+
#
|
201
|
+
# The version 4 UUID is purely random (except the version).
|
202
|
+
# It doesn't contain meaningful information such as MAC addresses, timestamps, etc.
|
203
|
+
#
|
204
|
+
# The result contains 122 random bits (15.25 random bytes).
|
205
|
+
#
|
206
|
+
# See RFC9562[https://www.rfc-editor.org/rfc/rfc9562] for details of UUIDv4.
|
207
|
+
#
|
208
|
+
# source://securerandom//lib/random/formatter.rb#170
|
209
|
+
def uuid; end
|
210
|
+
|
211
|
+
# Generate a random v4 UUID (Universally Unique IDentifier).
|
212
|
+
#
|
213
|
+
# require 'random/formatter'
|
214
|
+
#
|
215
|
+
# Random.uuid #=> "2d931510-d99f-494a-8c67-87feb05e1594"
|
216
|
+
# Random.uuid #=> "bad85eb9-0713-4da7-8d36-07a8e4b00eab"
|
217
|
+
# # or
|
218
|
+
# prng = Random.new
|
219
|
+
# prng.uuid #=> "62936e70-1815-439b-bf89-8492855a7e6b"
|
220
|
+
#
|
221
|
+
# The version 4 UUID is purely random (except the version).
|
222
|
+
# It doesn't contain meaningful information such as MAC addresses, timestamps, etc.
|
223
|
+
#
|
224
|
+
# The result contains 122 random bits (15.25 random bytes).
|
225
|
+
#
|
226
|
+
# See RFC9562[https://www.rfc-editor.org/rfc/rfc9562] for details of UUIDv4.
|
227
|
+
#
|
228
|
+
# source://securerandom//lib/random/formatter.rb#170
|
229
|
+
def uuid_v4; end
|
230
|
+
|
231
|
+
# Generate a random v7 UUID (Universally Unique IDentifier).
|
232
|
+
#
|
233
|
+
# require 'random/formatter'
|
234
|
+
#
|
235
|
+
# Random.uuid_v7 # => "0188d4c3-1311-7f96-85c7-242a7aa58f1e"
|
236
|
+
# Random.uuid_v7 # => "0188d4c3-16fe-744f-86af-38fa04c62bb5"
|
237
|
+
# Random.uuid_v7 # => "0188d4c3-1af8-764f-b049-c204ce0afa23"
|
238
|
+
# Random.uuid_v7 # => "0188d4c3-1e74-7085-b14f-ef6415dc6f31"
|
239
|
+
# # |<--sorted-->| |<----- random ---->|
|
240
|
+
#
|
241
|
+
# # or
|
242
|
+
# prng = Random.new
|
243
|
+
# prng.uuid_v7 # => "0188ca51-5e72-7950-a11d-def7ff977c98"
|
244
|
+
#
|
245
|
+
# The version 7 UUID starts with the least significant 48 bits of a 64 bit
|
246
|
+
# Unix timestamp (milliseconds since the epoch) and fills the remaining bits
|
247
|
+
# with random data, excluding the version and variant bits.
|
248
|
+
#
|
249
|
+
# This allows version 7 UUIDs to be sorted by creation time. Time ordered
|
250
|
+
# UUIDs can be used for better database index locality of newly inserted
|
251
|
+
# records, which may have a significant performance benefit compared to random
|
252
|
+
# data inserts.
|
253
|
+
#
|
254
|
+
# The result contains 74 random bits (9.25 random bytes).
|
255
|
+
#
|
256
|
+
# Note that this method cannot be made reproducible because its output
|
257
|
+
# includes not only random bits but also timestamp.
|
258
|
+
#
|
259
|
+
# See RFC9562[https://www.rfc-editor.org/rfc/rfc9562] for details of UUIDv7.
|
260
|
+
#
|
261
|
+
# ==== Monotonicity
|
262
|
+
#
|
263
|
+
# UUIDv7 has millisecond precision by default, so multiple UUIDs created
|
264
|
+
# within the same millisecond are not issued in monotonically increasing
|
265
|
+
# order. To create UUIDs that are time-ordered with sub-millisecond
|
266
|
+
# precision, up to 12 bits of additional timestamp may added with
|
267
|
+
# +extra_timestamp_bits+. The extra timestamp precision comes at the expense
|
268
|
+
# of random bits. Setting <tt>extra_timestamp_bits: 12</tt> provides ~244ns
|
269
|
+
# of precision, but only 62 random bits (7.75 random bytes).
|
270
|
+
#
|
271
|
+
# prng = Random.new
|
272
|
+
# Array.new(4) { prng.uuid_v7(extra_timestamp_bits: 12) }
|
273
|
+
# # =>
|
274
|
+
# ["0188d4c7-13da-74f9-8b53-22a786ffdd5a",
|
275
|
+
# "0188d4c7-13da-753b-83a5-7fb9b2afaeea",
|
276
|
+
# "0188d4c7-13da-754a-88ea-ac0baeedd8db",
|
277
|
+
# "0188d4c7-13da-7557-83e1-7cad9cda0d8d"]
|
278
|
+
# # |<--- sorted --->| |<-- random --->|
|
279
|
+
#
|
280
|
+
# Array.new(4) { prng.uuid_v7(extra_timestamp_bits: 8) }
|
281
|
+
# # =>
|
282
|
+
# ["0188d4c7-3333-7a95-850a-de6edb858f7e",
|
283
|
+
# "0188d4c7-3333-7ae8-842e-bc3a8b7d0cf9", # <- out of order
|
284
|
+
# "0188d4c7-3333-7ae2-995a-9f135dc44ead", # <- out of order
|
285
|
+
# "0188d4c7-3333-7af9-87c3-8f612edac82e"]
|
286
|
+
# # |<--- sorted -->||<---- random --->|
|
287
|
+
#
|
288
|
+
# Any rollbacks of the system clock will break monotonicity. UUIDv7 is based
|
289
|
+
# on UTC, which excludes leap seconds and can rollback the clock. To avoid
|
290
|
+
# this, the system clock can synchronize with an NTP server configured to use
|
291
|
+
# a "leap smear" approach. NTP or PTP will also be needed to synchronize
|
292
|
+
# across distributed nodes.
|
293
|
+
#
|
294
|
+
# Counters and other mechanisms for stronger guarantees of monotonicity are
|
295
|
+
# not implemented. Applications with stricter requirements should follow
|
296
|
+
# {Section 6.2}[https://www.rfc-editor.org/rfc/rfc9562.html#name-monotonicity-and-counters]
|
297
|
+
# of the specification.
|
298
|
+
#
|
299
|
+
# source://securerandom//lib/random/formatter.rb#247
|
300
|
+
def uuid_v7(extra_timestamp_bits: T.unsafe(nil)); end
|
301
|
+
|
302
|
+
private
|
303
|
+
|
304
|
+
# Generate a string that randomly draws from a
|
305
|
+
# source array of characters.
|
306
|
+
#
|
307
|
+
# The argument _source_ specifies the array of characters from which
|
308
|
+
# to generate the string.
|
309
|
+
# The argument _n_ specifies the length, in characters, of the string to be
|
310
|
+
# generated.
|
311
|
+
#
|
312
|
+
# The result may contain whatever characters are in the source array.
|
313
|
+
#
|
314
|
+
# require 'random/formatter'
|
315
|
+
#
|
316
|
+
# prng.choose([*'l'..'r'], 16) #=> "lmrqpoonmmlqlron"
|
317
|
+
# prng.choose([*'0'..'9'], 5) #=> "27309"
|
318
|
+
#
|
319
|
+
# source://securerandom//lib/random/formatter.rb#313
|
320
|
+
def choose(source, n); end
|
321
|
+
|
322
|
+
# Internal interface to Random; Generate random data _n_ bytes.
|
323
|
+
#
|
324
|
+
# source://securerandom//lib/random/formatter.rb#295
|
325
|
+
def gen_random(n); end
|
326
|
+
end
|
327
|
+
|
328
|
+
# == Secure random number generator interface.
|
329
|
+
#
|
330
|
+
# This library is an interface to secure random number generators which are
|
331
|
+
# suitable for generating session keys in HTTP cookies, etc.
|
332
|
+
#
|
333
|
+
# You can use this library in your application by requiring it:
|
334
|
+
#
|
335
|
+
# require 'securerandom'
|
336
|
+
#
|
337
|
+
# It supports the following secure random number generators:
|
338
|
+
#
|
339
|
+
# * openssl
|
340
|
+
# * /dev/urandom
|
341
|
+
# * Win32
|
342
|
+
#
|
343
|
+
# SecureRandom is extended by the Random::Formatter module which
|
344
|
+
# defines the following methods:
|
345
|
+
#
|
346
|
+
# * alphanumeric
|
347
|
+
# * base64
|
348
|
+
# * choose
|
349
|
+
# * gen_random
|
350
|
+
# * hex
|
351
|
+
# * rand
|
352
|
+
# * random_bytes
|
353
|
+
# * random_number
|
354
|
+
# * urlsafe_base64
|
355
|
+
# * uuid
|
356
|
+
#
|
357
|
+
# These methods are usable as class methods of SecureRandom such as
|
358
|
+
# +SecureRandom.hex+.
|
359
|
+
#
|
360
|
+
# If a secure random number generator is not available,
|
361
|
+
# +NotImplementedError+ is raised.
|
362
|
+
#
|
363
|
+
# source://securerandom//lib/securerandom.rb#41
|
364
|
+
module SecureRandom
|
365
|
+
extend ::Random::Formatter
|
366
|
+
|
367
|
+
class << self
|
368
|
+
# Returns a random binary string containing +size+ bytes.
|
369
|
+
#
|
370
|
+
# See Random.bytes
|
371
|
+
#
|
372
|
+
# source://securerandom//lib/securerandom.rb#50
|
373
|
+
def bytes(n); end
|
374
|
+
|
375
|
+
# source://securerandom//lib/securerandom.rb#64
|
376
|
+
def gen_random(n); end
|
377
|
+
|
378
|
+
private
|
379
|
+
|
380
|
+
# Implementation using OpenSSL
|
381
|
+
#
|
382
|
+
# source://securerandom//lib/securerandom.rb#59
|
383
|
+
def gen_random_openssl(n); end
|
384
|
+
|
385
|
+
# Implementation using system random device
|
386
|
+
#
|
387
|
+
# source://securerandom//lib/securerandom.rb#64
|
388
|
+
def gen_random_urandom(n); end
|
389
|
+
end
|
390
|
+
end
|
391
|
+
|
392
|
+
# The version
|
393
|
+
#
|
394
|
+
# source://securerandom//lib/securerandom.rb#44
|
395
|
+
SecureRandom::VERSION = T.let(T.unsafe(nil), String)
|
@@ -0,0 +1,225 @@
|
|
1
|
+
# typed: true
|
2
|
+
|
3
|
+
# DO NOT EDIT MANUALLY
|
4
|
+
# This is an autogenerated file for types exported from the `simplecov-html` gem.
|
5
|
+
# Please instead update this file by running `bin/tapioca gem simplecov-html`.
|
6
|
+
|
7
|
+
|
8
|
+
# source://simplecov-html//lib/simplecov-html.rb#16
|
9
|
+
module SimpleCov
|
10
|
+
class << self
|
11
|
+
# source://simplecov/0.22.0/lib/simplecov.rb#174
|
12
|
+
def at_exit_behavior; end
|
13
|
+
|
14
|
+
# source://simplecov/0.22.0/lib/simplecov.rb#170
|
15
|
+
def clear_result; end
|
16
|
+
|
17
|
+
# source://simplecov/0.22.0/lib/simplecov.rb#86
|
18
|
+
def collate(result_filenames, profile = T.unsafe(nil), ignore_timeout: T.unsafe(nil), &block); end
|
19
|
+
|
20
|
+
# source://simplecov/0.22.0/lib/simplecov.rb#223
|
21
|
+
def exit_and_report_previous_error(exit_status); end
|
22
|
+
|
23
|
+
# source://simplecov/0.22.0/lib/simplecov.rb#200
|
24
|
+
def exit_status_from_exception; end
|
25
|
+
|
26
|
+
# source://simplecov/0.22.0/lib/simplecov.rb#28
|
27
|
+
def external_at_exit; end
|
28
|
+
|
29
|
+
# source://simplecov/0.22.0/lib/simplecov.rb#28
|
30
|
+
def external_at_exit=(_arg0); end
|
31
|
+
|
32
|
+
# source://simplecov/0.22.0/lib/simplecov.rb#28
|
33
|
+
def external_at_exit?; end
|
34
|
+
|
35
|
+
# source://simplecov/0.22.0/lib/simplecov.rb#131
|
36
|
+
def filtered(files); end
|
37
|
+
|
38
|
+
# source://simplecov/0.22.0/lib/simplecov.rb#268
|
39
|
+
def final_result_process?; end
|
40
|
+
|
41
|
+
# source://simplecov/0.22.0/lib/simplecov.rb#142
|
42
|
+
def grouped(files); end
|
43
|
+
|
44
|
+
# source://simplecov/0.22.0/lib/simplecov.rb#162
|
45
|
+
def load_adapter(name); end
|
46
|
+
|
47
|
+
# source://simplecov/0.22.0/lib/simplecov.rb#158
|
48
|
+
def load_profile(name); end
|
49
|
+
|
50
|
+
# source://simplecov/0.22.0/lib/simplecov.rb#24
|
51
|
+
def pid; end
|
52
|
+
|
53
|
+
# source://simplecov/0.22.0/lib/simplecov.rb#24
|
54
|
+
def pid=(_arg0); end
|
55
|
+
|
56
|
+
# source://simplecov/0.22.0/lib/simplecov.rb#213
|
57
|
+
def previous_error?(error_exit_status); end
|
58
|
+
|
59
|
+
# source://simplecov/0.22.0/lib/simplecov.rb#248
|
60
|
+
def process_result(result); end
|
61
|
+
|
62
|
+
# source://simplecov/0.22.0/lib/simplecov.rb#233
|
63
|
+
def process_results_and_report_error; end
|
64
|
+
|
65
|
+
# source://simplecov/0.22.0/lib/simplecov.rb#229
|
66
|
+
def ready_to_process_results?; end
|
67
|
+
|
68
|
+
# source://simplecov/0.22.0/lib/simplecov.rb#101
|
69
|
+
def result; end
|
70
|
+
|
71
|
+
# source://simplecov/0.22.0/lib/simplecov.rb#124
|
72
|
+
def result?; end
|
73
|
+
|
74
|
+
# source://simplecov/0.22.0/lib/simplecov.rb#256
|
75
|
+
def result_exit_status(result); end
|
76
|
+
|
77
|
+
# source://simplecov/0.22.0/lib/simplecov.rb#296
|
78
|
+
def round_coverage(coverage); end
|
79
|
+
|
80
|
+
# source://simplecov/0.22.0/lib/simplecov.rb#186
|
81
|
+
def run_exit_tasks!; end
|
82
|
+
|
83
|
+
# source://simplecov/0.22.0/lib/simplecov.rb#24
|
84
|
+
def running; end
|
85
|
+
|
86
|
+
# source://simplecov/0.22.0/lib/simplecov.rb#24
|
87
|
+
def running=(_arg0); end
|
88
|
+
|
89
|
+
# source://simplecov/0.22.0/lib/simplecov.rb#48
|
90
|
+
def start(profile = T.unsafe(nil), &block); end
|
91
|
+
|
92
|
+
# source://simplecov/0.22.0/lib/simplecov.rb#276
|
93
|
+
def wait_for_other_processes; end
|
94
|
+
|
95
|
+
# source://simplecov/0.22.0/lib/simplecov.rb#285
|
96
|
+
def write_last_run(result); end
|
97
|
+
|
98
|
+
private
|
99
|
+
|
100
|
+
# source://simplecov/0.22.0/lib/simplecov.rb#399
|
101
|
+
def adapt_coverage_result; end
|
102
|
+
|
103
|
+
# source://simplecov/0.22.0/lib/simplecov.rb#371
|
104
|
+
def add_not_loaded_files(result); end
|
105
|
+
|
106
|
+
# source://simplecov/0.22.0/lib/simplecov.rb#302
|
107
|
+
def initial_setup(profile, &block); end
|
108
|
+
|
109
|
+
# source://simplecov/0.22.0/lib/simplecov.rb#363
|
110
|
+
def lookup_corresponding_ruby_coverage_name(criterion); end
|
111
|
+
|
112
|
+
# source://simplecov/0.22.0/lib/simplecov.rb#425
|
113
|
+
def make_parallel_tests_available; end
|
114
|
+
|
115
|
+
# source://simplecov/0.22.0/lib/simplecov.rb#434
|
116
|
+
def probably_running_parallel_tests?; end
|
117
|
+
|
118
|
+
# source://simplecov/0.22.0/lib/simplecov.rb#388
|
119
|
+
def process_coverage_result; end
|
120
|
+
|
121
|
+
# source://simplecov/0.22.0/lib/simplecov.rb#410
|
122
|
+
def remove_useless_results; end
|
123
|
+
|
124
|
+
# source://simplecov/0.22.0/lib/simplecov.rb#420
|
125
|
+
def result_with_not_loaded_files; end
|
126
|
+
|
127
|
+
# source://simplecov/0.22.0/lib/simplecov.rb#314
|
128
|
+
def start_coverage_measurement; end
|
129
|
+
|
130
|
+
# source://simplecov/0.22.0/lib/simplecov.rb#349
|
131
|
+
def start_coverage_with_criteria; end
|
132
|
+
end
|
133
|
+
end
|
134
|
+
|
135
|
+
# source://simplecov-html//lib/simplecov-html.rb#17
|
136
|
+
module SimpleCov::Formatter
|
137
|
+
class << self
|
138
|
+
# source://simplecov/0.22.0/lib/simplecov/default_formatter.rb#7
|
139
|
+
def from_env(env); end
|
140
|
+
end
|
141
|
+
end
|
142
|
+
|
143
|
+
# source://simplecov-html//lib/simplecov-html.rb#18
|
144
|
+
class SimpleCov::Formatter::HTMLFormatter
|
145
|
+
# @return [HTMLFormatter] a new instance of HTMLFormatter
|
146
|
+
#
|
147
|
+
# source://simplecov-html//lib/simplecov-html.rb#19
|
148
|
+
def initialize; end
|
149
|
+
|
150
|
+
# source://simplecov-html//lib/simplecov-html.rb#26
|
151
|
+
def format(result); end
|
152
|
+
|
153
|
+
private
|
154
|
+
|
155
|
+
# source://simplecov-html//lib/simplecov-html.rb#94
|
156
|
+
def asset_inline(name); end
|
157
|
+
|
158
|
+
# source://simplecov-html//lib/simplecov-html.rb#72
|
159
|
+
def asset_output_path; end
|
160
|
+
|
161
|
+
# source://simplecov-html//lib/simplecov-html.rb#80
|
162
|
+
def assets_path(name); end
|
163
|
+
|
164
|
+
# @return [Boolean]
|
165
|
+
#
|
166
|
+
# source://simplecov-html//lib/simplecov-html.rb#41
|
167
|
+
def branchable_result?; end
|
168
|
+
|
169
|
+
# source://simplecov-html//lib/simplecov-html.rb#125
|
170
|
+
def coverage_css_class(covered_percent); end
|
171
|
+
|
172
|
+
# source://simplecov-html//lib/simplecov-html.rb#121
|
173
|
+
def covered_percent(percent); end
|
174
|
+
|
175
|
+
# Returns a table containing the given source files
|
176
|
+
#
|
177
|
+
# source://simplecov-html//lib/simplecov-html.rb#112
|
178
|
+
def formatted_file_list(title, source_files); end
|
179
|
+
|
180
|
+
# Returns the html for the given source_file
|
181
|
+
#
|
182
|
+
# source://simplecov-html//lib/simplecov-html.rb#105
|
183
|
+
def formatted_source_file(source_file); end
|
184
|
+
|
185
|
+
# Return a (kind of) unique id for the source file given. Uses SHA1 on path for the id
|
186
|
+
#
|
187
|
+
# source://simplecov-html//lib/simplecov-html.rb#146
|
188
|
+
def id(source_file); end
|
189
|
+
|
190
|
+
# @return [Boolean]
|
191
|
+
#
|
192
|
+
# source://simplecov-html//lib/simplecov-html.rb#48
|
193
|
+
def line_status?(source_file, line); end
|
194
|
+
|
195
|
+
# source://simplecov-html//lib/simplecov-html.rb#158
|
196
|
+
def link_to_source_file(source_file); end
|
197
|
+
|
198
|
+
# source://simplecov-html//lib/simplecov-html.rb#56
|
199
|
+
def output_message(result); end
|
200
|
+
|
201
|
+
# source://simplecov-html//lib/simplecov-html.rb#68
|
202
|
+
def output_path; end
|
203
|
+
|
204
|
+
# source://simplecov-html//lib/simplecov-html.rb#154
|
205
|
+
def shortened_filename(source_file); end
|
206
|
+
|
207
|
+
# source://simplecov-html//lib/simplecov-html.rb#135
|
208
|
+
def strength_css_class(covered_strength); end
|
209
|
+
|
210
|
+
# Returns the an erb instance for the template of given name
|
211
|
+
#
|
212
|
+
# source://simplecov-html//lib/simplecov-html.rb#64
|
213
|
+
def template(name); end
|
214
|
+
|
215
|
+
# source://simplecov-html//lib/simplecov-html.rb#150
|
216
|
+
def timeago(time); end
|
217
|
+
end
|
218
|
+
|
219
|
+
# Only have a few content types, just hardcode them
|
220
|
+
#
|
221
|
+
# source://simplecov-html//lib/simplecov-html.rb#87
|
222
|
+
SimpleCov::Formatter::HTMLFormatter::CONTENT_TYPES = T.let(T.unsafe(nil), Hash)
|
223
|
+
|
224
|
+
# source://simplecov-html//lib/simplecov-html/version.rb#6
|
225
|
+
SimpleCov::Formatter::HTMLFormatter::VERSION = T.let(T.unsafe(nil), String)
|