cybrid_api_organization_ruby 0.124.85 → 0.124.86
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- checksums.yaml +4 -4
- data/Gemfile.lock +4 -4
- data/README.md +5 -5
- data/cybrid_api_organization_ruby.gemspec +1 -1
- data/lib/cybrid_api_organization_ruby/api/organizations_organization_api.rb +1 -1
- data/lib/cybrid_api_organization_ruby/api/subscription_deliveries_organization_api.rb +1 -1
- data/lib/cybrid_api_organization_ruby/api/subscription_events_organization_api.rb +1 -1
- data/lib/cybrid_api_organization_ruby/api/subscriptions_organization_api.rb +1 -1
- data/lib/cybrid_api_organization_ruby/api_client.rb +1 -1
- data/lib/cybrid_api_organization_ruby/api_error.rb +1 -1
- data/lib/cybrid_api_organization_ruby/configuration.rb +1 -1
- data/lib/cybrid_api_organization_ruby/models/error_response_organization_model.rb +1 -1
- data/lib/cybrid_api_organization_ruby/models/organization_organization_model.rb +1 -1
- data/lib/cybrid_api_organization_ruby/models/patch_organization_organization_model.rb +1 -1
- data/lib/cybrid_api_organization_ruby/models/post_subscription_delivery_organization_model.rb +1 -1
- data/lib/cybrid_api_organization_ruby/models/post_subscription_organization_model.rb +1 -1
- data/lib/cybrid_api_organization_ruby/models/subscription_delivery_list_organization_model.rb +1 -1
- data/lib/cybrid_api_organization_ruby/models/subscription_delivery_organization_model.rb +1 -1
- data/lib/cybrid_api_organization_ruby/models/subscription_environment_organization_model.rb +1 -1
- data/lib/cybrid_api_organization_ruby/models/subscription_event_list_organization_model.rb +1 -1
- data/lib/cybrid_api_organization_ruby/models/subscription_event_organization_model.rb +1 -1
- data/lib/cybrid_api_organization_ruby/models/subscription_list_organization_model.rb +1 -1
- data/lib/cybrid_api_organization_ruby/models/subscription_organization_model.rb +1 -1
- data/lib/cybrid_api_organization_ruby/models/subscription_state_organization_model.rb +1 -1
- data/lib/cybrid_api_organization_ruby/models/subscription_type_organization_model.rb +1 -1
- data/lib/cybrid_api_organization_ruby/version.rb +2 -2
- data/lib/cybrid_api_organization_ruby.rb +1 -1
- data/spec/api/organizations_organization_api_spec.rb +1 -1
- data/spec/api/subscription_deliveries_organization_api_spec.rb +1 -1
- data/spec/api/subscription_events_organization_api_spec.rb +1 -1
- data/spec/api/subscriptions_organization_api_spec.rb +1 -1
- data/spec/api_client_spec.rb +1 -1
- data/spec/configuration_spec.rb +1 -1
- data/spec/models/error_response_organization_model_spec.rb +1 -1
- data/spec/models/organization_organization_model_spec.rb +1 -1
- data/spec/models/patch_organization_organization_model_spec.rb +1 -1
- data/spec/models/post_subscription_delivery_organization_model_spec.rb +1 -1
- data/spec/models/post_subscription_organization_model_spec.rb +1 -1
- data/spec/models/subscription_delivery_list_organization_model_spec.rb +1 -1
- data/spec/models/subscription_delivery_organization_model_spec.rb +1 -1
- data/spec/models/subscription_environment_organization_model_spec.rb +1 -1
- data/spec/models/subscription_event_list_organization_model_spec.rb +1 -1
- data/spec/models/subscription_event_organization_model_spec.rb +1 -1
- data/spec/models/subscription_list_organization_model_spec.rb +1 -1
- data/spec/models/subscription_organization_model_spec.rb +1 -1
- data/spec/models/subscription_state_organization_model_spec.rb +1 -1
- data/spec/models/subscription_type_organization_model_spec.rb +1 -1
- data/spec/spec_helper.rb +1 -1
- data/vendor/bundle/ruby/3.3.0/cache/ethon-0.15.0.gem +0 -0
- data/vendor/bundle/ruby/3.3.0/cache/typhoeus-1.5.0.gem +0 -0
- data/vendor/bundle/ruby/3.3.0/extensions/x86_64-linux/3.3.0/byebug-12.0.0/gem_make.out +5 -5
- data/vendor/bundle/ruby/3.3.0/extensions/x86_64-linux/3.3.0/date-3.4.1/gem_make.out +5 -5
- data/vendor/bundle/ruby/3.3.0/extensions/x86_64-linux/3.3.0/jaro_winkler-1.5.6/gem_make.out +5 -5
- data/vendor/bundle/ruby/3.3.0/extensions/x86_64-linux/3.3.0/psych-5.2.6/gem_make.out +5 -5
- data/vendor/bundle/ruby/3.3.0/extensions/x86_64-linux/3.3.0/racc-1.8.1/gem_make.out +5 -5
- data/vendor/bundle/ruby/3.3.0/extensions/x86_64-linux/3.3.0/stringio-3.1.7/gem_make.out +5 -5
- data/vendor/bundle/ruby/3.3.0/gems/ethon-0.15.0/.github/workflows/ruby.yml +41 -0
- data/vendor/bundle/ruby/3.3.0/gems/{typhoeus-1.4.1 → ethon-0.15.0}/.gitignore +4 -4
- data/vendor/bundle/ruby/3.3.0/gems/{typhoeus-1.4.1 → ethon-0.15.0}/.rspec +0 -1
- data/vendor/bundle/ruby/3.3.0/gems/{ethon-0.17.0 → ethon-0.15.0}/CHANGELOG.md +1 -29
- data/vendor/bundle/ruby/3.3.0/gems/ethon-0.15.0/Gemfile +43 -0
- data/vendor/bundle/ruby/3.3.0/gems/{typhoeus-1.4.1 → ethon-0.15.0}/Guardfile +3 -2
- data/vendor/bundle/ruby/3.3.0/gems/{ethon-0.17.0 → ethon-0.15.0}/README.md +0 -23
- data/vendor/bundle/ruby/3.3.0/gems/{typhoeus-1.4.1 → ethon-0.15.0}/Rakefile +7 -5
- data/vendor/bundle/ruby/3.3.0/gems/{ethon-0.17.0 → ethon-0.15.0}/ethon.gemspec +3 -6
- data/vendor/bundle/ruby/3.3.0/gems/{ethon-0.17.0 → ethon-0.15.0}/lib/ethon/curls/classes.rb +2 -12
- data/vendor/bundle/ruby/3.3.0/gems/{ethon-0.17.0 → ethon-0.15.0}/lib/ethon/curls/codes.rb +2 -3
- data/vendor/bundle/ruby/3.3.0/gems/{ethon-0.17.0 → ethon-0.15.0}/lib/ethon/curls/options.rb +3 -4
- data/vendor/bundle/ruby/3.3.0/gems/{ethon-0.17.0 → ethon-0.15.0}/lib/ethon/easy/callbacks.rb +1 -2
- data/vendor/bundle/ruby/3.3.0/gems/{ethon-0.17.0 → ethon-0.15.0}/lib/ethon/easy/informations.rb +0 -3
- data/vendor/bundle/ruby/3.3.0/gems/{ethon-0.17.0 → ethon-0.15.0}/lib/ethon/easy/response_callbacks.rb +1 -6
- data/vendor/bundle/ruby/3.3.0/gems/{ethon-0.17.0 → ethon-0.15.0}/lib/ethon/version.rb +1 -1
- data/vendor/bundle/ruby/3.3.0/gems/ethon-0.15.0/profile/benchmarks.rb +104 -0
- data/vendor/bundle/ruby/3.3.0/gems/ethon-0.15.0/profile/memory_leaks.rb +114 -0
- data/vendor/bundle/ruby/3.3.0/gems/ethon-0.15.0/profile/perf_spec_helper.rb +37 -0
- data/vendor/bundle/ruby/3.3.0/gems/ethon-0.15.0/profile/support/memory_test_helpers.rb +76 -0
- data/vendor/bundle/ruby/3.3.0/gems/ethon-0.15.0/profile/support/os_memory_leak_tracker.rb +48 -0
- data/vendor/bundle/ruby/3.3.0/gems/ethon-0.15.0/profile/support/ruby_object_leak_tracker.rb +49 -0
- data/vendor/bundle/ruby/3.3.0/gems/ethon-0.15.0/spec/ethon/curl_spec.rb +38 -0
- data/vendor/bundle/ruby/3.3.0/gems/ethon-0.15.0/spec/ethon/easy/callbacks_spec.rb +59 -0
- data/vendor/bundle/ruby/3.3.0/gems/ethon-0.15.0/spec/ethon/easy/debug_info_spec.rb +54 -0
- data/vendor/bundle/ruby/3.3.0/gems/ethon-0.15.0/spec/ethon/easy/features_spec.rb +24 -0
- data/vendor/bundle/ruby/3.3.0/gems/ethon-0.15.0/spec/ethon/easy/form_spec.rb +104 -0
- data/vendor/bundle/ruby/3.3.0/gems/ethon-0.15.0/spec/ethon/easy/header_spec.rb +79 -0
- data/vendor/bundle/ruby/3.3.0/gems/ethon-0.15.0/spec/ethon/easy/http/custom_spec.rb +177 -0
- data/vendor/bundle/ruby/3.3.0/gems/ethon-0.15.0/spec/ethon/easy/http/delete_spec.rb +21 -0
- data/vendor/bundle/ruby/3.3.0/gems/ethon-0.15.0/spec/ethon/easy/http/get_spec.rb +126 -0
- data/vendor/bundle/ruby/3.3.0/gems/ethon-0.15.0/spec/ethon/easy/http/head_spec.rb +80 -0
- data/vendor/bundle/ruby/3.3.0/gems/ethon-0.15.0/spec/ethon/easy/http/options_spec.rb +51 -0
- data/vendor/bundle/ruby/3.3.0/gems/ethon-0.15.0/spec/ethon/easy/http/patch_spec.rb +51 -0
- data/vendor/bundle/ruby/3.3.0/gems/ethon-0.15.0/spec/ethon/easy/http/post_spec.rb +317 -0
- data/vendor/bundle/ruby/3.3.0/gems/ethon-0.15.0/spec/ethon/easy/http/put_spec.rb +168 -0
- data/vendor/bundle/ruby/3.3.0/gems/ethon-0.15.0/spec/ethon/easy/http_spec.rb +64 -0
- data/vendor/bundle/ruby/3.3.0/gems/ethon-0.15.0/spec/ethon/easy/informations_spec.rb +120 -0
- data/vendor/bundle/ruby/3.3.0/gems/ethon-0.15.0/spec/ethon/easy/mirror_spec.rb +47 -0
- data/vendor/bundle/ruby/3.3.0/gems/ethon-0.15.0/spec/ethon/easy/operations_spec.rb +268 -0
- data/vendor/bundle/ruby/3.3.0/gems/ethon-0.15.0/spec/ethon/easy/options_spec.rb +193 -0
- data/vendor/bundle/ruby/3.3.0/gems/ethon-0.15.0/spec/ethon/easy/queryable_spec.rb +235 -0
- data/vendor/bundle/ruby/3.3.0/gems/ethon-0.15.0/spec/ethon/easy/response_callbacks_spec.rb +152 -0
- data/vendor/bundle/ruby/3.3.0/gems/ethon-0.15.0/spec/ethon/easy/util_spec.rb +28 -0
- data/vendor/bundle/ruby/3.3.0/gems/ethon-0.15.0/spec/ethon/easy_spec.rb +203 -0
- data/vendor/bundle/ruby/3.3.0/gems/ethon-0.15.0/spec/ethon/libc_spec.rb +14 -0
- data/vendor/bundle/ruby/3.3.0/gems/ethon-0.15.0/spec/ethon/loggable_spec.rb +22 -0
- data/vendor/bundle/ruby/3.3.0/gems/ethon-0.15.0/spec/ethon/multi/operations_spec.rb +298 -0
- data/vendor/bundle/ruby/3.3.0/gems/ethon-0.15.0/spec/ethon/multi/options_spec.rb +182 -0
- data/vendor/bundle/ruby/3.3.0/gems/ethon-0.15.0/spec/ethon/multi/stack_spec.rb +80 -0
- data/vendor/bundle/ruby/3.3.0/gems/ethon-0.15.0/spec/ethon/multi_spec.rb +152 -0
- data/vendor/bundle/ruby/3.3.0/gems/ethon-0.15.0/spec/spec_helper.rb +28 -0
- data/vendor/bundle/ruby/3.3.0/gems/{typhoeus-1.4.1 → ethon-0.15.0}/spec/support/localhost_server.rb +2 -1
- data/vendor/bundle/ruby/3.3.0/gems/{typhoeus-1.4.1 → ethon-0.15.0}/spec/support/server.rb +10 -11
- data/vendor/bundle/ruby/3.3.0/gems/{typhoeus-1.4.1 → typhoeus-1.5.0}/CHANGELOG.md +43 -1
- data/vendor/bundle/ruby/3.3.0/gems/{typhoeus-1.4.1 → typhoeus-1.5.0}/lib/typhoeus/expectation.rb +4 -2
- data/vendor/bundle/ruby/3.3.0/gems/{typhoeus-1.4.1 → typhoeus-1.5.0}/lib/typhoeus/request/responseable.rb +1 -1
- data/vendor/bundle/ruby/3.3.0/gems/{typhoeus-1.4.1 → typhoeus-1.5.0}/lib/typhoeus/version.rb +1 -1
- data/vendor/bundle/ruby/3.3.0/gems/{typhoeus-1.4.1 → typhoeus-1.5.0}/typhoeus.gemspec +14 -4
- data/vendor/bundle/ruby/3.3.0/specifications/{ethon-0.17.0.gemspec → ethon-0.15.0.gemspec} +5 -6
- data/vendor/bundle/ruby/3.3.0/specifications/typhoeus-1.5.0.gemspec +26 -0
- metadata +156 -160
- data/vendor/bundle/ruby/3.3.0/cache/ethon-0.17.0.gem +0 -0
- data/vendor/bundle/ruby/3.3.0/cache/typhoeus-1.4.1.gem +0 -0
- data/vendor/bundle/ruby/3.3.0/gems/typhoeus-1.4.1/.github/workflows/ci.yml +0 -30
- data/vendor/bundle/ruby/3.3.0/gems/typhoeus-1.4.1/.github/workflows/experimental.yml +0 -33
- data/vendor/bundle/ruby/3.3.0/gems/typhoeus-1.4.1/Gemfile +0 -36
- data/vendor/bundle/ruby/3.3.0/gems/typhoeus-1.4.1/perf/profile.rb +0 -14
- data/vendor/bundle/ruby/3.3.0/gems/typhoeus-1.4.1/perf/vs_nethttp.rb +0 -64
- data/vendor/bundle/ruby/3.3.0/gems/typhoeus-1.4.1/spec/rack/typhoeus/middleware/params_decoder/helper_spec.rb +0 -156
- data/vendor/bundle/ruby/3.3.0/gems/typhoeus-1.4.1/spec/rack/typhoeus/middleware/params_decoder_spec.rb +0 -31
- data/vendor/bundle/ruby/3.3.0/gems/typhoeus-1.4.1/spec/spec_helper.rb +0 -29
- data/vendor/bundle/ruby/3.3.0/gems/typhoeus-1.4.1/spec/support/memory_cache.rb +0 -15
- data/vendor/bundle/ruby/3.3.0/gems/typhoeus-1.4.1/spec/typhoeus/adapters/faraday_spec.rb +0 -339
- data/vendor/bundle/ruby/3.3.0/gems/typhoeus-1.4.1/spec/typhoeus/cache/dalli_spec.rb +0 -41
- data/vendor/bundle/ruby/3.3.0/gems/typhoeus-1.4.1/spec/typhoeus/cache/redis_spec.rb +0 -41
- data/vendor/bundle/ruby/3.3.0/gems/typhoeus-1.4.1/spec/typhoeus/config_spec.rb +0 -15
- data/vendor/bundle/ruby/3.3.0/gems/typhoeus-1.4.1/spec/typhoeus/easy_factory_spec.rb +0 -143
- data/vendor/bundle/ruby/3.3.0/gems/typhoeus-1.4.1/spec/typhoeus/errors/no_stub_spec.rb +0 -13
- data/vendor/bundle/ruby/3.3.0/gems/typhoeus-1.4.1/spec/typhoeus/expectation_spec.rb +0 -280
- data/vendor/bundle/ruby/3.3.0/gems/typhoeus-1.4.1/spec/typhoeus/hydra/addable_spec.rb +0 -22
- data/vendor/bundle/ruby/3.3.0/gems/typhoeus-1.4.1/spec/typhoeus/hydra/before_spec.rb +0 -98
- data/vendor/bundle/ruby/3.3.0/gems/typhoeus-1.4.1/spec/typhoeus/hydra/block_connection_spec.rb +0 -18
- data/vendor/bundle/ruby/3.3.0/gems/typhoeus-1.4.1/spec/typhoeus/hydra/cacheable_spec.rb +0 -88
- data/vendor/bundle/ruby/3.3.0/gems/typhoeus-1.4.1/spec/typhoeus/hydra/memoizable_spec.rb +0 -53
- data/vendor/bundle/ruby/3.3.0/gems/typhoeus-1.4.1/spec/typhoeus/hydra/queueable_spec.rb +0 -98
- data/vendor/bundle/ruby/3.3.0/gems/typhoeus-1.4.1/spec/typhoeus/hydra/runnable_spec.rb +0 -137
- data/vendor/bundle/ruby/3.3.0/gems/typhoeus-1.4.1/spec/typhoeus/hydra/stubbable_spec.rb +0 -48
- data/vendor/bundle/ruby/3.3.0/gems/typhoeus-1.4.1/spec/typhoeus/hydra_spec.rb +0 -22
- data/vendor/bundle/ruby/3.3.0/gems/typhoeus-1.4.1/spec/typhoeus/pool_spec.rb +0 -137
- data/vendor/bundle/ruby/3.3.0/gems/typhoeus-1.4.1/spec/typhoeus/request/actions_spec.rb +0 -19
- data/vendor/bundle/ruby/3.3.0/gems/typhoeus-1.4.1/spec/typhoeus/request/before_spec.rb +0 -93
- data/vendor/bundle/ruby/3.3.0/gems/typhoeus-1.4.1/spec/typhoeus/request/block_connection_spec.rb +0 -75
- data/vendor/bundle/ruby/3.3.0/gems/typhoeus-1.4.1/spec/typhoeus/request/cacheable_spec.rb +0 -94
- data/vendor/bundle/ruby/3.3.0/gems/typhoeus-1.4.1/spec/typhoeus/request/callbacks_spec.rb +0 -91
- data/vendor/bundle/ruby/3.3.0/gems/typhoeus-1.4.1/spec/typhoeus/request/marshal_spec.rb +0 -60
- data/vendor/bundle/ruby/3.3.0/gems/typhoeus-1.4.1/spec/typhoeus/request/memoizable_spec.rb +0 -34
- data/vendor/bundle/ruby/3.3.0/gems/typhoeus-1.4.1/spec/typhoeus/request/operations_spec.rb +0 -101
- data/vendor/bundle/ruby/3.3.0/gems/typhoeus-1.4.1/spec/typhoeus/request/responseable_spec.rb +0 -13
- data/vendor/bundle/ruby/3.3.0/gems/typhoeus-1.4.1/spec/typhoeus/request/stubbable_spec.rb +0 -45
- data/vendor/bundle/ruby/3.3.0/gems/typhoeus-1.4.1/spec/typhoeus/request_spec.rb +0 -256
- data/vendor/bundle/ruby/3.3.0/gems/typhoeus-1.4.1/spec/typhoeus/response/header_spec.rb +0 -147
- data/vendor/bundle/ruby/3.3.0/gems/typhoeus-1.4.1/spec/typhoeus/response/informations_spec.rb +0 -323
- data/vendor/bundle/ruby/3.3.0/gems/typhoeus-1.4.1/spec/typhoeus/response/status_spec.rb +0 -256
- data/vendor/bundle/ruby/3.3.0/gems/typhoeus-1.4.1/spec/typhoeus/response_spec.rb +0 -100
- data/vendor/bundle/ruby/3.3.0/gems/typhoeus-1.4.1/spec/typhoeus_spec.rb +0 -105
- data/vendor/bundle/ruby/3.3.0/specifications/typhoeus-1.4.1.gemspec +0 -24
- /data/vendor/bundle/ruby/3.3.0/gems/{ethon-0.17.0 → ethon-0.15.0}/LICENSE +0 -0
- /data/vendor/bundle/ruby/3.3.0/gems/{ethon-0.17.0 → ethon-0.15.0}/lib/ethon/curl.rb +0 -0
- /data/vendor/bundle/ruby/3.3.0/gems/{ethon-0.17.0 → ethon-0.15.0}/lib/ethon/curls/constants.rb +0 -0
- /data/vendor/bundle/ruby/3.3.0/gems/{ethon-0.17.0 → ethon-0.15.0}/lib/ethon/curls/form_options.rb +0 -0
- /data/vendor/bundle/ruby/3.3.0/gems/{ethon-0.17.0 → ethon-0.15.0}/lib/ethon/curls/functions.rb +0 -0
- /data/vendor/bundle/ruby/3.3.0/gems/{ethon-0.17.0 → ethon-0.15.0}/lib/ethon/curls/infos.rb +0 -0
- /data/vendor/bundle/ruby/3.3.0/gems/{ethon-0.17.0 → ethon-0.15.0}/lib/ethon/curls/messages.rb +0 -0
- /data/vendor/bundle/ruby/3.3.0/gems/{ethon-0.17.0 → ethon-0.15.0}/lib/ethon/curls/settings.rb +0 -0
- /data/vendor/bundle/ruby/3.3.0/gems/{ethon-0.17.0 → ethon-0.15.0}/lib/ethon/easy/debug_info.rb +0 -0
- /data/vendor/bundle/ruby/3.3.0/gems/{ethon-0.17.0 → ethon-0.15.0}/lib/ethon/easy/features.rb +0 -0
- /data/vendor/bundle/ruby/3.3.0/gems/{ethon-0.17.0 → ethon-0.15.0}/lib/ethon/easy/form.rb +0 -0
- /data/vendor/bundle/ruby/3.3.0/gems/{ethon-0.17.0 → ethon-0.15.0}/lib/ethon/easy/header.rb +0 -0
- /data/vendor/bundle/ruby/3.3.0/gems/{ethon-0.17.0 → ethon-0.15.0}/lib/ethon/easy/http/actionable.rb +0 -0
- /data/vendor/bundle/ruby/3.3.0/gems/{ethon-0.17.0 → ethon-0.15.0}/lib/ethon/easy/http/custom.rb +0 -0
- /data/vendor/bundle/ruby/3.3.0/gems/{ethon-0.17.0 → ethon-0.15.0}/lib/ethon/easy/http/delete.rb +0 -0
- /data/vendor/bundle/ruby/3.3.0/gems/{ethon-0.17.0 → ethon-0.15.0}/lib/ethon/easy/http/get.rb +0 -0
- /data/vendor/bundle/ruby/3.3.0/gems/{ethon-0.17.0 → ethon-0.15.0}/lib/ethon/easy/http/head.rb +0 -0
- /data/vendor/bundle/ruby/3.3.0/gems/{ethon-0.17.0 → ethon-0.15.0}/lib/ethon/easy/http/options.rb +0 -0
- /data/vendor/bundle/ruby/3.3.0/gems/{ethon-0.17.0 → ethon-0.15.0}/lib/ethon/easy/http/patch.rb +0 -0
- /data/vendor/bundle/ruby/3.3.0/gems/{ethon-0.17.0 → ethon-0.15.0}/lib/ethon/easy/http/post.rb +0 -0
- /data/vendor/bundle/ruby/3.3.0/gems/{ethon-0.17.0 → ethon-0.15.0}/lib/ethon/easy/http/postable.rb +0 -0
- /data/vendor/bundle/ruby/3.3.0/gems/{ethon-0.17.0 → ethon-0.15.0}/lib/ethon/easy/http/put.rb +0 -0
- /data/vendor/bundle/ruby/3.3.0/gems/{ethon-0.17.0 → ethon-0.15.0}/lib/ethon/easy/http/putable.rb +0 -0
- /data/vendor/bundle/ruby/3.3.0/gems/{ethon-0.17.0 → ethon-0.15.0}/lib/ethon/easy/http.rb +0 -0
- /data/vendor/bundle/ruby/3.3.0/gems/{ethon-0.17.0 → ethon-0.15.0}/lib/ethon/easy/mirror.rb +0 -0
- /data/vendor/bundle/ruby/3.3.0/gems/{ethon-0.17.0 → ethon-0.15.0}/lib/ethon/easy/operations.rb +0 -0
- /data/vendor/bundle/ruby/3.3.0/gems/{ethon-0.17.0 → ethon-0.15.0}/lib/ethon/easy/options.rb +0 -0
- /data/vendor/bundle/ruby/3.3.0/gems/{ethon-0.17.0 → ethon-0.15.0}/lib/ethon/easy/params.rb +0 -0
- /data/vendor/bundle/ruby/3.3.0/gems/{ethon-0.17.0 → ethon-0.15.0}/lib/ethon/easy/queryable.rb +0 -0
- /data/vendor/bundle/ruby/3.3.0/gems/{ethon-0.17.0 → ethon-0.15.0}/lib/ethon/easy/util.rb +0 -0
- /data/vendor/bundle/ruby/3.3.0/gems/{ethon-0.17.0 → ethon-0.15.0}/lib/ethon/easy.rb +0 -0
- /data/vendor/bundle/ruby/3.3.0/gems/{ethon-0.17.0 → ethon-0.15.0}/lib/ethon/errors/ethon_error.rb +0 -0
- /data/vendor/bundle/ruby/3.3.0/gems/{ethon-0.17.0 → ethon-0.15.0}/lib/ethon/errors/global_init.rb +0 -0
- /data/vendor/bundle/ruby/3.3.0/gems/{ethon-0.17.0 → ethon-0.15.0}/lib/ethon/errors/invalid_option.rb +0 -0
- /data/vendor/bundle/ruby/3.3.0/gems/{ethon-0.17.0 → ethon-0.15.0}/lib/ethon/errors/invalid_value.rb +0 -0
- /data/vendor/bundle/ruby/3.3.0/gems/{ethon-0.17.0 → ethon-0.15.0}/lib/ethon/errors/multi_add.rb +0 -0
- /data/vendor/bundle/ruby/3.3.0/gems/{ethon-0.17.0 → ethon-0.15.0}/lib/ethon/errors/multi_fdset.rb +0 -0
- /data/vendor/bundle/ruby/3.3.0/gems/{ethon-0.17.0 → ethon-0.15.0}/lib/ethon/errors/multi_remove.rb +0 -0
- /data/vendor/bundle/ruby/3.3.0/gems/{ethon-0.17.0 → ethon-0.15.0}/lib/ethon/errors/multi_timeout.rb +0 -0
- /data/vendor/bundle/ruby/3.3.0/gems/{ethon-0.17.0 → ethon-0.15.0}/lib/ethon/errors/select.rb +0 -0
- /data/vendor/bundle/ruby/3.3.0/gems/{ethon-0.17.0 → ethon-0.15.0}/lib/ethon/errors.rb +0 -0
- /data/vendor/bundle/ruby/3.3.0/gems/{ethon-0.17.0 → ethon-0.15.0}/lib/ethon/libc.rb +0 -0
- /data/vendor/bundle/ruby/3.3.0/gems/{ethon-0.17.0 → ethon-0.15.0}/lib/ethon/loggable.rb +0 -0
- /data/vendor/bundle/ruby/3.3.0/gems/{ethon-0.17.0 → ethon-0.15.0}/lib/ethon/multi/operations.rb +0 -0
- /data/vendor/bundle/ruby/3.3.0/gems/{ethon-0.17.0 → ethon-0.15.0}/lib/ethon/multi/options.rb +0 -0
- /data/vendor/bundle/ruby/3.3.0/gems/{ethon-0.17.0 → ethon-0.15.0}/lib/ethon/multi/stack.rb +0 -0
- /data/vendor/bundle/ruby/3.3.0/gems/{ethon-0.17.0 → ethon-0.15.0}/lib/ethon/multi.rb +0 -0
- /data/vendor/bundle/ruby/3.3.0/gems/{ethon-0.17.0 → ethon-0.15.0}/lib/ethon.rb +0 -0
- /data/vendor/bundle/ruby/3.3.0/gems/{typhoeus-1.4.1 → typhoeus-1.5.0}/CONTRIBUTING.md +0 -0
- /data/vendor/bundle/ruby/3.3.0/gems/{typhoeus-1.4.1 → typhoeus-1.5.0}/LICENSE +0 -0
- /data/vendor/bundle/ruby/3.3.0/gems/{typhoeus-1.4.1 → typhoeus-1.5.0}/README.md +0 -0
- /data/vendor/bundle/ruby/3.3.0/gems/{typhoeus-1.4.1 → typhoeus-1.5.0}/UPGRADE.md +0 -0
- /data/vendor/bundle/ruby/3.3.0/gems/{typhoeus-1.4.1 → typhoeus-1.5.0}/lib/rack/typhoeus/middleware/params_decoder/helper.rb +0 -0
- /data/vendor/bundle/ruby/3.3.0/gems/{typhoeus-1.4.1 → typhoeus-1.5.0}/lib/rack/typhoeus/middleware/params_decoder.rb +0 -0
- /data/vendor/bundle/ruby/3.3.0/gems/{typhoeus-1.4.1 → typhoeus-1.5.0}/lib/rack/typhoeus.rb +0 -0
- /data/vendor/bundle/ruby/3.3.0/gems/{typhoeus-1.4.1 → typhoeus-1.5.0}/lib/typhoeus/adapters/faraday.rb +0 -0
- /data/vendor/bundle/ruby/3.3.0/gems/{typhoeus-1.4.1 → typhoeus-1.5.0}/lib/typhoeus/cache/dalli.rb +0 -0
- /data/vendor/bundle/ruby/3.3.0/gems/{typhoeus-1.4.1 → typhoeus-1.5.0}/lib/typhoeus/cache/rails.rb +0 -0
- /data/vendor/bundle/ruby/3.3.0/gems/{typhoeus-1.4.1 → typhoeus-1.5.0}/lib/typhoeus/cache/redis.rb +0 -0
- /data/vendor/bundle/ruby/3.3.0/gems/{typhoeus-1.4.1 → typhoeus-1.5.0}/lib/typhoeus/config.rb +0 -0
- /data/vendor/bundle/ruby/3.3.0/gems/{typhoeus-1.4.1 → typhoeus-1.5.0}/lib/typhoeus/easy_factory.rb +0 -0
- /data/vendor/bundle/ruby/3.3.0/gems/{typhoeus-1.4.1 → typhoeus-1.5.0}/lib/typhoeus/errors/no_stub.rb +0 -0
- /data/vendor/bundle/ruby/3.3.0/gems/{typhoeus-1.4.1 → typhoeus-1.5.0}/lib/typhoeus/errors/typhoeus_error.rb +0 -0
- /data/vendor/bundle/ruby/3.3.0/gems/{typhoeus-1.4.1 → typhoeus-1.5.0}/lib/typhoeus/errors.rb +0 -0
- /data/vendor/bundle/ruby/3.3.0/gems/{typhoeus-1.4.1 → typhoeus-1.5.0}/lib/typhoeus/hydra/addable.rb +0 -0
- /data/vendor/bundle/ruby/3.3.0/gems/{typhoeus-1.4.1 → typhoeus-1.5.0}/lib/typhoeus/hydra/before.rb +0 -0
- /data/vendor/bundle/ruby/3.3.0/gems/{typhoeus-1.4.1 → typhoeus-1.5.0}/lib/typhoeus/hydra/block_connection.rb +0 -0
- /data/vendor/bundle/ruby/3.3.0/gems/{typhoeus-1.4.1 → typhoeus-1.5.0}/lib/typhoeus/hydra/cacheable.rb +0 -0
- /data/vendor/bundle/ruby/3.3.0/gems/{typhoeus-1.4.1 → typhoeus-1.5.0}/lib/typhoeus/hydra/memoizable.rb +0 -0
- /data/vendor/bundle/ruby/3.3.0/gems/{typhoeus-1.4.1 → typhoeus-1.5.0}/lib/typhoeus/hydra/queueable.rb +0 -0
- /data/vendor/bundle/ruby/3.3.0/gems/{typhoeus-1.4.1 → typhoeus-1.5.0}/lib/typhoeus/hydra/runnable.rb +0 -0
- /data/vendor/bundle/ruby/3.3.0/gems/{typhoeus-1.4.1 → typhoeus-1.5.0}/lib/typhoeus/hydra/stubbable.rb +0 -0
- /data/vendor/bundle/ruby/3.3.0/gems/{typhoeus-1.4.1 → typhoeus-1.5.0}/lib/typhoeus/hydra.rb +0 -0
- /data/vendor/bundle/ruby/3.3.0/gems/{typhoeus-1.4.1 → typhoeus-1.5.0}/lib/typhoeus/pool.rb +0 -0
- /data/vendor/bundle/ruby/3.3.0/gems/{typhoeus-1.4.1 → typhoeus-1.5.0}/lib/typhoeus/railtie.rb +0 -0
- /data/vendor/bundle/ruby/3.3.0/gems/{typhoeus-1.4.1 → typhoeus-1.5.0}/lib/typhoeus/request/actions.rb +0 -0
- /data/vendor/bundle/ruby/3.3.0/gems/{typhoeus-1.4.1 → typhoeus-1.5.0}/lib/typhoeus/request/before.rb +0 -0
- /data/vendor/bundle/ruby/3.3.0/gems/{typhoeus-1.4.1 → typhoeus-1.5.0}/lib/typhoeus/request/block_connection.rb +0 -0
- /data/vendor/bundle/ruby/3.3.0/gems/{typhoeus-1.4.1 → typhoeus-1.5.0}/lib/typhoeus/request/cacheable.rb +0 -0
- /data/vendor/bundle/ruby/3.3.0/gems/{typhoeus-1.4.1 → typhoeus-1.5.0}/lib/typhoeus/request/callbacks.rb +0 -0
- /data/vendor/bundle/ruby/3.3.0/gems/{typhoeus-1.4.1 → typhoeus-1.5.0}/lib/typhoeus/request/marshal.rb +0 -0
- /data/vendor/bundle/ruby/3.3.0/gems/{typhoeus-1.4.1 → typhoeus-1.5.0}/lib/typhoeus/request/memoizable.rb +0 -0
- /data/vendor/bundle/ruby/3.3.0/gems/{typhoeus-1.4.1 → typhoeus-1.5.0}/lib/typhoeus/request/operations.rb +0 -0
- /data/vendor/bundle/ruby/3.3.0/gems/{typhoeus-1.4.1 → typhoeus-1.5.0}/lib/typhoeus/request/streamable.rb +0 -0
- /data/vendor/bundle/ruby/3.3.0/gems/{typhoeus-1.4.1 → typhoeus-1.5.0}/lib/typhoeus/request/stubbable.rb +0 -0
- /data/vendor/bundle/ruby/3.3.0/gems/{typhoeus-1.4.1 → typhoeus-1.5.0}/lib/typhoeus/request.rb +0 -0
- /data/vendor/bundle/ruby/3.3.0/gems/{typhoeus-1.4.1 → typhoeus-1.5.0}/lib/typhoeus/response/cacheable.rb +0 -0
- /data/vendor/bundle/ruby/3.3.0/gems/{typhoeus-1.4.1 → typhoeus-1.5.0}/lib/typhoeus/response/header.rb +0 -0
- /data/vendor/bundle/ruby/3.3.0/gems/{typhoeus-1.4.1 → typhoeus-1.5.0}/lib/typhoeus/response/informations.rb +0 -0
- /data/vendor/bundle/ruby/3.3.0/gems/{typhoeus-1.4.1 → typhoeus-1.5.0}/lib/typhoeus/response/status.rb +0 -0
- /data/vendor/bundle/ruby/3.3.0/gems/{typhoeus-1.4.1 → typhoeus-1.5.0}/lib/typhoeus/response.rb +0 -0
- /data/vendor/bundle/ruby/3.3.0/gems/{typhoeus-1.4.1 → typhoeus-1.5.0}/lib/typhoeus.rb +0 -0
@@ -1,53 +0,0 @@
|
|
1
|
-
require 'spec_helper'
|
2
|
-
|
3
|
-
describe Typhoeus::Hydra::Memoizable do
|
4
|
-
let(:base_url) { "localhost:3001" }
|
5
|
-
let(:hydra) { Typhoeus::Hydra.new() }
|
6
|
-
let(:request) { Typhoeus::Request.new(base_url) }
|
7
|
-
|
8
|
-
describe "add" do
|
9
|
-
context "when memoization activated" do
|
10
|
-
before { Typhoeus::Config.memoize = true }
|
11
|
-
|
12
|
-
context "when request new" do
|
13
|
-
it "sets no response" do
|
14
|
-
hydra.add(request)
|
15
|
-
expect(request.response).to be_nil
|
16
|
-
end
|
17
|
-
|
18
|
-
it "doesn't call complete" do
|
19
|
-
expect(request).to receive(:complete).never
|
20
|
-
hydra.add(request)
|
21
|
-
end
|
22
|
-
end
|
23
|
-
|
24
|
-
context "when request in memory" do
|
25
|
-
let(:response) { Typhoeus::Response.new }
|
26
|
-
before { hydra.memory[request] = response }
|
27
|
-
|
28
|
-
it "finishes request" do
|
29
|
-
expect(request).to receive(:finish).with(response, true)
|
30
|
-
hydra.add(request)
|
31
|
-
end
|
32
|
-
|
33
|
-
context "when queued request" do
|
34
|
-
let(:queued_request) { Typhoeus::Request.new(base_url) }
|
35
|
-
|
36
|
-
it "dequeues" do
|
37
|
-
hydra.queue(queued_request)
|
38
|
-
expect(request).to receive(:finish).with(response, true)
|
39
|
-
expect(queued_request).to receive(:finish).with(response, true)
|
40
|
-
hydra.add(request)
|
41
|
-
end
|
42
|
-
end
|
43
|
-
end
|
44
|
-
end
|
45
|
-
end
|
46
|
-
|
47
|
-
describe "#run" do
|
48
|
-
it "clears memory before starting" do
|
49
|
-
expect(hydra.memory).to receive(:clear)
|
50
|
-
hydra.run
|
51
|
-
end
|
52
|
-
end
|
53
|
-
end
|
@@ -1,98 +0,0 @@
|
|
1
|
-
require 'spec_helper'
|
2
|
-
|
3
|
-
describe Typhoeus::Hydra::Queueable do
|
4
|
-
let(:base_url) { "localhost:3001" }
|
5
|
-
let(:options) { {} }
|
6
|
-
let(:hydra) { Typhoeus::Hydra.new(options) }
|
7
|
-
|
8
|
-
describe "#queue" do
|
9
|
-
let(:request) { Typhoeus::Request.new("") }
|
10
|
-
|
11
|
-
it "accepts requests" do
|
12
|
-
hydra.queue(request)
|
13
|
-
end
|
14
|
-
|
15
|
-
it "sets hydra on request" do
|
16
|
-
hydra.queue(request)
|
17
|
-
expect(request.hydra).to eq(hydra)
|
18
|
-
end
|
19
|
-
|
20
|
-
it "adds to queued requests" do
|
21
|
-
hydra.queue(request)
|
22
|
-
expect(hydra.queued_requests).to include(request)
|
23
|
-
end
|
24
|
-
|
25
|
-
it "adds to front of queued requests" do
|
26
|
-
hydra.queue_front(request)
|
27
|
-
expect(hydra.queued_requests.first).to be(request)
|
28
|
-
end
|
29
|
-
end
|
30
|
-
|
31
|
-
describe "#abort" do
|
32
|
-
before { hydra.queued_requests << 1 }
|
33
|
-
|
34
|
-
it "clears queue" do
|
35
|
-
hydra.abort
|
36
|
-
expect(hydra.queued_requests).to be_empty
|
37
|
-
end
|
38
|
-
end
|
39
|
-
|
40
|
-
describe "#dequeue_many" do
|
41
|
-
before do
|
42
|
-
requests.each { |r| hydra.queue r }
|
43
|
-
end
|
44
|
-
|
45
|
-
context "when no request queued" do
|
46
|
-
let(:requests) { [] }
|
47
|
-
|
48
|
-
it "does nothing" do
|
49
|
-
expect(hydra).to_not receive(:add)
|
50
|
-
hydra.dequeue_many
|
51
|
-
end
|
52
|
-
end
|
53
|
-
|
54
|
-
context "when request queued" do
|
55
|
-
let(:first) { Typhoeus::Request.new("localhost:3001/first") }
|
56
|
-
let(:requests) { [first] }
|
57
|
-
|
58
|
-
it "adds request from queue to multi" do
|
59
|
-
expect(hydra).to receive(:add).with(first)
|
60
|
-
hydra.dequeue_many
|
61
|
-
end
|
62
|
-
end
|
63
|
-
|
64
|
-
context "when three request queued" do
|
65
|
-
let(:first) { Typhoeus::Request.new("localhost:3001/first") }
|
66
|
-
let(:second) { Typhoeus::Request.new("localhost:3001/second") }
|
67
|
-
let(:third) { Typhoeus::Request.new("localhost:3001/third") }
|
68
|
-
let(:requests) { [first, second, third] }
|
69
|
-
|
70
|
-
it "adds requests from queue to multi" do
|
71
|
-
expect(hydra).to receive(:add).with(first)
|
72
|
-
expect(hydra).to receive(:add).with(second)
|
73
|
-
expect(hydra).to receive(:add).with(third)
|
74
|
-
hydra.dequeue_many
|
75
|
-
end
|
76
|
-
|
77
|
-
context "when max_concurrency is two" do
|
78
|
-
let(:options) { {:max_concurrency => 2} }
|
79
|
-
it "adds requests from queue to multi" do
|
80
|
-
expect(hydra).to receive(:add).with(first)
|
81
|
-
expect(hydra).to receive(:add).with(second)
|
82
|
-
expect(hydra).to_not receive(:add).with(third)
|
83
|
-
hydra.dequeue_many
|
84
|
-
end
|
85
|
-
end
|
86
|
-
|
87
|
-
context "when max_concurrency is a string" do
|
88
|
-
let(:options) { {:max_concurrency => "2"} }
|
89
|
-
it "adds requests from queue to multi" do
|
90
|
-
expect(hydra).to receive(:add).with(first)
|
91
|
-
expect(hydra).to receive(:add).with(second)
|
92
|
-
expect(hydra).to_not receive(:add).with(third)
|
93
|
-
hydra.dequeue_many
|
94
|
-
end
|
95
|
-
end
|
96
|
-
end
|
97
|
-
end
|
98
|
-
end
|
@@ -1,137 +0,0 @@
|
|
1
|
-
require 'spec_helper'
|
2
|
-
|
3
|
-
describe Typhoeus::Hydra::Runnable do
|
4
|
-
let(:base_url) { "localhost:3001" }
|
5
|
-
let(:options) { {} }
|
6
|
-
let(:hydra) { Typhoeus::Hydra.new(options) }
|
7
|
-
let(:receive_counter) { double :mark => :twain }
|
8
|
-
|
9
|
-
describe "#run" do
|
10
|
-
let(:requests) { [] }
|
11
|
-
|
12
|
-
before do
|
13
|
-
requests.each { |r| hydra.queue r }
|
14
|
-
end
|
15
|
-
|
16
|
-
it "runs multi#dequeue_many" do
|
17
|
-
expect(hydra).to receive(:dequeue_many)
|
18
|
-
hydra.run
|
19
|
-
end
|
20
|
-
|
21
|
-
it "runs multi#perform" do
|
22
|
-
expect(hydra.multi).to receive(:perform)
|
23
|
-
hydra.run
|
24
|
-
end
|
25
|
-
|
26
|
-
context "when request queued" do
|
27
|
-
let(:first) { Typhoeus::Request.new("localhost:3001/first") }
|
28
|
-
let(:requests) { [first] }
|
29
|
-
|
30
|
-
it "sends" do
|
31
|
-
hydra.run
|
32
|
-
expect(first.response).to be
|
33
|
-
end
|
34
|
-
end
|
35
|
-
|
36
|
-
context "when three request queued" do
|
37
|
-
let(:first) { Typhoeus::Request.new("localhost:3001/first") }
|
38
|
-
let(:second) { Typhoeus::Request.new("localhost:3001/second") }
|
39
|
-
let(:third) { Typhoeus::Request.new("localhost:3001/third") }
|
40
|
-
let(:requests) { [first, second, third] }
|
41
|
-
|
42
|
-
it "sends first" do
|
43
|
-
hydra.run
|
44
|
-
expect(first.response).to be
|
45
|
-
end
|
46
|
-
|
47
|
-
it "sends second" do
|
48
|
-
hydra.run
|
49
|
-
expect(second.response).to be
|
50
|
-
end
|
51
|
-
|
52
|
-
it "sends third" do
|
53
|
-
hydra.run
|
54
|
-
expect(third.response).to be
|
55
|
-
end
|
56
|
-
|
57
|
-
it "sends first first" do
|
58
|
-
first.on_complete do
|
59
|
-
expect(second.response).to be_nil
|
60
|
-
expect(third.response).to be_nil
|
61
|
-
end
|
62
|
-
end
|
63
|
-
|
64
|
-
it "sends second second" do
|
65
|
-
first.on_complete do
|
66
|
-
expect(first.response).to be
|
67
|
-
expect(third.response).to be_nil
|
68
|
-
end
|
69
|
-
end
|
70
|
-
|
71
|
-
it "sends thirds last" do
|
72
|
-
first.on_complete do
|
73
|
-
expect(second.response).to be
|
74
|
-
expect(third.response).to be
|
75
|
-
end
|
76
|
-
end
|
77
|
-
end
|
78
|
-
|
79
|
-
context "when really queued request" do
|
80
|
-
let(:options) { {:max_concurrency => 1} }
|
81
|
-
let(:first) { Typhoeus::Request.new("localhost:3001/first") }
|
82
|
-
let(:second) { Typhoeus::Request.new("localhost:3001/second") }
|
83
|
-
let(:third) { Typhoeus::Request.new("localhost:3001/third") }
|
84
|
-
let(:requests) { [first, second, third] }
|
85
|
-
|
86
|
-
it "sends first" do
|
87
|
-
hydra.run
|
88
|
-
expect(first.response).to be
|
89
|
-
end
|
90
|
-
|
91
|
-
it "sends second" do
|
92
|
-
hydra.run
|
93
|
-
expect(second.response).to be
|
94
|
-
end
|
95
|
-
|
96
|
-
it "sends third" do
|
97
|
-
hydra.run
|
98
|
-
expect(third.response).to be
|
99
|
-
end
|
100
|
-
end
|
101
|
-
|
102
|
-
context "when request queued in callback" do
|
103
|
-
let(:first) do
|
104
|
-
Typhoeus::Request.new("localhost:3001/first").tap do |r|
|
105
|
-
r.on_complete{ hydra.queue(second) }
|
106
|
-
end
|
107
|
-
end
|
108
|
-
let(:second) { Typhoeus::Request.new("localhost:3001/second") }
|
109
|
-
let(:requests) { [first] }
|
110
|
-
|
111
|
-
before { Typhoeus.on_complete { |r| receive_counter.mark } }
|
112
|
-
after { Typhoeus.on_complete.clear; Typhoeus.before.clear }
|
113
|
-
|
114
|
-
context "when real request" do
|
115
|
-
context "when max_concurrency default" do
|
116
|
-
let(:options) { {} }
|
117
|
-
|
118
|
-
it "calls on_complete callback once for every response" do
|
119
|
-
expect(receive_counter).to receive(:mark).exactly(2).times
|
120
|
-
hydra.run
|
121
|
-
end
|
122
|
-
end
|
123
|
-
end
|
124
|
-
|
125
|
-
context "when no real request" do
|
126
|
-
context "when before hook returns and finishes response" do
|
127
|
-
before { Typhoeus.before{ |request| request.finish(Typhoeus::Response.new) } }
|
128
|
-
|
129
|
-
it "simulates real multi run and adds and finishes both requests" do
|
130
|
-
expect(receive_counter).to receive(:mark).exactly(2).times
|
131
|
-
hydra.run
|
132
|
-
end
|
133
|
-
end
|
134
|
-
end
|
135
|
-
end
|
136
|
-
end
|
137
|
-
end
|
@@ -1,48 +0,0 @@
|
|
1
|
-
require 'spec_helper'
|
2
|
-
|
3
|
-
describe Typhoeus::Hydra::Stubbable do
|
4
|
-
let(:base_url) { "localhost:3001" }
|
5
|
-
let(:request) { Typhoeus::Request.new(base_url) }
|
6
|
-
let(:response) { Typhoeus::Response.new }
|
7
|
-
let(:hydra) { Typhoeus::Hydra.new }
|
8
|
-
|
9
|
-
before { Typhoeus.stub(base_url).and_return(response) }
|
10
|
-
|
11
|
-
describe "#add" do
|
12
|
-
it "checks expectations" do
|
13
|
-
hydra.add(request)
|
14
|
-
end
|
15
|
-
|
16
|
-
context "when expectation found" do
|
17
|
-
it "calls on_headers callbacks" do
|
18
|
-
canary = :not_called
|
19
|
-
request.on_headers do
|
20
|
-
canary = :called
|
21
|
-
end
|
22
|
-
hydra.add(request)
|
23
|
-
hydra.run
|
24
|
-
expect(canary).to eq(:called)
|
25
|
-
end
|
26
|
-
|
27
|
-
it "calls on_body callbacks" do
|
28
|
-
canary = :not_called
|
29
|
-
request.on_body do
|
30
|
-
canary = :called
|
31
|
-
end
|
32
|
-
hydra.add(request)
|
33
|
-
hydra.run
|
34
|
-
expect(canary).to eq(:called)
|
35
|
-
end
|
36
|
-
|
37
|
-
it "finishes response" do
|
38
|
-
expect(request).to receive(:finish)
|
39
|
-
hydra.add(request)
|
40
|
-
end
|
41
|
-
|
42
|
-
it "is a mock" do
|
43
|
-
hydra.add(request)
|
44
|
-
expect(request.response.mock).to be(true)
|
45
|
-
end
|
46
|
-
end
|
47
|
-
end
|
48
|
-
end
|
@@ -1,22 +0,0 @@
|
|
1
|
-
require File.expand_path(File.dirname(__FILE__) + '/../spec_helper')
|
2
|
-
|
3
|
-
describe Typhoeus::Hydra do
|
4
|
-
let(:base_url) { "localhost:3001" }
|
5
|
-
let(:options) { {} }
|
6
|
-
let(:hydra) { Typhoeus::Hydra.new(options) }
|
7
|
-
|
8
|
-
describe "#new" do
|
9
|
-
let(:options) { {:pipeling => true} }
|
10
|
-
|
11
|
-
it "passes options to multi" do
|
12
|
-
expect(Ethon::Multi).to receive(:new).with(options)
|
13
|
-
hydra
|
14
|
-
end
|
15
|
-
end
|
16
|
-
|
17
|
-
describe "#hydra" do
|
18
|
-
it "returns a hydra" do
|
19
|
-
expect(Typhoeus::Hydra.hydra).to be_a(Typhoeus::Hydra)
|
20
|
-
end
|
21
|
-
end
|
22
|
-
end
|
@@ -1,137 +0,0 @@
|
|
1
|
-
require 'spec_helper'
|
2
|
-
|
3
|
-
describe Typhoeus::Pool do
|
4
|
-
let(:easy) { Ethon::Easy.new }
|
5
|
-
after { Typhoeus::Pool.clear }
|
6
|
-
|
7
|
-
describe "#easies" do
|
8
|
-
it "returns array" do
|
9
|
-
expect(Typhoeus::Pool.send(:easies)).to be_a(Array)
|
10
|
-
end
|
11
|
-
end
|
12
|
-
|
13
|
-
describe "#release" do
|
14
|
-
it "resets easy" do
|
15
|
-
expect(easy).to receive(:reset)
|
16
|
-
Typhoeus::Pool.release(easy)
|
17
|
-
end
|
18
|
-
|
19
|
-
it "flush cookies to disk" do
|
20
|
-
expect(easy).to receive(:cookielist=).with('flush')
|
21
|
-
expect(easy).to receive(:reset)
|
22
|
-
expect(easy).to receive(:cookielist=).with('all')
|
23
|
-
Typhoeus::Pool.release(easy)
|
24
|
-
end
|
25
|
-
|
26
|
-
it "writes cookies to disk" do
|
27
|
-
tempfile1 = Tempfile.new('cookies')
|
28
|
-
tempfile2 = Tempfile.new('cookies')
|
29
|
-
|
30
|
-
easy.cookiejar = tempfile1.path
|
31
|
-
easy.url = "localhost:3001/cookies-test"
|
32
|
-
easy.perform
|
33
|
-
|
34
|
-
Typhoeus::Pool.release(easy)
|
35
|
-
|
36
|
-
expect(File.zero?(tempfile1.path)).to be(false)
|
37
|
-
expect(File.read(tempfile1.path)).to match(/\s+foo\s+bar$/)
|
38
|
-
expect(File.read(tempfile1.path)).to match(/\s+bar\s+foo$/)
|
39
|
-
|
40
|
-
# do it again - and check if tempfile1 wasn't change
|
41
|
-
easy.cookiejar = tempfile2.path
|
42
|
-
easy.url = "localhost:3001/cookies-test2"
|
43
|
-
easy.perform
|
44
|
-
|
45
|
-
Typhoeus::Pool.release(easy)
|
46
|
-
|
47
|
-
# tempfile 1
|
48
|
-
expect(File.zero?(tempfile1.path)).to be(false)
|
49
|
-
expect(File.read(tempfile1.path)).to match(/\s+foo\s+bar$/)
|
50
|
-
expect(File.read(tempfile1.path)).to match(/\s+bar\s+foo$/)
|
51
|
-
|
52
|
-
# tempfile2
|
53
|
-
expect(File.zero?(tempfile2.path)).to be(false)
|
54
|
-
expect(File.read(tempfile2.path)).to match(/\s+foo2\s+bar$/)
|
55
|
-
expect(File.read(tempfile2.path)).to match(/\s+bar2\s+foo$/)
|
56
|
-
end
|
57
|
-
|
58
|
-
it "puts easy back into pool" do
|
59
|
-
Typhoeus::Pool.release(easy)
|
60
|
-
expect(Typhoeus::Pool.send(:easies)).to include(easy)
|
61
|
-
end
|
62
|
-
|
63
|
-
context "when threaded access" do
|
64
|
-
it "releases correct number of easies" do
|
65
|
-
(0..9).map do |n|
|
66
|
-
Thread.new do
|
67
|
-
Typhoeus::Pool.release(Ethon::Easy.new)
|
68
|
-
end
|
69
|
-
end.map(&:join)
|
70
|
-
expect(Typhoeus::Pool.send(:easies).size).to eq(10)
|
71
|
-
end
|
72
|
-
end
|
73
|
-
end
|
74
|
-
|
75
|
-
describe "#get" do
|
76
|
-
context "when easy in pool" do
|
77
|
-
before { Typhoeus::Pool.send(:easies) << easy }
|
78
|
-
|
79
|
-
it "takes" do
|
80
|
-
expect(Typhoeus::Pool.get).to eq(easy)
|
81
|
-
end
|
82
|
-
end
|
83
|
-
|
84
|
-
context "when no easy in pool" do
|
85
|
-
it "creates" do
|
86
|
-
expect(Typhoeus::Pool.get).to be_a(Ethon::Easy)
|
87
|
-
end
|
88
|
-
|
89
|
-
context "when threaded access" do
|
90
|
-
it "creates correct number of easies" do
|
91
|
-
queue = Queue.new
|
92
|
-
(0..9).map do |n|
|
93
|
-
Thread.new do
|
94
|
-
queue.enq(Typhoeus::Pool.get)
|
95
|
-
end
|
96
|
-
end.map(&:join)
|
97
|
-
|
98
|
-
array = Array.new(queue.size) { queue.pop }
|
99
|
-
expect(array.uniq.size).to eq(10)
|
100
|
-
end
|
101
|
-
end
|
102
|
-
end
|
103
|
-
|
104
|
-
context "when forked" do
|
105
|
-
before do
|
106
|
-
allow(Process).to receive(:pid).and_return(1)
|
107
|
-
Typhoeus::Pool.send(:easies) << easy
|
108
|
-
allow(Process).to receive(:pid).and_return(2)
|
109
|
-
end
|
110
|
-
|
111
|
-
after do
|
112
|
-
allow(Process).to receive(:pid).and_call_original
|
113
|
-
Typhoeus::Pool.instance_variable_set(:@pid, Process.pid)
|
114
|
-
end
|
115
|
-
|
116
|
-
it "creates" do
|
117
|
-
expect(Typhoeus::Pool.get).to_not eq(easy)
|
118
|
-
end
|
119
|
-
end
|
120
|
-
end
|
121
|
-
|
122
|
-
describe "#with" do
|
123
|
-
it "is re-entrant" do
|
124
|
-
array = []
|
125
|
-
Typhoeus::Pool.with_easy do |e1|
|
126
|
-
array << e1
|
127
|
-
Typhoeus::Pool.with_easy do |e2|
|
128
|
-
array << e2
|
129
|
-
Typhoeus::Pool.with_easy do |e3|
|
130
|
-
array << e3
|
131
|
-
end
|
132
|
-
end
|
133
|
-
end
|
134
|
-
expect(array.uniq.size).to eq(3)
|
135
|
-
end
|
136
|
-
end
|
137
|
-
end
|
@@ -1,19 +0,0 @@
|
|
1
|
-
require 'spec_helper'
|
2
|
-
|
3
|
-
describe Typhoeus::Request::Actions do
|
4
|
-
[:get, :post, :put, :delete, :head, :patch, :options].each do |name|
|
5
|
-
describe ".#{name}" do
|
6
|
-
let(:response) { Typhoeus::Request.method(name).call("http://localhost:3001") }
|
7
|
-
|
8
|
-
it "returns ok" do
|
9
|
-
expect(response.return_code).to eq(:ok)
|
10
|
-
end
|
11
|
-
|
12
|
-
unless name == :head
|
13
|
-
it "makes #{name.to_s.upcase} Request" do
|
14
|
-
expect(response.response_body).to include("\"REQUEST_METHOD\":\"#{name.to_s.upcase}\"")
|
15
|
-
end
|
16
|
-
end
|
17
|
-
end
|
18
|
-
end
|
19
|
-
end
|
@@ -1,93 +0,0 @@
|
|
1
|
-
require 'spec_helper'
|
2
|
-
|
3
|
-
describe Typhoeus::Request::Before do
|
4
|
-
let(:request) { Typhoeus::Request.new("") }
|
5
|
-
let(:receive_counter) { double :mark => :twain }
|
6
|
-
|
7
|
-
describe "#queue" do
|
8
|
-
context "when before" do
|
9
|
-
context "when one" do
|
10
|
-
it "executes" do
|
11
|
-
Typhoeus.before { |r| receive_counter.mark }
|
12
|
-
expect(receive_counter).to receive(:mark)
|
13
|
-
request.run
|
14
|
-
end
|
15
|
-
|
16
|
-
context "when true" do
|
17
|
-
it "calls super" do
|
18
|
-
Typhoeus.before { true }
|
19
|
-
expect(Typhoeus::Expectation).to receive(:response_for)
|
20
|
-
request.run
|
21
|
-
end
|
22
|
-
end
|
23
|
-
|
24
|
-
context "when false" do
|
25
|
-
it "doesn't call super" do
|
26
|
-
Typhoeus.before { false }
|
27
|
-
expect(Typhoeus::Expectation).to receive(:response_for).never
|
28
|
-
request.run
|
29
|
-
end
|
30
|
-
|
31
|
-
it "returns response" do
|
32
|
-
Typhoeus.before { |r| r.response = 1; false }
|
33
|
-
expect(request.run).to be(1)
|
34
|
-
end
|
35
|
-
end
|
36
|
-
|
37
|
-
context "when a response" do
|
38
|
-
it "doesn't call super" do
|
39
|
-
Typhoeus.before { Typhoeus::Response.new }
|
40
|
-
expect(Typhoeus::Expectation).to receive(:response_for).never
|
41
|
-
request.run
|
42
|
-
end
|
43
|
-
|
44
|
-
it "returns response" do
|
45
|
-
Typhoeus.before { |r| r.response = Typhoeus::Response.new }
|
46
|
-
expect(request.run).to be_a(Typhoeus::Response)
|
47
|
-
end
|
48
|
-
end
|
49
|
-
end
|
50
|
-
|
51
|
-
context "when multi" do
|
52
|
-
context "when all true" do
|
53
|
-
before { 3.times { Typhoeus.before { |r| receive_counter.mark } } }
|
54
|
-
|
55
|
-
it "calls super" do
|
56
|
-
expect(Typhoeus::Expectation).to receive(:response_for)
|
57
|
-
request.run
|
58
|
-
end
|
59
|
-
|
60
|
-
it "executes all" do
|
61
|
-
expect(receive_counter).to receive(:mark).exactly(3)
|
62
|
-
request.run
|
63
|
-
end
|
64
|
-
end
|
65
|
-
|
66
|
-
context "when middle false" do
|
67
|
-
before do
|
68
|
-
Typhoeus.before { |r| receive_counter.mark }
|
69
|
-
Typhoeus.before { |r| receive_counter.mark; nil }
|
70
|
-
Typhoeus.before { |r| receive_counter.mark }
|
71
|
-
end
|
72
|
-
|
73
|
-
it "doesn't call super" do
|
74
|
-
expect(Typhoeus::Expectation).to receive(:response_for).never
|
75
|
-
request.run
|
76
|
-
end
|
77
|
-
|
78
|
-
it "executes only two" do
|
79
|
-
expect(receive_counter).to receive(:mark).exactly(2).times
|
80
|
-
request.run
|
81
|
-
end
|
82
|
-
end
|
83
|
-
end
|
84
|
-
end
|
85
|
-
|
86
|
-
context "when no before" do
|
87
|
-
it "calls super" do
|
88
|
-
expect(Typhoeus::Expectation).to receive(:response_for)
|
89
|
-
request.run
|
90
|
-
end
|
91
|
-
end
|
92
|
-
end
|
93
|
-
end
|
data/vendor/bundle/ruby/3.3.0/gems/typhoeus-1.4.1/spec/typhoeus/request/block_connection_spec.rb
DELETED
@@ -1,75 +0,0 @@
|
|
1
|
-
require 'spec_helper'
|
2
|
-
|
3
|
-
describe Typhoeus::Request::BlockConnection do
|
4
|
-
let(:base_url) { "localhost:3001" }
|
5
|
-
let(:request) { Typhoeus::Request.new(base_url, {:method => :get}) }
|
6
|
-
|
7
|
-
describe "run" do
|
8
|
-
context "when blocked" do
|
9
|
-
before { request.block_connection = true }
|
10
|
-
|
11
|
-
it "raises" do
|
12
|
-
expect{ request.run }.to raise_error(Typhoeus::Errors::NoStub)
|
13
|
-
end
|
14
|
-
end
|
15
|
-
|
16
|
-
context "when not blocked" do
|
17
|
-
before { request.block_connection = false }
|
18
|
-
|
19
|
-
it "doesn't raise" do
|
20
|
-
expect{ request.run }.to_not raise_error
|
21
|
-
end
|
22
|
-
end
|
23
|
-
end
|
24
|
-
|
25
|
-
describe "#blocked?" do
|
26
|
-
context "when local block_connection" do
|
27
|
-
context "when true" do
|
28
|
-
before { request.block_connection = true }
|
29
|
-
|
30
|
-
it "returns true" do
|
31
|
-
expect(request.blocked?).to be_truthy
|
32
|
-
end
|
33
|
-
end
|
34
|
-
|
35
|
-
context "when false" do
|
36
|
-
before { request.block_connection = false }
|
37
|
-
|
38
|
-
it "returns false" do
|
39
|
-
expect(request.blocked?).to be_falsey
|
40
|
-
end
|
41
|
-
end
|
42
|
-
end
|
43
|
-
|
44
|
-
context "when global block_connection" do
|
45
|
-
context "when true" do
|
46
|
-
before { Typhoeus::Config.block_connection = true }
|
47
|
-
after { Typhoeus::Config.block_connection = false }
|
48
|
-
|
49
|
-
it "returns true" do
|
50
|
-
expect(request.blocked?).to be_truthy
|
51
|
-
end
|
52
|
-
end
|
53
|
-
|
54
|
-
context "when false" do
|
55
|
-
before { Typhoeus::Config.block_connection = false }
|
56
|
-
|
57
|
-
it "returns false" do
|
58
|
-
expect(request.blocked?).to be_falsey
|
59
|
-
end
|
60
|
-
end
|
61
|
-
end
|
62
|
-
|
63
|
-
context "when global and local block_connection" do
|
64
|
-
before do
|
65
|
-
Typhoeus::Config.block_connection = true
|
66
|
-
request.block_connection = false
|
67
|
-
end
|
68
|
-
after { Typhoeus::Config.block_connection = false }
|
69
|
-
|
70
|
-
it "takes local" do
|
71
|
-
expect(request.blocked?).to be_falsey
|
72
|
-
end
|
73
|
-
end
|
74
|
-
end
|
75
|
-
end
|