aboutsummaryrefslogtreecommitdiffstats
path: root/spec
diff options
context:
space:
mode:
authorhsbt <hsbt@b2dd03c8-39d4-4d8f-98ff-823fe69b080e>2017-11-01 23:29:38 +0000
committerhsbt <hsbt@b2dd03c8-39d4-4d8f-98ff-823fe69b080e>2017-11-01 23:29:38 +0000
commitdfe59a99f40c2f133ab0d3744d090de842c52f57 (patch)
tree51eae376f93c09bc82dde5a657a91df2c89062e4 /spec
parent757c38a189bf3bc0255072876693ee309eaa319f (diff)
downloadruby-dfe59a99f40c2f133ab0d3744d090de842c52f57.tar.gz
Update bundled bundler to 1.16.0.
* lib/bundler, spec/bundler: Merge bundler-1.16.0. * common.mk: rspec examples of bundler-1.16.0 needs require option. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@60603 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
Diffstat (limited to 'spec')
-rw-r--r--spec/bundler/bundler/bundler_spec.rb28
-rw-r--r--spec/bundler/bundler/cli_spec.rb52
-rw-r--r--spec/bundler/bundler/compact_index_client/updater_spec.rb2
-rw-r--r--spec/bundler/bundler/definition_spec.rb101
-rw-r--r--spec/bundler/bundler/dsl_spec.rb41
-rw-r--r--spec/bundler/bundler/endpoint_specification_spec.rb9
-rw-r--r--spec/bundler/bundler/env_spec.rb65
-rw-r--r--spec/bundler/bundler/environment_preserver_spec.rb5
-rw-r--r--spec/bundler/bundler/fetcher/base_spec.rb1
-rw-r--r--spec/bundler/bundler/fetcher/compact_index_spec.rb13
-rw-r--r--spec/bundler/bundler/fetcher/dependency_spec.rb15
-rw-r--r--spec/bundler/bundler/fetcher/downloader_spec.rb1
-rw-r--r--spec/bundler/bundler/fetcher/index_spec.rb3
-rw-r--r--spec/bundler/bundler/fetcher_spec.rb45
-rw-r--r--spec/bundler/bundler/friendly_errors_spec.rb4
-rw-r--r--spec/bundler/bundler/gem_helper_spec.rb96
-rw-r--r--spec/bundler/bundler/gem_version_promoter_spec.rb54
-rw-r--r--spec/bundler/bundler/index_spec.rb1
-rw-r--r--spec/bundler/bundler/installer/gem_installer_spec.rb3
-rw-r--r--spec/bundler/bundler/installer/parallel_installer_spec.rb2
-rw-r--r--spec/bundler/bundler/installer/spec_installation_spec.rb2
-rw-r--r--spec/bundler/bundler/lockfile_parser_spec.rb61
-rw-r--r--spec/bundler/bundler/mirror_spec.rb2
-rw-r--r--spec/bundler/bundler/plugin/api/source_spec.rb3
-rw-r--r--spec/bundler/bundler/plugin/api_spec.rb9
-rw-r--r--spec/bundler/bundler/plugin/dsl_spec.rb1
-rw-r--r--spec/bundler/bundler/plugin/index_spec.rb1
-rw-r--r--spec/bundler/bundler/plugin/installer_spec.rb6
-rw-r--r--spec/bundler/bundler/plugin/source_list_spec.rb1
-rw-r--r--spec/bundler/bundler/plugin_spec.rb1
-rw-r--r--spec/bundler/bundler/psyched_yaml_spec.rb2
-rw-r--r--spec/bundler/bundler/remote_specification_spec.rb1
-rw-r--r--spec/bundler/bundler/retry_spec.rb1
-rw-r--r--spec/bundler/bundler/ruby_dsl_spec.rb2
-rw-r--r--spec/bundler/bundler/ruby_version_spec.rb2
-rw-r--r--spec/bundler/bundler/rubygems_integration_spec.rb7
-rw-r--r--spec/bundler/bundler/settings/validator_spec.rb111
-rw-r--r--spec/bundler/bundler/settings_spec.rb82
-rw-r--r--spec/bundler/bundler/shared_helpers_spec.rb54
-rw-r--r--spec/bundler/bundler/source/git/git_proxy_spec.rb9
-rw-r--r--spec/bundler/bundler/source/rubygems/remote_spec.rb22
-rw-r--r--spec/bundler/bundler/source/rubygems_spec.rb1
-rw-r--r--spec/bundler/bundler/source_list_spec.rb44
-rw-r--r--spec/bundler/bundler/source_spec.rb1
-rw-r--r--spec/bundler/bundler/spec_set_spec.rb40
-rw-r--r--spec/bundler/bundler/ssl_certs/certificate_manager_spec.rb10
-rw-r--r--spec/bundler/bundler/stub_specification_spec.rb1
-rw-r--r--spec/bundler/bundler/ui/shell_spec.rb64
-rw-r--r--spec/bundler/bundler/ui_spec.rb1
-rw-r--r--spec/bundler/bundler/uri_credentials_filter_spec.rb1
-rw-r--r--spec/bundler/bundler/vendored_persistent_spec.rb78
-rw-r--r--spec/bundler/bundler/version_ranges_spec.rb2
-rw-r--r--spec/bundler/bundler/worker_spec.rb2
-rw-r--r--spec/bundler/bundler/yaml_serializer_spec.rb3
-rw-r--r--spec/bundler/cache/cache_path_spec.rb8
-rw-r--r--spec/bundler/cache/gems_spec.rb30
-rw-r--r--spec/bundler/cache/git_spec.rb37
-rw-r--r--spec/bundler/cache/path_spec.rb23
-rw-r--r--spec/bundler/cache/platform_spec.rb9
-rw-r--r--spec/bundler/commands/add_spec.rb5
-rw-r--r--spec/bundler/commands/binstubs_spec.rb168
-rw-r--r--spec/bundler/commands/check_spec.rb56
-rw-r--r--spec/bundler/commands/clean_spec.rb147
-rw-r--r--spec/bundler/commands/config_spec.rb7
-rw-r--r--spec/bundler/commands/console_spec.rb3
-rw-r--r--spec/bundler/commands/doctor_spec.rb17
-rw-r--r--spec/bundler/commands/exec_spec.rb81
-rw-r--r--spec/bundler/commands/help_spec.rb3
-rw-r--r--spec/bundler/commands/info_spec.rb1
-rw-r--r--spec/bundler/commands/init_spec.rb99
-rw-r--r--spec/bundler/commands/inject_spec.rb11
-rw-r--r--spec/bundler/commands/install_spec.rb82
-rw-r--r--spec/bundler/commands/issue_spec.rb1
-rw-r--r--spec/bundler/commands/licenses_spec.rb1
-rw-r--r--spec/bundler/commands/list_spec.rb40
-rw-r--r--spec/bundler/commands/lock_spec.rb35
-rw-r--r--spec/bundler/commands/newgem_spec.rb30
-rw-r--r--spec/bundler/commands/open_spec.rb1
-rw-r--r--spec/bundler/commands/outdated_spec.rb54
-rw-r--r--spec/bundler/commands/package_spec.rb30
-rw-r--r--spec/bundler/commands/pristine_spec.rb56
-rw-r--r--spec/bundler/commands/show_spec.rb11
-rw-r--r--spec/bundler/commands/update_spec.rb282
-rw-r--r--spec/bundler/commands/version_spec.rb39
-rw-r--r--spec/bundler/commands/viz_spec.rb1
-rw-r--r--spec/bundler/install/allow_offline_install_spec.rb10
-rw-r--r--spec/bundler/install/binstubs_spec.rb11
-rw-r--r--spec/bundler/install/bundler_spec.rb59
-rw-r--r--spec/bundler/install/deploy_spec.rb248
-rw-r--r--spec/bundler/install/failure_spec.rb3
-rw-r--r--spec/bundler/install/force_spec.rb91
-rw-r--r--spec/bundler/install/gemfile/eval_gemfile_spec.rb23
-rw-r--r--spec/bundler/install/gemfile/gemspec_spec.rb151
-rw-r--r--spec/bundler/install/gemfile/git_spec.rb152
-rw-r--r--spec/bundler/install/gemfile/groups_spec.rb91
-rw-r--r--spec/bundler/install/gemfile/install_if.rb1
-rw-r--r--spec/bundler/install/gemfile/lockfile_spec.rb48
-rw-r--r--spec/bundler/install/gemfile/path_spec.rb45
-rw-r--r--spec/bundler/install/gemfile/platform_spec.rb9
-rw-r--r--spec/bundler/install/gemfile/ruby_spec.rb1
-rw-r--r--spec/bundler/install/gemfile/sources_spec.rb138
-rw-r--r--spec/bundler/install/gemfile/specific_platform_spec.rb13
-rw-r--r--spec/bundler/install/gemfile_spec.rb21
-rw-r--r--spec/bundler/install/gems/compact_index_spec.rb148
-rw-r--r--spec/bundler/install/gems/dependency_api_spec.rb127
-rw-r--r--spec/bundler/install/gems/env_spec.rb1
-rw-r--r--spec/bundler/install/gems/flex_spec.rb46
-rw-r--r--spec/bundler/install/gems/mirror_spec.rb1
-rw-r--r--spec/bundler/install/gems/native_extensions_spec.rb2
-rw-r--r--spec/bundler/install/gems/post_install_spec.rb1
-rw-r--r--spec/bundler/install/gems/resolving_spec.rb15
-rw-r--r--spec/bundler/install/gems/standalone_spec.rb45
-rw-r--r--spec/bundler/install/gems/sudo_spec.rb15
-rw-r--r--spec/bundler/install/gems/win32_spec.rb1
-rw-r--r--spec/bundler/install/gemspecs_spec.rb5
-rw-r--r--spec/bundler/install/git_spec.rb17
-rw-r--r--spec/bundler/install/global_cache_spec.rb235
-rw-r--r--spec/bundler/install/path_spec.rb29
-rw-r--r--spec/bundler/install/post_bundle_message_spec.rb86
-rw-r--r--spec/bundler/install/prereleases_spec.rb1
-rw-r--r--spec/bundler/install/process_lock_spec.rb24
-rw-r--r--spec/bundler/install/security_policy_spec.rb6
-rw-r--r--spec/bundler/install/yanked_spec.rb3
-rw-r--r--spec/bundler/lock/git_spec.rb3
-rw-r--r--spec/bundler/lock/lockfile_bundler_1_spec.rb1386
-rw-r--r--spec/bundler/lock/lockfile_spec.rb286
-rw-r--r--spec/bundler/other/bundle_ruby_spec.rb3
-rw-r--r--spec/bundler/other/cli_dispatch_spec.rb21
-rw-r--r--spec/bundler/other/compatibility_guard_spec.rb25
-rw-r--r--spec/bundler/other/ext_spec.rb1
-rw-r--r--spec/bundler/other/major_deprecation_spec.rb106
-rw-r--r--spec/bundler/other/platform_spec.rb69
-rw-r--r--spec/bundler/other/ssl_cert_spec.rb6
-rw-r--r--spec/bundler/plugins/command_spec.rb1
-rw-r--r--spec/bundler/plugins/hook_spec.rb1
-rw-r--r--spec/bundler/plugins/install_spec.rb3
-rw-r--r--spec/bundler/plugins/source/example_spec.rb85
-rw-r--r--spec/bundler/plugins/source_spec.rb1
-rw-r--r--spec/bundler/quality_spec.rb105
-rw-r--r--spec/bundler/realworld/dependency_api_spec.rb9
-rw-r--r--spec/bundler/realworld/edgecases_spec.rb48
-rw-r--r--spec/bundler/realworld/gemfile_source_header_spec.rb4
-rw-r--r--spec/bundler/realworld/mirror_probe_spec.rb19
-rw-r--r--spec/bundler/realworld/parallel_spec.rb17
-rw-r--r--spec/bundler/resolver/basic_spec.rb98
-rw-r--r--spec/bundler/resolver/platform_spec.rb19
-rw-r--r--spec/bundler/runtime/executable_spec.rb54
-rw-r--r--spec/bundler/runtime/gem_tasks_spec.rb1
-rw-r--r--spec/bundler/runtime/inline_spec.rb20
-rw-r--r--spec/bundler/runtime/load_spec.rb18
-rw-r--r--spec/bundler/runtime/platform_spec.rb11
-rw-r--r--spec/bundler/runtime/require_spec.rb86
-rw-r--r--spec/bundler/runtime/setup_spec.rb193
-rw-r--r--spec/bundler/runtime/with_clean_env_spec.rb37
-rw-r--r--spec/bundler/spec_helper.rb47
-rw-r--r--spec/bundler/support/artifice/compact_index.rb5
-rw-r--r--spec/bundler/support/artifice/compact_index_api_missing.rb1
-rw-r--r--spec/bundler/support/artifice/compact_index_basic_authentication.rb1
-rw-r--r--spec/bundler/support/artifice/compact_index_checksum_mismatch.rb1
-rw-r--r--spec/bundler/support/artifice/compact_index_concurrent_download.rb1
-rw-r--r--spec/bundler/support/artifice/compact_index_creds_diff_host.rb3
-rw-r--r--spec/bundler/support/artifice/compact_index_extra.rb1
-rw-r--r--spec/bundler/support/artifice/compact_index_extra_api.rb1
-rw-r--r--spec/bundler/support/artifice/compact_index_extra_api_missing.rb17
-rw-r--r--spec/bundler/support/artifice/compact_index_extra_missing.rb1
-rw-r--r--spec/bundler/support/artifice/compact_index_forbidden.rb1
-rw-r--r--spec/bundler/support/artifice/compact_index_host_redirect.rb1
-rw-r--r--spec/bundler/support/artifice/compact_index_no_gem.rb13
-rw-r--r--spec/bundler/support/artifice/compact_index_partial_update.rb1
-rw-r--r--spec/bundler/support/artifice/compact_index_redirects.rb1
-rw-r--r--spec/bundler/support/artifice/compact_index_strict_basic_authentication.rb1
-rw-r--r--spec/bundler/support/artifice/compact_index_wrong_dependencies.rb1
-rw-r--r--spec/bundler/support/artifice/compact_index_wrong_gem_checksum.rb1
-rw-r--r--spec/bundler/support/artifice/endopint_marshal_fail_basic_authentication.rb1
-rw-r--r--spec/bundler/support/artifice/endpoint.rb29
-rw-r--r--spec/bundler/support/artifice/endpoint_500.rb1
-rw-r--r--spec/bundler/support/artifice/endpoint_api_forbidden.rb1
-rw-r--r--spec/bundler/support/artifice/endpoint_api_missing.rb1
-rw-r--r--spec/bundler/support/artifice/endpoint_basic_authentication.rb1
-rw-r--r--spec/bundler/support/artifice/endpoint_creds_diff_host.rb3
-rw-r--r--spec/bundler/support/artifice/endpoint_extra.rb1
-rw-r--r--spec/bundler/support/artifice/endpoint_extra_api.rb1
-rw-r--r--spec/bundler/support/artifice/endpoint_extra_missing.rb1
-rw-r--r--spec/bundler/support/artifice/endpoint_fallback.rb1
-rw-r--r--spec/bundler/support/artifice/endpoint_host_redirect.rb1
-rw-r--r--spec/bundler/support/artifice/endpoint_marshal_fail.rb1
-rw-r--r--spec/bundler/support/artifice/endpoint_mirror_source.rb1
-rw-r--r--spec/bundler/support/artifice/endpoint_redirect.rb1
-rw-r--r--spec/bundler/support/artifice/endpoint_strict_basic_authentication.rb1
-rw-r--r--spec/bundler/support/artifice/endpoint_timeout.rb3
-rw-r--r--spec/bundler/support/artifice/vcr.rb158
-rw-r--r--spec/bundler/support/artifice/vcr_cassettes/realworld/api.rubygems.org/api/v1/dependencies-gems=bundler/GET/request7
-rw-r--r--spec/bundler/support/artifice/vcr_cassettes/realworld/api.rubygems.org/api/v1/dependencies-gems=bundler/GET/responsebin0 -> 13564 bytes
-rw-r--r--spec/bundler/support/artifice/vcr_cassettes/realworld/api.rubygems.org/api/v1/dependencies/HEAD/request6
-rw-r--r--spec/bundler/support/artifice/vcr_cassettes/realworld/api.rubygems.org/api/v1/dependencies/HEAD/response24
-rw-r--r--spec/bundler/support/artifice/vcr_cassettes/realworld/api.rubygems.org/gems/bundler-1.12.3.gem/GET/request7
-rw-r--r--spec/bundler/support/artifice/vcr_cassettes/realworld/api.rubygems.org/gems/bundler-1.12.3.gem/GET/responsebin0 -> 280903 bytes
-rw-r--r--spec/bundler/support/artifice/vcr_cassettes/realworld/api.rubygems.org/quick/Marshal.4.8/bundler-1.12.3.gemspec.rz/GET/request7
-rw-r--r--spec/bundler/support/artifice/vcr_cassettes/realworld/api.rubygems.org/quick/Marshal.4.8/bundler-1.12.3.gemspec.rz/GET/responsebin0 -> 1425 bytes
-rw-r--r--spec/bundler/support/artifice/vcr_cassettes/realworld/api.rubygems.org/specs.4.8.gz/GET/request7
-rw-r--r--spec/bundler/support/artifice/vcr_cassettes/realworld/api.rubygems.org/specs.4.8.gz/GET/responsebin0 -> 3259479 bytes
-rw-r--r--spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/CFPropertyList/GET/request7
-rw-r--r--spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/CFPropertyList/GET/responsebin0 -> 2409 bytes
-rw-r--r--spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/ParseTree/GET/request7
-rw-r--r--spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/ParseTree/GET/responsebin0 -> 3082 bytes
-rw-r--r--spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/RedCloth/GET/request7
-rw-r--r--spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/RedCloth/GET/responsebin0 -> 3967 bytes
-rw-r--r--spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/RubyInline/GET/request7
-rw-r--r--spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/RubyInline/GET/responsebin0 -> 2679 bytes
-rw-r--r--spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/SexpProcessor/GET/request7
-rw-r--r--spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/SexpProcessor/GET/responsebin0 -> 1139 bytes
-rw-r--r--spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/ZenTest/GET/request7
-rw-r--r--spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/ZenTest/GET/responsebin0 -> 3605 bytes
-rw-r--r--spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/abstract/GET/request7
-rw-r--r--spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/abstract/GET/responsebin0 -> 1119 bytes
-rw-r--r--spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/actioncable/GET/request7
-rw-r--r--spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/actioncable/GET/responsebin0 -> 2215 bytes
-rw-r--r--spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/actionmailer/GET/request7
-rw-r--r--spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/actionmailer/GET/responsebin0 -> 15980 bytes
-rw-r--r--spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/actionpack/GET/request7
-rw-r--r--spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/actionpack/GET/responsebin0 -> 17131 bytes
-rw-r--r--spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/actionview/GET/request7
-rw-r--r--spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/actionview/GET/responsebin0 -> 5642 bytes
-rw-r--r--spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/actionwebservice/GET/request7
-rw-r--r--spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/actionwebservice/GET/responsebin0 -> 2436 bytes
-rw-r--r--spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/activejob/GET/request7
-rw-r--r--spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/activejob/GET/responsebin0 -> 3570 bytes
-rw-r--r--spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/activemodel-globalid/GET/request7
-rw-r--r--spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/activemodel-globalid/GET/responsebin0 -> 1259 bytes
-rw-r--r--spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/activemodel/GET/request7
-rw-r--r--spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/activemodel/GET/responsebin0 -> 12759 bytes
-rw-r--r--spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/activerecord-deprecated_finders/GET/request7
-rw-r--r--spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/activerecord-deprecated_finders/GET/responsebin0 -> 1396 bytes
-rw-r--r--spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/activerecord/GET/request7
-rw-r--r--spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/activerecord/GET/responsebin0 -> 16487 bytes
-rw-r--r--spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/activeresource/GET/request7
-rw-r--r--spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/activeresource/GET/responsebin0 -> 8619 bytes
-rw-r--r--spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/activesupport/GET/request7
-rw-r--r--spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/activesupport/GET/responsebin0 -> 14268 bytes
-rw-r--r--spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/adamantium/GET/request7
-rw-r--r--spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/adamantium/GET/responsebin0 -> 1716 bytes
-rw-r--r--spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/addressable/GET/request7
-rw-r--r--spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/addressable/GET/responsebin0 -> 2539 bytes
-rw-r--r--spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/allison/GET/request7
-rw-r--r--spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/allison/GET/responsebin0 -> 1292 bytes
-rw-r--r--spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/ansi/GET/request7
-rw-r--r--spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/ansi/GET/responsebin0 -> 1673 bytes
-rw-r--r--spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/archive-tar-minitar/GET/request7
-rw-r--r--spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/archive-tar-minitar/GET/responsebin0 -> 983 bytes
-rw-r--r--spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/arel/GET/request7
-rw-r--r--spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/arel/GET/responsebin0 -> 3489 bytes
-rw-r--r--spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/ast/GET/request7
-rw-r--r--spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/ast/GET/responsebin0 -> 1459 bytes
-rw-r--r--spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/astrolabe/GET/request7
-rw-r--r--spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/astrolabe/GET/responsebin0 -> 1632 bytes
-rw-r--r--spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/atomic/GET/request7
-rw-r--r--spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/atomic/GET/responsebin0 -> 3388 bytes
-rw-r--r--spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/autoparse/GET/request7
-rw-r--r--spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/autoparse/GET/responsebin0 -> 1542 bytes
-rw-r--r--spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/axiom-types/GET/request7
-rw-r--r--spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/axiom-types/GET/responsebin0 -> 1484 bytes
-rw-r--r--spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/backports/GET/request7
-rw-r--r--spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/backports/GET/responsebin0 -> 5492 bytes
-rw-r--r--spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/bacon/GET/request7
-rw-r--r--spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/bacon/GET/responsebin0 -> 1290 bytes
-rw-r--r--spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/bcrypt-ruby/GET/request7
-rw-r--r--spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/bcrypt-ruby/GET/responsebin0 -> 3733 bytes
-rw-r--r--spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/bcrypt/GET/request7
-rw-r--r--spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/bcrypt/GET/responsebin0 -> 2290 bytes
-rw-r--r--spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/bcrypt_pbkdf/GET/request7
-rw-r--r--spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/bcrypt_pbkdf/GET/responsebin0 -> 1409 bytes
-rw-r--r--spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/bones-extras/GET/request7
-rw-r--r--spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/bones-extras/GET/responsebin0 -> 1472 bytes
-rw-r--r--spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/bones-git/GET/request7
-rw-r--r--spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/bones-git/GET/responsebin0 -> 1624 bytes
-rw-r--r--spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/bones-rcov/GET/request7
-rw-r--r--spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/bones-rcov/GET/responsebin0 -> 1188 bytes
-rw-r--r--spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/bones-rspec/GET/request7
-rw-r--r--spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/bones-rspec/GET/responsebin0 -> 1331 bytes
-rw-r--r--spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/bones-rubyforge/GET/request7
-rw-r--r--spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/bones-rubyforge/GET/responsebin0 -> 1150 bytes
-rw-r--r--spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/bones-zentest/GET/request7
-rw-r--r--spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/bones-zentest/GET/responsebin0 -> 1210 bytes
-rw-r--r--spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/bones/GET/request7
-rw-r--r--spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/bones/GET/responsebin0 -> 3707 bytes
-rw-r--r--spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/builder/GET/request7
-rw-r--r--spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/builder/GET/responsebin0 -> 2000 bytes
-rw-r--r--spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/bundler/GET/request7
-rw-r--r--spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/bundler/GET/responsebin0 -> 11826 bytes
-rw-r--r--spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/camping/GET/request7
-rw-r--r--spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/camping/GET/responsebin0 -> 1815 bytes
-rw-r--r--spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/capybara/GET/request7
-rw-r--r--spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/capybara/GET/responsebin0 -> 4161 bytes
-rw-r--r--spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/celerity/GET/request7
-rw-r--r--spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/celerity/GET/responsebin0 -> 2444 bytes
-rw-r--r--spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/celluloid-essentials/GET/request7
-rw-r--r--spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/celluloid-essentials/GET/responsebin0 -> 1814 bytes
-rw-r--r--spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/celluloid-extras/GET/request7
-rw-r--r--spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/celluloid-extras/GET/responsebin0 -> 1572 bytes
-rw-r--r--spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/celluloid-fsm/GET/request7
-rw-r--r--spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/celluloid-fsm/GET/responsebin0 -> 1533 bytes
-rw-r--r--spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/celluloid-io/GET/request7
-rw-r--r--spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/celluloid-io/GET/responsebin0 -> 2502 bytes
-rw-r--r--spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/celluloid-pool/GET/request7
-rw-r--r--spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/celluloid-pool/GET/responsebin0 -> 1495 bytes
-rw-r--r--spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/celluloid-supervision/GET/request7
-rw-r--r--spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/celluloid-supervision/GET/responsebin0 -> 1618 bytes
-rw-r--r--spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/celluloid/GET/request7
-rw-r--r--spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/celluloid/GET/responsebin0 -> 3624 bytes
-rw-r--r--spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/cgi_multipart_eof_fix/GET/request7
-rw-r--r--spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/cgi_multipart_eof_fix/GET/responsebin0 -> 1316 bytes
-rw-r--r--spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/childprocess/GET/request7
-rw-r--r--spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/childprocess/GET/responsebin0 -> 3743 bytes
-rw-r--r--spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/climate_control/GET/request7
-rw-r--r--spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/climate_control/GET/responsebin0 -> 1331 bytes
-rw-r--r--spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/cocaine/GET/request7
-rw-r--r--spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/cocaine/GET/responsebin0 -> 1973 bytes
-rw-r--r--spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/coercible/GET/request7
-rw-r--r--spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/coercible/GET/responsebin0 -> 1405 bytes
-rw-r--r--spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/coffee-rails/GET/request7
-rw-r--r--spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/coffee-rails/GET/responsebin0 -> 1935 bytes
-rw-r--r--spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/coffee-script-source/GET/request7
-rw-r--r--spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/coffee-script-source/GET/responsebin0 -> 2382 bytes
-rw-r--r--spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/coffee-script/GET/request7
-rw-r--r--spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/coffee-script/GET/responsebin0 -> 2266 bytes
-rw-r--r--spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/colorize/GET/request7
-rw-r--r--spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/colorize/GET/responsebin0 -> 1783 bytes
-rw-r--r--spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/concurrent-ruby/GET/request7
-rw-r--r--spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/concurrent-ruby/GET/responsebin0 -> 5791 bytes
-rw-r--r--spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/configuration/GET/request7
-rw-r--r--spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/configuration/GET/responsebin0 -> 1437 bytes
-rw-r--r--spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/coveralls/GET/request7
-rw-r--r--spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/coveralls/GET/responsebin0 -> 3647 bytes
-rw-r--r--spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/crass/GET/request7
-rw-r--r--spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/crass/GET/responsebin0 -> 1417 bytes
-rw-r--r--spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/cucumber-core/GET/request7
-rw-r--r--spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/cucumber-core/GET/responsebin0 -> 1867 bytes
-rw-r--r--spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/cucumber-wire/GET/request7
-rw-r--r--spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/cucumber-wire/GET/responsebin0 -> 1133 bytes
-rw-r--r--spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/cucumber/GET/request7
-rw-r--r--spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/cucumber/GET/responsebin0 -> 8723 bytes
-rw-r--r--spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/culerity/GET/request7
-rw-r--r--spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/culerity/GET/responsebin0 -> 1646 bytes
-rw-r--r--spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/curses/GET/request7
-rw-r--r--spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/curses/GET/responsebin0 -> 2166 bytes
-rw-r--r--spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/daemons/GET/request7
-rw-r--r--spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/daemons/GET/responsebin0 -> 2369 bytes
-rw-r--r--spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/database_cleaner/GET/request7
-rw-r--r--spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/database_cleaner/GET/responsebin0 -> 2825 bytes
-rw-r--r--spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/declarative-option/GET/request7
-rw-r--r--spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/declarative-option/GET/responsebin0 -> 1183 bytes
-rw-r--r--spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/declarative/GET/request7
-rw-r--r--spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/declarative/GET/responsebin0 -> 1449 bytes
-rw-r--r--spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/descendants_tracker/GET/request7
-rw-r--r--spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/descendants_tracker/GET/responsebin0 -> 1266 bytes
-rw-r--r--spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/diff-lcs/GET/request7
-rw-r--r--spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/diff-lcs/GET/responsebin0 -> 1552 bytes
-rw-r--r--spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/docile/GET/request7
-rw-r--r--spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/docile/GET/responsebin0 -> 1690 bytes
-rw-r--r--spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/domain_name/GET/request7
-rw-r--r--spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/domain_name/GET/responsebin0 -> 2706 bytes
-rw-r--r--spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/dotenv-deployment/GET/request7
-rw-r--r--spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/dotenv-deployment/GET/responsebin0 -> 1322 bytes
-rw-r--r--spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/dotenv/GET/request7
-rw-r--r--spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/dotenv/GET/responsebin0 -> 2171 bytes
-rw-r--r--spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/echoe/GET/request7
-rw-r--r--spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/echoe/GET/responsebin0 -> 3497 bytes
-rw-r--r--spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/em-hiredis/GET/request7
-rw-r--r--spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/em-hiredis/GET/responsebin0 -> 1475 bytes
-rw-r--r--spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/english/GET/request7
-rw-r--r--spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/english/GET/responsebin0 -> 1473 bytes
-rw-r--r--spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/equalizer/GET/request7
-rw-r--r--spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/equalizer/GET/responsebin0 -> 1624 bytes
-rw-r--r--spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/erubi/GET/request7
-rw-r--r--spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/erubi/GET/responsebin0 -> 1457 bytes
-rw-r--r--spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/erubis/GET/request7
-rw-r--r--spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/erubis/GET/responsebin0 -> 1909 bytes
-rw-r--r--spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/escape_utils/GET/request7
-rw-r--r--spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/escape_utils/GET/responsebin0 -> 2132 bytes
-rw-r--r--spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/et-orbi/GET/request7
-rw-r--r--spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/et-orbi/GET/responsebin0 -> 1347 bytes
-rw-r--r--spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/event-bus/GET/request7
-rw-r--r--spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/event-bus/GET/responsebin0 -> 1280 bytes
-rw-r--r--spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/eventmachine-le/GET/request7
-rw-r--r--spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/eventmachine-le/GET/responsebin0 -> 1550 bytes
-rw-r--r--spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/eventmachine/GET/request7
-rw-r--r--spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/eventmachine/GET/responsebin0 -> 5984 bytes
-rw-r--r--spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/execjs/GET/request7
-rw-r--r--spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/execjs/GET/responsebin0 -> 3128 bytes
-rw-r--r--spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/extlib/GET/request7
-rw-r--r--spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/extlib/GET/responsebin0 -> 1731 bytes
-rw-r--r--spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/facets/GET/request7
-rw-r--r--spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/facets/GET/responsebin0 -> 4020 bytes
-rw-r--r--spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/facter/GET/request7
-rw-r--r--spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/facter/GET/responsebin0 -> 6040 bytes
-rw-r--r--spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/faker/GET/request7
-rw-r--r--spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/faker/GET/responsebin0 -> 2506 bytes
-rw-r--r--spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/faraday/GET/request7
-rw-r--r--spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/faraday/GET/responsebin0 -> 4140 bytes
-rw-r--r--spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/fastthread/GET/request7
-rw-r--r--spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/fastthread/GET/responsebin0 -> 1678 bytes
-rw-r--r--spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/faye-websocket/GET/request7
-rw-r--r--spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/faye-websocket/GET/responsebin0 -> 2954 bytes
-rw-r--r--spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/fcgi/GET/request7
-rw-r--r--spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/fcgi/GET/responsebin0 -> 1394 bytes
-rw-r--r--spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/ffi-win32-extensions/GET/request7
-rw-r--r--spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/ffi-win32-extensions/GET/responsebin0 -> 1247 bytes
-rw-r--r--spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/ffi/GET/request7
-rw-r--r--spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/ffi/GET/responsebin0 -> 10317 bytes
-rw-r--r--spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/flexmock/GET/request7
-rw-r--r--spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/flexmock/GET/responsebin0 -> 4115 bytes
-rw-r--r--spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/functional-ruby/GET/request7
-rw-r--r--spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/functional-ruby/GET/responsebin0 -> 1720 bytes
-rw-r--r--spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/gem_plugin/GET/request7
-rw-r--r--spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/gem_plugin/GET/responsebin0 -> 1292 bytes
-rw-r--r--spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/gemcutter/GET/request7
-rw-r--r--spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/gemcutter/GET/responsebin0 -> 2356 bytes
-rw-r--r--spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/gherkin/GET/request7
-rw-r--r--spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/gherkin/GET/responsebin0 -> 24606 bytes
-rw-r--r--spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/gherkin3/GET/request7
-rw-r--r--spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/gherkin3/GET/responsebin0 -> 1385 bytes
-rw-r--r--spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/git/GET/request7
-rw-r--r--spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/git/GET/responsebin0 -> 1868 bytes
-rw-r--r--spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/globalid/GET/request7
-rw-r--r--spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/globalid/GET/responsebin0 -> 1713 bytes
-rw-r--r--spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/google-api-client/GET/request7
-rw-r--r--spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/google-api-client/GET/responsebin0 -> 4701 bytes
-rw-r--r--spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/googleauth/GET/request7
-rw-r--r--spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/googleauth/GET/responsebin0 -> 1604 bytes
-rw-r--r--spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/gxapi_rails/GET/request7
-rw-r--r--spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/gxapi_rails/GET/responsebin0 -> 1461 bytes
-rw-r--r--spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/hashie/GET/request7
-rw-r--r--spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/hashie/GET/responsebin0 -> 2836 bytes
-rw-r--r--spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/highline/GET/request7
-rw-r--r--spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/highline/GET/responsebin0 -> 3414 bytes
-rw-r--r--spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/hike/GET/request7
-rw-r--r--spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/hike/GET/responsebin0 -> 2159 bytes
-rw-r--r--spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/hiredis/GET/request7
-rw-r--r--spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/hiredis/GET/responsebin0 -> 2409 bytes
-rw-r--r--spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/hitimes/GET/request7
-rw-r--r--spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/hitimes/GET/responsebin0 -> 3196 bytes
-rw-r--r--spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/hoe/GET/request7
-rw-r--r--spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/hoe/GET/responsebin0 -> 6300 bytes
-rw-r--r--spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/hooks/GET/request7
-rw-r--r--spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/hooks/GET/responsebin0 -> 1870 bytes
-rw-r--r--spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/http-cookie/GET/request7
-rw-r--r--spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/http-cookie/GET/responsebin0 -> 1702 bytes
-rw-r--r--spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/http_parser.rb/GET/request7
-rw-r--r--spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/http_parser.rb/GET/responsebin0 -> 1984 bytes
-rw-r--r--spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/httpadapter/GET/request7
-rw-r--r--spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/httpadapter/GET/responsebin0 -> 1300 bytes
-rw-r--r--spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/httpclient/GET/request7
-rw-r--r--spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/httpclient/GET/responsebin0 -> 3289 bytes
-rw-r--r--spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/hurley/GET/request7
-rw-r--r--spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/hurley/GET/responsebin0 -> 1159 bytes
-rw-r--r--spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/i18n/GET/request7
-rw-r--r--spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/i18n/GET/responsebin0 -> 2461 bytes
-rw-r--r--spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/ice_nine/GET/request7
-rw-r--r--spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/ice_nine/GET/responsebin0 -> 1643 bytes
-rw-r--r--spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/journey/GET/request7
-rw-r--r--spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/journey/GET/responsebin0 -> 1461 bytes
-rw-r--r--spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/jruby-pageant/GET/request7
-rw-r--r--spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/jruby-pageant/GET/responsebin0 -> 1477 bytes
-rw-r--r--spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/json/GET/request7
-rw-r--r--spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/json/GET/responsebin0 -> 5773 bytes
-rw-r--r--spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/json_pure/GET/request7
-rw-r--r--spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/json_pure/GET/responsebin0 -> 3740 bytes
-rw-r--r--spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/jwt/GET/request7
-rw-r--r--spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/jwt/GET/responsebin0 -> 1834 bytes
-rw-r--r--spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/language/GET/request7
-rw-r--r--spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/language/GET/responsebin0 -> 1119 bytes
-rw-r--r--spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/launchy/GET/request7
-rw-r--r--spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/launchy/GET/responsebin0 -> 2825 bytes
-rw-r--r--spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/libwebsocket/GET/request7
-rw-r--r--spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/libwebsocket/GET/responsebin0 -> 1625 bytes
-rw-r--r--spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/libxml-ruby/GET/request7
-rw-r--r--spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/libxml-ruby/GET/responsebin0 -> 5226 bytes
-rw-r--r--spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/liquid/GET/request7
-rw-r--r--spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/liquid/GET/responsebin0 -> 2606 bytes
-rw-r--r--spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/listen/GET/request7
-rw-r--r--spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/listen/GET/responsebin0 -> 5535 bytes
-rw-r--r--spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/little-plugger/GET/request7
-rw-r--r--spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/little-plugger/GET/responsebin0 -> 1385 bytes
-rw-r--r--spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/lockfile/GET/request7
-rw-r--r--spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/lockfile/GET/responsebin0 -> 1536 bytes
-rw-r--r--spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/logging/GET/request7
-rw-r--r--spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/logging/GET/responsebin0 -> 3756 bytes
-rw-r--r--spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/loofah/GET/request7
-rw-r--r--spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/loofah/GET/responsebin0 -> 2157 bytes
-rw-r--r--spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/loquacious/GET/request7
-rw-r--r--spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/loquacious/GET/responsebin0 -> 2055 bytes
-rw-r--r--spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/mab/GET/request7
-rw-r--r--spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/mab/GET/responsebin0 -> 1251 bytes
-rw-r--r--spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/mail/GET/request7
-rw-r--r--spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/mail/GET/responsebin0 -> 4606 bytes
-rw-r--r--spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/markaby/GET/request7
-rw-r--r--spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/markaby/GET/responsebin0 -> 1626 bytes
-rw-r--r--spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/memcache-client/GET/request7
-rw-r--r--spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/memcache-client/GET/responsebin0 -> 2171 bytes
-rw-r--r--spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/memoist/GET/request7
-rw-r--r--spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/memoist/GET/responsebin0 -> 1621 bytes
-rw-r--r--spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/memoizable/GET/request7
-rw-r--r--spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/memoizable/GET/responsebin0 -> 1396 bytes
-rw-r--r--spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/metaclass/GET/request7
-rw-r--r--spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/metaclass/GET/responsebin0 -> 1239 bytes
-rw-r--r--spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/metaid/GET/request7
-rw-r--r--spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/metaid/GET/responsebin0 -> 1117 bytes
-rw-r--r--spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/method_source/GET/request7
-rw-r--r--spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/method_source/GET/responsebin0 -> 2123 bytes
-rw-r--r--spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/mime-types-data/GET/request7
-rw-r--r--spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/mime-types-data/GET/responsebin0 -> 1224 bytes
-rw-r--r--spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/mime-types/GET/request7
-rw-r--r--spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/mime-types/GET/responsebin0 -> 2502 bytes
-rw-r--r--spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/mimemagic/GET/request7
-rw-r--r--spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/mimemagic/GET/responsebin0 -> 1608 bytes
-rw-r--r--spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/mini_portile/GET/request7
-rw-r--r--spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/mini_portile/GET/responsebin0 -> 1860 bytes
-rw-r--r--spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/mini_portile2/GET/request7
-rw-r--r--spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/mini_portile2/GET/responsebin0 -> 1319 bytes
-rw-r--r--spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/minitar-cli/GET/request7
-rw-r--r--spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/minitar-cli/GET/responsebin0 -> 1270 bytes
-rw-r--r--spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/minitar/GET/request7
-rw-r--r--spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/minitar/GET/responsebin0 -> 1254 bytes
-rw-r--r--spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/minitest/GET/request7
-rw-r--r--spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/minitest/GET/responsebin0 -> 5382 bytes
-rw-r--r--spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/mkrf/GET/request7
-rw-r--r--spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/mkrf/GET/responsebin0 -> 1354 bytes
-rw-r--r--spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/mocha/GET/request7
-rw-r--r--spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/mocha/GET/responsebin0 -> 3771 bytes
-rw-r--r--spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/mongrel/GET/request7
-rw-r--r--spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/mongrel/GET/responsebin0 -> 3434 bytes
-rw-r--r--spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/mono_logger/GET/request7
-rw-r--r--spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/mono_logger/GET/responsebin0 -> 1252 bytes
-rw-r--r--spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/multi_json/GET/request7
-rw-r--r--spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/multi_json/GET/responsebin0 -> 3387 bytes
-rw-r--r--spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/multi_test/GET/request7
-rw-r--r--spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/multi_test/GET/responsebin0 -> 1315 bytes
-rw-r--r--spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/multimap/GET/request7
-rw-r--r--spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/multimap/GET/responsebin0 -> 1171 bytes
-rw-r--r--spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/multipart-post/GET/request7
-rw-r--r--spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/multipart-post/GET/responsebin0 -> 1600 bytes
-rw-r--r--spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/mustermann/GET/request7
-rw-r--r--spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/mustermann/GET/responsebin0 -> 1524 bytes
-rw-r--r--spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/needle/GET/request7
-rw-r--r--spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/needle/GET/responsebin0 -> 1395 bytes
-rw-r--r--spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/nenv/GET/request7
-rw-r--r--spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/nenv/GET/responsebin0 -> 1372 bytes
-rw-r--r--spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/net-scp/GET/request7
-rw-r--r--spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/net-scp/GET/responsebin0 -> 1517 bytes
-rw-r--r--spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/net-ssh/GET/request7
-rw-r--r--spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/net-ssh/GET/responsebin0 -> 6107 bytes
-rw-r--r--spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/netrc/GET/request7
-rw-r--r--spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/netrc/GET/responsebin0 -> 2064 bytes
-rw-r--r--spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/newgem/GET/request7
-rw-r--r--spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/newgem/GET/responsebin0 -> 4664 bytes
-rw-r--r--spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/nio4r/GET/request7
-rw-r--r--spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/nio4r/GET/responsebin0 -> 3204 bytes
-rw-r--r--spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/nokogiri/GET/request7
-rw-r--r--spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/nokogiri/GET/responsebin0 -> 16546 bytes
-rw-r--r--spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/os/GET/request7
-rw-r--r--spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/os/GET/responsebin0 -> 2022 bytes
-rw-r--r--spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/paperclip/GET/request7
-rw-r--r--spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/paperclip/GET/responsebin0 -> 5136 bytes
-rw-r--r--spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/parser/GET/request7
-rw-r--r--spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/parser/GET/responsebin0 -> 4832 bytes
-rw-r--r--spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/pattern-match/GET/request7
-rw-r--r--spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/pattern-match/GET/responsebin0 -> 1486 bytes
-rw-r--r--spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/pkg-config/GET/request7
-rw-r--r--spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/pkg-config/GET/responsebin0 -> 1967 bytes
-rw-r--r--spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/polyglot/GET/request7
-rw-r--r--spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/polyglot/GET/responsebin0 -> 1780 bytes
-rw-r--r--spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/power_assert/GET/request7
-rw-r--r--spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/power_assert/GET/responsebin0 -> 1921 bytes
-rw-r--r--spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/powerbar/GET/request7
-rw-r--r--spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/powerbar/GET/responsebin0 -> 1595 bytes
-rw-r--r--spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/powerpack/GET/request7
-rw-r--r--spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/powerpack/GET/responsebin0 -> 1516 bytes
-rw-r--r--spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/preforker/GET/request7
-rw-r--r--spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/preforker/GET/responsebin0 -> 1161 bytes
-rw-r--r--spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/public_suffix/GET/request7
-rw-r--r--spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/public_suffix/GET/responsebin0 -> 1992 bytes
-rw-r--r--spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/racc/GET/request7
-rw-r--r--spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/racc/GET/responsebin0 -> 1605 bytes
-rw-r--r--spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/rack-cache/GET/request7
-rw-r--r--spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/rack-cache/GET/responsebin0 -> 2061 bytes
-rw-r--r--spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/rack-mount/GET/request7
-rw-r--r--spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/rack-mount/GET/responsebin0 -> 3015 bytes
-rw-r--r--spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/rack-protection/GET/request7
-rw-r--r--spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/rack-protection/GET/responsebin0 -> 1826 bytes
-rw-r--r--spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/rack-ssl/GET/request7
-rw-r--r--spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/rack-ssl/GET/responsebin0 -> 1537 bytes
-rw-r--r--spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/rack-test/GET/request7
-rw-r--r--spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/rack-test/GET/responsebin0 -> 1821 bytes
-rw-r--r--spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/rack/GET/request7
-rw-r--r--spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/rack/GET/responsebin0 -> 3633 bytes
-rw-r--r--spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/rails-deprecated_sanitizer/GET/request7
-rw-r--r--spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/rails-deprecated_sanitizer/GET/responsebin0 -> 1320 bytes
-rw-r--r--spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/rails-dom-testing/GET/request7
-rw-r--r--spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/rails-dom-testing/GET/responsebin0 -> 1706 bytes
-rw-r--r--spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/rails-html-sanitizer/GET/request7
-rw-r--r--spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/rails-html-sanitizer/GET/responsebin0 -> 1308 bytes
-rw-r--r--spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/rails-observers/GET/request7
-rw-r--r--spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/rails-observers/GET/responsebin0 -> 1297 bytes
-rw-r--r--spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/rails/GET/request7
-rw-r--r--spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/rails/GET/responsebin0 -> 21031 bytes
-rw-r--r--spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/railties/GET/request7
-rw-r--r--spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/railties/GET/responsebin0 -> 13615 bytes
-rw-r--r--spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/rainbow/GET/request7
-rw-r--r--spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/rainbow/GET/responsebin0 -> 1836 bytes
-rw-r--r--spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/rake-compiler/GET/request7
-rw-r--r--spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/rake-compiler/GET/responsebin0 -> 2482 bytes
-rw-r--r--spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/rake/GET/request7
-rw-r--r--spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/rake/GET/responsebin0 -> 4284 bytes
-rw-r--r--spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/rb-fchange/GET/request7
-rw-r--r--spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/rb-fchange/GET/responsebin0 -> 1330 bytes
-rw-r--r--spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/rb-fsevent/GET/request7
-rw-r--r--spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/rb-fsevent/GET/responsebin0 -> 2441 bytes
-rw-r--r--spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/rb-inotify/GET/request7
-rw-r--r--spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/rb-inotify/GET/responsebin0 -> 2294 bytes
-rw-r--r--spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/rb-kqueue/GET/request7
-rw-r--r--spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/rb-kqueue/GET/responsebin0 -> 1512 bytes
-rw-r--r--spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/rbnacl-libsodium/GET/request7
-rw-r--r--spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/rbnacl-libsodium/GET/responsebin0 -> 1954 bytes
-rw-r--r--spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/rbnacl/GET/request7
-rw-r--r--spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/rbnacl/GET/responsebin0 -> 1869 bytes
-rw-r--r--spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/rcov/GET/request7
-rw-r--r--spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/rcov/GET/responsebin0 -> 2709 bytes
-rw-r--r--spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/rdoc/GET/request7
-rw-r--r--spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/rdoc/GET/responsebin0 -> 3765 bytes
-rw-r--r--spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/redis-namespace/GET/request7
-rw-r--r--spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/redis-namespace/GET/responsebin0 -> 2749 bytes
-rw-r--r--spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/redis/GET/request7
-rw-r--r--spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/redis/GET/responsebin0 -> 3469 bytes
-rw-r--r--spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/ref/GET/request7
-rw-r--r--spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/ref/GET/responsebin0 -> 1331 bytes
-rw-r--r--spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/representable/GET/request7
-rw-r--r--spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/representable/GET/responsebin0 -> 5461 bytes
-rw-r--r--spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/resque-scheduler/GET/request7
-rw-r--r--spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/resque-scheduler/GET/responsebin0 -> 3413 bytes
-rw-r--r--spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/resque/GET/request7
-rw-r--r--spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/resque/GET/responsebin0 -> 4325 bytes
-rw-r--r--spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/rest-client/GET/request7
-rw-r--r--spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/rest-client/GET/responsebin0 -> 5867 bytes
-rw-r--r--spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/retriable/GET/request7
-rw-r--r--spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/retriable/GET/responsebin0 -> 1988 bytes
-rw-r--r--spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/rexical/GET/request7
-rw-r--r--spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/rexical/GET/responsebin0 -> 1320 bytes
-rw-r--r--spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/right_aws/GET/request7
-rw-r--r--spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/right_aws/GET/responsebin0 -> 2220 bytes
-rw-r--r--spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/right_http_connection/GET/request7
-rw-r--r--spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/right_http_connection/GET/responsebin0 -> 1463 bytes
-rw-r--r--spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/rspec-core/GET/request7
-rw-r--r--spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/rspec-core/GET/responsebin0 -> 6529 bytes
-rw-r--r--spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/rspec-expectations/GET/request7
-rw-r--r--spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/rspec-expectations/GET/responsebin0 -> 5082 bytes
-rw-r--r--spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/rspec-logsplit/GET/request7
-rw-r--r--spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/rspec-logsplit/GET/responsebin0 -> 1145 bytes
-rw-r--r--spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/rspec-mocks/GET/request7
-rw-r--r--spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/rspec-mocks/GET/responsebin0 -> 5744 bytes
-rw-r--r--spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/rspec-support/GET/request7
-rw-r--r--spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/rspec-support/GET/responsebin0 -> 1803 bytes
-rw-r--r--spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/rspec/GET/request7
-rw-r--r--spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/rspec/GET/responsebin0 -> 9093 bytes
-rw-r--r--spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/rubigen/GET/request7
-rw-r--r--spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/rubigen/GET/responsebin0 -> 2604 bytes
-rw-r--r--spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/rubocop/GET/request7
-rw-r--r--spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/rubocop/GET/responsebin0 -> 5383 bytes
-rw-r--r--spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/ruby-openid/GET/request7
-rw-r--r--spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/ruby-openid/GET/responsebin0 -> 2169 bytes
-rw-r--r--spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/ruby-progressbar/GET/request7
-rw-r--r--spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/ruby-progressbar/GET/responsebin0 -> 2172 bytes
-rw-r--r--spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/ruby-yadis/GET/request7
-rw-r--r--spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/ruby-yadis/GET/responsebin0 -> 1396 bytes
-rw-r--r--spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/ruby_dep/GET/request7
-rw-r--r--spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/ruby_dep/GET/responsebin0 -> 1449 bytes
-rw-r--r--spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/ruby_parser/GET/request7
-rw-r--r--spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/ruby_parser/GET/responsebin0 -> 3610 bytes
-rw-r--r--spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/rubyforge/GET/request7
-rw-r--r--spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/rubyforge/GET/responsebin0 -> 2161 bytes
-rw-r--r--spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/rubyzip/GET/request7
-rw-r--r--spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/rubyzip/GET/responsebin0 -> 2154 bytes
-rw-r--r--spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/rufus-scheduler/GET/request7
-rw-r--r--spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/rufus-scheduler/GET/responsebin0 -> 4127 bytes
-rw-r--r--spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/sass-listen/GET/request7
-rw-r--r--spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/sass-listen/GET/responsebin0 -> 1210 bytes
-rw-r--r--spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/sass-rails/GET/request7
-rw-r--r--spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/sass-rails/GET/responsebin0 -> 3197 bytes
-rw-r--r--spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/sass/GET/request7
-rw-r--r--spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/sass/GET/responsebin0 -> 14818 bytes
-rw-r--r--spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/selenium-webdriver/GET/request7
-rw-r--r--spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/selenium-webdriver/GET/responsebin0 -> 8060 bytes
-rw-r--r--spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/sexp_processor/GET/request7
-rw-r--r--spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/sexp_processor/GET/responsebin0 -> 2676 bytes
-rw-r--r--spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/shotgun/GET/request7
-rw-r--r--spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/shotgun/GET/responsebin0 -> 1262 bytes
-rw-r--r--spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/signet/GET/request7
-rw-r--r--spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/signet/GET/responsebin0 -> 2507 bytes
-rw-r--r--spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/simplecov-html/GET/request7
-rw-r--r--spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/simplecov-html/GET/responsebin0 -> 1939 bytes
-rw-r--r--spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/simplecov/GET/request7
-rw-r--r--spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/simplecov/GET/responsebin0 -> 2867 bytes
-rw-r--r--spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/sinatra/GET/request7
-rw-r--r--spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/sinatra/GET/responsebin0 -> 4641 bytes
-rw-r--r--spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/slop/GET/request7
-rw-r--r--spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/slop/GET/responsebin0 -> 3976 bytes
-rw-r--r--spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/spicycode-rcov/GET/request7
-rw-r--r--spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/spicycode-rcov/GET/responsebin0 -> 1380 bytes
-rw-r--r--spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/spoon/GET/request7
-rw-r--r--spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/spoon/GET/responsebin0 -> 984 bytes
-rw-r--r--spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/sprockets-rails/GET/request7
-rw-r--r--spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/sprockets-rails/GET/responsebin0 -> 2411 bytes
-rw-r--r--spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/sprockets/GET/request7
-rw-r--r--spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/sprockets/GET/responsebin0 -> 5490 bytes
-rw-r--r--spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/spruz/GET/request7
-rw-r--r--spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/spruz/GET/responsebin0 -> 1758 bytes
-rw-r--r--spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/sqlite3/GET/request7
-rw-r--r--spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/sqlite3/GET/responsebin0 -> 3024 bytes
-rw-r--r--spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/syntax/GET/request7
-rw-r--r--spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/syntax/GET/responsebin0 -> 1320 bytes
-rw-r--r--spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/sys-admin/GET/request7
-rw-r--r--spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/sys-admin/GET/responsebin0 -> 2482 bytes
-rw-r--r--spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/tenderlove-frex/GET/request7
-rw-r--r--spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/tenderlove-frex/GET/responsebin0 -> 1127 bytes
-rw-r--r--spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/term-ansicolor/GET/request7
-rw-r--r--spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/term-ansicolor/GET/responsebin0 -> 2152 bytes
-rw-r--r--spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/termios/GET/request7
-rw-r--r--spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/termios/GET/responsebin0 -> 1120 bytes
-rw-r--r--spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/test-spec/GET/request7
-rw-r--r--spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/test-spec/GET/responsebin0 -> 1314 bytes
-rw-r--r--spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/test-unit/GET/request7
-rw-r--r--spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/test-unit/GET/responsebin0 -> 3248 bytes
-rw-r--r--spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/text-format/GET/request7
-rw-r--r--spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/text-format/GET/responsebin0 -> 1203 bytes
-rw-r--r--spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/text-hyphen/GET/request7
-rw-r--r--spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/text-hyphen/GET/responsebin0 -> 1367 bytes
-rw-r--r--spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/thin/GET/request7
-rw-r--r--spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/thin/GET/responsebin0 -> 4119 bytes
-rw-r--r--spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/thor/GET/request7
-rw-r--r--spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/thor/GET/responsebin0 -> 2902 bytes
-rw-r--r--spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/thoughtbot-shoulda/GET/request7
-rw-r--r--spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/thoughtbot-shoulda/GET/responsebin0 -> 1730 bytes
-rw-r--r--spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/thread_safe/GET/request7
-rw-r--r--spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/thread_safe/GET/responsebin0 -> 1797 bytes
-rw-r--r--spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/tilt/GET/request7
-rw-r--r--spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/tilt/GET/responsebin0 -> 2483 bytes
-rw-r--r--spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/timers/GET/request7
-rw-r--r--spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/timers/GET/responsebin0 -> 1959 bytes
-rw-r--r--spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/tins/GET/request7
-rw-r--r--spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/tins/GET/responsebin0 -> 4223 bytes
-rw-r--r--spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/tlsmail/GET/request7
-rw-r--r--spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/tlsmail/GET/responsebin0 -> 1118 bytes
-rw-r--r--spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/tool/GET/request7
-rw-r--r--spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/tool/GET/responsebin0 -> 1384 bytes
-rw-r--r--spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/treetop/GET/request7
-rw-r--r--spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/treetop/GET/responsebin0 -> 2820 bytes
-rw-r--r--spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/trollop/GET/request7
-rw-r--r--spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/trollop/GET/responsebin0 -> 2282 bytes
-rw-r--r--spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/tzinfo/GET/request7
-rw-r--r--spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/tzinfo/GET/responsebin0 -> 4085 bytes
-rw-r--r--spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/uber/GET/request7
-rw-r--r--spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/uber/GET/responsebin0 -> 1784 bytes
-rw-r--r--spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/unf/GET/request7
-rw-r--r--spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/unf/GET/responsebin0 -> 1799 bytes
-rw-r--r--spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/unf_ext/GET/request7
-rw-r--r--spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/unf_ext/GET/responsebin0 -> 1944 bytes
-rw-r--r--spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/unicode-display_width/GET/request7
-rw-r--r--spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/unicode-display_width/GET/responsebin0 -> 1885 bytes
-rw-r--r--spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/uuidtools/GET/request7
-rw-r--r--spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/uuidtools/GET/responsebin0 -> 2003 bytes
-rw-r--r--spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/vegas/GET/request7
-rw-r--r--spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/vegas/GET/responsebin0 -> 1922 bytes
-rw-r--r--spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/virtus/GET/request7
-rw-r--r--spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/virtus/GET/responsebin0 -> 2839 bytes
-rw-r--r--spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/weakling/GET/request7
-rw-r--r--spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/weakling/GET/responsebin0 -> 1309 bytes
-rw-r--r--spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/websocket-driver/GET/request7
-rw-r--r--spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/websocket-driver/GET/responsebin0 -> 2733 bytes
-rw-r--r--spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/websocket-extensions/GET/request7
-rw-r--r--spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/websocket-extensions/GET/responsebin0 -> 1267 bytes
-rw-r--r--spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/websocket/GET/request7
-rw-r--r--spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/websocket/GET/responsebin0 -> 1863 bytes
-rw-r--r--spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/win32-api/GET/request7
-rw-r--r--spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/win32-api/GET/responsebin0 -> 3049 bytes
-rw-r--r--spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/win32-dir/GET/request7
-rw-r--r--spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/win32-dir/GET/responsebin0 -> 1924 bytes
-rw-r--r--spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/win32-security/GET/request7
-rw-r--r--spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/win32-security/GET/responsebin0 -> 1918 bytes
-rw-r--r--spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/win32console/GET/request7
-rw-r--r--spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/win32console/GET/responsebin0 -> 2032 bytes
-rw-r--r--spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/windows-api/GET/request7
-rw-r--r--spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/windows-api/GET/responsebin0 -> 1752 bytes
-rw-r--r--spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/windows-pr/GET/request7
-rw-r--r--spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/windows-pr/GET/responsebin0 -> 3434 bytes
-rw-r--r--spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/xpath/GET/request7
-rw-r--r--spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/xpath/GET/responsebin0 -> 1537 bytes
-rw-r--r--spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/versions/GET/request7
-rw-r--r--spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/versions/GET/responsebin0 -> 4840181 bytes
-rw-r--r--spec/bundler/support/artifice/vcr_cassettes/realworld/rubygems.org/gems/activesupport-3.2.12.gem/GET/request7
-rw-r--r--spec/bundler/support/artifice/vcr_cassettes/realworld/rubygems.org/gems/activesupport-3.2.12.gem/GET/responsebin0 -> 288578 bytes
-rw-r--r--spec/bundler/support/artifice/vcr_cassettes/realworld/rubygems.org/gems/activesupport-3.2.22.5.gem/GET/request7
-rw-r--r--spec/bundler/support/artifice/vcr_cassettes/realworld/rubygems.org/gems/activesupport-3.2.22.5.gem/GET/responsebin0 -> 290666 bytes
-rw-r--r--spec/bundler/support/artifice/vcr_cassettes/realworld/rubygems.org/gems/bundler-1.12.3.gem/GET/request7
-rw-r--r--spec/bundler/support/artifice/vcr_cassettes/realworld/rubygems.org/gems/bundler-1.12.3.gem/GET/responsebin0 -> 280901 bytes
-rw-r--r--spec/bundler/support/artifice/vcr_cassettes/realworld/rubygems.org/gems/diff-lcs-1.3.gem/GET/request7
-rw-r--r--spec/bundler/support/artifice/vcr_cassettes/realworld/rubygems.org/gems/diff-lcs-1.3.gem/GET/responsebin0 -> 46952 bytes
-rw-r--r--spec/bundler/support/artifice/vcr_cassettes/realworld/rubygems.org/gems/faker-1.1.2.gem/GET/request7
-rw-r--r--spec/bundler/support/artifice/vcr_cassettes/realworld/rubygems.org/gems/faker-1.1.2.gem/GET/responsebin0 -> 97089 bytes
-rw-r--r--spec/bundler/support/artifice/vcr_cassettes/realworld/rubygems.org/gems/i18n-0.6.11.gem/GET/request7
-rw-r--r--spec/bundler/support/artifice/vcr_cassettes/realworld/rubygems.org/gems/i18n-0.6.11.gem/GET/responsebin0 -> 62275 bytes
-rw-r--r--spec/bundler/support/artifice/vcr_cassettes/realworld/rubygems.org/gems/i18n-0.8.1.gem/GET/request7
-rw-r--r--spec/bundler/support/artifice/vcr_cassettes/realworld/rubygems.org/gems/i18n-0.8.1.gem/GET/responsebin0 -> 60267 bytes
-rw-r--r--spec/bundler/support/artifice/vcr_cassettes/realworld/rubygems.org/gems/mono_logger-1.1.0.gem/GET/request7
-rw-r--r--spec/bundler/support/artifice/vcr_cassettes/realworld/rubygems.org/gems/mono_logger-1.1.0.gem/GET/responsebin0 -> 11073 bytes
-rw-r--r--spec/bundler/support/artifice/vcr_cassettes/realworld/rubygems.org/gems/multi_json-1.12.1.gem/GET/request7
-rw-r--r--spec/bundler/support/artifice/vcr_cassettes/realworld/rubygems.org/gems/multi_json-1.12.1.gem/GET/responsebin0 -> 26949 bytes
-rw-r--r--spec/bundler/support/artifice/vcr_cassettes/realworld/rubygems.org/gems/rack-1.0.1.gem/GET/request7
-rw-r--r--spec/bundler/support/artifice/vcr_cassettes/realworld/rubygems.org/gems/rack-1.0.1.gem/GET/responsebin0 -> 135492 bytes
-rw-r--r--spec/bundler/support/artifice/vcr_cassettes/realworld/rubygems.org/gems/rack-1.6.5.gem/GET/request7
-rw-r--r--spec/bundler/support/artifice/vcr_cassettes/realworld/rubygems.org/gems/rack-1.6.5.gem/GET/responsebin0 -> 230247 bytes
-rw-r--r--spec/bundler/support/artifice/vcr_cassettes/realworld/rubygems.org/gems/rack-protection-1.5.3.gem/GET/request7
-rw-r--r--spec/bundler/support/artifice/vcr_cassettes/realworld/rubygems.org/gems/rack-protection-1.5.3.gem/GET/responsebin0 -> 19265 bytes
-rw-r--r--spec/bundler/support/artifice/vcr_cassettes/realworld/rubygems.org/gems/redis-3.3.3.gem/GET/request7
-rw-r--r--spec/bundler/support/artifice/vcr_cassettes/realworld/rubygems.org/gems/redis-3.3.3.gem/GET/responsebin0 -> 93544 bytes
-rw-r--r--spec/bundler/support/artifice/vcr_cassettes/realworld/rubygems.org/gems/redis-namespace-1.5.3.gem/GET/request7
-rw-r--r--spec/bundler/support/artifice/vcr_cassettes/realworld/rubygems.org/gems/redis-namespace-1.5.3.gem/GET/responsebin0 -> 17766 bytes
-rw-r--r--spec/bundler/support/artifice/vcr_cassettes/realworld/rubygems.org/gems/resque-1.24.1.gem/GET/request7
-rw-r--r--spec/bundler/support/artifice/vcr_cassettes/realworld/rubygems.org/gems/resque-1.24.1.gem/GET/responsebin0 -> 91457 bytes
-rw-r--r--spec/bundler/support/artifice/vcr_cassettes/realworld/rubygems.org/gems/resque-scheduler-2.2.0.gem/GET/request7
-rw-r--r--spec/bundler/support/artifice/vcr_cassettes/realworld/rubygems.org/gems/resque-scheduler-2.2.0.gem/GET/responsebin0 -> 37697 bytes
-rw-r--r--spec/bundler/support/artifice/vcr_cassettes/realworld/rubygems.org/gems/rufus-scheduler-2.0.24.gem/GET/request7
-rw-r--r--spec/bundler/support/artifice/vcr_cassettes/realworld/rubygems.org/gems/rufus-scheduler-2.0.24.gem/GET/responsebin0 -> 38721 bytes
-rw-r--r--spec/bundler/support/artifice/vcr_cassettes/realworld/rubygems.org/gems/sinatra-1.4.8.gem/GET/request7
-rw-r--r--spec/bundler/support/artifice/vcr_cassettes/realworld/rubygems.org/gems/sinatra-1.4.8.gem/GET/responsebin0 -> 370024 bytes
-rw-r--r--spec/bundler/support/artifice/vcr_cassettes/realworld/rubygems.org/gems/thread_safe-0.3.6.gem/GET/request7
-rw-r--r--spec/bundler/support/artifice/vcr_cassettes/realworld/rubygems.org/gems/thread_safe-0.3.6.gem/GET/responsebin0 -> 121705 bytes
-rw-r--r--spec/bundler/support/artifice/vcr_cassettes/realworld/rubygems.org/gems/tilt-2.0.7.gem/GET/request7
-rw-r--r--spec/bundler/support/artifice/vcr_cassettes/realworld/rubygems.org/gems/tilt-2.0.7.gem/GET/responsebin0 -> 55142 bytes
-rw-r--r--spec/bundler/support/artifice/vcr_cassettes/realworld/rubygems.org/gems/tzinfo-1.2.3.gem/GET/request7
-rw-r--r--spec/bundler/support/artifice/vcr_cassettes/realworld/rubygems.org/gems/tzinfo-1.2.3.gem/GET/responsebin0 -> 152423 bytes
-rw-r--r--spec/bundler/support/artifice/vcr_cassettes/realworld/rubygems.org/gems/vegas-0.1.11.gem/GET/request7
-rw-r--r--spec/bundler/support/artifice/vcr_cassettes/realworld/rubygems.org/gems/vegas-0.1.11.gem/GET/responsebin0 -> 13633 bytes
-rw-r--r--spec/bundler/support/artifice/vcr_cassettes/realworld/rubygems.org/quick/Marshal.4.8/bundler-1.12.3.gemspec.rz/GET/request7
-rw-r--r--spec/bundler/support/artifice/vcr_cassettes/realworld/rubygems.org/quick/Marshal.4.8/bundler-1.12.3.gemspec.rz/GET/responsebin0 -> 1425 bytes
-rw-r--r--spec/bundler/support/artifice/vcr_cassettes/realworld/rubygems.org/specs.4.8.gz/GET/request7
-rw-r--r--spec/bundler/support/artifice/vcr_cassettes/realworld/rubygems.org/specs.4.8.gz/GET/responsebin0 -> 3248225 bytes
-rw-r--r--spec/bundler/support/artifice/windows.rb1
-rw-r--r--spec/bundler/support/builders.rb30
-rw-r--r--spec/bundler/support/code_climate.rb1
-rw-r--r--spec/bundler/support/command_execution.rb57
-rw-r--r--spec/bundler/support/hax.rb14
-rw-r--r--spec/bundler/support/helpers.rb146
-rw-r--r--spec/bundler/support/indexes.rb70
-rw-r--r--spec/bundler/support/less_than_proc.rb1
-rw-r--r--spec/bundler/support/manpages.rb14
-rw-r--r--spec/bundler/support/matchers.rb34
-rw-r--r--spec/bundler/support/path.rb10
-rw-r--r--spec/bundler/support/permissions.rb1
-rw-r--r--spec/bundler/support/platforms.rb18
-rw-r--r--spec/bundler/support/rubygems_ext.rb6
-rw-r--r--spec/bundler/support/silent_logger.rb1
-rw-r--r--spec/bundler/support/sometimes.rb1
-rw-r--r--spec/bundler/support/streams.rb1
-rw-r--r--spec/bundler/support/sudo.rb1
-rw-r--r--spec/bundler/support/the_bundle.rb1
-rw-r--r--spec/bundler/update/gems/post_install_spec.rb5
-rw-r--r--spec/bundler/update/git_spec.rb75
-rw-r--r--spec/bundler/update/path_spec.rb1
867 files changed, 8653 insertions, 1650 deletions
diff --git a/spec/bundler/bundler/bundler_spec.rb b/spec/bundler/bundler/bundler_spec.rb
index 268c0d99ac..19e3f0336f 100644
--- a/spec/bundler/bundler/bundler_spec.rb
+++ b/spec/bundler/bundler/bundler_spec.rb
@@ -1,6 +1,6 @@
# encoding: utf-8
# frozen_string_literal: true
-require "spec_helper"
+
require "bundler"
RSpec.describe Bundler do
@@ -102,11 +102,29 @@ RSpec.describe Bundler do
subject
end
end
+
+ context "with gemspec containing local variables" do
+ before do
+ File.open(app_gemspec_path, "wb") do |f|
+ f.write strip_whitespace(<<-GEMSPEC)
+ must_not_leak = true
+ Gem::Specification.new do |gem|
+ gem.name = "leak check"
+ end
+ GEMSPEC
+ end
+ end
+
+ it "should not pollute the TOPLEVEL_BINDING" do
+ subject
+ expect(TOPLEVEL_BINDING.eval("local_variables")).to_not include(:must_not_leak)
+ end
+ end
end
describe "#which" do
let(:executable) { "executable" }
- let(:path) { %w(/a /b c ../d /e) }
+ let(:path) { %w[/a /b c ../d /e] }
let(:expected) { "executable" }
before do
@@ -145,8 +163,8 @@ RSpec.describe Bundler do
context "disable_shared_gems" do
it "should unset GEM_PATH with empty string" do
env = {}
- settings = { :disable_shared_gems => true }
- Bundler.send(:configure_gem_path, env, settings)
+ expect(Bundler).to receive(:use_system_gems?).and_return(false)
+ Bundler.send(:configure_gem_path, env)
expect(env.keys).to include("GEM_PATH")
expect(env["GEM_PATH"]).to eq ""
end
@@ -158,7 +176,7 @@ RSpec.describe Bundler do
let(:bundler_ui) { Bundler.ui }
it "should raise a friendly error" do
allow(File).to receive(:exist?).and_return(true)
- allow(FileUtils).to receive(:remove_entry_secure).and_raise(ArgumentError)
+ allow(bundler_fileutils).to receive(:remove_entry_secure).and_raise(ArgumentError)
allow(File).to receive(:world_writable?).and_return(true)
message = <<EOF
It is a security vulnerability to allow your home directory to be world-writable, and bundler can not continue.
diff --git a/spec/bundler/bundler/cli_spec.rb b/spec/bundler/bundler/cli_spec.rb
index d41e6de4a7..ace4e8a625 100644
--- a/spec/bundler/bundler/cli_spec.rb
+++ b/spec/bundler/bundler/cli_spec.rb
@@ -1,5 +1,5 @@
# frozen_string_literal: true
-require "spec_helper"
+
require "bundler/cli"
RSpec.describe "bundle executable" do
@@ -27,6 +27,18 @@ RSpec.describe "bundle executable" do
expect(out).to eq("Hello, world")
end
+ context "with no arguments" do
+ it "prints a concise help message", :bundler => "2" do
+ bundle! ""
+ expect(last_command.stderr).to be_empty
+ expect(last_command.stdout).to include("Bundler version #{Bundler::VERSION}").
+ and include("\n\nBundler commands:\n\n").
+ and include("\n\n Primary commands:\n").
+ and include("\n\n Utilities:\n").
+ and include("\n\nOptions:\n")
+ end
+ end
+
context "when ENV['BUNDLE_GEMFILE'] is set to an empty string" do
it "ignores it" do
gemfile bundled_app("Gemfile"), <<-G
@@ -60,12 +72,17 @@ RSpec.describe "bundle executable" do
it "prints the running command" do
gemfile ""
bundle! "info bundler", :verbose => true
- expect(out).to start_with("Running `bundle info bundler --no-color --verbose` with bundler #{Bundler::VERSION}")
+ expect(last_command.stdout).to start_with("Running `bundle info bundler --no-color --verbose` with bundler #{Bundler::VERSION}")
+ end
+
+ it "doesn't print defaults" do
+ install_gemfile! "", :verbose => true
+ expect(last_command.stdout).to start_with("Running `bundle install --no-color --retry 0 --verbose` with bundler #{Bundler::VERSION}")
end
it "doesn't print defaults" do
install_gemfile! "", :verbose => true
- expect(out).to start_with("Running `bundle install --no-color --retry 0 --verbose` with bundler #{Bundler::VERSION}")
+ expect(last_command.stdout).to start_with("Running `bundle install --no-color --retry 0 --verbose` with bundler #{Bundler::VERSION}")
end
end
@@ -73,13 +90,15 @@ RSpec.describe "bundle executable" do
shared_examples_for "no warning" do
it "prints no warning" do
bundle "fail"
- expect(err + out).to eq("Could not find command \"fail\".")
+ expect(last_command.stdboth).to eq("Could not find command \"fail\".")
end
end
let(:bundler_version) { "1.1" }
let(:latest_version) { nil }
before do
+ bundle! "config --global disable_version_check false"
+
simulate_bundler_version(bundler_version)
if latest_version
info_path = home(".bundle/cache/compact_index/rubygems.org.443.29b0360b937aa4d161703e6160654e47/info/bundler")
@@ -103,13 +122,12 @@ RSpec.describe "bundle executable" do
end
context "when the latest version is greater than the current version" do
- let(:latest_version) { "2.0" }
+ let(:latest_version) { "222.0" }
it "prints the version warning" do
bundle "fail"
- expect(err + out).to eq(<<-EOS.strip)
+ expect(last_command.stdout).to start_with(<<-EOS.strip)
The latest bundler is #{latest_version}, but you are currently running #{bundler_version}.
-To update, run `gem install bundler`
-Could not find command "fail".
+To install the latest version, run `gem install bundler`
EOS
end
@@ -121,21 +139,20 @@ Could not find command "fail".
context "running a parseable command" do
it "prints no warning" do
bundle! "config --parseable foo"
- expect(out).to eq ""
+ expect(last_command.stdboth).to eq ""
bundle "platform --ruby"
- expect(out).to eq "Could not locate Gemfile"
+ expect(last_command.stdboth).to eq "Could not locate Gemfile"
end
end
context "and is a pre-release" do
- let(:latest_version) { "2.0.0.pre.4" }
+ let(:latest_version) { "222.0.0.pre.4" }
it "prints the version warning" do
bundle "fail"
- expect(err + out).to eq(<<-EOS.strip)
+ expect(last_command.stdout).to start_with(<<-EOS.strip)
The latest bundler is #{latest_version}, but you are currently running #{bundler_version}.
-To update, run `gem install bundler --pre`
-Could not find command "fail".
+To install the latest version, run `gem install bundler --pre`
EOS
end
end
@@ -144,8 +161,13 @@ Could not find command "fail".
end
RSpec.describe "bundler executable" do
- it "shows the bundler version just as the `bundle` executable does" do
+ it "shows the bundler version just as the `bundle` executable does", :bundler => "< 2" do
bundler "--version"
expect(out).to eq("Bundler version #{Bundler::VERSION}")
end
+
+ it "shows the bundler version just as the `bundle` executable does", :bundler => "2" do
+ bundler "--version"
+ expect(out).to eq(Bundler::VERSION)
+ end
end
diff --git a/spec/bundler/bundler/compact_index_client/updater_spec.rb b/spec/bundler/bundler/compact_index_client/updater_spec.rb
index c1cae31956..3c4f212b60 100644
--- a/spec/bundler/bundler/compact_index_client/updater_spec.rb
+++ b/spec/bundler/bundler/compact_index_client/updater_spec.rb
@@ -1,5 +1,5 @@
# frozen_string_literal: true
-require "spec_helper"
+
require "net/http"
require "bundler/compact_index_client"
require "bundler/compact_index_client/updater"
diff --git a/spec/bundler/bundler/definition_spec.rb b/spec/bundler/bundler/definition_spec.rb
index 73d44a93ab..5abf0d9756 100644
--- a/spec/bundler/bundler/definition_spec.rb
+++ b/spec/bundler/bundler/definition_spec.rb
@@ -1,12 +1,12 @@
# frozen_string_literal: true
-require "spec_helper"
+
require "bundler/definition"
RSpec.describe Bundler::Definition do
describe "#lock" do
before do
allow(Bundler).to receive(:settings) { Bundler::Settings.new(".") }
- allow(Bundler).to receive(:default_gemfile) { Pathname.new("Gemfile") }
+ allow(Bundler::SharedHelpers).to receive(:find_gemfile) { Pathname.new("Gemfile") }
allow(Bundler).to receive(:ui) { double("UI", :info => "", :debug => "") }
end
context "when it's not possible to write to the file" do
@@ -32,7 +32,7 @@ RSpec.describe Bundler::Definition do
end
describe "detects changes" do
- it "for a path gem with changes" do
+ it "for a path gem with changes", :bundler => "< 2" do
build_lib "foo", "1.0", :path => lib_path("foo")
install_gemfile <<-G
@@ -70,7 +70,45 @@ RSpec.describe Bundler::Definition do
G
end
- it "for a path gem with deps and no changes" do
+ it "for a path gem with changes", :bundler => "2" do
+ build_lib "foo", "1.0", :path => lib_path("foo")
+
+ install_gemfile <<-G
+ source "file://#{gem_repo1}"
+ gem "foo", :path => "#{lib_path("foo")}"
+ G
+
+ build_lib "foo", "1.0", :path => lib_path("foo") do |s|
+ s.add_dependency "rack", "1.0"
+ end
+
+ bundle :install, :env => { "DEBUG" => 1 }
+
+ expect(out).to match(/re-resolving dependencies/)
+ lockfile_should_be <<-G
+ GEM
+ remote: file:#{gem_repo1}/
+ specs:
+ rack (1.0.0)
+
+ PATH
+ remote: #{lib_path("foo")}
+ specs:
+ foo (1.0)
+ rack (= 1.0)
+
+ PLATFORMS
+ #{lockfile_platforms}
+
+ DEPENDENCIES
+ foo!
+
+ BUNDLED WITH
+ #{Bundler::VERSION}
+ G
+ end
+
+ it "for a path gem with deps and no changes", :bundler => "< 2" do
build_lib "foo", "1.0", :path => lib_path("foo") do |s|
s.add_dependency "rack", "1.0"
s.add_development_dependency "net-ssh", "1.0"
@@ -107,6 +145,43 @@ RSpec.describe Bundler::Definition do
G
end
+ it "for a path gem with deps and no changes", :bundler => "2" do
+ build_lib "foo", "1.0", :path => lib_path("foo") do |s|
+ s.add_dependency "rack", "1.0"
+ s.add_development_dependency "net-ssh", "1.0"
+ end
+
+ install_gemfile <<-G
+ source "file://#{gem_repo1}"
+ gem "foo", :path => "#{lib_path("foo")}"
+ G
+
+ bundle :check, :env => { "DEBUG" => 1 }
+
+ expect(out).to match(/using resolution from the lockfile/)
+ lockfile_should_be <<-G
+ GEM
+ remote: file:#{gem_repo1}/
+ specs:
+ rack (1.0.0)
+
+ PATH
+ remote: #{lib_path("foo")}
+ specs:
+ foo (1.0)
+ rack (= 1.0)
+
+ PLATFORMS
+ #{lockfile_platforms}
+
+ DEPENDENCIES
+ foo!
+
+ BUNDLED WITH
+ #{Bundler::VERSION}
+ G
+ end
+
it "for a rubygems gem" do
install_gemfile <<-G
source "file://#{gem_repo1}"
@@ -123,7 +198,7 @@ RSpec.describe Bundler::Definition do
foo (1.0)
PLATFORMS
- ruby
+ #{lockfile_platforms}
DEPENDENCIES
foo
@@ -160,6 +235,12 @@ RSpec.describe Bundler::Definition do
end
context "eager unlock" do
+ let(:source_list) do
+ Bundler::SourceList.new.tap do |source_list|
+ source_list.global_rubygems_source = "file://#{gem_repo4}"
+ end
+ end
+
before do
gemfile <<-G
source "file://#{gem_repo4}"
@@ -203,11 +284,11 @@ RSpec.describe Bundler::Definition do
definition = Bundler::Definition.new(
bundled_app("Gemfile.lock"),
updated_deps_in_gemfile,
- Bundler::SourceList.new,
+ source_list,
unlock_hash_for_bundle_install
)
locked = definition.send(:converge_locked_specs).map(&:name)
- expect(locked.include?("shared_dep")).to be_truthy
+ expect(locked).to include "shared_dep"
end
it "should not eagerly unlock shared dependency with bundle update conservative updating behavior" do
@@ -217,11 +298,11 @@ RSpec.describe Bundler::Definition do
definition = Bundler::Definition.new(
bundled_app("Gemfile.lock"),
updated_deps_in_gemfile,
- Bundler::SourceList.new,
+ source_list,
:gems => ["shared_owner_a"], :lock_shared_dependencies => true
)
locked = definition.send(:converge_locked_specs).map(&:name)
- expect(locked).to eq %w(isolated_dep isolated_owner shared_dep shared_owner_b)
+ expect(locked).to eq %w[isolated_dep isolated_owner shared_dep shared_owner_b]
expect(locked.include?("shared_dep")).to be_truthy
end
end
@@ -242,7 +323,7 @@ RSpec.describe Bundler::Definition do
describe "find_indexed_specs" do
it "with no platform set in indexed specs" do
index = Bundler::Index.new
- %w(1.0.0 1.0.1 1.1.0).each {|v| index << build_stub_spec("foo", v) }
+ %w[1.0.0 1.0.1 1.1.0].each {|v| index << build_stub_spec("foo", v) }
dfn = Bundler::Definition.new(nil, [], mock_source_list, true)
dfn.instance_variable_set("@index", index)
diff --git a/spec/bundler/bundler/dsl_spec.rb b/spec/bundler/bundler/dsl_spec.rb
index 4f5eb6dc92..f706e1b9ad 100644
--- a/spec/bundler/bundler/dsl_spec.rb
+++ b/spec/bundler/bundler/dsl_spec.rb
@@ -1,5 +1,4 @@
# frozen_string_literal: true
-require "spec_helper"
RSpec.describe Bundler::Dsl do
before do
@@ -26,7 +25,7 @@ RSpec.describe Bundler::Dsl do
expect { subject.git_source(:example) }.to raise_error(Bundler::InvalidOption)
end
- context "default hosts (git, gist)" do
+ context "default hosts (git, gist)", :bundler => "< 2" do
it "converts :github to :git" do
subject.gem("sparks", :github => "indirect/sparks")
github_uri = "git://github.com/indirect/sparks.git"
@@ -63,11 +62,17 @@ RSpec.describe Bundler::Dsl do
expect(subject.dependencies.first.source.uri).to eq(bitbucket_uri)
end
end
+
+ context "default git sources", :bundler => "2" do
+ it "has none" do
+ expect(subject.instance_variable_get(:@git_sources)).to eq({})
+ end
+ end
end
describe "#method_missing" do
it "raises an error for unknown DSL methods" do
- expect(Bundler).to receive(:read_file).with("Gemfile").
+ expect(Bundler).to receive(:read_file).with(bundled_app("Gemfile").to_s).
and_return("unknown")
error_msg = "There was an error parsing `Gemfile`: Undefined local variable or method `unknown' for Gemfile. Bundler cannot continue."
@@ -78,13 +83,13 @@ RSpec.describe Bundler::Dsl do
describe "#eval_gemfile" do
it "handles syntax errors with a useful message" do
- expect(Bundler).to receive(:read_file).with("Gemfile").and_return("}")
+ expect(Bundler).to receive(:read_file).with(bundled_app("Gemfile").to_s).and_return("}")
expect { subject.eval_gemfile("Gemfile") }.
to raise_error(Bundler::GemfileError, /There was an error parsing `Gemfile`: (syntax error, unexpected tSTRING_DEND|(compile error - )?syntax error, unexpected '\}'). Bundler cannot continue./)
end
it "distinguishes syntax errors from evaluation errors" do
- expect(Bundler).to receive(:read_file).with("Gemfile").and_return(
+ expect(Bundler).to receive(:read_file).with(bundled_app("Gemfile").to_s).and_return(
"ruby '2.1.5', :engine => 'ruby', :engine_version => '1.2.4'"
)
expect { subject.eval_gemfile("Gemfile") }.
@@ -105,6 +110,11 @@ RSpec.describe Bundler::Dsl do
to raise_error(Bundler::GemfileError, /is not a valid platform/)
end
+ it "rejects empty gem name" do
+ expect { subject.gem("") }.
+ to raise_error(Bundler::GemfileError, /an empty gem name is not valid/)
+ end
+
it "rejects with a leading space in the name" do
expect { subject.gem(" foo") }.
to raise_error(Bundler::GemfileError, /' foo' is not a valid gem name because it contains whitespace/)
@@ -150,13 +160,13 @@ RSpec.describe Bundler::Dsl do
to raise_error(Bundler::GemfileError, /The `branch` option for `gem 'foo'` is not allowed. Only gems with a git source can specify a branch/)
end
- it "allows specifiying a branch on git gems" do
+ it "allows specifying a branch on git gems" do
subject.gem("foo", :branch => "test", :git => "http://mytestrepo")
dep = subject.dependencies.last
expect(dep.name).to eq "foo"
end
- it "allows specifiying a branch on git gems with a git_source" do
+ it "allows specifying a branch on git gems with a git_source" do
subject.git_source(:test_source) {|n| "https://github.com/#{n}" }
subject.gem("foo", :branch => "test", :test_source => "bundler/bundler")
dep = subject.dependencies.last
@@ -206,7 +216,7 @@ RSpec.describe Bundler::Dsl do
# end
describe "#git" do
it "from a single repo" do
- rails_gems = %w(railties action_pack active_model)
+ rails_gems = %w[railties action_pack active_model]
subject.git "https://github.com/rails/rails.git" do
rails_gems.each {|rails_gem| subject.send :gem, rails_gem }
end
@@ -219,9 +229,9 @@ RSpec.describe Bundler::Dsl do
# gem 'spree_api'
# gem 'spree_backend'
# end
- describe "#github" do
+ describe "#github", :bundler => "< 2" do
it "from github" do
- spree_gems = %w(spree_core spree_api spree_backend)
+ spree_gems = %w[spree_core spree_api spree_backend]
subject.github "spree" do
spree_gems.each {|spree_gem| subject.send :gem, spree_gem }
end
@@ -231,6 +241,17 @@ RSpec.describe Bundler::Dsl do
end
end
end
+
+ describe "#github", :bundler => "2" do
+ it "from github" do
+ expect do
+ spree_gems = %w[spree_core spree_api spree_backend]
+ subject.github "spree" do
+ spree_gems.each {|spree_gem| subject.send :gem, spree_gem }
+ end
+ end.to raise_error(Bundler::DeprecatedError, /github method has been removed/)
+ end
+ end
end
describe "syntax errors" do
diff --git a/spec/bundler/bundler/endpoint_specification_spec.rb b/spec/bundler/bundler/endpoint_specification_spec.rb
index 0b8da840d2..a9371f6617 100644
--- a/spec/bundler/bundler/endpoint_specification_spec.rb
+++ b/spec/bundler/bundler/endpoint_specification_spec.rb
@@ -1,5 +1,4 @@
# frozen_string_literal: true
-require "spec_helper"
RSpec.describe Bundler::EndpointSpecification do
let(:name) { "foo" }
@@ -8,7 +7,7 @@ RSpec.describe Bundler::EndpointSpecification do
let(:dependencies) { [] }
let(:metadata) { nil }
- subject { described_class.new(name, version, platform, dependencies, metadata) }
+ subject(:spec) { described_class.new(name, version, platform, dependencies, metadata) }
describe "#build_dependency" do
let(:name) { "foo" }
@@ -63,4 +62,10 @@ RSpec.describe Bundler::EndpointSpecification do
end
end
end
+
+ it "supports equality comparison" do
+ other_spec = described_class.new("bar", version, platform, dependencies, metadata)
+ expect(spec).to eql(spec)
+ expect(spec).to_not eql(other_spec)
+ end
end
diff --git a/spec/bundler/bundler/env_spec.rb b/spec/bundler/bundler/env_spec.rb
index 269c323ac6..83c03e67d5 100644
--- a/spec/bundler/bundler/env_spec.rb
+++ b/spec/bundler/bundler/env_spec.rb
@@ -1,20 +1,19 @@
# frozen_string_literal: true
-require "spec_helper"
+
require "bundler/settings"
RSpec.describe Bundler::Env do
- let(:env) { described_class.new }
let(:git_proxy_stub) { Bundler::Source::Git::GitProxy.new(nil, nil, nil) }
describe "#report" do
it "prints the environment" do
- out = env.report
+ out = described_class.report
expect(out).to include("Environment")
expect(out).to include(Bundler::VERSION)
expect(out).to include(Gem::VERSION)
- expect(out).to include(env.send(:ruby_version))
- expect(out).to include(env.send(:git_version))
+ expect(out).to include(described_class.send(:ruby_version))
+ expect(out).to include(described_class.send(:git_version))
expect(out).to include(OpenSSL::OPENSSL_VERSION)
end
@@ -36,7 +35,7 @@ RSpec.describe Bundler::Env do
L
end
- let(:output) { env.report(:print_gemfile => true) }
+ let(:output) { described_class.report(:print_gemfile => true) }
it "prints the Gemfile" do
expect(output).to include("Gemfile")
@@ -50,7 +49,7 @@ RSpec.describe Bundler::Env do
end
context "when there no Gemfile and print_gemfile is true" do
- let(:output) { env.report(:print_gemfile => true) }
+ let(:output) { described_class.report(:print_gemfile => true) }
it "prints the environment" do
expect(output).to start_with("## Environment")
@@ -76,20 +75,68 @@ RSpec.describe Bundler::Env do
end
it "prints the gemspec" do
- output = env.report(:print_gemspecs => true)
+ output = described_class.report(:print_gemspecs => true)
expect(output).to include("foo.gemspec")
expect(output).to include(gemspec)
end
end
+ context "when eval_gemfile is used" do
+ it "prints all gemfiles" do
+ create_file "other/Gemfile-other", "gem 'rack'"
+ create_file "other/Gemfile", "eval_gemfile 'Gemfile-other'"
+ create_file "Gemfile-alt", <<-G
+ source "file:#{gem_repo1}"
+ eval_gemfile "other/Gemfile"
+ G
+ gemfile "eval_gemfile #{File.expand_path("Gemfile-alt").dump}"
+
+ output = described_class.report(:print_gemspecs => true)
+ expect(output).to include(strip_whitespace(<<-ENV))
+ ## Gemfile
+
+ ### Gemfile
+
+ ```ruby
+ eval_gemfile #{File.expand_path("Gemfile-alt").dump}
+ ```
+
+ ### Gemfile-alt
+
+ ```ruby
+ source "file:#{gem_repo1}"
+ eval_gemfile "other/Gemfile"
+ ```
+
+ ### other/Gemfile
+
+ ```ruby
+ eval_gemfile 'Gemfile-other'
+ ```
+
+ ### other/Gemfile-other
+
+ ```ruby
+ gem 'rack'
+ ```
+
+ ### Gemfile.lock
+
+ ```
+ <No #{bundled_app("Gemfile.lock")} found>
+ ```
+ ENV
+ end
+ end
+
context "when the git version is OS specific" do
it "includes OS specific information with the version number" do
expect(git_proxy_stub).to receive(:git).with("--version").
and_return("git version 1.2.3 (Apple Git-BS)")
expect(Bundler::Source::Git::GitProxy).to receive(:new).and_return(git_proxy_stub)
- expect(env.report).to include("Git 1.2.3 (Apple Git-BS)")
+ expect(described_class.report).to include("Git 1.2.3 (Apple Git-BS)")
end
end
end
diff --git a/spec/bundler/bundler/environment_preserver_spec.rb b/spec/bundler/bundler/environment_preserver_spec.rb
index 41d2650055..530ca6f835 100644
--- a/spec/bundler/bundler/environment_preserver_spec.rb
+++ b/spec/bundler/bundler/environment_preserver_spec.rb
@@ -1,5 +1,4 @@
# frozen_string_literal: true
-require "spec_helper"
RSpec.describe Bundler::EnvironmentPreserver do
let(:preserver) { described_class.new(env, ["foo"]) }
@@ -22,14 +21,14 @@ RSpec.describe Bundler::EnvironmentPreserver do
it "should not affect the original env" do
subject
- expect(env.keys.sort).to eq(%w(bar foo))
+ expect(env.keys.sort).to eq(%w[bar foo])
end
context "when a key is empty" do
let(:env) { { "foo" => "" } }
it "should not create backup entries" do
- expect(subject.key?("BUNDLER_ORIG_foo")).to eq(false)
+ expect(subject).not_to have_key "BUNDLER_ORIG_foo"
end
end
diff --git a/spec/bundler/bundler/fetcher/base_spec.rb b/spec/bundler/bundler/fetcher/base_spec.rb
index 38b69429bc..df1245d44d 100644
--- a/spec/bundler/bundler/fetcher/base_spec.rb
+++ b/spec/bundler/bundler/fetcher/base_spec.rb
@@ -1,5 +1,4 @@
# frozen_string_literal: true
-require "spec_helper"
RSpec.describe Bundler::Fetcher::Base do
let(:downloader) { double(:downloader) }
diff --git a/spec/bundler/bundler/fetcher/compact_index_spec.rb b/spec/bundler/bundler/fetcher/compact_index_spec.rb
index e653c1ea43..e0f58766ea 100644
--- a/spec/bundler/bundler/fetcher/compact_index_spec.rb
+++ b/spec/bundler/bundler/fetcher/compact_index_spec.rb
@@ -1,5 +1,4 @@
# frozen_string_literal: true
-require "spec_helper"
RSpec.describe Bundler::Fetcher::CompactIndex do
let(:downloader) { double(:downloader) }
@@ -46,7 +45,17 @@ RSpec.describe Bundler::Fetcher::CompactIndex do
end
context "when OpenSSL is FIPS-enabled", :ruby => ">= 2.0.0" do
- before { stub_const("OpenSSL::OPENSSL_FIPS", true) }
+ def remove_cached_md5_availability
+ return unless Bundler::SharedHelpers.instance_variable_defined?(:@md5_available)
+ Bundler::SharedHelpers.remove_instance_variable(:@md5_available)
+ end
+
+ before do
+ remove_cached_md5_availability
+ stub_const("OpenSSL::OPENSSL_FIPS", true)
+ end
+
+ after { remove_cached_md5_availability }
context "when FIPS-mode is active" do
before do
diff --git a/spec/bundler/bundler/fetcher/dependency_spec.rb b/spec/bundler/bundler/fetcher/dependency_spec.rb
index 134ca1bc57..081fdff34d 100644
--- a/spec/bundler/bundler/fetcher/dependency_spec.rb
+++ b/spec/bundler/bundler/fetcher/dependency_spec.rb
@@ -1,5 +1,4 @@
# frozen_string_literal: true
-require "spec_helper"
RSpec.describe Bundler::Fetcher::Dependency do
let(:downloader) { double(:downloader) }
@@ -64,7 +63,7 @@ RSpec.describe Bundler::Fetcher::Dependency do
end
describe "#specs" do
- let(:gem_names) { %w(foo bar) }
+ let(:gem_names) { %w[foo bar] }
let(:full_dependency_list) { ["bar"] }
let(:last_spec_list) { [["boulder", gem_version1, "ruby", resque]] }
let(:fail_errors) { double(:fail_errors) }
@@ -103,7 +102,7 @@ RSpec.describe Bundler::Fetcher::Dependency do
context "when all given gem names are in the full dependency list" do
let(:gem_names) { ["foo"] }
- let(:full_dependency_list) { %w(foo bar) }
+ let(:full_dependency_list) { %w[foo bar] }
let(:last_spec_list) { ["boulder"] }
it "should return a hash with the remote_uri and the last spec list" do
@@ -190,7 +189,7 @@ RSpec.describe Bundler::Fetcher::Dependency do
end
describe "#dependency_specs" do
- let(:gem_names) { [%w(foo bar), %w(bundler rubocop)] }
+ let(:gem_names) { [%w[foo bar], %w[bundler rubocop]] }
let(:gem_list) { double(:gem_list) }
let(:formatted_specs_and_deps) { double(:formatted_specs_and_deps) }
@@ -212,7 +211,7 @@ RSpec.describe Bundler::Fetcher::Dependency do
end
describe "#unmarshalled_dep_gems" do
- let(:gem_names) { [%w(foo bar), %w(bundler rubocop)] }
+ let(:gem_names) { [%w[foo bar], %w[bundler rubocop]] }
let(:dep_api_uri) { double(:dep_api_uri) }
let(:unmarshalled_gems) { double(:unmarshalled_gems) }
let(:fetch_response) { double(:fetch_response, :body => double(:body)) }
@@ -220,7 +219,7 @@ RSpec.describe Bundler::Fetcher::Dependency do
before { allow(subject).to receive(:dependency_api_uri).with(gem_names).and_return(dep_api_uri) }
- it "should fetch dependencies from Rubygems and unmarshal them" do
+ it "should fetch dependencies from RubyGems and unmarshal them" do
expect(gem_names).to receive(:each_slice).with(rubygems_limit).and_call_original
expect(downloader).to receive(:fetch).with(dep_api_uri).and_return(fetch_response)
expect(Bundler).to receive(:load_marshal).with(fetch_response.body).and_return([unmarshalled_gems])
@@ -254,7 +253,7 @@ RSpec.describe Bundler::Fetcher::Dependency do
spec_list, deps_list = subject.get_formatted_specs_and_deps(gem_list)
expect(spec_list).to eq([["typhoeus", "1.0.1", "ruby", [["resque", ["req3,req4"]]]],
["grape", "2.0.2", "jruby", [["faraday", ["req1,req2"]]]]])
- expect(deps_list).to eq(%w(resque faraday))
+ expect(deps_list).to eq(%w[resque faraday])
end
end
@@ -262,7 +261,7 @@ RSpec.describe Bundler::Fetcher::Dependency do
let(:uri) { URI("http://gem-api.com") }
context "with gem names" do
- let(:gem_names) { %w(foo bar bundler rubocop) }
+ let(:gem_names) { %w[foo bar bundler rubocop] }
before { allow(subject).to receive(:fetch_uri).and_return(uri) }
diff --git a/spec/bundler/bundler/fetcher/downloader_spec.rb b/spec/bundler/bundler/fetcher/downloader_spec.rb
index 4dcd94b1b2..c9b4fa662a 100644
--- a/spec/bundler/bundler/fetcher/downloader_spec.rb
+++ b/spec/bundler/bundler/fetcher/downloader_spec.rb
@@ -1,5 +1,4 @@
# frozen_string_literal: true
-require "spec_helper"
RSpec.describe Bundler::Fetcher::Downloader do
let(:connection) { double(:connection) }
diff --git a/spec/bundler/bundler/fetcher/index_spec.rb b/spec/bundler/bundler/fetcher/index_spec.rb
index b17e0d1727..0cf0ae764e 100644
--- a/spec/bundler/bundler/fetcher/index_spec.rb
+++ b/spec/bundler/bundler/fetcher/index_spec.rb
@@ -1,12 +1,11 @@
# frozen_string_literal: true
-require "spec_helper"
RSpec.describe Bundler::Fetcher::Index do
let(:downloader) { nil }
let(:remote) { nil }
let(:display_uri) { "http://sample_uri.com" }
let(:rubygems) { double(:rubygems) }
- let(:gem_names) { %w(foo bar) }
+ let(:gem_names) { %w[foo bar] }
subject { described_class.new(downloader, remote, display_uri) }
diff --git a/spec/bundler/bundler/fetcher_spec.rb b/spec/bundler/bundler/fetcher_spec.rb
index 585768343f..f9e52e09c0 100644
--- a/spec/bundler/bundler/fetcher_spec.rb
+++ b/spec/bundler/bundler/fetcher_spec.rb
@@ -1,5 +1,5 @@
# frozen_string_literal: true
-require "spec_helper"
+
require "bundler/fetcher"
RSpec.describe Bundler::Fetcher do
@@ -85,11 +85,52 @@ RSpec.describe Bundler::Fetcher do
end
end
end
+
+ context "when no ssl configuration is set" do
+ it "no cert" do
+ expect(fetcher.send(:connection).cert).to be_nil
+ expect(fetcher.send(:connection).key).to be_nil
+ end
+ end
+
+ context "when bunder ssl ssl configuration is set" do
+ before do
+ allow(Bundler.settings).to receive(:[]).and_return(nil)
+ allow(Bundler.settings).to receive(:[]).with(:ssl_client_cert).and_return("/cert")
+ expect(File).to receive(:read).with("/cert").and_return("")
+ expect(OpenSSL::X509::Certificate).to receive(:new).and_return("cert")
+ expect(OpenSSL::PKey::RSA).to receive(:new).and_return("key")
+ end
+ it "use bundler configuration" do
+ expect(fetcher.send(:connection).cert).to eq("cert")
+ expect(fetcher.send(:connection).key).to eq("key")
+ end
+ end
+
+ context "when gem ssl configuration is set" do
+ before do
+ allow(Bundler.rubygems.configuration).to receive_messages(
+ :http_proxy => nil,
+ :ssl_client_cert => "cert",
+ :ssl_ca_cert => "ca"
+ )
+ expect(File).to receive(:read).and_return("")
+ expect(OpenSSL::X509::Certificate).to receive(:new).and_return("cert")
+ expect(OpenSSL::PKey::RSA).to receive(:new).and_return("key")
+ store = double("ca store")
+ expect(store).to receive(:add_file)
+ expect(OpenSSL::X509::Store).to receive(:new).and_return(store)
+ end
+ it "use gem configuration" do
+ expect(fetcher.send(:connection).cert).to eq("cert")
+ expect(fetcher.send(:connection).key).to eq("key")
+ end
+ end
end
describe "#user_agent" do
it "builds user_agent with current ruby version and Bundler settings" do
- allow(Bundler.settings).to receive(:all).and_return(%w(foo bar))
+ allow(Bundler.settings).to receive(:all).and_return(%w[foo bar])
expect(fetcher.user_agent).to match(%r{bundler/(\d.)})
expect(fetcher.user_agent).to match(%r{rubygems/(\d.)})
expect(fetcher.user_agent).to match(%r{ruby/(\d.)})
diff --git a/spec/bundler/bundler/friendly_errors_spec.rb b/spec/bundler/bundler/friendly_errors_spec.rb
index 19799d5495..2a1be491ef 100644
--- a/spec/bundler/bundler/friendly_errors_spec.rb
+++ b/spec/bundler/bundler/friendly_errors_spec.rb
@@ -1,5 +1,5 @@
# frozen_string_literal: true
-require "spec_helper"
+
require "bundler"
require "bundler/friendly_errors"
require "cgi"
@@ -39,7 +39,7 @@ RSpec.describe Bundler, "friendly errors" do
bundle :install, :env => { "DEBUG" => true }
- expect(err).to include("Failed to load #{home(".gemrc")}")
+ expect(last_command.stderr).to include("Failed to load #{home(".gemrc")}")
expect(exitstatus).to eq(0) if exitstatus
end
end
diff --git a/spec/bundler/bundler/gem_helper_spec.rb b/spec/bundler/bundler/gem_helper_spec.rb
index 498ed89447..c36204c542 100644
--- a/spec/bundler/bundler/gem_helper_spec.rb
+++ b/spec/bundler/bundler/gem_helper_spec.rb
@@ -1,5 +1,5 @@
# frozen_string_literal: true
-require "spec_helper"
+
require "rake"
require "bundler/gem_helper"
@@ -105,8 +105,8 @@ RSpec.describe Bundler::GemHelper do
context "defines Rake tasks" do
let(:task_names) do
- %w(build install release release:guard_clean
- release:source_control_push release:rubygem_push)
+ %w[build install release release:guard_clean
+ release:source_control_push release:rubygem_push]
end
context "before installation" do
@@ -256,5 +256,95 @@ RSpec.describe Bundler::GemHelper do
end
end
end
+
+ describe "release:rubygem_push" do
+ let!(:rake_application) { Rake.application }
+
+ before(:each) do
+ Rake.application = Rake::Application.new
+ subject.install
+ allow(subject).to receive(:sh)
+ end
+
+ after(:each) do
+ Rake.application = rake_application
+ end
+
+ before do
+ Dir.chdir(app_path) do
+ `git init`
+ `git config user.email "you@example.com"`
+ `git config user.name "name"`
+ `git config push.default simple`
+ end
+
+ # silence messages
+ allow(Bundler.ui).to receive(:confirm)
+ allow(Bundler.ui).to receive(:error)
+
+ credentials = double("credentials", "file?" => true)
+ allow(Bundler.user_home).to receive(:join).
+ with(".gem/credentials").and_return(credentials)
+ end
+
+ describe "success messaging" do
+ context "No allowed_push_host set" do
+ before do
+ allow(subject).to receive(:allowed_push_host).and_return(nil)
+ end
+
+ around do |example|
+ orig_host = ENV["RUBYGEMS_HOST"]
+ ENV["RUBYGEMS_HOST"] = rubygems_host_env
+
+ example.run
+
+ ENV["RUBYGEMS_HOST"] = orig_host
+ end
+
+ context "RUBYGEMS_HOST env var is set" do
+ let(:rubygems_host_env) { "https://custom.env.gemhost.com" }
+
+ it "should report successful push to the host from the environment" do
+ mock_confirm_message "Pushed #{app_name} #{app_version} to #{rubygems_host_env}"
+
+ Rake.application["release:rubygem_push"].invoke
+ end
+ end
+
+ context "RUBYGEMS_HOST env var is not set" do
+ let(:rubygems_host_env) { nil }
+
+ it "should report successful push to rubygems.org" do
+ mock_confirm_message "Pushed #{app_name} #{app_version} to rubygems.org"
+
+ Rake.application["release:rubygem_push"].invoke
+ end
+ end
+
+ context "RUBYGEMS_HOST env var is an empty string" do
+ let(:rubygems_host_env) { "" }
+
+ it "should report successful push to rubygems.org" do
+ mock_confirm_message "Pushed #{app_name} #{app_version} to rubygems.org"
+
+ Rake.application["release:rubygem_push"].invoke
+ end
+ end
+ end
+
+ context "allowed_push_host set in gemspec" do
+ before do
+ allow(subject).to receive(:allowed_push_host).and_return("https://my.gemhost.com")
+ end
+
+ it "should report successful push to the allowed gem host" do
+ mock_confirm_message "Pushed #{app_name} #{app_version} to https://my.gemhost.com"
+
+ Rake.application["release:rubygem_push"].invoke
+ end
+ end
+ end
+ end
end
end
diff --git a/spec/bundler/bundler/gem_version_promoter_spec.rb b/spec/bundler/bundler/gem_version_promoter_spec.rb
index c7620e2620..01e0232fba 100644
--- a/spec/bundler/bundler/gem_version_promoter_spec.rb
+++ b/spec/bundler/bundler/gem_version_promoter_spec.rb
@@ -1,5 +1,4 @@
# frozen_string_literal: true
-require "spec_helper"
RSpec.describe Bundler::GemVersionPromoter do
context "conservative resolver" do
@@ -27,13 +26,15 @@ RSpec.describe Bundler::GemVersionPromoter do
end
end
- def build_spec_group(name, version)
- Bundler::Resolver::SpecGroup.new(build_spec(name, version))
+ def build_spec_groups(name, versions)
+ versions.map do |v|
+ Bundler::Resolver::SpecGroup.new(build_spec(name, v))
+ end
end
# Rightmost (highest array index) in result is most preferred.
# Leftmost (lowest array index) in result is least preferred.
- # `build_spec_group` has all version of gem in index.
+ # `build_spec_groups` has all versions of gem in index.
# `build_spec` is the version currently in the .lock file.
#
# In default (not strict) mode, all versions in the index will
@@ -44,28 +45,28 @@ RSpec.describe Bundler::GemVersionPromoter do
it "when keeping build_spec, keep current, next release" do
keep_locked(:level => :patch)
res = @gvp.filter_dep_specs(
- build_spec_group("foo", %w(1.7.8 1.7.9 1.8.0)),
+ build_spec_groups("foo", %w[1.7.8 1.7.9 1.8.0]),
build_spec("foo", "1.7.8").first
)
- expect(versions(res)).to eq %w(1.7.9 1.7.8)
+ expect(versions(res)).to eq %w[1.7.9 1.7.8]
end
it "when unlocking prefer next release first" do
unlocking(:level => :patch)
res = @gvp.filter_dep_specs(
- build_spec_group("foo", %w(1.7.8 1.7.9 1.8.0)),
+ build_spec_groups("foo", %w[1.7.8 1.7.9 1.8.0]),
build_spec("foo", "1.7.8").first
)
- expect(versions(res)).to eq %w(1.7.8 1.7.9)
+ expect(versions(res)).to eq %w[1.7.8 1.7.9]
end
it "when unlocking keep current when already at latest release" do
unlocking(:level => :patch)
res = @gvp.filter_dep_specs(
- build_spec_group("foo", %w(1.7.9 1.8.0 2.0.0)),
+ build_spec_groups("foo", %w[1.7.9 1.8.0 2.0.0]),
build_spec("foo", "1.7.9").first
)
- expect(versions(res)).to eq %w(1.7.9)
+ expect(versions(res)).to eq %w[1.7.9]
end
end
@@ -73,19 +74,19 @@ RSpec.describe Bundler::GemVersionPromoter do
it "when unlocking favor next releases, remove minor and major increases" do
unlocking(:level => :minor)
res = @gvp.filter_dep_specs(
- build_spec_group("foo", %w(0.2.0 0.3.0 0.3.1 0.9.0 1.0.0 2.0.0 2.0.1)),
+ build_spec_groups("foo", %w[0.2.0 0.3.0 0.3.1 0.9.0 1.0.0 2.0.0 2.0.1]),
build_spec("foo", "0.2.0").first
)
- expect(versions(res)).to eq %w(0.2.0 0.3.0 0.3.1 0.9.0)
+ expect(versions(res)).to eq %w[0.2.0 0.3.0 0.3.1 0.9.0]
end
it "when keep locked, keep current, then favor next release, remove minor and major increases" do
keep_locked(:level => :minor)
res = @gvp.filter_dep_specs(
- build_spec_group("foo", %w(0.2.0 0.3.0 0.3.1 0.9.0 1.0.0 2.0.0 2.0.1)),
+ build_spec_groups("foo", %w[0.2.0 0.3.0 0.3.1 0.9.0 1.0.0 2.0.0 2.0.1]),
build_spec("foo", "0.2.0").first
)
- expect(versions(res)).to eq %w(0.3.0 0.3.1 0.9.0 0.2.0)
+ expect(versions(res)).to eq %w[0.3.0 0.3.1 0.9.0 0.2.0]
end
end
@@ -93,37 +94,37 @@ RSpec.describe Bundler::GemVersionPromoter do
it "when not unlocking, same order but make sure build_spec version is most preferred to stay put" do
keep_locked(:level => :patch)
res = @gvp.sort_dep_specs(
- build_spec_group("foo", %w(1.5.4 1.6.5 1.7.6 1.7.7 1.7.8 1.7.9 1.8.0 1.8.1 2.0.0 2.0.1)),
+ build_spec_groups("foo", %w[1.5.4 1.6.5 1.7.6 1.7.7 1.7.8 1.7.9 1.8.0 1.8.1 2.0.0 2.0.1]),
build_spec("foo", "1.7.7").first
)
- expect(versions(res)).to eq %w(1.5.4 1.6.5 1.7.6 2.0.0 2.0.1 1.8.0 1.8.1 1.7.8 1.7.9 1.7.7)
+ expect(versions(res)).to eq %w[1.5.4 1.6.5 1.7.6 2.0.0 2.0.1 1.8.0 1.8.1 1.7.8 1.7.9 1.7.7]
end
it "when unlocking favor next release, then current over minor increase" do
unlocking(:level => :patch)
res = @gvp.sort_dep_specs(
- build_spec_group("foo", %w(1.7.7 1.7.8 1.7.9 1.8.0)),
+ build_spec_groups("foo", %w[1.7.7 1.7.8 1.7.9 1.8.0]),
build_spec("foo", "1.7.8").first
)
- expect(versions(res)).to eq %w(1.7.7 1.8.0 1.7.8 1.7.9)
+ expect(versions(res)).to eq %w[1.7.7 1.8.0 1.7.8 1.7.9]
end
it "when unlocking do proper integer comparison, not string" do
unlocking(:level => :patch)
res = @gvp.sort_dep_specs(
- build_spec_group("foo", %w(1.7.7 1.7.8 1.7.9 1.7.15 1.8.0)),
+ build_spec_groups("foo", %w[1.7.7 1.7.8 1.7.9 1.7.15 1.8.0]),
build_spec("foo", "1.7.8").first
)
- expect(versions(res)).to eq %w(1.7.7 1.8.0 1.7.8 1.7.9 1.7.15)
+ expect(versions(res)).to eq %w[1.7.7 1.8.0 1.7.8 1.7.9 1.7.15]
end
it "leave current when unlocking but already at latest release" do
unlocking(:level => :patch)
res = @gvp.sort_dep_specs(
- build_spec_group("foo", %w(1.7.9 1.8.0 2.0.0)),
+ build_spec_groups("foo", %w[1.7.9 1.8.0 2.0.0]),
build_spec("foo", "1.7.9").first
)
- expect(versions(res)).to eq %w(2.0.0 1.8.0 1.7.9)
+ expect(versions(res)).to eq %w[2.0.0 1.8.0 1.7.9]
end
end
@@ -131,10 +132,10 @@ RSpec.describe Bundler::GemVersionPromoter do
it "when unlocking favor next release, then minor increase over current" do
unlocking(:level => :minor)
res = @gvp.sort_dep_specs(
- build_spec_group("foo", %w(0.2.0 0.3.0 0.3.1 0.9.0 1.0.0 2.0.0 2.0.1)),
+ build_spec_groups("foo", %w[0.2.0 0.3.0 0.3.1 0.9.0 1.0.0 2.0.0 2.0.1]),
build_spec("foo", "0.2.0").first
)
- expect(versions(res)).to eq %w(2.0.0 2.0.1 1.0.0 0.2.0 0.3.0 0.3.1 0.9.0)
+ expect(versions(res)).to eq %w[2.0.0 2.0.1 1.0.0 0.2.0 0.3.0 0.3.1 0.9.0]
end
end
@@ -159,7 +160,7 @@ RSpec.describe Bundler::GemVersionPromoter do
end
it "should accept major, minor patch strings" do
- %w(major minor patch).each do |value|
+ %w[major minor patch].each do |value|
subject.level = value
expect(subject.level).to eq value.to_sym
end
@@ -170,8 +171,7 @@ RSpec.describe Bundler::GemVersionPromoter do
it "should not kerblooie on its own debug output" do
gvp = unlocking(:level => :patch)
dep = Bundler::DepProxy.new(dep("foo", "1.2.0").first, "ruby")
- result = gvp.send(:debug_format_result, dep, [build_spec_group("foo", "1.2.0"),
- build_spec_group("foo", "1.3.0")])
+ result = gvp.send(:debug_format_result, dep, build_spec_groups("foo", %w[1.2.0 1.3.0]))
expect(result.class).to eq Array
end
end
diff --git a/spec/bundler/bundler/index_spec.rb b/spec/bundler/bundler/index_spec.rb
index 09b09e08fa..0f3f6e4944 100644
--- a/spec/bundler/bundler/index_spec.rb
+++ b/spec/bundler/bundler/index_spec.rb
@@ -1,5 +1,4 @@
# frozen_string_literal: true
-require "spec_helper"
RSpec.describe Bundler::Index do
let(:specs) { [] }
diff --git a/spec/bundler/bundler/installer/gem_installer_spec.rb b/spec/bundler/bundler/installer/gem_installer_spec.rb
index e2f30cdd70..7340a3acc0 100644
--- a/spec/bundler/bundler/installer/gem_installer_spec.rb
+++ b/spec/bundler/bundler/installer/gem_installer_spec.rb
@@ -1,5 +1,5 @@
# frozen_string_literal: true
-require "spec_helper"
+
require "bundler/installer/gem_installer"
RSpec.describe Bundler::GemInstaller do
@@ -20,6 +20,7 @@ RSpec.describe Bundler::GemInstaller do
it "invokes install method with build_args", :rubygems => ">= 2" do
allow(Bundler.settings).to receive(:[]).with(:bin)
allow(Bundler.settings).to receive(:[]).with(:inline)
+ allow(Bundler.settings).to receive(:[]).with(:forget_cli_options)
allow(Bundler.settings).to receive(:[]).with("build.dummy").and_return("--with-dummy-config=dummy")
expect(spec_source).to receive(:install).with(spec, :force => false, :ensure_builtin_gems_cached => false, :build_args => ["--with-dummy-config=dummy"])
subject.install_from_spec
diff --git a/spec/bundler/bundler/installer/parallel_installer_spec.rb b/spec/bundler/bundler/installer/parallel_installer_spec.rb
index 7d2c441399..ace5c1a23a 100644
--- a/spec/bundler/bundler/installer/parallel_installer_spec.rb
+++ b/spec/bundler/bundler/installer/parallel_installer_spec.rb
@@ -1,5 +1,5 @@
# frozen_string_literal: true
-require "spec_helper"
+
require "bundler/installer/parallel_installer"
RSpec.describe Bundler::ParallelInstaller do
diff --git a/spec/bundler/bundler/installer/spec_installation_spec.rb b/spec/bundler/bundler/installer/spec_installation_spec.rb
index 1e368ab7c5..a9cf09a372 100644
--- a/spec/bundler/bundler/installer/spec_installation_spec.rb
+++ b/spec/bundler/bundler/installer/spec_installation_spec.rb
@@ -1,5 +1,5 @@
# frozen_string_literal: true
-require "spec_helper"
+
require "bundler/installer/parallel_installer"
RSpec.describe Bundler::ParallelInstaller::SpecInstallation do
diff --git a/spec/bundler/bundler/lockfile_parser_spec.rb b/spec/bundler/bundler/lockfile_parser_spec.rb
index 17bb447194..3a6d61336f 100644
--- a/spec/bundler/bundler/lockfile_parser_spec.rb
+++ b/spec/bundler/bundler/lockfile_parser_spec.rb
@@ -1,5 +1,5 @@
# frozen_string_literal: true
-require "spec_helper"
+
require "bundler/lockfile_parser"
RSpec.describe Bundler::LockfileParser do
@@ -91,4 +91,63 @@ RSpec.describe Bundler::LockfileParser do
end
end
end
+
+ describe "#initialize" do
+ before { allow(Bundler::SharedHelpers).to receive(:find_gemfile).and_return(bundled_app("gems.rb")) }
+ subject { described_class.new(lockfile_contents) }
+
+ let(:sources) do
+ [Bundler::Source::Git.new("uri" => "https://github.com/alloy/peiji-san.git", "revision" => "eca485d8dc95f12aaec1a434b49d295c7e91844b"),
+ Bundler::Source::Rubygems.new("remotes" => ["https://rubygems.org"])]
+ end
+ let(:dependencies) do
+ {
+ "peiji-san" => Bundler::Dependency.new("peiji-san", ">= 0"),
+ "rake" => Bundler::Dependency.new("rake", ">= 0"),
+ }
+ end
+ let(:specs) do
+ [
+ Bundler::LazySpecification.new("peiji-san", v("1.2.0"), rb),
+ Bundler::LazySpecification.new("rake", v("10.3.2"), rb),
+ ]
+ end
+ let(:platforms) { [rb] }
+ let(:bundler_version) { Gem::Version.new("1.12.0.rc.2") }
+ let(:ruby_version) { "ruby 2.1.3p242" }
+
+ shared_examples_for "parsing" do
+ it "parses correctly" do
+ expect(subject.sources).to eq sources
+ expect(subject.dependencies).to eq dependencies
+ expect(subject.specs).to eq specs
+ expect(Hash[subject.specs.map {|s| [s, s.dependencies] }]).to eq Hash[subject.specs.map {|s| [s, s.dependencies] }]
+ expect(subject.platforms).to eq platforms
+ expect(subject.bundler_version).to eq bundler_version
+ expect(subject.ruby_version).to eq ruby_version
+ end
+ end
+
+ include_examples "parsing"
+
+ context "when an extra section is at the end" do
+ let(:lockfile_contents) { super() + "\n\nFOO BAR\n baz\n baa\n qux\n" }
+ include_examples "parsing"
+ end
+
+ context "when an extra section is at the start" do
+ let(:lockfile_contents) { "FOO BAR\n baz\n baa\n qux\n\n" + super() }
+ include_examples "parsing"
+ end
+
+ context "when an extra section is in the middle" do
+ let(:lockfile_contents) { super().split(/(?=GEM)/).insert(1, "FOO BAR\n baz\n baa\n qux\n\n").join }
+ include_examples "parsing"
+ end
+
+ context "when a dependency has options" do
+ let(:lockfile_contents) { super().sub("peiji-san!", "peiji-san!\n foo: bar") }
+ include_examples "parsing"
+ end
+ end
end
diff --git a/spec/bundler/bundler/mirror_spec.rb b/spec/bundler/bundler/mirror_spec.rb
index 9051a80465..0a8b9f8926 100644
--- a/spec/bundler/bundler/mirror_spec.rb
+++ b/spec/bundler/bundler/mirror_spec.rb
@@ -1,5 +1,5 @@
# frozen_string_literal: true
-require "spec_helper"
+
require "bundler/mirror"
RSpec.describe Bundler::Settings::Mirror do
diff --git a/spec/bundler/bundler/plugin/api/source_spec.rb b/spec/bundler/bundler/plugin/api/source_spec.rb
index 4dbb993b89..2c50ff56a4 100644
--- a/spec/bundler/bundler/plugin/api/source_spec.rb
+++ b/spec/bundler/bundler/plugin/api/source_spec.rb
@@ -1,5 +1,4 @@
# frozen_string_literal: true
-require "spec_helper"
RSpec.describe Bundler::Plugin::API::Source do
let(:uri) { "uri://to/test" }
@@ -37,7 +36,7 @@ RSpec.describe Bundler::Plugin::API::Source do
context "install_path" do
let(:uri) { "uri://to/a/repository-name" }
- let(:hash) { Digest::SHA1.hexdigest(uri) }
+ let(:hash) { Digest(:SHA1).hexdigest(uri) }
let(:install_path) { Pathname.new "/bundler/install/path" }
before do
diff --git a/spec/bundler/bundler/plugin/api_spec.rb b/spec/bundler/bundler/plugin/api_spec.rb
index e40b9adb0f..58fb908572 100644
--- a/spec/bundler/bundler/plugin/api_spec.rb
+++ b/spec/bundler/bundler/plugin/api_spec.rb
@@ -1,5 +1,4 @@
# frozen_string_literal: true
-require "spec_helper"
RSpec.describe Bundler::Plugin::API do
context "plugin declarations" do
@@ -60,15 +59,15 @@ RSpec.describe Bundler::Plugin::API do
# A test of delegation
it "provides the Bundler's functions" do
- expect(Bundler).to receive(:an_unkown_function).once
+ expect(Bundler).to receive(:an_unknown_function).once
- api.an_unkown_function
+ api.an_unknown_function
end
it "includes Bundler::SharedHelpers' functions" do
- expect(Bundler::SharedHelpers).to receive(:an_unkown_helper).once
+ expect(Bundler::SharedHelpers).to receive(:an_unknown_helper).once
- api.an_unkown_helper
+ api.an_unknown_helper
end
context "#tmp" do
diff --git a/spec/bundler/bundler/plugin/dsl_spec.rb b/spec/bundler/bundler/plugin/dsl_spec.rb
index cd15b6ea9d..be23db3bba 100644
--- a/spec/bundler/bundler/plugin/dsl_spec.rb
+++ b/spec/bundler/bundler/plugin/dsl_spec.rb
@@ -1,5 +1,4 @@
# frozen_string_literal: true
-require "spec_helper"
RSpec.describe Bundler::Plugin::DSL do
DSL = Bundler::Plugin::DSL
diff --git a/spec/bundler/bundler/plugin/index_spec.rb b/spec/bundler/bundler/plugin/index_spec.rb
index 24b9a408ff..163b563b2a 100644
--- a/spec/bundler/bundler/plugin/index_spec.rb
+++ b/spec/bundler/bundler/plugin/index_spec.rb
@@ -1,5 +1,4 @@
# frozen_string_literal: true
-require "spec_helper"
RSpec.describe Bundler::Plugin::Index do
Index = Bundler::Plugin::Index
diff --git a/spec/bundler/bundler/plugin/installer_spec.rb b/spec/bundler/bundler/plugin/installer_spec.rb
index e8d5941e33..f8bf8450c9 100644
--- a/spec/bundler/bundler/plugin/installer_spec.rb
+++ b/spec/bundler/bundler/plugin/installer_spec.rb
@@ -1,12 +1,16 @@
# frozen_string_literal: true
-require "spec_helper"
RSpec.describe Bundler::Plugin::Installer do
subject(:installer) { Bundler::Plugin::Installer.new }
+ before do
+ # allow(Bundler::SharedHelpers).to receive(:find_gemfile).and_return(Pathname.new("/Gemfile"))
+ end
+
describe "cli install" do
it "uses Gem.sources when non of the source is provided" do
sources = double(:sources)
+ Bundler.settings # initialize it before we have to touch rubygems.ext_lock
allow(Bundler).to receive_message_chain("rubygems.sources") { sources }
allow(installer).to receive(:install_rubygems).
diff --git a/spec/bundler/bundler/plugin/source_list_spec.rb b/spec/bundler/bundler/plugin/source_list_spec.rb
index 86cc4ac4ed..64a1233dd1 100644
--- a/spec/bundler/bundler/plugin/source_list_spec.rb
+++ b/spec/bundler/bundler/plugin/source_list_spec.rb
@@ -1,5 +1,4 @@
# frozen_string_literal: true
-require "spec_helper"
RSpec.describe Bundler::Plugin::SourceList do
SourceList = Bundler::Plugin::SourceList
diff --git a/spec/bundler/bundler/plugin_spec.rb b/spec/bundler/bundler/plugin_spec.rb
index 5bbb7384c8..9796b580a3 100644
--- a/spec/bundler/bundler/plugin_spec.rb
+++ b/spec/bundler/bundler/plugin_spec.rb
@@ -1,5 +1,4 @@
# frozen_string_literal: true
-require "spec_helper"
RSpec.describe Bundler::Plugin do
Plugin = Bundler::Plugin
diff --git a/spec/bundler/bundler/psyched_yaml_spec.rb b/spec/bundler/bundler/psyched_yaml_spec.rb
index 18e40d6b5a..d5d68c5cc3 100644
--- a/spec/bundler/bundler/psyched_yaml_spec.rb
+++ b/spec/bundler/bundler/psyched_yaml_spec.rb
@@ -1,5 +1,5 @@
# frozen_string_literal: true
-require "spec_helper"
+
require "bundler/psyched_yaml"
RSpec.describe "Bundler::YamlLibrarySyntaxError" do
diff --git a/spec/bundler/bundler/remote_specification_spec.rb b/spec/bundler/bundler/remote_specification_spec.rb
index 644814c563..8115e026d8 100644
--- a/spec/bundler/bundler/remote_specification_spec.rb
+++ b/spec/bundler/bundler/remote_specification_spec.rb
@@ -1,5 +1,4 @@
# frozen_string_literal: true
-require "spec_helper"
RSpec.describe Bundler::RemoteSpecification do
let(:name) { "foo" }
diff --git a/spec/bundler/bundler/retry_spec.rb b/spec/bundler/bundler/retry_spec.rb
index 525f05d327..b893580d72 100644
--- a/spec/bundler/bundler/retry_spec.rb
+++ b/spec/bundler/bundler/retry_spec.rb
@@ -1,5 +1,4 @@
# frozen_string_literal: true
-require "spec_helper"
RSpec.describe Bundler::Retry do
it "return successful result if no errors" do
diff --git a/spec/bundler/bundler/ruby_dsl_spec.rb b/spec/bundler/bundler/ruby_dsl_spec.rb
index 3e0ec9d7f0..bc1ca98457 100644
--- a/spec/bundler/bundler/ruby_dsl_spec.rb
+++ b/spec/bundler/bundler/ruby_dsl_spec.rb
@@ -1,5 +1,5 @@
# frozen_string_literal: true
-require "spec_helper"
+
require "bundler/ruby_dsl"
RSpec.describe Bundler::RubyDsl do
diff --git a/spec/bundler/bundler/ruby_version_spec.rb b/spec/bundler/bundler/ruby_version_spec.rb
index f77ec606fc..3f30821b5c 100644
--- a/spec/bundler/bundler/ruby_version_spec.rb
+++ b/spec/bundler/bundler/ruby_version_spec.rb
@@ -1,5 +1,5 @@
# frozen_string_literal: true
-require "spec_helper"
+
require "bundler/ruby_version"
RSpec.describe "Bundler::RubyVersion and its subclasses" do
diff --git a/spec/bundler/bundler/rubygems_integration_spec.rb b/spec/bundler/bundler/rubygems_integration_spec.rb
index 38ff9dae7e..b1b15d9e5d 100644
--- a/spec/bundler/bundler/rubygems_integration_spec.rb
+++ b/spec/bundler/bundler/rubygems_integration_spec.rb
@@ -1,5 +1,4 @@
# frozen_string_literal: true
-require "spec_helper"
RSpec.describe Bundler::RubygemsIntegration do
it "uses the same chdir lock as rubygems", :rubygems => "2.1" do
@@ -67,7 +66,7 @@ RSpec.describe Bundler::RubygemsIntegration do
end
let(:fetcher) { double("gem_remote_fetcher") }
- it "succesfully downloads gem with retries" do
+ it "successfully downloads gem with retries" do
expect(Bundler.rubygems).to receive(:gem_remote_fetcher).and_return(fetcher)
expect(fetcher).to receive(:headers=).with("X-Gemfile-Source" => "https://foo.bar")
expect(Bundler::Retry).to receive(:new).with("download gem from #{uri}/").
@@ -95,7 +94,7 @@ RSpec.describe Bundler::RubygemsIntegration do
expect(fetcher).to receive(:fetch_path).with(uri + "specs.4.8.gz").and_return(specs_response)
expect(fetcher).to receive(:fetch_path).with(uri + "prerelease_specs.4.8.gz").and_return(prerelease_specs_response)
result = Bundler.rubygems.fetch_all_remote_specs(remote_with_mirror)
- expect(result).to eq(%w(specs prerelease_specs))
+ expect(result).to eq(%w[specs prerelease_specs])
end
end
@@ -108,7 +107,7 @@ RSpec.describe Bundler::RubygemsIntegration do
expect(fetcher).to receive(:fetch_path).with(uri + "specs.4.8.gz").and_return(specs_response)
expect(fetcher).to receive(:fetch_path).with(uri + "prerelease_specs.4.8.gz").and_return(prerelease_specs_response)
result = Bundler.rubygems.fetch_all_remote_specs(remote_no_mirror)
- expect(result).to eq(%w(specs prerelease_specs))
+ expect(result).to eq(%w[specs prerelease_specs])
end
end
end
diff --git a/spec/bundler/bundler/settings/validator_spec.rb b/spec/bundler/bundler/settings/validator_spec.rb
new file mode 100644
index 0000000000..e4ffd89435
--- /dev/null
+++ b/spec/bundler/bundler/settings/validator_spec.rb
@@ -0,0 +1,111 @@
+# frozen_string_literal: true
+
+RSpec.describe Bundler::Settings::Validator do
+ describe ".validate!" do
+ def validate!(key, value, settings)
+ transformed_key = Bundler.settings.key_for(key)
+ if value.nil?
+ settings.delete(transformed_key)
+ else
+ settings[transformed_key] = value
+ end
+ described_class.validate!(key, value, settings)
+ settings
+ end
+
+ it "path and path.system are mutually exclusive" do
+ expect(validate!("path", "bundle", {})).to eq("BUNDLE_PATH" => "bundle")
+ expect(validate!("path", "bundle", "BUNDLE_PATH__SYSTEM" => false)).to eq("BUNDLE_PATH" => "bundle")
+ expect(validate!("path", "bundle", "BUNDLE_PATH__SYSTEM" => true)).to eq("BUNDLE_PATH" => "bundle")
+ expect(validate!("path", nil, "BUNDLE_PATH__SYSTEM" => true)).to eq("BUNDLE_PATH__SYSTEM" => true)
+ expect(validate!("path", nil, "BUNDLE_PATH__SYSTEM" => false)).to eq("BUNDLE_PATH__SYSTEM" => false)
+ expect(validate!("path", nil, {})).to eq({})
+
+ expect(validate!("path.system", true, "BUNDLE_PATH" => "bundle")).to eq("BUNDLE_PATH__SYSTEM" => true)
+ expect(validate!("path.system", false, "BUNDLE_PATH" => "bundle")).to eq("BUNDLE_PATH" => "bundle", "BUNDLE_PATH__SYSTEM" => false)
+ expect(validate!("path.system", nil, "BUNDLE_PATH" => "bundle")).to eq("BUNDLE_PATH" => "bundle")
+ expect(validate!("path.system", true, {})).to eq("BUNDLE_PATH__SYSTEM" => true)
+ expect(validate!("path.system", false, {})).to eq("BUNDLE_PATH__SYSTEM" => false)
+ expect(validate!("path.system", nil, {})).to eq({})
+ end
+
+ it "a group cannot be in both `with` & `without` simultaneously" do
+ expect do
+ validate!("with", "", {})
+ validate!("with", nil, {})
+ validate!("with", "", "BUNDLE_WITHOUT" => "a")
+ validate!("with", nil, "BUNDLE_WITHOUT" => "a")
+ validate!("with", "b:c", "BUNDLE_WITHOUT" => "a")
+
+ validate!("without", "", {})
+ validate!("without", nil, {})
+ validate!("without", "", "BUNDLE_WITH" => "a")
+ validate!("without", nil, "BUNDLE_WITH" => "a")
+ validate!("without", "b:c", "BUNDLE_WITH" => "a")
+ end.not_to raise_error
+
+ expect { validate!("with", "b:c", "BUNDLE_WITHOUT" => "c:d") }.to raise_error Bundler::InvalidOption, strip_whitespace(<<-EOS).strip
+ Setting `with` to "b:c" failed:
+ - a group cannot be in both `with` & `without` simultaneously
+ - `without` is current set to [:c, :d]
+ - the `c` groups conflict
+ EOS
+
+ expect { validate!("without", "b:c", "BUNDLE_WITH" => "c:d") }.to raise_error Bundler::InvalidOption, strip_whitespace(<<-EOS).strip
+ Setting `without` to "b:c" failed:
+ - a group cannot be in both `with` & `without` simultaneously
+ - `with` is current set to [:c, :d]
+ - the `c` groups conflict
+ EOS
+ end
+ end
+
+ describe described_class::Rule do
+ let(:keys) { %w[key] }
+ let(:description) { "rule description" }
+ let(:validate) { proc { raise "validate called!" } }
+ subject(:rule) { described_class.new(keys, description, &validate) }
+
+ describe "#validate!" do
+ it "calls the block" do
+ expect { rule.validate!("key", nil, {}) }.to raise_error(RuntimeError, /validate called!/)
+ end
+ end
+
+ describe "#fail!" do
+ it "raises with a helpful message" do
+ expect { subject.fail!("key", "value", "reason1", "reason2") }.to raise_error Bundler::InvalidOption, strip_whitespace(<<-EOS).strip
+ Setting `key` to "value" failed:
+ - rule description
+ - reason1
+ - reason2
+ EOS
+ end
+ end
+
+ describe "#set" do
+ it "works when the value has not changed" do
+ allow(Bundler.ui).to receive(:info).never
+
+ subject.set({}, "key", nil)
+ subject.set({ "BUNDLE_KEY" => "value" }, "key", "value")
+ end
+
+ it "prints out when the value is changing" do
+ settings = {}
+
+ expect(Bundler.ui).to receive(:info).with("Setting `key` to \"value\", since rule description, reason1")
+ subject.set(settings, "key", "value", "reason1")
+ expect(settings).to eq("BUNDLE_KEY" => "value")
+
+ expect(Bundler.ui).to receive(:info).with("Setting `key` to \"value2\", since rule description, reason2")
+ subject.set(settings, "key", "value2", "reason2")
+ expect(settings).to eq("BUNDLE_KEY" => "value2")
+
+ expect(Bundler.ui).to receive(:info).with("Setting `key` to nil, since rule description, reason3")
+ subject.set(settings, "key", nil, "reason3")
+ expect(settings).to eq({})
+ end
+ end
+ end
+end
diff --git a/spec/bundler/bundler/settings_spec.rb b/spec/bundler/bundler/settings_spec.rb
index 7302da5421..1a31493e20 100644
--- a/spec/bundler/bundler/settings_spec.rb
+++ b/spec/bundler/bundler/settings_spec.rb
@@ -1,5 +1,5 @@
# frozen_string_literal: true
-require "spec_helper"
+
require "bundler/settings"
RSpec.describe Bundler::Settings do
@@ -40,7 +40,7 @@ that would suck --ehhh=oh geez it looks like i might have broken bundler somehow
before do
hash.each do |key, value|
- settings[key] = value
+ settings.set_local key, value
end
end
@@ -100,12 +100,12 @@ that would suck --ehhh=oh geez it looks like i might have broken bundler somehow
context "when is boolean" do
it "returns a boolean" do
- settings[:frozen] = "true"
+ settings.set_local :frozen, "true"
expect(settings[:frozen]).to be true
end
context "when specific gem is configured" do
it "returns a boolean" do
- settings["ignore_messages.foobar"] = "true"
+ settings.set_local "ignore_messages.foobar", "true"
expect(settings["ignore_messages.foobar"]).to be true
end
end
@@ -113,16 +113,16 @@ that would suck --ehhh=oh geez it looks like i might have broken bundler somehow
context "when is number" do
it "returns a number" do
- settings[:ssl_verify_mode] = "1"
+ settings.set_local :ssl_verify_mode, "1"
expect(settings[:ssl_verify_mode]).to be 1
end
end
context "when it's not possible to write to the file" do
it "raises an PermissionError with explanation" do
- expect(FileUtils).to receive(:mkdir_p).with(settings.send(:local_config_file).dirname).
+ expect(bundler_fileutils).to receive(:mkdir_p).with(settings.send(:local_config_file).dirname).
and_raise(Errno::EACCES)
- expect { settings[:frozen] = "1" }.
+ expect { settings.set_local :frozen, "1" }.
to raise_error(Bundler::PermissionError, /config/)
end
end
@@ -130,7 +130,7 @@ that would suck --ehhh=oh geez it looks like i might have broken bundler somehow
describe "#temporary" do
it "reset after used" do
- Bundler.settings[:no_install] = true
+ Bundler.settings.set_local :no_install, true
Bundler.settings.temporary(:no_install => false) do
expect(Bundler.settings[:no_install]).to eq false
@@ -138,12 +138,28 @@ that would suck --ehhh=oh geez it looks like i might have broken bundler somehow
expect(Bundler.settings[:no_install]).to eq true
end
+
+ it "returns the return value of the block" do
+ ret = Bundler.settings.temporary({}) { :ret }
+ expect(ret).to eq :ret
+ end
+
+ context "when called without a block" do
+ it "leaves the setting changed" do
+ Bundler.settings.temporary(:foo => :random)
+ expect(Bundler.settings[:foo]).to eq "random"
+ end
+
+ it "returns nil" do
+ expect(Bundler.settings.temporary(:foo => :bar)).to be_nil
+ end
+ end
end
describe "#set_global" do
context "when it's not possible to write to the file" do
it "raises an PermissionError with explanation" do
- expect(FileUtils).to receive(:mkdir_p).with(settings.send(:global_config_file).dirname).
+ expect(bundler_fileutils).to receive(:mkdir_p).with(settings.send(:global_config_file).dirname).
and_raise(Errno::EACCES)
expect { settings.set_global(:frozen, "1") }.
to raise_error(Bundler::PermissionError, %r{\.bundle/config})
@@ -154,7 +170,7 @@ that would suck --ehhh=oh geez it looks like i might have broken bundler somehow
describe "#pretty_values_for" do
it "prints the converted value rather than the raw string" do
bool_key = described_class::BOOL_KEYS.first
- settings[bool_key] = false
+ settings.set_local(bool_key, "false")
expect(subject.pretty_values_for(bool_key)).to eq [
"Set for your local app (#{bundled_app("config")}): false",
]
@@ -177,7 +193,7 @@ that would suck --ehhh=oh geez it looks like i might have broken bundler somehow
context "with a configured mirror" do
let(:mirror_uri) { URI("https://rubygems-mirror.org/") }
- before { settings["mirror.https://rubygems.org/"] = mirror_uri.to_s }
+ before { settings.set_local "mirror.https://rubygems.org/", mirror_uri.to_s }
it "returns the mirror URI" do
expect(settings.mirror_for(uri)).to eq(mirror_uri)
@@ -194,6 +210,22 @@ that would suck --ehhh=oh geez it looks like i might have broken bundler somehow
it "is case insensitive" do
expect(settings.mirror_for("HTTPS://RUBYGEMS.ORG/")).to eq(mirror_uri)
end
+
+ context "with a file URI" do
+ let(:mirror_uri) { URI("file:/foo/BAR/baz/qUx/") }
+
+ it "returns the mirror URI" do
+ expect(settings.mirror_for(uri)).to eq(mirror_uri)
+ end
+
+ it "converts a string parameter to a URI" do
+ expect(settings.mirror_for("file:/foo/BAR/baz/qUx/")).to eq(mirror_uri)
+ end
+
+ it "normalizes the URI" do
+ expect(settings.mirror_for("file:/foo/BAR/baz/qUx")).to eq(mirror_uri)
+ end
+ end
end
end
@@ -208,7 +240,7 @@ that would suck --ehhh=oh geez it looks like i might have broken bundler somehow
end
context "with credentials configured by URL" do
- before { settings["https://gemserver.example.org/"] = credentials }
+ before { settings.set_local "https://gemserver.example.org/", credentials }
it "returns the configured credentials" do
expect(settings.credentials_for(uri)).to eq(credentials)
@@ -216,7 +248,7 @@ that would suck --ehhh=oh geez it looks like i might have broken bundler somehow
end
context "with credentials configured by hostname" do
- before { settings["gemserver.example.org"] = credentials }
+ before { settings.set_local "gemserver.example.org", credentials }
it "returns the configured credentials" do
expect(settings.credentials_for(uri)).to eq(credentials)
@@ -226,41 +258,51 @@ that would suck --ehhh=oh geez it looks like i might have broken bundler somehow
describe "URI normalization" do
it "normalizes HTTP URIs in credentials configuration" do
- settings["http://gemserver.example.org"] = "username:password"
+ settings.set_local "http://gemserver.example.org", "username:password"
expect(settings.all).to include("http://gemserver.example.org/")
end
it "normalizes HTTPS URIs in credentials configuration" do
- settings["https://gemserver.example.org"] = "username:password"
+ settings.set_local "https://gemserver.example.org", "username:password"
expect(settings.all).to include("https://gemserver.example.org/")
end
it "normalizes HTTP URIs in mirror configuration" do
- settings["mirror.http://rubygems.org"] = "http://rubygems-mirror.org"
+ settings.set_local "mirror.http://rubygems.org", "http://rubygems-mirror.org"
expect(settings.all).to include("mirror.http://rubygems.org/")
end
it "normalizes HTTPS URIs in mirror configuration" do
- settings["mirror.https://rubygems.org"] = "http://rubygems-mirror.org"
+ settings.set_local "mirror.https://rubygems.org", "http://rubygems-mirror.org"
expect(settings.all).to include("mirror.https://rubygems.org/")
end
it "does not normalize other config keys that happen to contain 'http'" do
- settings["local.httparty"] = home("httparty")
+ settings.set_local "local.httparty", home("httparty")
expect(settings.all).to include("local.httparty")
end
it "does not normalize other config keys that happen to contain 'https'" do
- settings["local.httpsmarty"] = home("httpsmarty")
+ settings.set_local "local.httpsmarty", home("httpsmarty")
expect(settings.all).to include("local.httpsmarty")
end
it "reads older keys without trailing slashes" do
- settings["mirror.https://rubygems.org"] = "http://rubygems-mirror.org"
+ settings.set_local "mirror.https://rubygems.org", "http://rubygems-mirror.org"
expect(settings.mirror_for("https://rubygems.org/")).to eq(
URI("http://rubygems-mirror.org/")
)
end
+
+ it "normalizes URIs with a fallback_timeout option" do
+ settings.set_local "mirror.https://rubygems.org/.fallback_timeout", "true"
+ expect(settings.all).to include("mirror.https://rubygems.org/.fallback_timeout")
+ end
+
+ it "normalizes URIs with a fallback_timeout option without a trailing slash" do
+ settings.set_local "mirror.https://rubygems.org.fallback_timeout", "true"
+ expect(settings.all).to include("mirror.https://rubygems.org/.fallback_timeout")
+ end
end
describe "BUNDLE_ keys format" do
diff --git a/spec/bundler/bundler/shared_helpers_spec.rb b/spec/bundler/bundler/shared_helpers_spec.rb
index d3b93b56d0..b8f099d5ba 100644
--- a/spec/bundler/bundler/shared_helpers_spec.rb
+++ b/spec/bundler/bundler/shared_helpers_spec.rb
@@ -1,5 +1,4 @@
# frozen_string_literal: true
-require "spec_helper"
RSpec.describe Bundler::SharedHelpers do
let(:ext_lock_double) { double(:ext_lock) }
@@ -31,6 +30,16 @@ RSpec.describe Bundler::SharedHelpers do
)
end
end
+
+ context "Gemfile is not an absolute path" do
+ before { ENV["BUNDLE_GEMFILE"] = "Gemfile" }
+
+ let(:expected_gemfile_path) { Pathname.new("Gemfile").expand_path }
+
+ it "returns the Gemfile path" do
+ expect(subject.default_gemfile).to eq(expected_gemfile_path)
+ end
+ end
end
describe "#default_lockfile" do
@@ -102,7 +111,7 @@ RSpec.describe Bundler::SharedHelpers do
context "currently in directory with a Gemfile" do
before { File.new("Gemfile", "w") }
- it "returns path of the bundle gemfile" do
+ it "returns path of the bundle Gemfile" do
expect(subject.in_bundle?).to eq("#{bundled_app}/Gemfile")
end
end
@@ -252,20 +261,53 @@ RSpec.describe Bundler::SharedHelpers do
subject.set_bundle_environment
end
- it "exits if bundle path contains the path seperator" do
- stub_const("File::PATH_SEPARATOR", ":".freeze)
+ it "exits if bundle path contains the unix-like path separator" do
+ if Gem.respond_to?(:path_separator)
+ allow(Gem).to receive(:path_separator).and_return(":")
+ else
+ stub_const("File::PATH_SEPARATOR", ":".freeze)
+ end
allow(Bundler).to receive(:bundle_path) { Pathname.new("so:me/dir/bin") }
expect { subject.send(:validate_bundle_path) }.to raise_error(
Bundler::PathError,
- "Your bundle path contains a ':', which is the " \
+ "Your bundle path contains text matching \":\", which is the " \
"path separator for your system. Bundler cannot " \
"function correctly when the Bundle path contains the " \
"system's PATH separator. Please change your " \
- "bundle path to not include ':'.\nYour current bundle " \
+ "bundle path to not match \":\".\nYour current bundle " \
"path is '#{Bundler.bundle_path}'."
)
end
+ context "with a jruby path_separator regex", :ruby => "1.9" do
+ # In versions of jruby that supported ruby 1.8, the path separator was the standard File::PATH_SEPARATOR
+ let(:regex) { Regexp.new("(?<!jar:file|jar|file|classpath|uri:classloader|uri|http|https):") }
+ it "does not exit if bundle path is the standard uri path" do
+ allow(Bundler.rubygems).to receive(:path_separator).and_return(regex)
+ allow(Bundler).to receive(:bundle_path) { Pathname.new("uri:classloader:/WEB-INF/gems") }
+ expect { subject.send(:validate_bundle_path) }.not_to raise_error
+ end
+
+ it "exits if bundle path contains another directory" do
+ allow(Bundler.rubygems).to receive(:path_separator).and_return(regex)
+ allow(Bundler).to receive(:bundle_path) {
+ Pathname.new("uri:classloader:/WEB-INF/gems:other/dir")
+ }
+
+ expect { subject.send(:validate_bundle_path) }.to raise_error(
+ Bundler::PathError,
+ "Your bundle path contains text matching " \
+ "/(?<!jar:file|jar|file|classpath|uri:classloader|uri|http|https):/, which is the " \
+ "path separator for your system. Bundler cannot " \
+ "function correctly when the Bundle path contains the " \
+ "system's PATH separator. Please change your " \
+ "bundle path to not match " \
+ "/(?<!jar:file|jar|file|classpath|uri:classloader|uri|http|https):/." \
+ "\nYour current bundle path is '#{Bundler.bundle_path}'."
+ )
+ end
+ end
+
context "ENV['PATH'] does not exist" do
before { ENV.delete("PATH") }
diff --git a/spec/bundler/bundler/source/git/git_proxy_spec.rb b/spec/bundler/bundler/source/git/git_proxy_spec.rb
index 34fe21e9fb..d282a449a5 100644
--- a/spec/bundler/bundler/source/git/git_proxy_spec.rb
+++ b/spec/bundler/bundler/source/git/git_proxy_spec.rb
@@ -1,5 +1,4 @@
# frozen_string_literal: true
-require "spec_helper"
RSpec.describe Bundler::Source::Git::GitProxy do
let(:uri) { "https://github.com/bundler/bundler.git" }
@@ -7,25 +6,25 @@ RSpec.describe Bundler::Source::Git::GitProxy do
context "with configured credentials" do
it "adds username and password to URI" do
- Bundler.settings[uri] = "u:p"
+ Bundler.settings.temporary(uri => "u:p")
expect(subject).to receive(:git_retry).with(match("https://u:p@github.com/bundler/bundler.git"))
subject.checkout
end
it "adds username and password to URI for host" do
- Bundler.settings["github.com"] = "u:p"
+ Bundler.settings.temporary("github.com" => "u:p")
expect(subject).to receive(:git_retry).with(match("https://u:p@github.com/bundler/bundler.git"))
subject.checkout
end
it "does not add username and password to mismatched URI" do
- Bundler.settings["https://u:p@github.com/bundler/bundler-mismatch.git"] = "u:p"
+ Bundler.settings.temporary("https://u:p@github.com/bundler/bundler-mismatch.git" => "u:p")
expect(subject).to receive(:git_retry).with(match(uri))
subject.checkout
end
it "keeps original userinfo" do
- Bundler.settings["github.com"] = "u:p"
+ Bundler.settings.temporary("github.com" => "u:p")
original = "https://orig:info@github.com/bundler/bundler.git"
subject = described_class.new(Pathname("path"), original, "HEAD")
expect(subject).to receive(:git_retry).with(match(original))
diff --git a/spec/bundler/bundler/source/rubygems/remote_spec.rb b/spec/bundler/bundler/source/rubygems/remote_spec.rb
index 54394fc0ca..9a7ab42128 100644
--- a/spec/bundler/bundler/source/rubygems/remote_spec.rb
+++ b/spec/bundler/bundler/source/rubygems/remote_spec.rb
@@ -1,5 +1,5 @@
# frozen_string_literal: true
-require "spec_helper"
+
require "bundler/source/rubygems/remote"
RSpec.describe Bundler::Source::Rubygems::Remote do
@@ -8,7 +8,7 @@ RSpec.describe Bundler::Source::Rubygems::Remote do
end
before do
- allow(Digest::MD5).to receive(:hexdigest).with(duck_type(:to_s)) {|string| "MD5HEX(#{string})" }
+ allow(Digest(:MD5)).to receive(:hexdigest).with(duck_type(:to_s)) {|string| "MD5HEX(#{string})" }
end
let(:uri_no_auth) { URI("https://gems.example.com") }
@@ -22,7 +22,7 @@ RSpec.describe Bundler::Source::Rubygems::Remote do
end
it "applies configured credentials" do
- Bundler.settings[uri_no_auth.to_s] = credentials
+ Bundler.settings.temporary(uri_no_auth.to_s => credentials)
expect(remote(uri_no_auth).uri).to eq(uri_with_auth)
end
end
@@ -33,7 +33,7 @@ RSpec.describe Bundler::Source::Rubygems::Remote do
end
it "does not apply given credentials" do
- Bundler.settings[uri_no_auth.to_s] = credentials
+ Bundler.settings.temporary(uri_no_auth.to_s => credentials)
expect(remote(uri_no_auth).anonymized_uri).to eq(uri_no_auth)
end
end
@@ -44,7 +44,7 @@ RSpec.describe Bundler::Source::Rubygems::Remote do
end
it "only applies the given user" do
- Bundler.settings[uri_no_auth.to_s] = credentials
+ Bundler.settings.temporary(uri_no_auth.to_s => credentials)
expect(remote(uri_no_auth).cache_slug).to eq("gems.example.com.username.443.MD5HEX(gems.example.com.username.443./)")
end
end
@@ -57,7 +57,7 @@ RSpec.describe Bundler::Source::Rubygems::Remote do
end
it "does not apply configured credentials" do
- Bundler.settings[uri_no_auth.to_s] = "other:stuff"
+ Bundler.settings.temporary(uri_no_auth.to_s => "other:stuff")
expect(remote(uri_with_auth).uri).to eq(uri_with_auth)
end
end
@@ -68,7 +68,7 @@ RSpec.describe Bundler::Source::Rubygems::Remote do
end
it "does not apply given credentials" do
- Bundler.settings[uri_no_auth.to_s] = "other:stuff"
+ Bundler.settings.temporary(uri_no_auth.to_s => "other:stuff")
expect(remote(uri_with_auth).anonymized_uri).to eq(uri_no_auth)
end
end
@@ -79,7 +79,7 @@ RSpec.describe Bundler::Source::Rubygems::Remote do
end
it "does not apply given credentials" do
- Bundler.settings[uri_with_auth.to_s] = credentials
+ Bundler.settings.temporary(uri_with_auth.to_s => credentials)
expect(remote(uri_with_auth).cache_slug).to eq("gems.example.com.username.443.MD5HEX(gems.example.com.username.443./)")
end
end
@@ -106,7 +106,7 @@ RSpec.describe Bundler::Source::Rubygems::Remote do
let(:mirror_uri_with_auth) { URI("https://username:password@rubygems-mirror.org/") }
let(:mirror_uri_no_auth) { URI("https://rubygems-mirror.org/") }
- before { Bundler.settings["mirror.https://rubygems.org/"] = mirror_uri_with_auth.to_s }
+ before { Bundler.settings.set_local("mirror.https://rubygems.org/", mirror_uri_with_auth.to_s) }
specify "#uri returns the mirror URI with credentials" do
expect(remote(uri).uri).to eq(mirror_uri_with_auth)
@@ -131,8 +131,8 @@ RSpec.describe Bundler::Source::Rubygems::Remote do
let(:mirror_uri_no_auth) { URI("https://rubygems-mirror.org/") }
before do
- Bundler.settings["mirror.https://rubygems.org/"] = mirror_uri_no_auth.to_s
- Bundler.settings[mirror_uri_no_auth.to_s] = credentials
+ Bundler.settings.temporary("mirror.https://rubygems.org/" => mirror_uri_no_auth.to_s)
+ Bundler.settings.temporary(mirror_uri_no_auth.to_s => credentials)
end
specify "#uri returns the mirror URI with credentials" do
diff --git a/spec/bundler/bundler/source/rubygems_spec.rb b/spec/bundler/bundler/source/rubygems_spec.rb
index b8f9f09c20..7c457a7265 100644
--- a/spec/bundler/bundler/source/rubygems_spec.rb
+++ b/spec/bundler/bundler/source/rubygems_spec.rb
@@ -1,5 +1,4 @@
# frozen_string_literal: true
-require "spec_helper"
RSpec.describe Bundler::Source::Rubygems do
before do
diff --git a/spec/bundler/bundler/source_list_spec.rb b/spec/bundler/bundler/source_list_spec.rb
index 6a23c8bcbf..ce3353012c 100644
--- a/spec/bundler/bundler/source_list_spec.rb
+++ b/spec/bundler/bundler/source_list_spec.rb
@@ -1,5 +1,4 @@
# frozen_string_literal: true
-require "spec_helper"
RSpec.describe Bundler::SourceList do
before do
@@ -13,6 +12,7 @@ RSpec.describe Bundler::SourceList do
subject(:source_list) { Bundler::SourceList.new }
let(:rubygems_aggregate) { Bundler::Source::Rubygems.new }
+ let(:metadata_source) { Bundler::Source::Metadata.new }
describe "adding sources" do
before do
@@ -85,7 +85,7 @@ RSpec.describe Bundler::SourceList do
end
it "ignores git protocols on request" do
- Bundler.settings["git.allow_insecure"] = true
+ Bundler.settings.temporary(:"git.allow_insecure" => true)
expect(Bundler.ui).to_not receive(:warn).with(msg)
source_list.add_git_source("uri" => "git://existing-git.org/path.git")
end
@@ -115,18 +115,19 @@ RSpec.describe Bundler::SourceList do
end
end
- describe "#add_rubygems_remote" do
- before do
- @returned_source = source_list.add_rubygems_remote("https://rubygems.org/")
- end
+ describe "#add_rubygems_remote", :bundler => "< 2" do
+ let!(:returned_source) { source_list.add_rubygems_remote("https://rubygems.org/") }
it "returns the aggregate rubygems source" do
- expect(@returned_source).to be_instance_of(Bundler::Source::Rubygems)
+ expect(returned_source).to be_instance_of(Bundler::Source::Rubygems)
end
it "adds the provided remote to the beginning of the aggregate source" do
source_list.add_rubygems_remote("https://othersource.org")
- expect(@returned_source.remotes.first).to eq(URI("https://othersource.org/"))
+ expect(returned_source.remotes).to eq [
+ URI("https://othersource.org/"),
+ URI("https://rubygems.org/"),
+ ]
end
end
@@ -204,6 +205,7 @@ RSpec.describe Bundler::SourceList do
Bundler::Source::Rubygems.new("remotes" => ["https://fourth-rubygems.org"]),
Bundler::Source::Rubygems.new("remotes" => ["https://fifth-rubygems.org"]),
rubygems_aggregate,
+ metadata_source,
]
end
end
@@ -354,7 +356,7 @@ RSpec.describe Bundler::SourceList do
end
describe "#lock_sources" do
- it "combines the rubygems sources into a single instance, removing duplicate remotes from the end" do
+ before do
source_list.add_git_source("uri" => "git://third-git.org/path.git")
source_list.add_rubygems_source("remotes" => ["https://duplicate-rubygems.org"])
source_list.add_plugin_source("new_source", "uri" => "https://third-bar.org/foo")
@@ -368,7 +370,9 @@ RSpec.describe Bundler::SourceList do
source_list.add_path_source("path" => "/first/path/to/gem")
source_list.add_rubygems_source("remotes" => ["https://duplicate-rubygems.org"])
source_list.add_git_source("uri" => "git://first-git.org/path.git")
+ end
+ it "combines the rubygems sources into a single instance, removing duplicate remotes from the end", :bundler => "< 2" do
expect(source_list.lock_sources).to eq [
Bundler::Source::Git.new("uri" => "git://first-git.org/path.git"),
Bundler::Source::Git.new("uri" => "git://second-git.org/path.git"),
@@ -386,6 +390,24 @@ RSpec.describe Bundler::SourceList do
]),
]
end
+
+ it "returns all sources, without combining rubygems sources", :bundler => "2" do
+ expect(source_list.lock_sources).to eq [
+ Bundler::Source::Rubygems.new,
+ Bundler::Source::Rubygems.new("remotes" => ["https://duplicate-rubygems.org"]),
+ Bundler::Source::Rubygems.new("remotes" => ["https://first-rubygems.org"]),
+ Bundler::Source::Rubygems.new("remotes" => ["https://second-rubygems.org"]),
+ Bundler::Source::Rubygems.new("remotes" => ["https://third-rubygems.org"]),
+ Bundler::Source::Git.new("uri" => "git://first-git.org/path.git"),
+ Bundler::Source::Git.new("uri" => "git://second-git.org/path.git"),
+ Bundler::Source::Git.new("uri" => "git://third-git.org/path.git"),
+ Bundler::Source::Path.new("path" => "/first/path/to/gem"),
+ Bundler::Source::Path.new("path" => "/second/path/to/gem"),
+ Bundler::Source::Path.new("path" => "/third/path/to/gem"),
+ ASourcePlugin.new("uri" => "https://second-plugin.org/random"),
+ ASourcePlugin.new("uri" => "https://third-bar.org/foo"),
+ ]
+ end
end
describe "replace_sources!" do
@@ -414,7 +436,7 @@ RSpec.describe Bundler::SourceList do
end
describe "#cached!" do
- let(:rubygems_source) { source_list.add_rubygems_remote("https://rubygems.org") }
+ let(:rubygems_source) { source_list.add_rubygems_source("remotes" => ["https://rubygems.org"]) }
let(:git_source) { source_list.add_git_source("uri" => "git://host/path.git") }
let(:path_source) { source_list.add_path_source("path" => "/path/to/gem") }
@@ -427,7 +449,7 @@ RSpec.describe Bundler::SourceList do
end
describe "#remote!" do
- let(:rubygems_source) { source_list.add_rubygems_remote("https://rubygems.org") }
+ let(:rubygems_source) { source_list.add_rubygems_source("remotes" => ["https://rubygems.org"]) }
let(:git_source) { source_list.add_git_source("uri" => "git://host/path.git") }
let(:path_source) { source_list.add_path_source("path" => "/path/to/gem") }
diff --git a/spec/bundler/bundler/source_spec.rb b/spec/bundler/bundler/source_spec.rb
index 08d1698fcd..9ef8e7e50f 100644
--- a/spec/bundler/bundler/source_spec.rb
+++ b/spec/bundler/bundler/source_spec.rb
@@ -1,5 +1,4 @@
# frozen_string_literal: true
-require "spec_helper"
RSpec.describe Bundler::Source do
class ExampleSource < Bundler::Source
diff --git a/spec/bundler/bundler/spec_set_spec.rb b/spec/bundler/bundler/spec_set_spec.rb
index 8f7c27f065..6fedd38b50 100644
--- a/spec/bundler/bundler/spec_set_spec.rb
+++ b/spec/bundler/bundler/spec_set_spec.rb
@@ -1,5 +1,4 @@
# frozen_string_literal: true
-require "spec_helper"
RSpec.describe Bundler::SpecSet do
let(:specs) do
@@ -17,6 +16,7 @@ RSpec.describe Bundler::SpecSet do
build_spec("e", "1.0.0.pre.1"),
].flatten
end
+
subject { described_class.new(specs) }
context "enumerable methods" do
@@ -29,15 +29,49 @@ RSpec.describe Bundler::SpecSet do
end
end
+ describe "#find_by_name_and_platform" do
+ let(:platform) { Gem::Platform.new("universal-darwin-64") }
+ let(:platform_spec) { build_spec("b", "2.0", platform).first }
+ let(:specs) do
+ [
+ build_spec("a", "1.0"),
+ platform_spec,
+ ].flatten
+ end
+
+ it "finds spec with given name and platform" do
+ spec = described_class.new(specs).find_by_name_and_platform("b", platform)
+ expect(spec).to eq platform_spec
+ end
+ end
+
+ describe "#merge" do
+ let(:other_specs) do
+ [
+ build_spec("f", "1.0"),
+ build_spec("g", "2.0"),
+ ].flatten
+ end
+
+ let(:other_spec_set) { described_class.new(other_specs) }
+
+ it "merges the items in each gemspec" do
+ new_spec_set = subject.merge(other_spec_set)
+ specs = new_spec_set.to_a.map(&:full_name)
+ expect(specs).to include("a-1.0")
+ expect(specs).to include("f-1.0")
+ end
+ end
+
describe "#to_a" do
it "returns the specs in order" do
- expect(subject.to_a.map(&:full_name)).to eq %w(
+ expect(subject.to_a.map(&:full_name)).to eq %w[
a-1.0
b-1.0
e-1.0.0.pre.1
c-1.1
d-2.0
- )
+ ]
end
end
end
diff --git a/spec/bundler/bundler/ssl_certs/certificate_manager_spec.rb b/spec/bundler/bundler/ssl_certs/certificate_manager_spec.rb
index 66853a6815..d1ec08bdc4 100644
--- a/spec/bundler/bundler/ssl_certs/certificate_manager_spec.rb
+++ b/spec/bundler/bundler/ssl_certs/certificate_manager_spec.rb
@@ -1,5 +1,5 @@
# frozen_string_literal: true
-require "spec_helper"
+
require "bundler/ssl_certs/certificate_manager"
RSpec.describe Bundler::SSLCerts::CertificateManager do
@@ -78,17 +78,17 @@ RSpec.describe Bundler::SSLCerts::CertificateManager do
context "when certificate manager is not up to date" do
before do
allow(subject).to receive(:up_to_date?).and_return(false)
- allow(FileUtils).to receive(:rm)
- allow(FileUtils).to receive(:cp)
+ allow(bundler_fileutils).to receive(:rm)
+ allow(bundler_fileutils).to receive(:cp)
end
it "should remove the current bundler certs" do
- expect(FileUtils).to receive(:rm).with(subject.bundler_certs)
+ expect(bundler_fileutils).to receive(:rm).with(subject.bundler_certs)
subject.update!
end
it "should copy the rubygems certs into bundler certs" do
- expect(FileUtils).to receive(:cp).with(subject.rubygems_certs, subject.bundler_cert_path)
+ expect(bundler_fileutils).to receive(:cp).with(subject.rubygems_certs, subject.bundler_cert_path)
subject.update!
end
diff --git a/spec/bundler/bundler/stub_specification_spec.rb b/spec/bundler/bundler/stub_specification_spec.rb
index f1ddf43bb4..5521d83769 100644
--- a/spec/bundler/bundler/stub_specification_spec.rb
+++ b/spec/bundler/bundler/stub_specification_spec.rb
@@ -1,5 +1,4 @@
# frozen_string_literal: true
-require "spec_helper"
RSpec.describe Bundler::StubSpecification do
let(:gemspec) do
diff --git a/spec/bundler/bundler/ui/shell_spec.rb b/spec/bundler/bundler/ui/shell_spec.rb
new file mode 100644
index 0000000000..9a47a3572f
--- /dev/null
+++ b/spec/bundler/bundler/ui/shell_spec.rb
@@ -0,0 +1,64 @@
+# frozen_string_literal: true
+
+RSpec.describe Bundler::UI::Shell do
+ subject { described_class.new }
+
+ before { subject.level = "debug" }
+
+ describe "#info" do
+ before { subject.level = "info" }
+ it "prints to stdout" do
+ expect { subject.info("info") }.to output("info\n").to_stdout
+ end
+ end
+
+ describe "#confirm" do
+ before { subject.level = "confirm" }
+ it "prints to stdout" do
+ expect { subject.confirm("confirm") }.to output("confirm\n").to_stdout
+ end
+ end
+
+ describe "#warn" do
+ before { subject.level = "warn" }
+ it "prints to stdout", :bundler => "< 2" do
+ expect { subject.warn("warning") }.to output("warning\n").to_stdout
+ end
+
+ it "prints to stderr", :bundler => "2" do
+ expect { subject.warn("warning") }.to output("warning\n").to_stderr
+ end
+
+ context "when stderr flag is enabled" do
+ before { Bundler.settings.temporary(:error_on_stderr => true) }
+ it "prints to stderr" do
+ expect { subject.warn("warning!") }.to output("warning!\n").to_stderr
+ end
+ end
+ end
+
+ describe "#debug" do
+ it "prints to stdout" do
+ expect { subject.debug("debug") }.to output("debug\n").to_stdout
+ end
+ end
+
+ describe "#error" do
+ before { subject.level = "error" }
+
+ it "prints to stdout", :bundler => "< 2" do
+ expect { subject.error("error!!!") }.to output("error!!!\n").to_stdout
+ end
+
+ it "prints to stderr", :bundler => "2" do
+ expect { subject.error("error!!!") }.to output("error!!!\n").to_stderr
+ end
+
+ context "when stderr flag is enabled" do
+ before { Bundler.settings.temporary(:error_on_stderr => true) }
+ it "prints to stderr" do
+ expect { subject.error("error!!!") }.to output("error!!!\n").to_stderr
+ end
+ end
+ end
+end
diff --git a/spec/bundler/bundler/ui_spec.rb b/spec/bundler/bundler/ui_spec.rb
index fc76eb1ee7..6ef8729277 100644
--- a/spec/bundler/bundler/ui_spec.rb
+++ b/spec/bundler/bundler/ui_spec.rb
@@ -1,5 +1,4 @@
# frozen_string_literal: true
-require "spec_helper"
RSpec.describe Bundler::UI do
describe Bundler::UI::Silent do
diff --git a/spec/bundler/bundler/uri_credentials_filter_spec.rb b/spec/bundler/bundler/uri_credentials_filter_spec.rb
index 1dd01b4be0..fe52d16306 100644
--- a/spec/bundler/bundler/uri_credentials_filter_spec.rb
+++ b/spec/bundler/bundler/uri_credentials_filter_spec.rb
@@ -1,5 +1,4 @@
# frozen_string_literal: true
-require "spec_helper"
RSpec.describe Bundler::URICredentialsFilter do
subject { described_class }
diff --git a/spec/bundler/bundler/vendored_persistent_spec.rb b/spec/bundler/bundler/vendored_persistent_spec.rb
new file mode 100644
index 0000000000..338431c4a6
--- /dev/null
+++ b/spec/bundler/bundler/vendored_persistent_spec.rb
@@ -0,0 +1,78 @@
+# frozen_string_literal: true
+
+require "spec_helper"
+require "bundler/vendored_persistent"
+
+RSpec.describe Bundler::PersistentHTTP do
+ describe "#warn_old_tls_version_rubygems_connection" do
+ let(:uri) { "https://index.rubygems.org" }
+ let(:connection) { instance_double(subject.http_class) }
+ let(:tls_version) { "TLSv1.2" }
+ let(:socket) { double("Socket") }
+ let(:socket_io) { double("SocketIO") }
+
+ before do
+ allow(connection).to receive(:use_ssl?).and_return(!tls_version.nil?)
+ allow(socket).to receive(:io).and_return(socket_io)
+ connection.instance_variable_set(:@socket, socket)
+
+ if tls_version
+ allow(socket_io).to receive(:ssl_version).and_return(tls_version)
+ end
+ end
+
+ shared_examples_for "does not warn" do
+ it "does not warn" do
+ allow(Bundler.ui).to receive(:warn).never
+ subject.warn_old_tls_version_rubygems_connection(URI(uri), connection)
+ end
+ end
+
+ shared_examples_for "does warn" do |*expected|
+ it "warns" do
+ expect(Bundler.ui).to receive(:warn).with(*expected)
+ subject.warn_old_tls_version_rubygems_connection(URI(uri), connection)
+ end
+ end
+
+ context "an HTTPS uri with TLSv1.2" do
+ include_examples "does not warn"
+ end
+
+ context "without SSL" do
+ let(:tls_version) { nil }
+
+ include_examples "does not warn"
+ end
+
+ context "without a socket" do
+ let(:socket) { nil }
+
+ include_examples "does not warn"
+ end
+
+ context "with a different TLD" do
+ let(:uri) { "https://foo.bar" }
+ include_examples "does not warn"
+
+ context "and an outdated TLS version" do
+ let(:tls_version) { "TLSv1" }
+ include_examples "does not warn"
+ end
+ end
+
+ context "with a nonsense TLS version" do
+ let(:tls_version) { "BlahBlah2.0Blah" }
+ include_examples "does not warn"
+ end
+
+ context "with an outdated TLS version" do
+ let(:tls_version) { "TLSv1" }
+ include_examples "does warn",
+ "Warning: Your Ruby version is compiled against a copy of OpenSSL that is very old. " \
+ "Starting in January 2018, RubyGems.org will refuse connection requests from these very old versions of OpenSSL. " \
+ "If you will need to continue installing gems after January 2018, please follow this guide to upgrade: http://ruby.to/tls-outdated.",
+ :wrap => true
+ end
+ end
+end
diff --git a/spec/bundler/bundler/version_ranges_spec.rb b/spec/bundler/bundler/version_ranges_spec.rb
index f746aa88ad..ccbb9285d5 100644
--- a/spec/bundler/bundler/version_ranges_spec.rb
+++ b/spec/bundler/bundler/version_ranges_spec.rb
@@ -1,5 +1,5 @@
# frozen_string_literal: true
-require "spec_helper"
+
require "bundler/version_ranges"
RSpec.describe Bundler::VersionRanges do
diff --git a/spec/bundler/bundler/worker_spec.rb b/spec/bundler/bundler/worker_spec.rb
index fbfe6ddab3..2e5642709d 100644
--- a/spec/bundler/bundler/worker_spec.rb
+++ b/spec/bundler/bundler/worker_spec.rb
@@ -1,5 +1,5 @@
# frozen_string_literal: true
-require "spec_helper"
+
require "bundler/worker"
RSpec.describe Bundler::Worker do
diff --git a/spec/bundler/bundler/yaml_serializer_spec.rb b/spec/bundler/bundler/yaml_serializer_spec.rb
index c28db59223..1241c74bbf 100644
--- a/spec/bundler/bundler/yaml_serializer_spec.rb
+++ b/spec/bundler/bundler/yaml_serializer_spec.rb
@@ -1,5 +1,5 @@
# frozen_string_literal: true
-require "spec_helper"
+
require "bundler/yaml_serializer"
RSpec.describe Bundler::YAMLSerializer do
@@ -156,6 +156,7 @@ RSpec.describe Bundler::YAMLSerializer do
"a_joke" => {
"my-stand" => "I can totally keep secrets",
"but" => "The people I tell them to can't :P",
+ "wouldn't it be funny if this string were empty?" => "",
},
"more" => {
"first" => [
diff --git a/spec/bundler/cache/cache_path_spec.rb b/spec/bundler/cache/cache_path_spec.rb
index ec6d6e312a..69d3809964 100644
--- a/spec/bundler/cache/cache_path_spec.rb
+++ b/spec/bundler/cache/cache_path_spec.rb
@@ -1,5 +1,4 @@
# frozen_string_literal: true
-require "spec_helper"
RSpec.describe "bundle package" do
before do
@@ -24,11 +23,10 @@ RSpec.describe "bundle package" do
end
end
- context "when given an absolute path" do
- it "exits with non-zero status" do
+ context "with absolute --cache-path" do
+ it "caches gems at given path" do
bundle :package, "cache-path" => "/tmp/cache-foo"
- expect(out).to match(/must be relative/)
- expect(exitstatus).to eq(15) if exitstatus
+ expect(bundled_app("/tmp/cache-foo/rack-1.0.0.gem")).to exist
end
end
end
diff --git a/spec/bundler/cache/gems_spec.rb b/spec/bundler/cache/gems_spec.rb
index 7828c87fec..4a0b953830 100644
--- a/spec/bundler/cache/gems_spec.rb
+++ b/spec/bundler/cache/gems_spec.rb
@@ -1,15 +1,14 @@
# frozen_string_literal: true
-require "spec_helper"
RSpec.describe "bundle cache" do
- describe "when there are only gemsources" do
+ shared_examples_for "when there are only gemsources" do
before :each do
gemfile <<-G
gem 'rack'
G
- system_gems "rack-1.0.0"
- bundle :cache
+ system_gems "rack-1.0.0", :path => :bundle_path
+ bundle! :cache
end
it "copies the .gem file to vendor/cache" do
@@ -28,7 +27,7 @@ RSpec.describe "bundle cache" do
end
it "uses the cache as a source when installing gems with --local" do
- system_gems []
+ system_gems [], :path => :bundle_path
bundle "install --local"
expect(the_bundle).to include_gems("rack 1.0.0")
@@ -47,7 +46,7 @@ RSpec.describe "bundle cache" do
end
it "does not reinstall gems from the cache if they exist in the bundle" do
- system_gems "rack-1.0.0"
+ system_gems "rack-1.0.0", :path => :bundle_path
gemfile <<-G
gem "rack"
@@ -57,7 +56,7 @@ RSpec.describe "bundle cache" do
s.write "lib/rack.rb", "RACK = 'FAIL'"
end
- bundle "install --local"
+ bundle! :install, :local => true
expect(the_bundle).to include_gems("rack 1.0.0")
end
@@ -74,6 +73,16 @@ RSpec.describe "bundle cache" do
end
end
+ context "using system gems" do
+ before { bundle! "config path.system true" }
+ it_behaves_like "when there are only gemsources"
+ end
+
+ context "installing into a local path" do
+ before { bundle! "config path ./.bundle" }
+ it_behaves_like "when there are only gemsources"
+ end
+
describe "when there is a built-in gem", :ruby => "2.0" do
before :each do
build_repo2 do
@@ -87,7 +96,8 @@ RSpec.describe "bundle cache" do
FileUtils.rm("#{system_gem_path}/cache/builtin_gem-1.0.2.gem")
end
- it "uses builtin gems" do
+ it "uses builtin gems when installing to system gems" do
+ bundle! "config path.system true"
install_gemfile %(gem 'builtin_gem', '1.0.2')
expect(the_bundle).to include_gems("builtin_gem 1.0.2")
end
@@ -119,6 +129,8 @@ RSpec.describe "bundle cache" do
end
it "errors if the builtin gem isn't available to cache" do
+ bundle! "config path.system true"
+
install_gemfile <<-G
gem 'builtin_gem', '1.0.2'
G
@@ -184,7 +196,7 @@ RSpec.describe "bundle cache" do
it "adds and removes when gems are updated" do
update_repo2
- bundle "update"
+ bundle "update", :all => bundle_update_requires_all?
expect(cached_gem("rack-1.2")).to exist
expect(cached_gem("rack-1.0.0")).not_to exist
end
diff --git a/spec/bundler/cache/git_spec.rb b/spec/bundler/cache/git_spec.rb
index 31b3816a3b..33387dbbb2 100644
--- a/spec/bundler/cache/git_spec.rb
+++ b/spec/bundler/cache/git_spec.rb
@@ -1,5 +1,4 @@
# frozen_string_literal: true
-require "spec_helper"
RSpec.describe "git base name" do
it "base_name should strip private repo uris" do
@@ -13,7 +12,7 @@ RSpec.describe "git base name" do
end
end
-%w(cache package).each do |cmd|
+%w[cache package].each do |cmd|
RSpec.describe "bundle #{cmd} with git" do
it "copies repository to vendor cache and uses it" do
git = build_git "foo"
@@ -23,7 +22,7 @@ end
gem "foo", :git => '#{lib_path("foo-1.0")}'
G
- bundle "#{cmd} --all"
+ bundle "#{cmd}", forgotten_command_line_options([:all, :cache_all] => true)
expect(bundled_app("vendor/cache/foo-1.0-#{ref}")).to exist
expect(bundled_app("vendor/cache/foo-1.0-#{ref}/.git")).not_to exist
expect(bundled_app("vendor/cache/foo-1.0-#{ref}/.bundlecache")).to be_file
@@ -41,7 +40,7 @@ end
G
bundle "install --path vendor/bundle"
- bundle "#{cmd} --all"
+ bundle "#{cmd}", forgotten_command_line_options([:all, :cache_all] => true)
expect(bundled_app("vendor/cache/foo-1.0-#{ref}")).to exist
expect(bundled_app("vendor/cache/foo-1.0-#{ref}/.git")).not_to exist
@@ -53,14 +52,14 @@ end
it "runs twice without exploding" do
build_git "foo"
- install_gemfile <<-G
+ install_gemfile! <<-G
gem "foo", :git => '#{lib_path("foo-1.0")}'
G
- bundle "#{cmd} --all"
- bundle "#{cmd} --all"
+ bundle! "#{cmd}", forgotten_command_line_options([:all, :cache_all] => true)
+ bundle! "#{cmd}", forgotten_command_line_options([:all, :cache_all] => true)
- expect(err).to lack_errors
+ expect(last_command.stdout).to include "Updating files in vendor/cache"
FileUtils.rm_rf lib_path("foo-1.0")
expect(the_bundle).to include_gems "foo 1.0"
end
@@ -73,7 +72,7 @@ end
gem "foo", :git => '#{lib_path("foo-1.0")}'
G
- bundle "#{cmd} --all"
+ bundle "#{cmd}", forgotten_command_line_options([:all, :cache_all] => true)
update_git "foo" do |s|
s.write "lib/foo.rb", "puts :CACHE"
@@ -82,14 +81,14 @@ end
ref = git.ref_for("master", 11)
expect(ref).not_to eq(old_ref)
- bundle "update"
- bundle "#{cmd} --all"
+ bundle! "update", :all => bundle_update_requires_all?
+ bundle! "#{cmd}", forgotten_command_line_options([:all, :cache_all] => true)
expect(bundled_app("vendor/cache/foo-1.0-#{ref}")).to exist
expect(bundled_app("vendor/cache/foo-1.0-#{old_ref}")).not_to exist
FileUtils.rm_rf lib_path("foo-1.0")
- run "require 'foo'"
+ run! "require 'foo'"
expect(out).to eq("CACHE")
end
@@ -101,7 +100,7 @@ end
gem "foo", :git => '#{lib_path("foo-1.0")}'
G
- bundle "#{cmd} --all"
+ bundle! cmd, forgotten_command_line_options([:all, :cache_all] => true)
update_git "foo" do |s|
s.write "lib/foo.rb", "puts :CACHE"
@@ -130,7 +129,7 @@ end
bundle %(config local.foo #{lib_path("foo-1.0")})
bundle "install"
- bundle "#{cmd} --all"
+ bundle "#{cmd}", forgotten_command_line_options([:all, :cache_all] => true)
expect(bundled_app("vendor/cache/foo-invalid-#{ref}")).to exist
@@ -162,14 +161,14 @@ end
G
ref = git.ref_for("master", 11)
- bundle "#{cmd} --all"
+ bundle "#{cmd}", forgotten_command_line_options([:all, :cache_all] => true)
expect(bundled_app("vendor/cache/has_submodule-1.0-#{ref}")).to exist
expect(bundled_app("vendor/cache/has_submodule-1.0-#{ref}/submodule-1.0")).to exist
expect(the_bundle).to include_gems "has_submodule 1.0"
end
- it "displays warning message when detecting git repo in Gemfile" do
+ it "displays warning message when detecting git repo in Gemfile", :bundler => "< 2" do
build_git "foo"
install_gemfile <<-G
@@ -188,8 +187,8 @@ end
gem "foo", :git => '#{lib_path("foo-1.0")}'
G
- bundle "#{cmd} --all"
- bundle "#{cmd}"
+ bundle cmd, forgotten_command_line_options([:all, :cache_all] => true)
+ bundle cmd
expect(out).not_to include("Your Gemfile contains path and git dependencies.")
end
@@ -205,7 +204,7 @@ end
install_gemfile <<-G
gem "foo", :git => '#{lib_path("foo-1.0")}'
G
- bundle "#{cmd} --all"
+ bundle cmd, forgotten_command_line_options([:all, :cache_all] => true)
ref = git.ref_for("master", 11)
gemspec = bundled_app("vendor/cache/foo-1.0-#{ref}/foo.gemspec").read
diff --git a/spec/bundler/cache/path_spec.rb b/spec/bundler/cache/path_spec.rb
index bbce448759..8c6a843476 100644
--- a/spec/bundler/cache/path_spec.rb
+++ b/spec/bundler/cache/path_spec.rb
@@ -1,7 +1,6 @@
# frozen_string_literal: true
-require "spec_helper"
-%w(cache package).each do |cmd|
+%w[cache package].each do |cmd|
RSpec.describe "bundle #{cmd} with path" do
it "is no-op when the path is within the bundle" do
build_lib "foo", :path => bundled_app("lib/foo")
@@ -10,7 +9,7 @@ require "spec_helper"
gem "foo", :path => '#{bundled_app("lib/foo")}'
G
- bundle "#{cmd} --all"
+ bundle cmd, forgotten_command_line_options([:all, :cache_all] => true)
expect(bundled_app("vendor/cache/foo-1.0")).not_to exist
expect(the_bundle).to include_gems "foo 1.0"
end
@@ -22,7 +21,7 @@ require "spec_helper"
gem "foo", :path => '#{lib_path("foo-1.0")}'
G
- bundle "#{cmd} --all"
+ bundle cmd, forgotten_command_line_options([:all, :cache_all] => true)
expect(bundled_app("vendor/cache/foo-1.0")).to exist
expect(bundled_app("vendor/cache/foo-1.0/.bundlecache")).to be_file
@@ -40,7 +39,7 @@ require "spec_helper"
gem "#{libname}", :path => '#{libpath}'
G
- bundle "#{cmd} --all"
+ bundle cmd, forgotten_command_line_options([:all, :cache_all] => true)
expect(bundled_app("vendor/cache/#{libname}")).to exist
expect(bundled_app("vendor/cache/#{libname}/.bundlecache")).to be_file
@@ -55,13 +54,13 @@ require "spec_helper"
gem "foo", :path => '#{lib_path("foo-1.0")}'
G
- bundle "#{cmd} --all"
+ bundle cmd, forgotten_command_line_options([:all, :cache_all] => true)
build_lib "foo" do |s|
s.write "lib/foo.rb", "puts :CACHE"
end
- bundle "#{cmd} --all"
+ bundle cmd, forgotten_command_line_options([:all, :cache_all] => true)
expect(bundled_app("vendor/cache/foo-1.0")).to exist
FileUtils.rm_rf lib_path("foo-1.0")
@@ -77,17 +76,17 @@ require "spec_helper"
gem "foo", :path => '#{lib_path("foo-1.0")}'
G
- bundle "#{cmd} --all"
+ bundle cmd, forgotten_command_line_options([:all, :cache_all] => true)
install_gemfile <<-G
gem "bar", :path => '#{lib_path("bar-1.0")}'
G
- bundle "#{cmd} --all"
+ bundle cmd, forgotten_command_line_options([:all, :cache_all] => true)
expect(bundled_app("vendor/cache/bar-1.0")).not_to exist
end
- it "raises a warning without --all" do
+ it "raises a warning without --all", :bundler => "< 2" do
build_lib "foo"
install_gemfile <<-G
@@ -106,7 +105,7 @@ require "spec_helper"
gem "foo", :path => '#{lib_path("foo-1.0")}'
G
- bundle "#{cmd} --all"
+ bundle cmd, forgotten_command_line_options([:all, :cache_all] => true)
build_lib "bar"
install_gemfile <<-G
@@ -125,7 +124,7 @@ require "spec_helper"
gem "foo", :path => '#{lib_path("foo-1.0")}'
G
- bundle "#{cmd} --all"
+ bundle cmd, forgotten_command_line_options([:all, :cache_all] => true)
build_lib "baz"
gemfile <<-G
diff --git a/spec/bundler/cache/platform_spec.rb b/spec/bundler/cache/platform_spec.rb
index ed80c949aa..c0622a3c94 100644
--- a/spec/bundler/cache/platform_spec.rb
+++ b/spec/bundler/cache/platform_spec.rb
@@ -1,5 +1,4 @@
# frozen_string_literal: true
-require "spec_helper"
RSpec.describe "bundle cache with multiple platforms" do
before :each do
@@ -35,18 +34,14 @@ RSpec.describe "bundle cache with multiple platforms" do
end
it "ensures that a successful bundle install does not delete gems for other platforms" do
- bundle "install"
-
- expect(exitstatus).to eq 0 if exitstatus
+ bundle! "install"
expect(bundled_app("vendor/cache/rack-1.0.0.gem")).to exist
expect(bundled_app("vendor/cache/activesupport-2.3.5.gem")).to exist
end
it "ensures that a successful bundle update does not delete gems for other platforms" do
- bundle "update"
-
- expect(exitstatus).to eq 0 if exitstatus
+ bundle! "update", :all => bundle_update_requires_all?
expect(bundled_app("vendor/cache/rack-1.0.0.gem")).to exist
expect(bundled_app("vendor/cache/activesupport-2.3.5.gem")).to exist
diff --git a/spec/bundler/commands/add_spec.rb b/spec/bundler/commands/add_spec.rb
index 4931402c33..7916db960a 100644
--- a/spec/bundler/commands/add_spec.rb
+++ b/spec/bundler/commands/add_spec.rb
@@ -1,5 +1,4 @@
# frozen_string_literal: true
-require "spec_helper"
RSpec.describe "bundle add" do
before :each do
@@ -82,7 +81,7 @@ RSpec.describe "bundle add" do
it "using combination of short form options works like long form" do
bundle "add 'foo' -s='file://#{gem_repo2}' -g='development' -v='~>1.0'"
- expect(bundled_app("Gemfile").read).to match(%r{gem "foo", "~> 1.0", :group => \[:development\], :source => "file:\/\/#{gem_repo2}"})
+ expect(bundled_app("Gemfile").read).to include %(gem "foo", "~> 1.0", :group => [:development], :source => "file://#{gem_repo2}")
expect(the_bundle).to include_gems "foo 1.1"
end
@@ -93,7 +92,7 @@ RSpec.describe "bundle add" do
it "shows error message when gem cannot be found" do
bundle "add 'werk_it'"
- expect(out).to match("Could not find gem 'werk_it' in any of the gem sources listed in your Gemfile.")
+ expect(out).to match("Could not find gem 'werk_it' in")
bundle "add 'werk_it' -s='file://#{gem_repo2}'"
expect(out).to match("Could not find gem 'werk_it' in rubygems repository")
diff --git a/spec/bundler/commands/binstubs_spec.rb b/spec/bundler/commands/binstubs_spec.rb
index cb0999348e..0313f48b60 100644
--- a/spec/bundler/commands/binstubs_spec.rb
+++ b/spec/bundler/commands/binstubs_spec.rb
@@ -1,5 +1,4 @@
# frozen_string_literal: true
-require "spec_helper"
RSpec.describe "bundle binstubs <gem>" do
context "when the gem exists in the lockfile" do
@@ -51,22 +50,130 @@ RSpec.describe "bundle binstubs <gem>" do
expect(out).to include("`bundle binstubs` needs at least one gem to run.")
end
- it "does not bundle the bundler binary" do
- install_gemfile <<-G
- source "file://#{gem_repo1}"
- G
+ context "the bundle binstub" do
+ before do
+ if system_bundler_version == :bundler
+ system_gems :bundler
+ elsif system_bundler_version
+ build_repo4 do
+ build_gem "bundler", system_bundler_version do |s|
+ s.executables = "bundle"
+ s.bindir = "exe"
+ s.write "exe/bundle", "puts %(system bundler #{system_bundler_version}\\n\#{ARGV.inspect})"
+ end
+ end
+ system_gems "bundler-#{system_bundler_version}", :gem_repo => gem_repo4
+ end
+ build_repo2 do
+ build_gem "prints_loaded_gems", "1.0" do |s|
+ s.executables = "print_loaded_gems"
+ s.write "bin/print_loaded_gems", <<-R
+ specs = Gem.loaded_specs.values.reject {|s| Bundler.rubygems.spec_default_gem?(s) }
+ puts specs.map(&:full_name).sort.inspect
+ R
+ end
+ end
+ install_gemfile! <<-G
+ source "file://#{gem_repo2}"
+ gem "rack"
+ gem "prints_loaded_gems"
+ G
+ bundle! "binstubs bundler rack prints_loaded_gems"
+ end
+
+ let(:system_bundler_version) { Bundler::VERSION }
+
+ it "runs bundler" do
+ sys_exec! "#{bundled_app("bin/bundle")} install"
+ expect(out).to eq %(system bundler #{system_bundler_version}\n["install"])
+ end
+
+ context "when BUNDLER_VERSION is set" do
+ it "runs the correct version of bundler" do
+ sys_exec "BUNDLER_VERSION='999.999.999' #{bundled_app("bin/bundle")} install"
+ expect(exitstatus).to eq(42) if exitstatus
+ expect(last_command.stderr).to include("Activating bundler (999.999.999) failed:").
+ and include("To install the version of bundler this project requires, run `gem install bundler -v '999.999.999'`")
+ end
+ end
+
+ context "when a lockfile exists with a locked bundler version" do
+ it "runs the correct version of bundler when the version is newer" do
+ lockfile lockfile.gsub(system_bundler_version, "999.999.999")
+ sys_exec "#{bundled_app("bin/bundle")} install"
+ expect(exitstatus).to eq(42) if exitstatus
+ expect(last_command.stderr).to include("Activating bundler (999.999.999) failed:").
+ and include("To install the version of bundler this project requires, run `gem install bundler -v '999.999.999'`")
+ end
+
+ it "runs the correct version of bundler when the version is older" do
+ simulate_bundler_version "55"
+ lockfile lockfile.gsub(system_bundler_version, "44.0")
+ sys_exec "#{bundled_app("bin/bundle")} install"
+ expect(exitstatus).to eq(42) if exitstatus
+ expect(last_command.stderr).to include("Activating bundler (44.0) failed:").
+ and include("To install the version of bundler this project requires, run `gem install bundler -v '44.0'`")
+ end
+
+ it "runs the correct version of bundler when the version is a pre-release" do
+ simulate_bundler_version "55"
+ lockfile lockfile.gsub(system_bundler_version, "2.12.0.a")
+ sys_exec "#{bundled_app("bin/bundle")} install"
+ expect(exitstatus).to eq(42) if exitstatus
+ expect(last_command.stderr).to include("Activating bundler (2.12.0.a) failed:").
+ and include("To install the version of bundler this project requires, run `gem install bundler -v '2.12.0.a'`")
+ end
+ end
+
+ context "when update --bundler is called" do
+ before { lockfile.gsub(system_bundler_version, "1.1.1") }
+
+ it "calls through to the latest bundler version" do
+ sys_exec! "#{bundled_app("bin/bundle")} update --bundler"
+ expect(last_command.stdout).to eq %(system bundler #{system_bundler_version}\n["update", "--bundler"])
+ end
+
+ it "calls through to the explicit bundler version" do
+ sys_exec "#{bundled_app("bin/bundle")} update --bundler=999.999.999"
+ expect(exitstatus).to eq(42) if exitstatus
+ expect(last_command.stderr).to include("Activating bundler (999.999.999) failed:").
+ and include("To install the version of bundler this project requires, run `gem install bundler -v '999.999.999'`")
+ end
+ end
+
+ context "without a lockfile" do
+ it "falls back to the latest installed bundler" do
+ FileUtils.rm bundled_app("Gemfile.lock")
+ sys_exec! bundled_app("bin/bundle").to_s
+ expect(out).to eq "system bundler #{system_bundler_version}\n[]"
+ end
+ end
+
+ context "using another binstub", :ruby_repo do
+ let(:system_bundler_version) { :bundler }
+ it "loads all gems" do
+ sys_exec! bundled_app("bin/print_loaded_gems").to_s
+ expect(out).to eq %(["bundler-#{Bundler::VERSION}", "prints_loaded_gems-1.0", "rack-1.2"])
+ end
- bundle "binstubs bundler"
+ context "when requesting a different bundler version" do
+ before { lockfile lockfile.gsub(Bundler::VERSION, "999.999.999") }
- expect(bundled_app("bin/bundle")).not_to exist
- expect(out).to include("Sorry, Bundler can only be run via Rubygems.")
+ it "attempts to load that version" do
+ sys_exec bundled_app("bin/rackup").to_s
+ expect(exitstatus).to eq(42) if exitstatus
+ expect(last_command.stderr).to include("Activating bundler (999.999.999) failed:").
+ and include("To install the version of bundler this project requires, run `gem install bundler -v '999.999.999'`")
+ end
+ end
+ end
end
it "installs binstubs from git gems" do
FileUtils.mkdir_p(lib_path("foo/bin"))
FileUtils.touch(lib_path("foo/bin/foo"))
build_git "foo", "1.0", :path => lib_path("foo") do |s|
- s.executables = %w(foo)
+ s.executables = %w[foo]
end
install_gemfile <<-G
gem "foo", :git => "#{lib_path("foo")}"
@@ -81,7 +188,7 @@ RSpec.describe "bundle binstubs <gem>" do
FileUtils.mkdir_p(lib_path("foo/bin"))
FileUtils.touch(lib_path("foo/bin/foo"))
build_lib "foo", "1.0", :path => lib_path("foo") do |s|
- s.executables = %w(foo)
+ s.executables = %w[foo]
end
install_gemfile <<-G
gem "foo", :path => "#{lib_path("foo")}"
@@ -104,6 +211,19 @@ RSpec.describe "bundle binstubs <gem>" do
expect(File.stat(binary).mode.to_s(8)).to eq("100775")
end
end
+
+ context "when using --shebang" do
+ it "sets the specified shebang for the the binstub" do
+ install_gemfile <<-G
+ source "file://#{gem_repo1}"
+ gem "rack"
+ G
+
+ bundle "binstubs rack --shebang jruby"
+
+ expect(File.open("bin/rackup").gets).to eq("#!/usr/bin/env jruby\n")
+ end
+ end
end
context "when the gem doesn't exist" do
@@ -131,33 +251,43 @@ RSpec.describe "bundle binstubs <gem>" do
expect(bundled_app("exec/rackup")).to exist
end
- it "setting is saved for bundle install" do
+ it "setting is saved for bundle install", :bundler => "< 2" do
install_gemfile <<-G
source "file://#{gem_repo1}"
gem "rack"
gem "rails"
G
- bundle "binstubs rack --path exec"
- bundle :install
+ bundle! "binstubs rack", forgotten_command_line_options([:path, :bin] => "exec")
+ bundle! :install
expect(bundled_app("exec/rails")).to exist
end
end
- context "after installing with --standalone" do
+ context "with --standalone option" do
before do
install_gemfile <<-G
source "file://#{gem_repo1}"
gem "rack"
G
- bundle "install --standalone"
end
- it "includes the standalone path" do
- bundle "binstubs rack --standalone"
- standalone_line = File.read(bundled_app("bin/rackup")).each_line.find {|line| line.include? "$:.unshift" }.strip
- expect(standalone_line).to eq %($:.unshift File.expand_path "../../bundle", path.realpath)
+ it "generates a standalone binstub" do
+ bundle! "binstubs rack --standalone"
+ expect(bundled_app("bin/rackup")).to exist
+ end
+
+ it "generates a binstub that does not depend on rubygems or bundler" do
+ bundle! "binstubs rack --standalone"
+ expect(File.read(bundled_app("bin/rackup"))).to_not include("Gem.bin_path")
+ end
+
+ context "when specified --path option" do
+ it "generates a standalone binstub at the given path" do
+ bundle! "binstubs rack --standalone --path foo"
+ expect(bundled_app("foo/rackup")).to exist
+ end
end
end
diff --git a/spec/bundler/commands/check_spec.rb b/spec/bundler/commands/check_spec.rb
index 532be07c3f..f2af446fbf 100644
--- a/spec/bundler/commands/check_spec.rb
+++ b/spec/bundler/commands/check_spec.rb
@@ -1,5 +1,4 @@
# frozen_string_literal: true
-require "spec_helper"
RSpec.describe "bundle check" do
it "returns success when the Gemfile is satisfied" do
@@ -93,7 +92,7 @@ RSpec.describe "bundle check" do
expect(out).to include("Bundler can't satisfy your Gemfile's dependencies.")
end
- it "remembers --without option from install" do
+ it "remembers --without option from install", :bundler => "< 2" do
gemfile <<-G
source "file://#{gem_repo1}"
group :foo do
@@ -101,9 +100,21 @@ RSpec.describe "bundle check" do
end
G
- bundle "install --without foo"
- bundle "check"
- expect(exitstatus).to eq(0) if exitstatus
+ bundle! "install --without foo"
+ bundle! "check"
+ expect(out).to include("The Gemfile's dependencies are satisfied")
+ end
+
+ it "uses the without setting" do
+ bundle! "config without foo"
+ install_gemfile! <<-G
+ source "file://#{gem_repo1}"
+ group :foo do
+ gem "rack"
+ end
+ G
+
+ bundle! "check"
expect(out).to include("The Gemfile's dependencies are satisfied")
end
@@ -113,7 +124,7 @@ RSpec.describe "bundle check" do
gem "rack", :group => :foo
G
- bundle "install --without foo"
+ bundle :install, forgotten_command_line_options(:without => "foo")
gemfile <<-G
source "file://#{gem_repo1}"
@@ -126,8 +137,6 @@ RSpec.describe "bundle check" do
end
it "ignores missing gems restricted to other platforms" do
- system_gems "rack-1.0.0"
-
gemfile <<-G
source "file://#{gem_repo1}"
gem "rack"
@@ -136,6 +145,8 @@ RSpec.describe "bundle check" do
end
G
+ system_gems "rack-1.0.0", :path => :bundle_path
+
lockfile <<-G
GEM
remote: file:#{gem_repo1}/
@@ -157,8 +168,6 @@ RSpec.describe "bundle check" do
end
it "works with env conditionals" do
- system_gems "rack-1.0.0"
-
gemfile <<-G
source "file://#{gem_repo1}"
gem "rack"
@@ -167,6 +176,8 @@ RSpec.describe "bundle check" do
end
G
+ system_gems "rack-1.0.0", :path => :bundle_path
+
lockfile <<-G
GEM
remote: file:#{gem_repo1}/
@@ -211,25 +222,23 @@ RSpec.describe "bundle check" do
3.times do
bundle :check
expect(out).to eq(last_out)
- expect(err).to lack_errors
end
end
it "fails when there's no lock file and frozen is set" do
- gemfile <<-G
+ install_gemfile! <<-G
source "file://#{gem_repo1}"
gem "foo"
G
- bundle "install"
- bundle "install --deployment"
+ bundle! "install", forgotten_command_line_options(:deployment => true)
FileUtils.rm(bundled_app("Gemfile.lock"))
bundle :check
- expect(exitstatus).not_to eq(0) if exitstatus
+ expect(last_command).to be_failure
end
- context "--path" do
+ context "--path", :bundler => "< 2" do
before do
gemfile <<-G
source "file://#{gem_repo1}"
@@ -241,15 +250,13 @@ RSpec.describe "bundle check" do
end
it "returns success" do
- bundle "check --path vendor/bundle"
- expect(exitstatus).to eq(0) if exitstatus
+ bundle! "check --path vendor/bundle"
expect(out).to include("The Gemfile's dependencies are satisfied")
end
- it "should write to .bundle/config" do
+ it "should write to .bundle/config", :bundler => "< 2" do
bundle "check --path vendor/bundle"
- bundle "check"
- expect(exitstatus).to eq(0) if exitstatus
+ bundle! "check"
end
end
@@ -299,7 +306,7 @@ RSpec.describe "bundle check" do
rack (1.0.0)
PLATFORMS
- #{generic_local_platform}
+ #{lockfile_platforms}
DEPENDENCIES
rack
@@ -330,9 +337,8 @@ RSpec.describe "bundle check" do
context "is newer" do
it "does not change the lock but warns" do
lockfile lock_with(Bundler::VERSION.succ)
- bundle :check
- expect(out).to include("the running version of Bundler (#{Bundler::VERSION}) is older than the version that created the lockfile (#{Bundler::VERSION.succ})")
- expect(err).to lack_errors
+ bundle! :check
+ expect(last_command.bundler_err).to include("the running version of Bundler (#{Bundler::VERSION}) is older than the version that created the lockfile (#{Bundler::VERSION.succ})")
lockfile_should_be lock_with(Bundler::VERSION.succ)
end
end
diff --git a/spec/bundler/commands/clean_spec.rb b/spec/bundler/commands/clean_spec.rb
index 02d96a0ff7..bab87372d1 100644
--- a/spec/bundler/commands/clean_spec.rb
+++ b/spec/bundler/commands/clean_spec.rb
@@ -1,5 +1,4 @@
# frozen_string_literal: true
-require "spec_helper"
RSpec.describe "bundle clean" do
def should_have_gems(*gems)
@@ -26,16 +25,16 @@ RSpec.describe "bundle clean" do
gem "foo"
G
- bundle "install --path vendor/bundle --no-clean"
+ bundle! "install", forgotten_command_line_options(:path => "vendor/bundle", :clean => false)
gemfile <<-G
source "file://#{gem_repo1}"
gem "thin"
G
- bundle "install"
+ bundle! "install"
- bundle :clean
+ bundle! :clean
expect(out).to include("Removing foo (1.0)")
@@ -53,7 +52,7 @@ RSpec.describe "bundle clean" do
gem "foo"
G
- bundle "install --path vendor/bundle --no-clean"
+ bundle "install", forgotten_command_line_options(:path => "vendor/bundle", :clean => false)
gemfile <<-G
source "file://#{gem_repo1}"
@@ -81,7 +80,7 @@ RSpec.describe "bundle clean" do
gem "foo"
G
- bundle "install --path vendor/bundle --no-clean"
+ bundle! "install", forgotten_command_line_options(:path => "vendor/bundle", :clean => false)
gemfile <<-G
source "file://#{gem_repo1}"
@@ -89,9 +88,9 @@ RSpec.describe "bundle clean" do
gem "rack", "0.9.1"
gem "foo"
G
- bundle "install"
+ bundle! "update rack"
- bundle :clean
+ bundle! :clean
expect(out).to include("Removing rack (1.0.0)")
@@ -112,8 +111,8 @@ RSpec.describe "bundle clean" do
end
G
- bundle "install --path vendor/bundle"
- bundle "install --without test_group"
+ bundle "install", forgotten_command_line_options(:path => "vendor/bundle")
+ bundle "install", forgotten_command_line_options(:without => "test_group")
bundle :clean
expect(out).to include("Removing rack (1.0.0)")
@@ -138,12 +137,13 @@ RSpec.describe "bundle clean" do
end
G
- bundle "install --path vendor/bundle"
+ bundle "install", forgotten_command_line_options(:path => "vendor/bundle")
bundle :clean
- digest = Digest::SHA1.hexdigest(git_path.to_s)
- expect(vendored_gems("cache/bundler/git/foo-1.0-#{digest}")).to exist
+ digest = Digest(:SHA1).hexdigest(git_path.to_s)
+ cache_path = Bundler::VERSION.start_with?("1.") ? vendored_gems("cache/bundler/git/foo-1.0-#{digest}") : home(".bundle/cache/git/foo-1.0-#{digest}")
+ expect(cache_path).to exist
end
it "removes unused git gems" do
@@ -160,7 +160,7 @@ RSpec.describe "bundle clean" do
end
G
- bundle "install --path vendor/bundle"
+ bundle "install", forgotten_command_line_options(:path => "vendor/bundle")
gemfile <<-G
source "file://#{gem_repo1}"
@@ -175,7 +175,7 @@ RSpec.describe "bundle clean" do
expect(vendored_gems("gems/rack-1.0.0")).to exist
expect(vendored_gems("bundler/gems/foo-#{revision[0..11]}")).not_to exist
- digest = Digest::SHA1.hexdigest(git_path.to_s)
+ digest = Digest(:SHA1).hexdigest(git_path.to_s)
expect(vendored_gems("cache/bundler/git/foo-#{digest}")).not_to exist
expect(vendored_gems("specifications/rack-1.0.0.gemspec")).to exist
@@ -196,13 +196,13 @@ RSpec.describe "bundle clean" do
end
G
- bundle "install --path vendor/bundle"
+ bundle! "install", forgotten_command_line_options(:path => "vendor/bundle")
update_git "foo", :path => lib_path("foo-bar")
revision2 = revision_for(lib_path("foo-bar"))
- bundle "update"
- bundle :clean
+ bundle! "update", :all => bundle_update_requires_all?
+ bundle! :clean
expect(out).to include("Removing foo-bar (#{revision[0..11]})")
@@ -226,7 +226,7 @@ RSpec.describe "bundle clean" do
gem "activesupport", :git => "#{lib_path("rails")}", :ref => '#{revision}'
G
- bundle "install --path vendor/bundle"
+ bundle "install", forgotten_command_line_options(:path => "vendor/bundle")
bundle :clean
expect(out).to include("")
@@ -248,13 +248,13 @@ RSpec.describe "bundle clean" do
end
end
G
- bundle "install --path vendor/bundle --without test"
+ bundle "install", forgotten_command_line_options(:path => "vendor/bundle", :without => "test")
bundle :clean
expect(out).to include("")
expect(vendored_gems("bundler/gems/foo-#{revision[0..11]}")).to exist
- digest = Digest::SHA1.hexdigest(git_path.to_s)
+ digest = Digest(:SHA1).hexdigest(git_path.to_s)
expect(vendored_gems("cache/bundler/git/foo-#{digest}")).to_not exist
end
@@ -269,13 +269,14 @@ RSpec.describe "bundle clean" do
end
G
- bundle "install --path vendor/bundle --without development"
+ bundle "install", forgotten_command_line_options(:path => "vendor/bundle", :without => "development")
bundle :clean
expect(exitstatus).to eq(0) if exitstatus
end
it "displays an error when used without --path" do
+ bundle! "config path.system true"
install_gemfile <<-G
source "file://#{gem_repo1}"
@@ -284,7 +285,7 @@ RSpec.describe "bundle clean" do
bundle :clean
- expect(exitstatus).to eq(1) if exitstatus
+ expect(exitstatus).to eq(15) if exitstatus
expect(out).to include("--force")
end
@@ -297,7 +298,7 @@ RSpec.describe "bundle clean" do
gem "foo"
G
- bundle "install --path vendor/bundle"
+ bundle "install", forgotten_command_line_options(:path => "vendor/bundle")
gemfile <<-G
source "file://#{gem_repo1}"
@@ -319,34 +320,37 @@ RSpec.describe "bundle clean" do
end
it "does not call clean automatically when using system gems" do
- gemfile <<-G
+ bundle! "config path.system true"
+
+ bundle! :config
+
+ install_gemfile! <<-G
source "file://#{gem_repo1}"
gem "thin"
gem "rack"
G
- bundle :install
- gemfile <<-G
+ bundle! "info thin"
+
+ install_gemfile! <<-G
source "file://#{gem_repo1}"
gem "rack"
G
- bundle :install
- sys_exec "gem list"
- expect(out).to include("rack (1.0.0)")
- expect(out).to include("thin (1.0)")
+ sys_exec! "gem list"
+ expect(out).to include("rack (1.0.0)").and include("thin (1.0)")
end
- it "--clean should override the bundle setting on install" do
+ it "--clean should override the bundle setting on install", :bundler => "< 2" do
gemfile <<-G
source "file://#{gem_repo1}"
gem "thin"
gem "rack"
G
- bundle "install --path vendor/bundle --clean"
+ bundle "install", forgotten_command_line_options(:path => "vendor/bundle", :clean => true)
gemfile <<-G
source "file://#{gem_repo1}"
@@ -359,7 +363,7 @@ RSpec.describe "bundle clean" do
should_not_have_gems "thin-1.0"
end
- it "--clean should override the bundle setting on update" do
+ it "--clean should override the bundle setting on update", :bundler => "< 2" do
build_repo2
gemfile <<-G
@@ -367,18 +371,42 @@ RSpec.describe "bundle clean" do
gem "foo"
G
- bundle "install --path vendor/bundle --clean"
+ bundle! "install", forgotten_command_line_options(:path => "vendor/bundle", :clean => true)
update_repo2 do
build_gem "foo", "1.0.1"
end
- bundle "update"
+ bundle! "update", :all => bundle_update_requires_all?
should_have_gems "foo-1.0.1"
should_not_have_gems "foo-1.0"
end
+ it "automatically cleans when path has not been set", :bundler => "2" do
+ build_repo2
+
+ install_gemfile! <<-G
+ source "file://#{gem_repo2}"
+
+ gem "foo"
+ G
+
+ update_repo2 do
+ build_gem "foo", "1.0.1"
+ end
+
+ bundle! "update", :all => true
+
+ files = Pathname.glob(bundled_app(".bundle", Bundler.ruby_scope, "*", "*"))
+ files.map! {|f| f.to_s.sub(bundled_app(".bundle", Bundler.ruby_scope).to_s, "") }
+ expect(files.sort).to eq %w[
+ /cache/foo-1.0.1.gem
+ /gems/foo-1.0.1
+ /specifications/foo-1.0.1.gemspec
+ ]
+ end
+
it "does not clean automatically on --path" do
gemfile <<-G
source "file://#{gem_repo1}"
@@ -386,7 +414,7 @@ RSpec.describe "bundle clean" do
gem "thin"
gem "rack"
G
- bundle "install --path vendor/bundle"
+ bundle "install", forgotten_command_line_options(:path => "vendor/bundle")
gemfile <<-G
source "file://#{gem_repo1}"
@@ -406,17 +434,19 @@ RSpec.describe "bundle clean" do
gem "foo"
G
- bundle "install --path vendor/bundle"
+ bundle! "install", forgotten_command_line_options(:path => "vendor/bundle")
update_repo2 do
build_gem "foo", "1.0.1"
end
- bundle :update
+ bundle! :update, :all => bundle_update_requires_all?
should_have_gems "foo-1.0", "foo-1.0.1"
end
it "does not clean on bundle update when using --system" do
+ bundle! "config path.system true"
+
build_repo2
gemfile <<-G
@@ -424,18 +454,20 @@ RSpec.describe "bundle clean" do
gem "foo"
G
- bundle "install"
+ bundle! "install"
update_repo2 do
build_gem "foo", "1.0.1"
end
- bundle :update
+ bundle! :update, :all => bundle_update_requires_all?
- sys_exec "gem list"
+ sys_exec! "gem list"
expect(out).to include("foo (1.0.1, 1.0)")
end
it "cleans system gems when --force is used" do
+ bundle! "config path.system true"
+
gemfile <<-G
source "file://#{gem_repo1}"
@@ -459,8 +491,10 @@ RSpec.describe "bundle clean" do
end
describe "when missing permissions" do
+ before { ENV["BUNDLE_PATH__SYSTEM"] = "true" }
+ let(:system_cache_path) { system_gem_path("cache") }
after do
- FileUtils.chmod(0o755, default_bundle_path("cache"))
+ FileUtils.chmod(0o755, system_cache_path)
end
it "returns a helpful error message" do
gemfile <<-G
@@ -478,7 +512,6 @@ RSpec.describe "bundle clean" do
G
bundle :install
- system_cache_path = default_bundle_path("cache")
FileUtils.chmod(0o500, system_cache_path)
bundle :clean, :force => true
@@ -502,7 +535,7 @@ RSpec.describe "bundle clean" do
gem "foo", :git => "#{lib_path("foo-1.0")}"
G
- bundle "install --path vendor/bundle"
+ bundle "install", forgotten_command_line_options(:path => "vendor/bundle")
# mimic 7 length git revisions in Gemfile.lock
gemfile_lock = File.read(bundled_app("Gemfile.lock")).split("\n")
@@ -513,7 +546,7 @@ RSpec.describe "bundle clean" do
file.print gemfile_lock.join("\n")
end
- bundle "install --path vendor/bundle"
+ bundle "install", forgotten_command_line_options(:path => "vendor/bundle")
bundle :clean
@@ -523,6 +556,8 @@ RSpec.describe "bundle clean" do
end
it "when using --force on system gems, it doesn't remove binaries" do
+ bundle! "config path.system true"
+
build_repo2
update_repo2 do
build_gem "bindir" do |s|
@@ -561,10 +596,8 @@ RSpec.describe "bundle clean" do
gem "bar", "1.0", :path => "#{relative_path}"
G
- bundle "install --path vendor/bundle"
- bundle :clean
-
- expect(exitstatus).to eq(0) if exitstatus
+ bundle "install", forgotten_command_line_options(:path => "vendor/bundle")
+ bundle! :clean
end
it "doesn't remove gems in dry-run mode with path set" do
@@ -575,7 +608,7 @@ RSpec.describe "bundle clean" do
gem "foo"
G
- bundle "install --path vendor/bundle --no-clean"
+ bundle "install", forgotten_command_line_options(:path => "vendor/bundle", :clean => false)
gemfile <<-G
source "file://#{gem_repo1}"
@@ -603,7 +636,7 @@ RSpec.describe "bundle clean" do
gem "foo"
G
- bundle "install --path vendor/bundle --no-clean"
+ bundle "install", forgotten_command_line_options(:path => "vendor/bundle", :clean => false)
gemfile <<-G
source "file://#{gem_repo1}"
@@ -633,7 +666,7 @@ RSpec.describe "bundle clean" do
gem "foo"
G
- bundle "install --path vendor/bundle --no-clean"
+ bundle "install", forgotten_command_line_options(:path => "vendor/bundle", :clean => false)
bundle "config dry_run false"
gemfile <<-G
@@ -663,7 +696,7 @@ RSpec.describe "bundle clean" do
gem "foo"
G
- bundle "install --path vendor/bundle --no-clean"
+ bundle! "install", forgotten_command_line_options(:path => "vendor/bundle", :clean => false)
gemfile <<-G
source "file://#{gem_repo1}"
@@ -672,8 +705,8 @@ RSpec.describe "bundle clean" do
gem "weakling"
G
- bundle "config auto_install 1"
- bundle :clean
+ bundle! "config auto_install 1"
+ bundle! :clean
expect(out).to include("Installing weakling 0.0.3")
should_have_gems "thin-1.0", "rack-1.0.0", "weakling-0.0.3"
should_not_have_gems "foo-1.0"
@@ -690,7 +723,7 @@ RSpec.describe "bundle clean" do
gem "very_simple_git_binary", :git => "#{lib_path("very_simple_git_binary-1.0")}", :ref => "#{revision}"
G
- bundle! "install --path vendor/bundle"
+ bundle! "install", forgotten_command_line_options(:path => "vendor/bundle")
expect(vendored_gems("bundler/gems/extensions")).to exist
expect(vendored_gems("bundler/gems/very_simple_git_binary-1.0-#{revision[0..11]}")).to exist
diff --git a/spec/bundler/commands/config_spec.rb b/spec/bundler/commands/config_spec.rb
index a3ca696ec1..9e49357465 100644
--- a/spec/bundler/commands/config_spec.rb
+++ b/spec/bundler/commands/config_spec.rb
@@ -1,5 +1,4 @@
# frozen_string_literal: true
-require "spec_helper"
RSpec.describe ".bundle/config" do
before :each do
@@ -46,7 +45,7 @@ RSpec.describe ".bundle/config" do
describe "BUNDLE_APP_CONFIG" do
it "can be moved with an environment variable" do
ENV["BUNDLE_APP_CONFIG"] = tmp("foo/bar").to_s
- bundle "install --path vendor/bundle"
+ bundle "install", forgotten_command_line_options(:path => "vendor/bundle")
expect(bundled_app(".bundle")).not_to exist
expect(tmp("foo/bar/config")).to exist
@@ -58,7 +57,7 @@ RSpec.describe ".bundle/config" do
Dir.chdir bundled_app("omg")
ENV["BUNDLE_APP_CONFIG"] = "../foo"
- bundle "install --path vendor/bundle"
+ bundle "install", forgotten_command_line_options(:path => "vendor/bundle")
expect(bundled_app(".bundle")).not_to exist
expect(bundled_app("../foo/config")).to exist
@@ -267,7 +266,7 @@ RSpec.describe ".bundle/config" do
expect(out).to eq "bar=value"
end
- it "preferes local config over global" do
+ it "prefers local config over global" do
bundle "config --local bar value2"
bundle "config --global bar value"
bundle "config bar --parseable"
diff --git a/spec/bundler/commands/console_spec.rb b/spec/bundler/commands/console_spec.rb
index de14b6db5f..9bf66e8f5b 100644
--- a/spec/bundler/commands/console_spec.rb
+++ b/spec/bundler/commands/console_spec.rb
@@ -1,7 +1,6 @@
# frozen_string_literal: true
-require "spec_helper"
-RSpec.describe "bundle console" do
+RSpec.describe "bundle console", :bundler => "< 2" do
before :each do
install_gemfile <<-G
source "file://#{gem_repo1}"
diff --git a/spec/bundler/commands/doctor_spec.rb b/spec/bundler/commands/doctor_spec.rb
index 7c6e48ce19..2572d4ff4d 100644
--- a/spec/bundler/commands/doctor_spec.rb
+++ b/spec/bundler/commands/doctor_spec.rb
@@ -1,5 +1,5 @@
# frozen_string_literal: true
-require "spec_helper"
+
require "stringio"
require "bundler/cli"
require "bundler/cli/doctor"
@@ -17,45 +17,42 @@ RSpec.describe "bundle doctor" do
end
it "exits with no message if the installed gem has no C extensions" do
- gemfile <<-G
+ install_gemfile! <<-G
source "file://#{gem_repo1}"
gem "rack"
G
- bundle :install
- Bundler::CLI::Doctor.new({}).run
+ expect { Bundler::CLI::Doctor.new({}).run }.not_to raise_error
expect(@stdout.string).to be_empty
end
it "exits with no message if the installed gem's C extension dylib breakage is fine" do
- gemfile <<-G
+ install_gemfile! <<-G
source "file://#{gem_repo1}"
gem "rack"
G
- bundle :install
doctor = Bundler::CLI::Doctor.new({})
expect(doctor).to receive(:bundles_for_gem).exactly(2).times.and_return ["/path/to/rack/rack.bundle"]
expect(doctor).to receive(:dylibs).exactly(2).times.and_return ["/usr/lib/libSystem.dylib"]
allow(File).to receive(:exist?).and_call_original
allow(File).to receive(:exist?).with("/usr/lib/libSystem.dylib").and_return(true)
- doctor.run
+ expect { doctor.run }.not_to(raise_error, @stdout.string)
expect(@stdout.string).to be_empty
end
it "exits with a message if one of the linked libraries is missing" do
- gemfile <<-G
+ install_gemfile! <<-G
source "file://#{gem_repo1}"
gem "rack"
G
- bundle :install
doctor = Bundler::CLI::Doctor.new({})
expect(doctor).to receive(:bundles_for_gem).exactly(2).times.and_return ["/path/to/rack/rack.bundle"]
expect(doctor).to receive(:dylibs).exactly(2).times.and_return ["/usr/local/opt/icu4c/lib/libicui18n.57.1.dylib"]
allow(File).to receive(:exist?).and_call_original
allow(File).to receive(:exist?).with("/usr/local/opt/icu4c/lib/libicui18n.57.1.dylib").and_return(false)
- expect { doctor.run }.to raise_error Bundler::ProductionError, strip_whitespace(<<-E).strip
+ expect { doctor.run }.to raise_error(Bundler::ProductionError, strip_whitespace(<<-E).strip), @stdout.string
The following gems are missing OS dependencies:
* bundler: /usr/local/opt/icu4c/lib/libicui18n.57.1.dylib
* rack: /usr/local/opt/icu4c/lib/libicui18n.57.1.dylib
diff --git a/spec/bundler/commands/exec_spec.rb b/spec/bundler/commands/exec_spec.rb
index 7736adefe1..077e1b03a2 100644
--- a/spec/bundler/commands/exec_spec.rb
+++ b/spec/bundler/commands/exec_spec.rb
@@ -1,10 +1,9 @@
# frozen_string_literal: true
-require "spec_helper"
RSpec.describe "bundle exec" do
- let(:system_gems_to_install) { %w(rack-1.0.0 rack-0.9.1) }
+ let(:system_gems_to_install) { %w[rack-1.0.0 rack-0.9.1] }
before :each do
- system_gems(system_gems_to_install)
+ system_gems(system_gems_to_install, :path => :bundle_path)
end
it "activates the correct gem" do
@@ -138,7 +137,7 @@ RSpec.describe "bundle exec" do
end
it "handles gems installed with --without" do
- install_gemfile <<-G, :without => :middleware
+ install_gemfile <<-G, forgotten_command_line_options(:without => "middleware")
source "file://#{gem_repo1}"
gem "rack" # rack 0.9.1 and 1.0 exist
@@ -217,6 +216,7 @@ RSpec.describe "bundle exec" do
end
it "raises a helpful error when exec'ing to something outside of the bundle", :ruby_repo, :rubygems => ">= 2.5.2" do
+ bundle! "config clean false" # want to keep the rackup binstub
install_gemfile! <<-G
source "file://#{gem_repo1}"
gem "with_license"
@@ -224,7 +224,7 @@ RSpec.describe "bundle exec" do
[true, false].each do |l|
bundle! "config disable_exec_load #{l}"
bundle "exec rackup"
- expect(err).to include "can't find executable rackup for gem rack. rack is not currently included in the bundle, perhaps you meant to add it to your Gemfile?"
+ expect(last_command.stderr).to include "can't find executable rackup for gem rack. rack is not currently included in the bundle, perhaps you meant to add it to your Gemfile?"
end
end
@@ -238,7 +238,7 @@ RSpec.describe "bundle exec" do
[true, false].each do |l|
bundle! "config disable_exec_load #{l}"
bundle "exec rackup"
- expect(err).to include "rack is not part of the bundle. Add it to your Gemfile."
+ expect(last_command.stderr).to include "rack is not part of the bundle. Add it to your Gemfile."
end
end
@@ -518,8 +518,8 @@ RSpec.describe "bundle exec" do
it "like a normally executed executable" do
subject
expect(exitstatus).to eq(exit_code) if exitstatus
- expect(err).to eq(expected_err)
- expect(out).to eq(expected)
+ expect(last_command.stderr).to eq(expected_err)
+ expect(last_command.stdout).to eq(expected)
end
end
@@ -538,7 +538,27 @@ RSpec.describe "bundle exec" do
end
end
- context "the executable is empty" do
+ context "the executable exits by SignalException" do
+ let(:executable) do
+ ex = super()
+ ex << "\n"
+ if LessThanProc.with(RUBY_VERSION).call("1.9")
+ # Ruby < 1.9 needs a flush for a exit by signal, later
+ # rubies do not
+ ex << "STDOUT.flush\n"
+ end
+ ex << "raise SignalException, 'SIGTERM'\n"
+ ex
+ end
+ let(:exit_code) do
+ # signal mask 128 + plus signal 15 -> TERM
+ # this is specified by C99
+ 128 + 15
+ end
+ it_behaves_like "it runs"
+ end
+
+ context "the executable is empty", :bundler => "< 2" do
let(:executable) { "" }
let(:exit_code) { 0 }
@@ -553,7 +573,16 @@ RSpec.describe "bundle exec" do
end
end
- context "the executable raises" do
+ context "the executable is empty", :bundler => "2" do
+ let(:executable) { "" }
+
+ let(:exit_code) { 0 }
+ let(:expected_err) { "#{path} is empty" }
+ let(:expected) { "" }
+ it_behaves_like "it runs"
+ end
+
+ context "the executable raises", :bundler => "< 2" do
let(:executable) { super() << "\nraise 'ERROR'" }
let(:exit_code) { 1 }
let(:expected) { super() << "\nbundler: failed to load command: #{path} (#{path})" }
@@ -564,12 +593,22 @@ RSpec.describe "bundle exec" do
it_behaves_like "it runs"
end
+ context "the executable raises", :bundler => "2" do
+ let(:executable) { super() << "\nraise 'ERROR'" }
+ let(:exit_code) { 1 }
+ let(:expected_err) do
+ "bundler: failed to load command: #{path} (#{path})" \
+ "\nRuntimeError: ERROR\n #{path}:10:in `<top (required)>'"
+ end
+ it_behaves_like "it runs"
+ end
+
context "when the file uses the current ruby shebang", :ruby_repo do
let(:shebang) { "#!#{Gem.ruby}" }
it_behaves_like "it runs"
end
- context "when Bundler.setup fails" do
+ context "when Bundler.setup fails", :bundler => "< 2" do
before do
gemfile <<-G
gem 'rack', '2'
@@ -586,6 +625,24 @@ RSpec.describe "bundle exec" do
it_behaves_like "it runs"
end
+ context "when Bundler.setup fails", :bundler => "2" do
+ before do
+ gemfile <<-G
+ gem 'rack', '2'
+ G
+ ENV["BUNDLER_FORCE_TTY"] = "true"
+ end
+
+ let(:exit_code) { Bundler::GemNotFound.new.status_code }
+ let(:expected) { <<-EOS.strip }
+\e[31mCould not find gem 'rack (= 2)' in locally installed gems.
+The source contains 'rack' at: 1.0.0\e[0m
+\e[33mRun `bundle install` to install missing gems.\e[0m
+ EOS
+
+ it_behaves_like "it runs"
+ end
+
context "when the executable exits non-zero via at_exit" do
let(:executable) { super() + "\n\nat_exit { $! ? raise($!) : exit(1) }" }
let(:exit_code) { 1 }
@@ -729,7 +786,7 @@ __FILE__: #{path.to_s.inspect}
# sanity check that we get the newer, custom version without bundler
sys_exec("#{Gem.ruby} #{file}")
- expect(err).to include("custom openssl should not be loaded")
+ expect(last_command.stderr).to include("custom openssl should not be loaded")
end
end
end
diff --git a/spec/bundler/commands/help_spec.rb b/spec/bundler/commands/help_spec.rb
index 6faeed058e..cd6f13756c 100644
--- a/spec/bundler/commands/help_spec.rb
+++ b/spec/bundler/commands/help_spec.rb
@@ -1,8 +1,7 @@
# frozen_string_literal: true
-require "spec_helper"
RSpec.describe "bundle help" do
- # Rubygems 1.4+ no longer load gem plugins so this test is no longer needed
+ # RubyGems 1.4+ no longer load gem plugins so this test is no longer needed
it "complains if older versions of bundler are installed", :rubygems => "< 1.4" do
system_gems "bundler-0.8.1"
diff --git a/spec/bundler/commands/info_spec.rb b/spec/bundler/commands/info_spec.rb
index cdfea983dc..a9ab8fc210 100644
--- a/spec/bundler/commands/info_spec.rb
+++ b/spec/bundler/commands/info_spec.rb
@@ -1,5 +1,4 @@
# frozen_string_literal: true
-require "spec_helper"
RSpec.describe "bundle info" do
context "info from specific gem in gemfile" do
diff --git a/spec/bundler/commands/init_spec.rb b/spec/bundler/commands/init_spec.rb
index 6ab7e25cc3..0441e62e13 100644
--- a/spec/bundler/commands/init_spec.rb
+++ b/spec/bundler/commands/init_spec.rb
@@ -1,10 +1,16 @@
# frozen_string_literal: true
-require "spec_helper"
RSpec.describe "bundle init" do
- it "generates a Gemfile" do
- bundle :init
- expect(bundled_app("Gemfile")).to exist
+ it "generates a Gemfile", :bundler => "< 2" do
+ bundle! :init
+ expect(out).to include("Writing new Gemfile")
+ expect(bundled_app("Gemfile")).to be_file
+ end
+
+ it "generates a gems.rb", :bundler => "2" do
+ bundle! :init
+ expect(out).to include("Writing new gems.rb")
+ expect(bundled_app("gems.rb")).to be_file
end
context "when a Gemfile already exists" do
@@ -24,7 +30,24 @@ RSpec.describe "bundle init" do
end
end
- context "given --gemspec option" do
+ context "when a gems.rb already exists" do
+ before do
+ create_file "gems.rb", <<-G
+ gem "rails"
+ G
+ end
+
+ it "does not change existing gem.rb files" do
+ expect { bundle :init }.not_to change { File.read(bundled_app("gems.rb")) }
+ end
+
+ it "notifies the user that an existing gems.rb already exists" do
+ bundle :init
+ expect(out).to include("gems.rb already exists")
+ end
+ end
+
+ context "given --gemspec option", :bundler => "< 2" do
let(:spec_file) { tmp.join("test.gemspec") }
it "should generate from an existing gemspec" do
@@ -40,7 +63,11 @@ RSpec.describe "bundle init" do
bundle :init, :gemspec => spec_file
- gemfile = bundled_app("Gemfile").read
+ gemfile = if Bundler::VERSION[0, 2] == "1."
+ bundled_app("Gemfile").read
+ else
+ bundled_app("gems.rb").read
+ end
expect(gemfile).to match(%r{source 'https://rubygems.org'})
expect(gemfile.scan(/gem "rack", "= 1.0.1"/).size).to eq(1)
expect(gemfile.scan(/gem "rspec", "= 1.2"/).size).to eq(1)
@@ -59,7 +86,65 @@ RSpec.describe "bundle init" do
end
bundle :init, :gemspec => spec_file
- expect(out).to include("There was an error while loading `test.gemspec`")
+ expect(last_command.bundler_err).to include("There was an error while loading `test.gemspec`")
+ end
+ end
+ end
+
+ context "when init_gems_rb setting is enabled" do
+ before { bundle "config init_gems_rb true" }
+
+ it "generates a gems.rb file" do
+ bundle :init
+ expect(bundled_app("gems.rb")).to exist
+ end
+
+ context "when gems.rb already exists" do
+ before do
+ create_file("gems.rb", <<-G)
+ gem "rails"
+ G
+ end
+
+ it "does not change existing Gemfiles" do
+ expect { bundle :init }.not_to change { File.read(bundled_app("gems.rb")) }
+ end
+
+ it "notifies the user that an existing gems.rb already exists" do
+ bundle :init
+ expect(out).to include("gems.rb already exists")
+ end
+ end
+
+ context "given --gemspec option", :bundler => "< 2" do
+ let(:spec_file) { tmp.join("test.gemspec") }
+
+ before do
+ File.open(spec_file, "w") do |file|
+ file << <<-S
+ Gem::Specification.new do |s|
+ s.name = 'test'
+ s.add_dependency 'rack', '= 1.0.1'
+ s.add_development_dependency 'rspec', '1.2'
+ end
+ S
+ end
+ end
+
+ it "should generate from an existing gemspec" do
+ bundle :init, :gemspec => spec_file
+
+ gemfile = bundled_app("gems.rb").read
+ expect(gemfile).to match(%r{source 'https://rubygems.org'})
+ expect(gemfile.scan(/gem "rack", "= 1.0.1"/).size).to eq(1)
+ expect(gemfile.scan(/gem "rspec", "= 1.2"/).size).to eq(1)
+ expect(gemfile.scan(/group :development/).size).to eq(1)
+ end
+
+ it "prints message to user" do
+ bundle :init, :gemspec => spec_file
+
+ expect(out).to include("Writing new gems.rb")
end
end
end
diff --git a/spec/bundler/commands/inject_spec.rb b/spec/bundler/commands/inject_spec.rb
index dd0f1348cc..6c1994b59d 100644
--- a/spec/bundler/commands/inject_spec.rb
+++ b/spec/bundler/commands/inject_spec.rb
@@ -1,7 +1,6 @@
# frozen_string_literal: true
-require "spec_helper"
-RSpec.describe "bundle inject" do
+RSpec.describe "bundle inject", :bundler => "< 2" do
before :each do
gemfile <<-G
source "file://#{gem_repo1}"
@@ -80,7 +79,11 @@ Usage: "bundle inject GEM VERSION"
context "when frozen" do
before do
bundle "install"
- bundle "config --local frozen 1"
+ if Bundler.feature_flag.bundler_2_mode?
+ bundle! "config --local deployment true"
+ else
+ bundle! "config --local frozen true"
+ end
end
it "injects anyway" do
@@ -97,7 +100,7 @@ Usage: "bundle inject GEM VERSION"
it "restores frozen afterwards" do
bundle "inject 'rack-obama' '> 0'"
config = YAML.load(bundled_app(".bundle/config").read)
- expect(config["BUNDLE_FROZEN"]).to eq("1")
+ expect(config["BUNDLE_DEPLOYMENT"] || config["BUNDLE_FROZEN"]).to eq("true")
end
it "doesn't allow Gemfile changes" do
diff --git a/spec/bundler/commands/install_spec.rb b/spec/bundler/commands/install_spec.rb
index 2d67a39f1e..4cb8584633 100644
--- a/spec/bundler/commands/install_spec.rb
+++ b/spec/bundler/commands/install_spec.rb
@@ -1,5 +1,4 @@
# frozen_string_literal: true
-require "spec_helper"
RSpec.describe "bundle install with gem sources" do
describe "the simple case" do
@@ -17,8 +16,7 @@ RSpec.describe "bundle install with gem sources" do
raise StandardError, "FAIL"
G
- expect(err).to lack_errors
- expect(out).to match(/StandardError, "FAIL"/)
+ expect(last_command.bundler_err).to include('StandardError, "FAIL"')
expect(bundled_app("Gemfile.lock")).not_to exist
end
@@ -31,13 +29,23 @@ RSpec.describe "bundle install with gem sources" do
expect(bundled_app("Gemfile.lock")).to exist
end
- it "does not create ./.bundle by default" do
+ it "does not create ./.bundle by default", :bundler => "< 2" do
gemfile <<-G
source "file://#{gem_repo1}"
gem "rack"
G
- bundle :install # can't use install_gemfile since it sets retry
+ bundle! :install # can't use install_gemfile since it sets retry
+ expect(bundled_app(".bundle")).not_to exist
+ end
+
+ it "does not create ./.bundle by default when installing to system gems" do
+ gemfile <<-G
+ source "file://#{gem_repo1}"
+ gem "rack"
+ G
+
+ bundle! :install, :env => { "BUNDLE_PATH__SYSTEM" => true } # can't use install_gemfile since it sets retry
expect(bundled_app(".bundle")).not_to exist
end
@@ -168,7 +176,7 @@ RSpec.describe "bundle install with gem sources" do
end
it "does not reinstall any gem that is already available locally" do
- system_gems "activesupport-2.3.2"
+ system_gems "activesupport-2.3.2", :path => :bundle_path
build_repo2 do
build_gem "activesupport", "2.3.2" do |s|
@@ -185,7 +193,7 @@ RSpec.describe "bundle install with gem sources" do
end
it "works when the gemfile specifies gems that only exist in the system" do
- build_gem "foo", :to_system => true
+ build_gem "foo", :to_bundle => true
install_gemfile <<-G
source "file://#{gem_repo1}"
gem "rack"
@@ -196,7 +204,7 @@ RSpec.describe "bundle install with gem sources" do
end
it "prioritizes local gems over remote gems" do
- build_gem "rack", "1.0.0", :to_system => true do |s|
+ build_gem "rack", "1.0.0", :to_bundle => true do |s|
s.add_dependency "activesupport", "2.3.5"
end
@@ -263,26 +271,26 @@ RSpec.describe "bundle install with gem sources" do
end
it "works" do
- bundle "install --path vendor"
+ bundle "install", forgotten_command_line_options(:path => "vendor")
expect(the_bundle).to include_gems "rack 1.0"
end
- it "allows running bundle install --system without deleting foo" do
- bundle "install --path vendor"
- bundle "install --system"
+ it "allows running bundle install --system without deleting foo", :bundler => "< 2" do
+ bundle "install", forgotten_command_line_options(:path => "vendor")
+ bundle "install", forgotten_command_line_options(:system => true)
FileUtils.rm_rf(bundled_app("vendor"))
expect(the_bundle).to include_gems "rack 1.0"
end
- it "allows running bundle install --system after deleting foo" do
- bundle "install --path vendor"
+ it "allows running bundle install --system after deleting foo", :bundler => "< 2" do
+ bundle "install", forgotten_command_line_options(:path => "vendor")
FileUtils.rm_rf(bundled_app("vendor"))
- bundle "install --system"
+ bundle "install", forgotten_command_line_options(:system => true)
expect(the_bundle).to include_gems "rack 1.0"
end
end
- it "finds gems in multiple sources" do
+ it "finds gems in multiple sources", :bundler => "< 2" do
build_repo2
update_repo2
@@ -316,9 +324,9 @@ RSpec.describe "bundle install with gem sources" do
it "gracefully handles error when rubygems server is unavailable" do
install_gemfile <<-G, :artifice => nil
source "file://#{gem_repo1}"
- source "http://localhost:9384"
-
- gem 'foo'
+ source "http://localhost:9384" do
+ gem 'foo'
+ end
G
bundle :install, :artifice => nil
@@ -345,9 +353,8 @@ RSpec.describe "bundle install with gem sources" do
gem "ajp-rails", "0.0.0"
G
- expect(out).not_to match(/Error Report/i)
- expect(err).not_to match(/Error Report/i)
- expect(out).to include("An error occurred while installing ajp-rails (0.0.0), and Bundler cannot continue.").
+ expect(last_command.stdboth).not_to match(/Error Report/i)
+ expect(last_command.bundler_err).to include("An error occurred while installing ajp-rails (0.0.0), and Bundler cannot continue.").
and include("Make sure that `gem install ajp-rails -v '0.0.0'` succeeds before bundling.")
end
@@ -382,10 +389,10 @@ RSpec.describe "bundle install with gem sources" do
context "and using an unsupported Ruby version" do
it "prints an error" do
install_gemfile <<-G
- ::RUBY_VERSION = '1.8.7'
- ruby '~> 2.1'
+ ::RUBY_VERSION = '2.0.1'
+ ruby '~> 2.2'
G
- expect(out).to include("Your Ruby version is 1.8.7, but your Gemfile specified ~> 2.1")
+ expect(out).to include("Your Ruby version is 2.0.1, but your Gemfile specified ~> 2.2")
end
end
@@ -404,7 +411,7 @@ RSpec.describe "bundle install with gem sources" do
specs:
PLATFORMS
- ruby
+ #{lockfile_platforms}
DEPENDENCIES
@@ -428,7 +435,7 @@ RSpec.describe "bundle install with gem sources" do
specs:
PLATFORMS
- ruby
+ #{lockfile_platforms}
DEPENDENCIES
@@ -489,17 +496,34 @@ RSpec.describe "bundle install with gem sources" do
it "should display a proper message to explain the problem" do
FileUtils.chmod(0o500, bundled_app("vendor"))
- bundle :install, :path => "vendor"
+ bundle :install, forgotten_command_line_options(:path => "vendor")
expect(out).to include(bundled_app("vendor").to_s)
expect(out).to include("grant write permissions")
end
end
+ context "after installing with --standalone" do
+ before do
+ install_gemfile! <<-G
+ source "file://#{gem_repo1}"
+ gem "rack"
+ G
+ forgotten_command_line_options(:path => "bundle")
+ bundle! "install", :standalone => true
+ end
+
+ it "includes the standalone path" do
+ bundle! "binstubs rack", :standalone => true
+ standalone_line = File.read(bundled_app("bin/rackup")).each_line.find {|line| line.include? "$:.unshift" }.strip
+ expect(standalone_line).to eq %($:.unshift File.expand_path "../../bundle", path.realpath)
+ end
+ end
+
describe "when bundle install is executed with unencoded authentication" do
before do
gemfile <<-G
source 'https://rubygems.org/'
- gem 'bundler'
+ gem "."
G
end
diff --git a/spec/bundler/commands/issue_spec.rb b/spec/bundler/commands/issue_spec.rb
index 056ef0f300..04c575130e 100644
--- a/spec/bundler/commands/issue_spec.rb
+++ b/spec/bundler/commands/issue_spec.rb
@@ -1,5 +1,4 @@
# frozen_string_literal: true
-require "spec_helper"
RSpec.describe "bundle issue" do
it "exits with a message" do
diff --git a/spec/bundler/commands/licenses_spec.rb b/spec/bundler/commands/licenses_spec.rb
index 0ee1a46945..144931fb27 100644
--- a/spec/bundler/commands/licenses_spec.rb
+++ b/spec/bundler/commands/licenses_spec.rb
@@ -1,5 +1,4 @@
# frozen_string_literal: true
-require "spec_helper"
RSpec.describe "bundle licenses" do
before :each do
diff --git a/spec/bundler/commands/list_spec.rb b/spec/bundler/commands/list_spec.rb
new file mode 100644
index 0000000000..0ea70f015c
--- /dev/null
+++ b/spec/bundler/commands/list_spec.rb
@@ -0,0 +1,40 @@
+# frozen_string_literal: true
+
+RSpec.describe "bundle list", :bundler => "2" do
+ before do
+ install_gemfile <<-G
+ source "file://#{gem_repo1}"
+ gem "rack"
+ G
+ end
+
+ context "with name-only option" do
+ it "prints only the name of the gems in the bundle" do
+ bundle "list --name-only"
+ expect(out).to eq "rack"
+ end
+ end
+
+ context "when no gems are in the gemfile" do
+ before do
+ install_gemfile <<-G
+ source "file://#{gem_repo1}"
+ G
+ end
+
+ it "prints message saying no gems are in the bundle" do
+ bundle "list"
+ expect(out).to include("No gems in the Gemfile")
+ end
+ end
+
+ it "lists gems installed in the bundle" do
+ bundle "list"
+ expect(out).to include(" * rack (1.0.0)")
+ end
+
+ it "aliases the ls command to list" do
+ bundle "ls"
+ expect(out).to include("Gems included by the bundle")
+ end
+end
diff --git a/spec/bundler/commands/lock_spec.rb b/spec/bundler/commands/lock_spec.rb
index 5c15b6a7f6..b16a828cad 100644
--- a/spec/bundler/commands/lock_spec.rb
+++ b/spec/bundler/commands/lock_spec.rb
@@ -1,5 +1,4 @@
# frozen_string_literal: true
-require "spec_helper"
RSpec.describe "bundle lock" do
def strip_lockfile(lockfile)
@@ -44,7 +43,7 @@ RSpec.describe "bundle lock" do
with_license (1.0)
PLATFORMS
- #{local}
+ #{lockfile_platforms}
DEPENDENCIES
foo
@@ -59,7 +58,7 @@ RSpec.describe "bundle lock" do
it "prints a lockfile when there is no existing lockfile with --print" do
bundle "lock --print"
- expect(out).to include(@lockfile)
+ expect(out).to eq(@lockfile)
end
it "prints a lockfile when there is an existing lockfile with --print" do
@@ -87,7 +86,7 @@ RSpec.describe "bundle lock" do
it "does not fetch remote specs when using the --local option" do
bundle "lock --update --local"
- expect(out).to include("sources listed in your Gemfile")
+ expect(out).to match(/sources listed in your Gemfile|installed locally/)
end
it "writes to a custom location using --lockfile" do
@@ -120,17 +119,17 @@ RSpec.describe "bundle lock" do
context "conservative updates" do
before do
build_repo4 do
- build_gem "foo", %w(1.4.3 1.4.4) do |s|
+ build_gem "foo", %w[1.4.3 1.4.4] do |s|
s.add_dependency "bar", "~> 2.0"
end
- build_gem "foo", %w(1.4.5 1.5.0) do |s|
+ build_gem "foo", %w[1.4.5 1.5.0] do |s|
s.add_dependency "bar", "~> 2.1"
end
- build_gem "foo", %w(1.5.1) do |s|
+ build_gem "foo", %w[1.5.1] do |s|
s.add_dependency "bar", "~> 3.0"
end
- build_gem "bar", %w(2.0.3 2.0.4 2.0.5 2.1.0 2.1.1 3.0.0)
- build_gem "qux", %w(1.0.0 1.0.1 1.1.0 2.0.0)
+ build_gem "bar", %w[2.0.3 2.0.4 2.0.5 2.1.0 2.1.1 3.0.0]
+ build_gem "qux", %w[1.0.0 1.0.1 1.1.0 2.0.0]
end
# establish a lockfile set to 1.4.3
@@ -153,13 +152,13 @@ RSpec.describe "bundle lock" do
it "single gem updates dependent gem to minor" do
bundle "lock --update foo --patch"
- expect(the_bundle.locked_gems.specs.map(&:full_name)).to eq(%w(foo-1.4.5 bar-2.1.1 qux-1.0.0).sort)
+ expect(the_bundle.locked_gems.specs.map(&:full_name)).to eq(%w[foo-1.4.5 bar-2.1.1 qux-1.0.0].sort)
end
it "minor preferred with strict" do
bundle "lock --update --minor --strict"
- expect(the_bundle.locked_gems.specs.map(&:full_name)).to eq(%w(foo-1.5.0 bar-2.1.1 qux-1.1.0).sort)
+ expect(the_bundle.locked_gems.specs.map(&:full_name)).to eq(%w[foo-1.5.0 bar-2.1.1 qux-1.1.0].sort)
end
end
@@ -167,13 +166,13 @@ RSpec.describe "bundle lock" do
bundle! "lock --add-platform java x86-mingw32"
lockfile = Bundler::LockfileParser.new(read_lockfile)
- expect(lockfile.platforms).to eq([java, local, mingw])
+ expect(lockfile.platforms).to match_array(local_platforms.unshift(java, mingw).uniq)
end
it "supports adding the `ruby` platform" do
bundle! "lock --add-platform ruby"
lockfile = Bundler::LockfileParser.new(read_lockfile)
- expect(lockfile.platforms).to eq([local, "ruby"].uniq)
+ expect(lockfile.platforms).to match_array(local_platforms.unshift("ruby").uniq)
end
it "warns when adding an unknown platform" do
@@ -185,17 +184,17 @@ RSpec.describe "bundle lock" do
bundle! "lock --add-platform java x86-mingw32"
lockfile = Bundler::LockfileParser.new(read_lockfile)
- expect(lockfile.platforms).to eq([java, local, mingw])
+ expect(lockfile.platforms).to match_array(local_platforms.unshift(java, mingw).uniq)
bundle! "lock --remove-platform java"
lockfile = Bundler::LockfileParser.new(read_lockfile)
- expect(lockfile.platforms).to eq([local, mingw])
+ expect(lockfile.platforms).to match_array(local_platforms.unshift(mingw).uniq)
end
it "errors when removing all platforms" do
- bundle "lock --remove-platform #{local}"
- expect(out).to include("Removing all platforms from the bundle is not allowed")
+ bundle "lock --remove-platform #{local_platforms.join(" ")}"
+ expect(last_command.bundler_err).to include("Removing all platforms from the bundle is not allowed")
end
# from https://github.com/bundler/bundler/issues/4896
@@ -221,7 +220,7 @@ RSpec.describe "bundle lock" do
# we need all these versions to get the sorting the same as it would be
# pulling from rubygems.org
- %w(0.8.3 0.8.2 0.8.1 0.8.0).each do |v|
+ %w[0.8.3 0.8.2 0.8.1 0.8.0].each do |v|
build_gem "win32-process", v do |s|
s.add_dependency "ffi", ">= 1.0.0"
end
diff --git a/spec/bundler/commands/newgem_spec.rb b/spec/bundler/commands/newgem_spec.rb
index e9c19005eb..dcd89391a4 100644
--- a/spec/bundler/commands/newgem_spec.rb
+++ b/spec/bundler/commands/newgem_spec.rb
@@ -1,5 +1,4 @@
# frozen_string_literal: true
-require "spec_helper"
RSpec.describe "bundle gem" do
def reset!
@@ -166,10 +165,10 @@ RSpec.describe "bundle gem" do
expect(bundled_app("test_gem/.git")).to exist
end
- context "when git is not avaiable" do
+ context "when git is not available" do
let(:gem_name) { "test_gem" }
- # This spec cannot have `git` avaiable in the test env
+ # This spec cannot have `git` available in the test env
before do
load_paths = [lib, spec]
load_path_str = "-I#{load_paths.join(File::PATH_SEPARATOR)}"
@@ -191,8 +190,6 @@ RSpec.describe "bundle gem" do
end
it "generates a valid gemspec" do
- system_gems ["rake-10.0.2"]
-
in_app_root
bundle "gem newgem --bin"
@@ -214,12 +211,11 @@ RSpec.describe "bundle gem" do
end
Dir.chdir(bundled_app("newgem")) do
- bundle "exec rake build"
+ system_gems ["rake-10.0.2"], :path => :bundle_path
+ bundle! "exec rake build"
end
- expect(exitstatus).to be_zero if exitstatus
- expect(out).not_to include("ERROR")
- expect(err).not_to include("ERROR")
+ expect(last_command.stdboth).not_to include("ERROR")
end
context "gem naming with relative paths" do
@@ -785,24 +781,24 @@ RSpec.describe "bundle gem" do
it "fails gracefully with a ." do
bundle "gem foo.gemspec"
- expect(out).to end_with("Invalid gem name foo.gemspec -- `Foo.gemspec` is an invalid constant name")
+ expect(last_command.bundler_err).to end_with("Invalid gem name foo.gemspec -- `Foo.gemspec` is an invalid constant name")
end
it "fails gracefully with a ^" do
bundle "gem ^"
- expect(out).to end_with("Invalid gem name ^ -- `^` is an invalid constant name")
+ expect(last_command.bundler_err).to end_with("Invalid gem name ^ -- `^` is an invalid constant name")
end
it "fails gracefully with a space" do
bundle "gem 'foo bar'"
- expect(out).to end_with("Invalid gem name foo bar -- `Foo bar` is an invalid constant name")
+ expect(last_command.bundler_err).to end_with("Invalid gem name foo bar -- `Foo bar` is an invalid constant name")
end
it "fails gracefully when multiple names are passed" do
bundle "gem foo bar baz"
- expect(out).to eq(<<-E.strip)
+ expect(last_command.bundler_err).to eq(<<-E.strip)
ERROR: "bundle gem" was called with arguments ["foo", "bar", "baz"]
-Usage: "bundle gem GEM [OPTIONS]"
+Usage: "bundle gem NAME [OPTIONS]"
E
end
end
@@ -890,8 +886,8 @@ Usage: "bundle gem GEM [OPTIONS]"
in_app_root do
FileUtils.touch("conflict-foobar")
end
- output = bundle "gem conflict-foobar"
- expect(output).to include("Errno::ENOTDIR")
+ bundle "gem conflict-foobar"
+ expect(last_command.bundler_err).to include("Errno::ENOTDIR")
expect(exitstatus).to eql(32) if exitstatus
end
end
@@ -902,7 +898,7 @@ Usage: "bundle gem GEM [OPTIONS]"
FileUtils.mkdir_p("conflict-foobar/Gemfile")
end
bundle! "gem conflict-foobar"
- expect(out).to include("file_clash conflict-foobar/Gemfile").
+ expect(last_command.stdout).to include("file_clash conflict-foobar/Gemfile").
and include "Initializing git repo in #{bundled_app("conflict-foobar")}"
end
end
diff --git a/spec/bundler/commands/open_spec.rb b/spec/bundler/commands/open_spec.rb
index 6872e859d2..5cab846fb5 100644
--- a/spec/bundler/commands/open_spec.rb
+++ b/spec/bundler/commands/open_spec.rb
@@ -1,5 +1,4 @@
# frozen_string_literal: true
-require "spec_helper"
RSpec.describe "bundle open" do
before :each do
diff --git a/spec/bundler/commands/outdated_spec.rb b/spec/bundler/commands/outdated_spec.rb
index c6b6c9f59e..f0ad136c98 100644
--- a/spec/bundler/commands/outdated_spec.rb
+++ b/spec/bundler/commands/outdated_spec.rb
@@ -1,5 +1,4 @@
# frozen_string_literal: true
-require "spec_helper"
RSpec.describe "bundle outdated" do
before :each do
@@ -192,6 +191,8 @@ RSpec.describe "bundle outdated" do
build_gem "activesupport", "2.3.4"
end
+ bundle! "config clean false"
+
install_gemfile <<-G
source "file://#{gem_repo2}"
gem "activesupport", "2.3.4"
@@ -334,7 +335,7 @@ RSpec.describe "bundle outdated" do
G
update_repo2 do
- build_gem "activesupport", %w(2.4.0 3.0.0)
+ build_gem "activesupport", %w[2.4.0 3.0.0]
build_gem "weakling", "0.0.5"
end
@@ -352,7 +353,7 @@ RSpec.describe "bundle outdated" do
G
update_repo2 do
- build_gem "activesupport", %w(2.3.9)
+ build_gem "activesupport", %w[2.3.9]
build_gem "weakling", "0.1.5"
end
@@ -370,7 +371,7 @@ RSpec.describe "bundle outdated" do
G
update_repo2 do
- build_gem "activesupport", %w(2.4.0 2.5.0)
+ build_gem "activesupport", %w[2.4.0 2.5.0]
build_gem "weakling", "1.1.5"
end
@@ -406,9 +407,9 @@ RSpec.describe "bundle outdated" do
expect(out).to include("Installing foo 1.0")
end
- context "after bundle install --deployment" do
+ context "after bundle install --deployment", :bundler => "< 2" do
before do
- install_gemfile <<-G, :deployment => true
+ install_gemfile <<-G, forgotten_command_line_options(:deployment => true)
source "file://#{gem_repo2}"
gem "rack"
@@ -420,7 +421,7 @@ RSpec.describe "bundle outdated" do
update_repo2 { build_gem "activesupport", "3.0" }
bundle "outdated"
- expect(exitstatus).to_not be_zero if exitstatus
+ expect(last_command).to be_failure
expect(out).to include("You are trying to check outdated gems in deployment mode.")
expect(out).to include("Run `bundle outdated` elsewhere.")
expect(out).to include("If this is a development machine, remove the ")
@@ -428,6 +429,29 @@ RSpec.describe "bundle outdated" do
end
end
+ context "after bundle config deployment true" do
+ before do
+ install_gemfile <<-G
+ source "file://#{gem_repo2}"
+
+ gem "rack"
+ gem "foo"
+ G
+ bundle! "config deployment true"
+ end
+
+ it "outputs a helpful message about being in deployment mode" do
+ update_repo2 { build_gem "activesupport", "3.0" }
+
+ bundle "outdated"
+ expect(last_command).to be_failure
+ expect(out).to include("You are trying to check outdated gems in deployment mode.")
+ expect(out).to include("Run `bundle outdated` elsewhere.")
+ expect(out).to include("If this is a development machine, remove the ")
+ expect(out).to include("Gemfile freeze\nby running `bundle config --delete deployment`.")
+ end
+ end
+
context "update available for a gem on a different platform" do
before do
install_gemfile <<-G
@@ -629,9 +653,9 @@ RSpec.describe "bundle outdated" do
context "without update-strict" do
before do
build_repo4 do
- build_gem "patch", %w(1.0.0 1.0.1)
- build_gem "minor", %w(1.0.0 1.0.1 1.1.0)
- build_gem "major", %w(1.0.0 1.0.1 1.1.0 2.0.0)
+ build_gem "patch", %w[1.0.0 1.0.1]
+ build_gem "minor", %w[1.0.0 1.0.1 1.1.0]
+ build_gem "major", %w[1.0.0 1.0.1 1.1.0 2.0.0]
end
# establish a lockfile set to 1.0.0
@@ -689,17 +713,17 @@ RSpec.describe "bundle outdated" do
context "with update-strict" do
before do
build_repo4 do
- build_gem "foo", %w(1.4.3 1.4.4) do |s|
+ build_gem "foo", %w[1.4.3 1.4.4] do |s|
s.add_dependency "bar", "~> 2.0"
end
- build_gem "foo", %w(1.4.5 1.5.0) do |s|
+ build_gem "foo", %w[1.4.5 1.5.0] do |s|
s.add_dependency "bar", "~> 2.1"
end
- build_gem "foo", %w(1.5.1) do |s|
+ build_gem "foo", %w[1.5.1] do |s|
s.add_dependency "bar", "~> 3.0"
end
- build_gem "bar", %w(2.0.3 2.0.4 2.0.5 2.1.0 2.1.1 3.0.0)
- build_gem "qux", %w(1.0.0 1.1.0 2.0.0)
+ build_gem "bar", %w[2.0.3 2.0.4 2.0.5 2.1.0 2.1.1 3.0.0]
+ build_gem "qux", %w[1.0.0 1.1.0 2.0.0]
end
# establish a lockfile set to 1.4.3
diff --git a/spec/bundler/commands/package_spec.rb b/spec/bundler/commands/package_spec.rb
index 86c09db3ca..6351909bc7 100644
--- a/spec/bundler/commands/package_spec.rb
+++ b/spec/bundler/commands/package_spec.rb
@@ -1,5 +1,4 @@
# frozen_string_literal: true
-require "spec_helper"
RSpec.describe "bundle package" do
context "with --gemfile" do
@@ -25,7 +24,7 @@ RSpec.describe "bundle package" do
gem 'bundler'
D
- bundle "package --all"
+ bundle :package, forgotten_command_line_options([:all, :cache_all] => true)
expect(bundled_app("vendor/cache/rack-1.0.0.gem")).to exist
expect(bundled_app("vendor/cache/bundler-0.9.gem")).to_not exist
@@ -55,7 +54,7 @@ RSpec.describe "bundle package" do
gemspec
D
- bundle! "package --all"
+ bundle! :package, forgotten_command_line_options([:all, :cache_all] => true)
expect(bundled_app("vendor/cache/rack-1.0.0.gem")).to exist
expect(bundled_app("vendor/cache/nokogiri-1.4.2.gem")).to exist
@@ -86,7 +85,7 @@ RSpec.describe "bundle package" do
gemspec
D
- bundle! "package --all"
+ bundle! :package, forgotten_command_line_options([:all, :cache_all] => true)
expect(bundled_app("vendor/cache/rack-1.0.0.gem")).to exist
expect(bundled_app("vendor/cache/nokogiri-1.4.2.gem")).to exist
@@ -130,7 +129,7 @@ RSpec.describe "bundle package" do
gemspec :name => 'mygem_test'
D
- bundle! "package --all"
+ bundle! :package, forgotten_command_line_options([:all, :cache_all] => true)
expect(bundled_app("vendor/cache/rack-1.0.0.gem")).to exist
expect(bundled_app("vendor/cache/nokogiri-1.4.2.gem")).to exist
@@ -142,14 +141,14 @@ RSpec.describe "bundle package" do
end
end
- context "with --path" do
+ context "with --path", :bundler => "< 2" do
it "sets root directory for gems" do
gemfile <<-D
source "file://#{gem_repo1}"
gem 'rack'
D
- bundle "package --path=#{bundled_app("test")}"
+ bundle! :package, forgotten_command_line_options(:path => bundled_app("test"))
expect(the_bundle).to include_gems "rack 1.0.0"
expect(bundled_app("test/vendor/cache/")).to exist
@@ -163,7 +162,7 @@ RSpec.describe "bundle package" do
gem 'rack'
D
- bundle "package --no-install"
+ bundle! "package --no-install"
expect(the_bundle).not_to include_gems "rack 1.0.0"
expect(bundled_app("vendor/cache/rack-1.0.0.gem")).to exist
@@ -175,8 +174,8 @@ RSpec.describe "bundle package" do
gem 'rack'
D
- bundle "package --no-install"
- bundle "install"
+ bundle! "package --no-install"
+ bundle! "install"
expect(the_bundle).to include_gems "rack 1.0.0"
end
@@ -203,9 +202,10 @@ RSpec.describe "bundle package" do
bundle "install"
end
- subject { bundle "package --frozen" }
+ subject { bundle :package, forgotten_command_line_options(:frozen => true) }
it "tries to install with frozen" do
+ bundle! "config deployment true"
gemfile <<-G
source "file://#{gem_repo1}"
gem "rack"
@@ -217,7 +217,7 @@ RSpec.describe "bundle package" do
expect(out).to include("You have added to the Gemfile")
expect(out).to include("* rack-obama")
bundle "env"
- expect(out).to include("frozen")
+ expect(out).to include("frozen").or include("deployment")
end
end
end
@@ -241,16 +241,16 @@ RSpec.describe "bundle install with gem sources" do
it "does not hit the remote at all" do
build_repo2
- install_gemfile <<-G
+ install_gemfile! <<-G
source "file://#{gem_repo2}"
gem "rack"
G
- bundle :pack
+ bundle! :pack
simulate_new_machine
FileUtils.rm_rf gem_repo2
- bundle "install --deployment"
+ bundle! :install, forgotten_command_line_options(:deployment => true, :path => "vendor/bundle")
expect(the_bundle).to include_gems "rack 1.0.0"
end
diff --git a/spec/bundler/commands/pristine_spec.rb b/spec/bundler/commands/pristine_spec.rb
index 3aca313e0f..ee75934380 100644
--- a/spec/bundler/commands/pristine_spec.rb
+++ b/spec/bundler/commands/pristine_spec.rb
@@ -1,6 +1,6 @@
# frozen_string_literal: true
-require "spec_helper"
-require "fileutils"
+
+require "bundler/vendored_fileutils"
RSpec.describe "bundle pristine", :ruby_repo do
before :each do
@@ -28,7 +28,7 @@ RSpec.describe "bundle pristine", :ruby_repo do
G
end
- context "when sourced from Rubygems" do
+ context "when sourced from RubyGems" do
it "reverts using cached .gem file" do
spec = Bundler.definition.specs["weakling"].first
changes_txt = Pathname.new(spec.full_gem_path).join("lib/changes.txt")
@@ -55,12 +55,23 @@ RSpec.describe "bundle pristine", :ruby_repo do
changed_file = Pathname.new(spec.full_gem_path).join("lib/foo.rb")
diff = "#Pristine spec changes"
- File.open(changed_file, "a") {|f| f.puts "#Pristine spec changes" }
+ File.open(changed_file, "a") {|f| f.puts diff }
expect(File.read(changed_file)).to include(diff)
- bundle "pristine"
+ bundle! "pristine"
expect(File.read(changed_file)).to_not include(diff)
end
+
+ it "removes added files" do
+ spec = Bundler.definition.specs["foo"].first
+ changes_txt = Pathname.new(spec.full_gem_path).join("lib/changes.txt")
+
+ FileUtils.touch(changes_txt)
+ expect(changes_txt).to be_file
+
+ bundle! "pristine"
+ expect(changes_txt).not_to be_file
+ end
end
context "when sourced from gemspec" do
@@ -69,7 +80,7 @@ RSpec.describe "bundle pristine", :ruby_repo do
changed_file = Pathname.new(spec.full_gem_path).join("lib/baz.rb")
diff = "#Pristine spec changes"
- File.open(changed_file, "a") {|f| f.puts "#Pristine spec changes" }
+ File.open(changed_file, "a") {|f| f.puts diff }
expect(File.read(changed_file)).to include(diff)
bundle "pristine"
@@ -102,6 +113,39 @@ RSpec.describe "bundle pristine", :ruby_repo do
end
end
+ context "when passing a list of gems to pristine" do
+ it "resets them" do
+ foo = Bundler.definition.specs["foo"].first
+ foo_changes_txt = Pathname.new(foo.full_gem_path).join("lib/changes.txt")
+ FileUtils.touch(foo_changes_txt)
+ expect(foo_changes_txt).to be_file
+
+ bar = Bundler.definition.specs["bar"].first
+ bar_changes_txt = Pathname.new(bar.full_gem_path).join("lib/changes.txt")
+ FileUtils.touch(bar_changes_txt)
+ expect(bar_changes_txt).to be_file
+
+ weakling = Bundler.definition.specs["weakling"].first
+ weakling_changes_txt = Pathname.new(weakling.full_gem_path).join("lib/changes.txt")
+ FileUtils.touch(weakling_changes_txt)
+ expect(weakling_changes_txt).to be_file
+
+ bundle! "pristine foo bar weakling"
+
+ expect(out).to include("Cannot pristine bar (1.0). Gem is sourced from local path.").
+ and include("Installing weakling 1.0")
+
+ expect(weakling_changes_txt).not_to be_file
+ expect(foo_changes_txt).not_to be_file
+ expect(bar_changes_txt).to be_file
+ end
+
+ it "raises when one of them is not in the lockfile" do
+ bundle "pristine abcabcabc"
+ expect(out).to include("Could not find gem 'abcabcabc'.")
+ end
+ end
+
context "when a build config exists for one of the gems" do
let(:very_simple_binary) { Bundler.definition.specs["very_simple_binary"].first }
let(:c_ext_dir) { Pathname.new(very_simple_binary.full_gem_path).join("ext") }
diff --git a/spec/bundler/commands/show_spec.rb b/spec/bundler/commands/show_spec.rb
index fc34831a72..adbf289fd0 100644
--- a/spec/bundler/commands/show_spec.rb
+++ b/spec/bundler/commands/show_spec.rb
@@ -1,7 +1,6 @@
# frozen_string_literal: true
-require "spec_helper"
-RSpec.describe "bundle show" do
+RSpec.describe "bundle show", :bundler => "< 2" do
context "with a standard Gemfile" do
before :each do
install_gemfile <<-G
@@ -32,15 +31,15 @@ RSpec.describe "bundle show" do
end
it "warns if path no longer exists on disk" do
- FileUtils.rm_rf("#{system_gem_path}/gems/rails-2.3.2")
+ FileUtils.rm_rf(default_bundle_path("gems", "rails-2.3.2"))
bundle "show rails"
- expect(out).to match(/has been deleted/i)
- expect(out).to include(default_bundle_path("gems", "rails-2.3.2").to_s)
+ expect(out).to match(/has been deleted/i).
+ and include(default_bundle_path("gems", "rails-2.3.2").to_s)
end
- it "prints the path to the running bundler" do
+ it "prints the path to the running bundler", :ruby_repo do
bundle "show bundler"
expect(out).to eq(root.to_s)
end
diff --git a/spec/bundler/commands/update_spec.rb b/spec/bundler/commands/update_spec.rb
index 4992e428da..a8283cf593 100644
--- a/spec/bundler/commands/update_spec.rb
+++ b/spec/bundler/commands/update_spec.rb
@@ -1,5 +1,4 @@
# frozen_string_literal: true
-require "spec_helper"
RSpec.describe "bundle update" do
before :each do
@@ -12,7 +11,7 @@ RSpec.describe "bundle update" do
G
end
- describe "with no arguments" do
+ describe "with no arguments", :bundler => "< 2" do
it "updates the entire bundle" do
update_repo2 do
build_gem "activesupport", "3.0"
@@ -35,6 +34,51 @@ RSpec.describe "bundle update" do
end
end
+ describe "with --all", :bundler => "2" do
+ it "updates the entire bundle" do
+ update_repo2 do
+ build_gem "activesupport", "3.0"
+ end
+
+ bundle! "update", :all => true
+ expect(out).to include("Bundle updated!")
+ expect(the_bundle).to include_gems "rack 1.2", "rack-obama 1.0", "activesupport 3.0"
+ end
+
+ it "doesn't delete the Gemfile.lock file if something goes wrong" do
+ gemfile <<-G
+ source "file://#{gem_repo2}"
+ gem "activesupport"
+ gem "rack-obama"
+ exit!
+ G
+ bundle "update", :all => true
+ expect(bundled_app("Gemfile.lock")).to exist
+ end
+ end
+
+ context "when update_requires_all_flag is set" do
+ before { bundle! "config update_requires_all_flag true" }
+
+ it "errors when passed nothing" do
+ install_gemfile! ""
+ bundle :update
+ expect(out).to eq("To update everything, pass the `--all` flag.")
+ end
+
+ it "errors when passed --all and another option" do
+ install_gemfile! ""
+ bundle "update --all foo"
+ expect(out).to eq("Cannot specify --all along with specific options.")
+ end
+
+ it "updates everything when passed --all" do
+ install_gemfile! ""
+ bundle "update --all"
+ expect(out).to include("Bundle updated!")
+ end
+ end
+
describe "--quiet argument" do
it "hides UI messages" do
bundle "update --quiet"
@@ -101,7 +145,7 @@ RSpec.describe "bundle update" do
end
end
- bundle! "update"
+ bundle! "update", :all => bundle_update_requires_all?
expect(the_bundle).to include_gems("a 1.0", "b 1.0", "c 2.0")
end
@@ -112,13 +156,13 @@ RSpec.describe "bundle update" do
it "doesn't hit repo2" do
FileUtils.rm_rf(gem_repo2)
- bundle "update --local"
- expect(out).not_to match(/Fetching source index/)
+ bundle "update --local --all"
+ expect(out).not_to include("Fetching source index")
end
end
describe "with --group option" do
- it "should update only specifed group gems" do
+ it "should update only specified group gems" do
install_gemfile <<-G
source "file://#{gem_repo2}"
gem "activesupport", :group => :development
@@ -154,46 +198,66 @@ RSpec.describe "bundle update" do
end
describe "in a frozen bundle" do
- it "should fail loudly" do
- bundle "install --deployment"
- bundle "update"
+ it "should fail loudly", :bundler => "< 2" do
+ bundle! "install --deployment"
+ bundle "update", :all => bundle_update_requires_all?
+ expect(last_command).to be_failure
expect(out).to match(/You are trying to install in deployment mode after changing.your Gemfile/m)
expect(out).to match(/freeze \nby running `bundle install --no-deployment`./m)
- expect(exitstatus).not_to eq(0) if exitstatus
end
- it "should suggest different command when frozen is set globally" do
- bundler "config --global frozen 1"
- bundle "update"
- expect(out).to match(/You are trying to install in deployment mode after changing.your Gemfile/m)
- expect(out).to match(/freeze \nby running `bundle config --delete frozen`./m)
+ it "should suggest different command when frozen is set globally", :bundler => "< 2" do
+ bundle! "config --global frozen 1"
+ bundle "update", :all => bundle_update_requires_all?
+ expect(out).to match(/You are trying to install in deployment mode after changing.your Gemfile/m).
+ and match(/freeze \nby running `bundle config --delete frozen`./m)
+ end
+
+ it "should suggest different command when frozen is set globally", :bundler => "2" do
+ bundle! "config --global deployment true"
+ bundle "update", :all => bundle_update_requires_all?
+ expect(out).to match(/You are trying to install in deployment mode after changing.your Gemfile/m).
+ and match(/freeze \nby running `bundle config --delete deployment`./m)
end
end
describe "with --source option" do
- it "should not update gems not included in the source that happen to have the same name" do
- pending("Allowed to fail to preserve backwards-compatibility")
-
- install_gemfile <<-G
+ it "should not update gems not included in the source that happen to have the same name", :bundler => "< 2" do
+ install_gemfile! <<-G
source "file://#{gem_repo2}"
gem "activesupport"
G
update_repo2 { build_gem "activesupport", "3.0" }
- bundle "update --source activesupport"
- expect(the_bundle).not_to include_gems "activesupport 3.0"
+ bundle! "update --source activesupport"
+ expect(the_bundle).to include_gem "activesupport 3.0"
end
- it "should update gems not included in the source that happen to have the same name" do
- install_gemfile <<-G
+ it "should not update gems not included in the source that happen to have the same name", :bundler => "2" do
+ install_gemfile! <<-G
source "file://#{gem_repo2}"
gem "activesupport"
G
update_repo2 { build_gem "activesupport", "3.0" }
- bundle "update --source activesupport"
- expect(the_bundle).to include_gems "activesupport 3.0"
+ bundle! "update --source activesupport"
+ expect(the_bundle).not_to include_gem "activesupport 3.0"
+ end
+
+ context "with unlock_source_unlocks_spec set to false" do
+ before { bundle! "config unlock_source_unlocks_spec false" }
+
+ it "should not update gems not included in the source that happen to have the same name" do
+ install_gemfile <<-G
+ source "file://#{gem_repo2}"
+ gem "activesupport"
+ G
+ update_repo2 { build_gem "activesupport", "3.0" }
+
+ bundle "update --source activesupport"
+ expect(the_bundle).not_to include_gems "activesupport 3.0"
+ end
end
end
@@ -213,7 +277,7 @@ RSpec.describe "bundle update" do
G
end
- it "should not update the child dependencies of a gem that has the same name as the source" do
+ it "should not update the child dependencies of a gem that has the same name as the source", :bundler => "< 2" do
update_repo2 do
build_gem "fred", "2.0"
build_gem "harry", "2.0" do |s|
@@ -225,6 +289,18 @@ RSpec.describe "bundle update" do
expect(the_bundle).to include_gems "harry 2.0"
expect(the_bundle).to include_gems "fred 1.0"
end
+
+ it "should not update the child dependencies of a gem that has the same name as the source", :bundler => "2" do
+ update_repo2 do
+ build_gem "fred", "2.0"
+ build_gem "harry", "2.0" do |s|
+ s.add_dependency "fred"
+ end
+ end
+
+ bundle "update --source harry"
+ expect(the_bundle).to include_gems "harry 1.0", "fred 1.0"
+ end
end
context "when there is a child dependency that appears elsewhere in the dependency graph" do
@@ -246,7 +322,7 @@ RSpec.describe "bundle update" do
G
end
- it "should not update the child dependencies of a gem that has the same name as the source" do
+ it "should not update the child dependencies of a gem that has the same name as the source", :bundler => "< 2" do
update_repo2 do
build_gem "george", "2.0"
build_gem "harry", "2.0" do |s|
@@ -259,6 +335,18 @@ RSpec.describe "bundle update" do
expect(the_bundle).to include_gems "fred 1.0"
expect(the_bundle).to include_gems "george 1.0"
end
+
+ it "should not update the child dependencies of a gem that has the same name as the source", :bundler => "2" do
+ update_repo2 do
+ build_gem "george", "2.0"
+ build_gem "harry", "2.0" do |s|
+ s.add_dependency "george"
+ end
+ end
+
+ bundle "update --source harry"
+ expect(the_bundle).to include_gems "harry 1.0", "fred 1.0", "george 1.0"
+ end
end
end
@@ -285,6 +373,24 @@ RSpec.describe "bundle update in more complicated situations" do
expect(the_bundle).to include_gems "thin 2.0", "rack 1.2", "rack-obama 1.0"
end
+ it "will warn when some explicitly updated gems are not updated" do
+ install_gemfile! <<-G
+ source "file:#{gem_repo2}"
+
+ gem "thin"
+ gem "rack-obama"
+ G
+
+ update_repo2 do
+ build_gem("thin", "2.0") {|s| s.add_dependency "rack" }
+ build_gem "rack", "10.0"
+ end
+
+ bundle! "update thin rack-obama"
+ expect(last_command.stdboth).to include "Bundler attempted to update rack-obama but its version stayed the same"
+ expect(the_bundle).to include_gems "thin 2.0", "rack 10.0", "rack-obama 1.0"
+ end
+
it "will update only from pinned source" do
install_gemfile <<-G
source "file://#{gem_repo2}"
@@ -313,7 +419,7 @@ RSpec.describe "bundle update without a Gemfile.lock" do
gem "rack", "1.0"
G
- bundle "update"
+ bundle "update", :all => bundle_update_requires_all?
expect(the_bundle).to include_gems "rack 1.0.0"
end
@@ -333,21 +439,23 @@ RSpec.describe "bundle update when a gem depends on a newer version of bundler"
G
end
- it "should not explode" do
- bundle "update"
- expect(err).to lack_errors
+ it "should explain that bundler conflicted", :bundler => "< 2" do
+ bundle "update", :all => bundle_update_requires_all?
+ expect(last_command.stdboth).not_to match(/in snapshot/i)
+ expect(last_command.bundler_err).to match(/current Bundler version/i).
+ and match(/perhaps you need to update bundler/i)
end
- it "should explain that bundler conflicted" do
- bundle "update"
- expect(out).not_to match(/in snapshot/i)
- expect(out).to match(/current Bundler version/i)
- expect(out).to match(/perhaps you need to update bundler/i)
+ it "should warn that the newer version of Bundler would conflict", :bundler => "2" do
+ bundle! "update", :all => true
+ expect(last_command.bundler_err).to include("rails (3.0.1) has dependency bundler").
+ and include("so the dependency is being ignored")
+ expect(the_bundle).to include_gem "rails 3.0.1"
end
end
RSpec.describe "bundle update" do
- it "shows the previous version of the gem when updated from rubygems source" do
+ it "shows the previous version of the gem when updated from rubygems source", :bundler => "< 2" do
build_repo2
install_gemfile <<-G
@@ -355,17 +463,52 @@ RSpec.describe "bundle update" do
gem "activesupport"
G
- bundle "update"
+ bundle "update", :all => bundle_update_requires_all?
expect(out).to include("Using activesupport 2.3.5")
update_repo2 do
build_gem "activesupport", "3.0"
end
- bundle "update"
+ bundle "update", :all => bundle_update_requires_all?
expect(out).to include("Installing activesupport 3.0 (was 2.3.5)")
end
+ context "with suppress_install_using_messages set" do
+ before { bundle! "config suppress_install_using_messages true" }
+
+ it "only prints `Using` for versions that have changed" do
+ build_repo4 do
+ build_gem "bar"
+ build_gem "foo"
+ end
+
+ install_gemfile! <<-G
+ source "file://#{gem_repo4}"
+ gem "bar"
+ gem "foo"
+ G
+
+ bundle! "update", :all => bundle_update_requires_all?
+ out.gsub!(/RubyGems [\d\.]+ is not threadsafe.*\n?/, "")
+ expect(out).to include "Resolving dependencies...\nBundle updated!"
+
+ update_repo4 do
+ build_gem "foo", "2.0"
+ end
+
+ bundle! "update", :all => bundle_update_requires_all?
+ out.sub!("Removing foo (1.0)\n", "")
+ out.gsub!(/RubyGems [\d\.]+ is not threadsafe.*\n?/, "")
+ expect(out).to include strip_whitespace(<<-EOS).strip
+ Resolving dependencies...
+ Fetching foo 2.0 (was 1.0)
+ Installing foo 2.0 (was 1.0)
+ Bundle updated
+ EOS
+ end
+ end
+
it "shows error message when Gemfile.lock is not preset and gem is specified" do
install_gemfile <<-G
source "file://#{gem_repo2}"
@@ -403,7 +546,7 @@ RSpec.describe "bundle update --ruby" do
specs:
PLATFORMS
- ruby
+ #{lockfile_platforms}
DEPENDENCIES
@@ -429,7 +572,7 @@ RSpec.describe "bundle update --ruby" do
specs:
PLATFORMS
- ruby
+ #{lockfile_platforms}
DEPENDENCIES
@@ -473,7 +616,7 @@ RSpec.describe "bundle update --ruby" do
specs:
PLATFORMS
- ruby
+ #{lockfile_platforms}
DEPENDENCIES
@@ -487,22 +630,43 @@ RSpec.describe "bundle update --ruby" do
end
end
+RSpec.describe "bundle update --bundler" do
+ it "updates the bundler version in the lockfile without re-resolving" do
+ build_repo4 do
+ build_gem "rack", "1.0"
+ end
+
+ install_gemfile! <<-G
+ source "file:#{gem_repo4}"
+ gem "rack"
+ G
+ lockfile lockfile.sub(Bundler::VERSION, "1.0.0")
+
+ FileUtils.rm_r gem_repo4
+
+ bundle! :update, :bundler => true, :verbose => true
+ expect(the_bundle).to include_gem "rack 1.0"
+
+ expect(the_bundle.locked_gems.bundler_version).to eq v(Bundler::VERSION)
+ end
+end
+
# these specs are slow and focus on integration and therefore are not exhaustive. unit specs elsewhere handle that.
RSpec.describe "bundle update conservative" do
context "patch and minor options" do
before do
build_repo4 do
- build_gem "foo", %w(1.4.3 1.4.4) do |s|
+ build_gem "foo", %w[1.4.3 1.4.4] do |s|
s.add_dependency "bar", "~> 2.0"
end
- build_gem "foo", %w(1.4.5 1.5.0) do |s|
+ build_gem "foo", %w[1.4.5 1.5.0] do |s|
s.add_dependency "bar", "~> 2.1"
end
- build_gem "foo", %w(1.5.1) do |s|
+ build_gem "foo", %w[1.5.1] do |s|
s.add_dependency "bar", "~> 3.0"
end
- build_gem "bar", %w(2.0.3 2.0.4 2.0.5 2.1.0 2.1.1 3.0.0)
- build_gem "qux", %w(1.0.0 1.0.1 1.1.0 2.0.0)
+ build_gem "bar", %w[2.0.3 2.0.4 2.0.5 2.1.0 2.1.1 3.0.0]
+ build_gem "qux", %w[1.0.0 1.0.1 1.1.0 2.0.0]
end
# establish a lockfile set to 1.4.3
@@ -524,13 +688,13 @@ RSpec.describe "bundle update conservative" do
context "patch preferred" do
it "single gem updates dependent gem to minor" do
- bundle "update --patch foo"
+ bundle! "update --patch foo"
expect(the_bundle).to include_gems "foo 1.4.5", "bar 2.1.1", "qux 1.0.0"
end
it "update all" do
- bundle "update --patch"
+ bundle! "update --patch", :all => bundle_update_requires_all?
expect(the_bundle).to include_gems "foo 1.4.5", "bar 2.1.1", "qux 1.0.1"
end
@@ -538,7 +702,7 @@ RSpec.describe "bundle update conservative" do
context "minor preferred" do
it "single gem updates dependent gem to major" do
- bundle "update --minor foo"
+ bundle! "update --minor foo"
expect(the_bundle).to include_gems "foo 1.5.1", "bar 3.0.0", "qux 1.0.0"
end
@@ -546,13 +710,13 @@ RSpec.describe "bundle update conservative" do
context "strict" do
it "patch preferred" do
- bundle "update --patch foo bar --strict"
+ bundle! "update --patch foo bar --strict"
expect(the_bundle).to include_gems "foo 1.4.4", "bar 2.0.5", "qux 1.0.0"
end
it "minor preferred" do
- bundle "update --minor --strict"
+ bundle! "update --minor --strict", :all => bundle_update_requires_all?
expect(the_bundle).to include_gems "foo 1.5.0", "bar 2.1.1", "qux 1.1.0"
end
@@ -562,18 +726,18 @@ RSpec.describe "bundle update conservative" do
context "eager unlocking" do
before do
build_repo4 do
- build_gem "isolated_owner", %w(1.0.1 1.0.2) do |s|
+ build_gem "isolated_owner", %w[1.0.1 1.0.2] do |s|
s.add_dependency "isolated_dep", "~> 2.0"
end
- build_gem "isolated_dep", %w(2.0.1 2.0.2)
+ build_gem "isolated_dep", %w[2.0.1 2.0.2]
- build_gem "shared_owner_a", %w(3.0.1 3.0.2) do |s|
+ build_gem "shared_owner_a", %w[3.0.1 3.0.2] do |s|
s.add_dependency "shared_dep", "~> 5.0"
end
- build_gem "shared_owner_b", %w(4.0.1 4.0.2) do |s|
+ build_gem "shared_owner_b", %w[4.0.1 4.0.2] do |s|
s.add_dependency "shared_dep", "~> 5.0"
end
- build_gem "shared_dep", %w(5.0.1 5.0.2)
+ build_gem "shared_dep", %w[5.0.1 5.0.2]
end
gemfile <<-G
@@ -649,9 +813,9 @@ RSpec.describe "bundle update conservative" do
end
it "raises if too many flags are provided" do
- bundle "update --patch --minor"
+ bundle "update --patch --minor", :all => bundle_update_requires_all?
- expect(out).to eq "Provide only one of the following options: minor, patch"
+ expect(last_command.bundler_err).to eq "Provide only one of the following options: minor, patch"
end
end
end
diff --git a/spec/bundler/commands/version_spec.rb b/spec/bundler/commands/version_spec.rb
new file mode 100644
index 0000000000..b919c25e0f
--- /dev/null
+++ b/spec/bundler/commands/version_spec.rb
@@ -0,0 +1,39 @@
+# frozen_string_literal: true
+
+RSpec.describe "bundle version" do
+ context "with -v" do
+ it "outputs the version", :bundler => "< 2" do
+ bundle! "-v"
+ expect(out).to eq("Bundler version #{Bundler::VERSION}")
+ end
+
+ it "outputs the version", :bundler => "2" do
+ bundle! "-v"
+ expect(out).to eq(Bundler::VERSION)
+ end
+ end
+
+ context "with --version" do
+ it "outputs the version", :bundler => "< 2" do
+ bundle! "--version"
+ expect(out).to eq("Bundler version #{Bundler::VERSION}")
+ end
+
+ it "outputs the version", :bundler => "2" do
+ bundle! "--version"
+ expect(out).to eq(Bundler::VERSION)
+ end
+ end
+
+ context "with version" do
+ it "outputs the version with build metadata", :bundler => "< 2" do
+ bundle! "version"
+ expect(out).to match(/\ABundler version #{Regexp.escape(Bundler::VERSION)} \(\d{4}-\d{2}-\d{2} commit [a-fA-F0-9]{7,}\)\z/)
+ end
+
+ it "outputs the version with build metadata", :bundler => "2" do
+ bundle! "version"
+ expect(out).to match(/\A#{Regexp.escape(Bundler::VERSION)} \(\d{4}-\d{2}-\d{2} commit [a-fA-F0-9]{7,}\)\z/)
+ end
+ end
+end
diff --git a/spec/bundler/commands/viz_spec.rb b/spec/bundler/commands/viz_spec.rb
index 77112aace4..0e8667eaa7 100644
--- a/spec/bundler/commands/viz_spec.rb
+++ b/spec/bundler/commands/viz_spec.rb
@@ -1,5 +1,4 @@
# frozen_string_literal: true
-require "spec_helper"
RSpec.describe "bundle viz", :ruby => "1.9.3", :if => Bundler.which("dot") do
let(:ruby_graphviz) do
diff --git a/spec/bundler/install/allow_offline_install_spec.rb b/spec/bundler/install/allow_offline_install_spec.rb
index 1bca055c9f..d4bb595771 100644
--- a/spec/bundler/install/allow_offline_install_spec.rb
+++ b/spec/bundler/install/allow_offline_install_spec.rb
@@ -1,5 +1,4 @@
# frozen_string_literal: true
-require "spec_helper"
RSpec.describe "bundle install with :allow_offline_install" do
before do
@@ -27,8 +26,9 @@ RSpec.describe "bundle install with :allow_offline_install" do
context "with cached data locally" do
it "will install from the compact index" do
- system_gems ["rack-1.0.0"]
+ system_gems ["rack-1.0.0"], :path => :bundle_path
+ bundle! "config clean false"
install_gemfile! <<-G, :artifice => "compact_index"
source "http://testgemserver.local"
gem "rack-obama"
@@ -42,8 +42,8 @@ RSpec.describe "bundle install with :allow_offline_install" do
gem "rack-obama"
G
- bundle! :update, :artifice => "fail"
- expect(out).to include("Using the cached data for the new index because of a network error")
+ bundle! :update, :artifice => "fail", :all => true
+ expect(last_command.stdboth).to include "Using the cached data for the new index because of a network error"
expect(the_bundle).to include_gems("rack-obama 1.0", "rack 1.0.0")
end
@@ -76,7 +76,7 @@ RSpec.describe "bundle install with :allow_offline_install" do
gem "a", :git => #{git.path.to_s.dump}
G
- break_git_remote_ops! { bundle! :update }
+ break_git_remote_ops! { bundle! :update, :all => true }
expect(out).to include("Using cached git data because of network errors")
expect(the_bundle).to be_locked
diff --git a/spec/bundler/install/binstubs_spec.rb b/spec/bundler/install/binstubs_spec.rb
index a1a9ab167d..23eb691ab8 100644
--- a/spec/bundler/install/binstubs_spec.rb
+++ b/spec/bundler/install/binstubs_spec.rb
@@ -1,7 +1,6 @@
# frozen_string_literal: true
-require "spec_helper"
-RSpec.describe "bundle install" do
+RSpec.describe "bundle install", :bundler => "< 2" do
describe "when system_bindir is set" do
# On OS X, Gem.bindir defaults to /usr/bin, so system_bindir is useful if
# you want to avoid sudo installs for system gems with OS X's default ruby
@@ -21,7 +20,7 @@ RSpec.describe "bundle install" do
end
end
- describe "when multiple gems contain the same exe" do
+ describe "when multiple gems contain the same exe", :bundler => "< 2" do
before do
build_repo2 do
build_gem "fake", "14" do |s|
@@ -36,12 +35,6 @@ RSpec.describe "bundle install" do
G
end
- it "prints a deprecation notice" do
- bundle "config major_deprecations true"
- gembin("rackup")
- expect(out).to include("Bundler is using a binstub that was created for a different gem.")
- end
-
it "loads the correct spec's executable" do
gembin("rackup")
expect(out).to eq("1.2")
diff --git a/spec/bundler/install/bundler_spec.rb b/spec/bundler/install/bundler_spec.rb
index c1ce57e60e..08b7e2b673 100644
--- a/spec/bundler/install/bundler_spec.rb
+++ b/spec/bundler/install/bundler_spec.rb
@@ -1,5 +1,4 @@
# frozen_string_literal: true
-require "spec_helper"
RSpec.describe "bundle install" do
describe "with bundler dependencies" do
@@ -38,8 +37,6 @@ RSpec.describe "bundle install" do
G
nice_error = <<-E.strip.gsub(/^ {8}/, "")
- Fetching source index from file:#{gem_repo2}/
- Resolving dependencies...
Bundler could not find compatible versions for gem "bundler":
In Gemfile:
bundler (= 0.9.2)
@@ -49,9 +46,9 @@ RSpec.describe "bundle install" do
This Gemfile requires a different version of Bundler.
Perhaps you need to update Bundler by running `gem install bundler`?
- Could not find gem 'bundler (= 0.9.2)' in any of the sources
+ Could not find gem 'bundler (= 0.9.2)' in any
E
- expect(out).to eq(nice_error)
+ expect(last_command.bundler_err).to include(nice_error)
end
it "works for gems with multiple versions in its dependencies" do
@@ -99,8 +96,6 @@ RSpec.describe "bundle install" do
G
nice_error = <<-E.strip.gsub(/^ {8}/, "")
- Fetching source index from file:#{gem_repo2}/
- Resolving dependencies...
Bundler could not find compatible versions for gem "activesupport":
In Gemfile:
activemerchant was resolved to 1.0, which depends on
@@ -109,7 +104,7 @@ RSpec.describe "bundle install" do
rails_fail was resolved to 1.0, which depends on
activesupport (= 1.2.3)
E
- expect(out).to include(nice_error)
+ expect(last_command.bundler_err).to include(nice_error)
end
it "causes a conflict if a child dependency conflicts with the Gemfile" do
@@ -120,8 +115,6 @@ RSpec.describe "bundle install" do
G
nice_error = <<-E.strip.gsub(/^ {8}/, "")
- Fetching source index from file:#{gem_repo2}/
- Resolving dependencies...
Bundler could not find compatible versions for gem "activesupport":
In Gemfile:
activesupport (= 2.3.5)
@@ -129,19 +122,55 @@ RSpec.describe "bundle install" do
rails_fail was resolved to 1.0, which depends on
activesupport (= 1.2.3)
E
- expect(out).to include(nice_error)
+ expect(last_command.bundler_err).to include(nice_error)
end
- it "can install dependencies with newer bundler version" do
- install_gemfile <<-G
+ it "can install dependencies with newer bundler version with system gems", :ruby => "> 2" do
+ bundle! "config path.system true"
+ install_gemfile! <<-G
+ source "file://#{gem_repo2}"
+ gem "rails", "3.0"
+ G
+
+ simulate_bundler_version "99999999.99.1"
+
+ bundle! "check", :env => { "BUNDLER_SPEC_IGNORE_COMPATIBILITY_GUARD" => "1" }
+ expect(out).to include("The Gemfile's dependencies are satisfied")
+ end
+
+ it "can install dependencies with newer bundler version with a local path", :ruby => "> 2" do
+ bundle! "config path .bundle"
+ install_gemfile! <<-G
source "file://#{gem_repo2}"
gem "rails", "3.0"
G
- simulate_bundler_version "10.0.0"
+ simulate_bundler_version "99999999.99.1"
- bundle "check"
+ bundle! "check", :env => { "BUNDLER_SPEC_IGNORE_COMPATIBILITY_GUARD" => "1" }
expect(out).to include("The Gemfile's dependencies are satisfied")
end
+
+ context "with allow_bundler_dependency_conflicts set" do
+ before { bundle! "config allow_bundler_dependency_conflicts true" }
+
+ it "are forced to the current bundler version with warnings when no compatible version is found" do
+ build_repo4 do
+ build_gem "requires_nonexistant_bundler" do |s|
+ s.add_runtime_dependency "bundler", "99.99.99.99"
+ end
+ end
+
+ install_gemfile! <<-G
+ source "file://#{gem_repo4}"
+ gem "requires_nonexistant_bundler"
+ G
+
+ expect(out).to include "requires_nonexistant_bundler (1.0) has dependency bundler (= 99.99.99.99), " \
+ "which is unsatisfied by the current bundler version #{Bundler::VERSION}, so the dependency is being ignored"
+
+ expect(the_bundle).to include_gems "bundler #{Bundler::VERSION}", "requires_nonexistant_bundler 1.0"
+ end
+ end
end
end
diff --git a/spec/bundler/install/deploy_spec.rb b/spec/bundler/install/deploy_spec.rb
index bcbd57bc4f..3b9d68982a 100644
--- a/spec/bundler/install/deploy_spec.rb
+++ b/spec/bundler/install/deploy_spec.rb
@@ -1,5 +1,4 @@
# frozen_string_literal: true
-require "spec_helper"
RSpec.describe "install with --deployment or --frozen" do
before do
@@ -9,44 +8,48 @@ RSpec.describe "install with --deployment or --frozen" do
G
end
- it "fails without a lockfile and says that --deployment requires a lock" do
- bundle "install --deployment"
- expect(out).to include("The --deployment flag requires a Gemfile.lock")
- end
+ context "with CLI flags", :bundler => "< 2" do
+ it "fails without a lockfile and says that --deployment requires a lock" do
+ bundle "install --deployment"
+ expect(out).to include("The --deployment flag requires a Gemfile.lock")
+ end
- it "fails without a lockfile and says that --frozen requires a lock" do
- bundle "install --frozen"
- expect(out).to include("The --frozen flag requires a Gemfile.lock")
- end
+ it "fails without a lockfile and says that --frozen requires a lock" do
+ bundle "install --frozen"
+ expect(out).to include("The --frozen flag requires a Gemfile.lock")
+ end
- it "disallows --deployment --system" do
- bundle "install --deployment --system"
- expect(out).to include("You have specified both --deployment")
- expect(out).to include("Please choose only one option")
- expect(exitstatus).to eq(15) if exitstatus
- end
+ it "disallows --deployment --system" do
+ bundle "install --deployment --system"
+ expect(out).to include("You have specified both --deployment")
+ expect(out).to include("Please choose only one option")
+ expect(exitstatus).to eq(15) if exitstatus
+ end
- it "disallows --deployment --path --system" do
- bundle "install --deployment --path . --system"
- expect(out).to include("You have specified both --path")
- expect(out).to include("as well as --system")
- expect(out).to include("Please choose only one option")
- expect(exitstatus).to eq(15) if exitstatus
- end
+ it "disallows --deployment --path --system" do
+ bundle "install --deployment --path . --system"
+ expect(out).to include("You have specified both --path")
+ expect(out).to include("as well as --system")
+ expect(out).to include("Please choose only one option")
+ expect(exitstatus).to eq(15) if exitstatus
+ end
- it "works after you try to deploy without a lock" do
- bundle "install --deployment"
- bundle :install
- expect(exitstatus).to eq(0) if exitstatus
- expect(the_bundle).to include_gems "rack 1.0"
+ it "works after you try to deploy without a lock" do
+ bundle "install --deployment"
+ bundle! :install
+ expect(the_bundle).to include_gems "rack 1.0"
+ end
end
it "still works if you are not in the app directory and specify --gemfile" do
bundle "install"
- Dir.chdir tmp
- simulate_new_machine
- bundle "install --gemfile #{tmp}/bundled_app/Gemfile --deployment"
- Dir.chdir bundled_app
+ Dir.chdir tmp do
+ simulate_new_machine
+ bundle! :install,
+ forgotten_command_line_options(:gemfile => "#{tmp}/bundled_app/Gemfile",
+ :deployment => true,
+ :path => "vendor/bundle")
+ end
expect(the_bundle).to include_gems "rack 1.0"
end
@@ -58,15 +61,13 @@ RSpec.describe "install with --deployment or --frozen" do
end
G
bundle :install
- bundle "install --deployment --without test"
- expect(exitstatus).to eq(0) if exitstatus
+ bundle! :install, forgotten_command_line_options(:deployment => true, :without => "test")
end
- it "works when you bundle exec bundle" do
+ it "works when you bundle exec bundle", :ruby_repo do
bundle :install
bundle "install --deployment"
- bundle "exec bundle check"
- expect(exitstatus).to eq(0) if exitstatus
+ bundle! "exec bundle check"
end
it "works when using path gems from the same path and the version is specified" do
@@ -78,7 +79,7 @@ RSpec.describe "install with --deployment or --frozen" do
G
bundle! :install
- bundle! "install --deployment"
+ bundle! :install, forgotten_command_line_options(:deployment => true)
end
it "works when there are credentials in the source URL" do
@@ -88,21 +89,18 @@ RSpec.describe "install with --deployment or --frozen" do
gem "rack-obama", ">= 1.0"
G
- bundle "install --deployment", :artifice => "endpoint_strict_basic_authentication"
-
- expect(exitstatus).to eq(0) if exitstatus
+ bundle! :install, forgotten_command_line_options(:deployment => true).merge(:artifice => "endpoint_strict_basic_authentication")
end
it "works with sources given by a block" do
- install_gemfile <<-G
+ install_gemfile! <<-G
source "file://#{gem_repo1}" do
gem "rack"
end
G
- bundle "install --deployment"
+ bundle! :install, forgotten_command_line_options(:deployment => true)
- expect(exitstatus).to eq(0) if exitstatus
expect(the_bundle).to include_gems "rack 1.0"
end
@@ -111,14 +109,16 @@ RSpec.describe "install with --deployment or --frozen" do
bundle "install"
end
- it "works with the --deployment flag if you didn't change anything" do
- bundle "install --deployment"
- expect(exitstatus).to eq(0) if exitstatus
+ it "works with the --deployment flag if you didn't change anything", :bundler => "< 2" do
+ bundle! "install --deployment"
end
- it "works with the --frozen flag if you didn't change anything" do
- bundle "install --frozen"
- expect(exitstatus).to eq(0) if exitstatus
+ it "works with the --frozen flag if you didn't change anything", :bundler => "< 2" do
+ bundle! "install --frozen"
+ end
+
+ it "works with BUNDLE_FROZEN if you didn't change anything" do
+ bundle! :install, :env => { "BUNDLE_FROZEN" => "true" }
end
it "explodes with the --deployment flag if you make a change and don't check in the lockfile" do
@@ -128,7 +128,7 @@ RSpec.describe "install with --deployment or --frozen" do
gem "rack-obama"
G
- bundle "install --deployment"
+ bundle :install, forgotten_command_line_options(:deployment => true)
expect(out).to include("deployment mode")
expect(out).to include("You have added to the Gemfile")
expect(out).to include("* rack-obama")
@@ -136,7 +136,36 @@ RSpec.describe "install with --deployment or --frozen" do
expect(out).not_to include("You have changed in the Gemfile")
end
- it "can have --frozen set via an environment variable" do
+ it "works if a path gem is missing but is in a without group" do
+ build_lib "path_gem"
+ install_gemfile! <<-G
+ source "file://#{gem_repo1}"
+ gem "rake"
+ gem "path_gem", :path => "#{lib_path("path_gem-1.0")}", :group => :development
+ G
+ expect(the_bundle).to include_gems "path_gem 1.0"
+ FileUtils.rm_r lib_path("path_gem-1.0")
+
+ bundle! :install, forgotten_command_line_options(:path => ".bundle", :without => "development", :deployment => true).merge(:env => { :DEBUG => "1" })
+ run! "puts :WIN"
+ expect(out).to eq("WIN")
+ end
+
+ it "explodes if a path gem is missing" do
+ build_lib "path_gem"
+ install_gemfile! <<-G
+ source "file://#{gem_repo1}"
+ gem "rake"
+ gem "path_gem", :path => "#{lib_path("path_gem-1.0")}", :group => :development
+ G
+ expect(the_bundle).to include_gems "path_gem 1.0"
+ FileUtils.rm_r lib_path("path_gem-1.0")
+
+ bundle :install, forgotten_command_line_options(:path => ".bundle", :deployment => true)
+ expect(out).to include("The path `#{lib_path("path_gem-1.0")}` does not exist.")
+ end
+
+ it "can have --frozen set via an environment variable", :bundler => "< 2" do
gemfile <<-G
source "file://#{gem_repo1}"
gem "rack"
@@ -152,6 +181,22 @@ RSpec.describe "install with --deployment or --frozen" do
expect(out).not_to include("You have changed in the Gemfile")
end
+ it "can have --deployment set via an environment variable" do
+ gemfile <<-G
+ source "file://#{gem_repo1}"
+ gem "rack"
+ gem "rack-obama"
+ G
+
+ ENV["BUNDLE_DEPLOYMENT"] = "true"
+ bundle "install"
+ expect(out).to include("deployment mode")
+ expect(out).to include("You have added to the Gemfile")
+ expect(out).to include("* rack-obama")
+ expect(out).not_to include("You have deleted from the Gemfile")
+ expect(out).not_to include("You have changed in the Gemfile")
+ end
+
it "can have --frozen set to false via an environment variable" do
gemfile <<-G
source "file://#{gem_repo1}"
@@ -160,20 +205,21 @@ RSpec.describe "install with --deployment or --frozen" do
G
ENV["BUNDLE_FROZEN"] = "false"
+ ENV["BUNDLE_DEPLOYMENT"] = "false"
bundle "install"
expect(out).not_to include("deployment mode")
expect(out).not_to include("You have added to the Gemfile")
expect(out).not_to include("* rack-obama")
end
- it "explodes with the --frozen flag if you make a change and don't check in the lockfile" do
+ it "explodes with the --frozen flag if you make a change and don't check in the lockfile", :bundler => "< 2" do
gemfile <<-G
source "file://#{gem_repo1}"
gem "rack"
gem "rack-obama", "1.1"
G
- bundle "install --frozen"
+ bundle :install, forgotten_command_line_options(:frozen => true)
expect(out).to include("deployment mode")
expect(out).to include("You have added to the Gemfile")
expect(out).to include("* rack-obama (= 1.1)")
@@ -187,7 +233,7 @@ RSpec.describe "install with --deployment or --frozen" do
gem "activesupport"
G
- bundle "install --deployment"
+ bundle :install, forgotten_command_line_options(:deployment => true)
expect(out).to include("deployment mode")
expect(out).to include("You have added to the Gemfile:\n* activesupport\n\n")
expect(out).to include("You have deleted from the Gemfile:\n* rack")
@@ -200,7 +246,7 @@ RSpec.describe "install with --deployment or --frozen" do
gem "rack", :git => "git://hubz.com"
G
- bundle "install --deployment"
+ bundle :install, forgotten_command_line_options(:deployment => true)
expect(out).to include("deployment mode")
expect(out).to include("You have added to the Gemfile:\n* source: git://hubz.com (at master)")
expect(out).not_to include("You have changed in the Gemfile")
@@ -219,7 +265,7 @@ RSpec.describe "install with --deployment or --frozen" do
gem "rack"
G
- bundle "install --deployment"
+ bundle :install, forgotten_command_line_options(:deployment => true)
expect(out).to include("deployment mode")
expect(out).to include("You have deleted from the Gemfile:\n* source: #{lib_path("rack-1.0")} (at master@#{revision_for(lib_path("rack-1.0"))[0..6]}")
expect(out).not_to include("You have added to the Gemfile")
@@ -242,15 +288,93 @@ RSpec.describe "install with --deployment or --frozen" do
gem "foo", :git => "#{lib_path("rack")}"
G
- bundle "install --deployment"
+ bundle :install, forgotten_command_line_options(:deployment => true)
expect(out).to include("deployment mode")
expect(out).to include("You have changed in the Gemfile:\n* rack from `no specified source` to `#{lib_path("rack")} (at master@#{revision_for(lib_path("rack"))[0..6]})`")
expect(out).not_to include("You have added to the Gemfile")
expect(out).not_to include("You have deleted from the Gemfile")
end
+ context "when replacing a host with the same host with credentials" do
+ let(:success_message) do
+ if Bundler::VERSION.split(".", 2).first == "1"
+ "Could not reach host localgemserver.test"
+ else
+ "Bundle complete!"
+ end
+ end
+
+ before do
+ install_gemfile <<-G
+ source "http://user_name:password@localgemserver.test/"
+ gem "rack"
+ G
+
+ lockfile <<-G
+ GEM
+ remote: http://localgemserver.test/
+ specs:
+ rack (1.0.0)
+
+ PLATFORMS
+ #{local}
+
+ DEPENDENCIES
+ rack
+ G
+ end
+
+ it "prevents the replace by default" do
+ bundle :install, forgotten_command_line_options(:deployment => true)
+
+ expect(out).to match(/The list of sources changed/)
+ end
+
+ context "when allow_deployment_source_credential_changes is true" do
+ before { bundle! "config allow_deployment_source_credential_changes true" }
+
+ it "allows the replace" do
+ bundle :install, forgotten_command_line_options(:deployment => true)
+
+ expect(out).to match(/#{success_message}/)
+ end
+ end
+
+ context "when allow_deployment_source_credential_changes is false" do
+ before { bundle! "config allow_deployment_source_credential_changes false" }
+
+ it "prevents the replace" do
+ bundle :install, forgotten_command_line_options(:deployment => true)
+
+ expect(out).to match(/The list of sources changed/)
+ end
+ end
+
+ context "when BUNDLE_ALLOW_DEPLOYMENT_SOURCE_CREDENTIAL_CHANGES env var is true" do
+ before { ENV["BUNDLE_ALLOW_DEPLOYMENT_SOURCE_CREDENTIAL_CHANGES"] = "true" }
+
+ it "allows the replace" do
+ bundle :install, forgotten_command_line_options(:deployment => true)
+
+ expect(out).to match(/#{success_message}/)
+ end
+ end
+
+ context "when BUNDLE_ALLOW_DEPLOYMENT_SOURCE_CREDENTIAL_CHANGES env var is false" do
+ before { ENV["BUNDLE_ALLOW_DEPLOYMENT_SOURCE_CREDENTIAL_CHANGES"] = "false" }
+
+ it "prevents the replace" do
+ bundle :install, forgotten_command_line_options(:deployment => true)
+
+ expect(out).to match(/The list of sources changed/)
+ end
+ end
+ end
+
it "remembers that the bundle is frozen at runtime" do
- bundle "install --deployment"
+ bundle! :lock
+
+ bundle! "config deployment true"
gemfile <<-G
source "file://#{gem_repo1}"
@@ -281,19 +405,17 @@ You have deleted from the Gemfile:
bundle! :install
expect(the_bundle).to include_gems "foo 1.0"
- bundle! "package --all"
+ bundle! :package, forgotten_command_line_options([:all, :cache_all] => true)
expect(bundled_app("vendor/cache/foo")).to be_directory
bundle! "install --local"
- expect(out).to include("Using foo 1.0 from source at")
- expect(out).to include("vendor/cache/foo")
+ expect(out).to include("Updating files in vendor/cache")
simulate_new_machine
- bundle! "install --deployment --verbose"
+ bundle! "install --verbose", forgotten_command_line_options(:deployment => true)
expect(out).not_to include("You are trying to install in deployment mode after changing your Gemfile")
expect(out).not_to include("You have added to the Gemfile")
expect(out).not_to include("You have deleted from the Gemfile")
- expect(out).to include("Using foo 1.0 from source at")
expect(out).to include("vendor/cache/foo")
expect(the_bundle).to include_gems "foo 1.0"
end
diff --git a/spec/bundler/install/failure_spec.rb b/spec/bundler/install/failure_spec.rb
index 738b2cf1bd..896138c659 100644
--- a/spec/bundler/install/failure_spec.rb
+++ b/spec/bundler/install/failure_spec.rb
@@ -1,5 +1,4 @@
# frozen_string_literal: true
-require "spec_helper"
RSpec.describe "bundle install" do
context "installing a gem fails" do
@@ -19,7 +18,7 @@ RSpec.describe "bundle install" do
source "file:#{gem_repo2}"
gem "rails"
G
- expect(out).to end_with(<<-M.strip)
+ expect(last_command.bundler_err).to end_with(<<-M.strip)
An error occurred while installing activesupport (2.3.2), and Bundler cannot continue.
Make sure that `gem install activesupport -v '2.3.2'` succeeds before bundling.
diff --git a/spec/bundler/install/force_spec.rb b/spec/bundler/install/force_spec.rb
index dc4956a7ae..52fa4f0d61 100644
--- a/spec/bundler/install/force_spec.rb
+++ b/spec/bundler/install/force_spec.rb
@@ -1,66 +1,61 @@
# frozen_string_literal: true
-require "spec_helper"
RSpec.describe "bundle install" do
- describe "with --force" do
- before :each do
- gemfile <<-G
- source "file://#{gem_repo1}"
- gem "rack"
- G
- end
+ %w[force redownload].each do |flag|
+ describe_opts = {}
+ describe_opts[:bundler] = "< 2" if flag == "force"
+ describe "with --#{flag}", describe_opts do
+ before :each do
+ gemfile <<-G
+ source "file://#{gem_repo1}"
+ gem "rack"
+ G
+ end
- it "re-installs installed gems" do
- rack_lib = default_bundle_path("gems/rack-1.0.0/lib/rack.rb")
+ it "re-installs installed gems" do
+ rack_lib = default_bundle_path("gems/rack-1.0.0/lib/rack.rb")
- bundle "install"
- rack_lib.open("w") {|f| f.write("blah blah blah") }
- bundle "install --force"
+ bundle! :install
+ rack_lib.open("w") {|f| f.write("blah blah blah") }
+ bundle! :install, flag => true
- expect(exitstatus).to eq(0) if exitstatus
- expect(out).to include "Using bundler"
- expect(out).to include "Installing rack 1.0.0"
- expect(rack_lib.open(&:read)).to eq("RACK = '1.0.0'\n")
- expect(the_bundle).to include_gems "rack 1.0.0"
- end
+ expect(out).to include "Installing rack 1.0.0"
+ expect(rack_lib.open(&:read)).to eq("RACK = '1.0.0'\n")
+ expect(the_bundle).to include_gems "rack 1.0.0"
+ end
- it "works on first bundle install" do
- bundle "install --force"
+ it "works on first bundle install" do
+ bundle! :install, flag => true
- expect(exitstatus).to eq(0) if exitstatus
- expect(out).to include "Using bundler"
- expect(out).to include "Installing rack 1.0.0"
- expect(the_bundle).to include_gems "rack 1.0.0"
- end
+ expect(out).to include "Installing rack 1.0.0"
+ expect(the_bundle).to include_gems "rack 1.0.0"
+ end
- context "with a git gem" do
- let!(:ref) { build_git("foo", "1.0").ref_for("HEAD", 11) }
+ context "with a git gem" do
+ let!(:ref) { build_git("foo", "1.0").ref_for("HEAD", 11) }
- before do
- gemfile <<-G
- gem "foo", :git => "#{lib_path("foo-1.0")}"
- G
- end
+ before do
+ gemfile <<-G
+ gem "foo", :git => "#{lib_path("foo-1.0")}"
+ G
+ end
- it "re-installs installed gems" do
- foo_lib = default_bundle_path("bundler/gems/foo-1.0-#{ref}/lib/foo.rb")
+ it "re-installs installed gems" do
+ foo_lib = default_bundle_path("bundler/gems/foo-1.0-#{ref}/lib/foo.rb")
- bundle! "install"
- foo_lib.open("w") {|f| f.write("blah blah blah") }
- bundle! "install --force"
+ bundle! :install
+ foo_lib.open("w") {|f| f.write("blah blah blah") }
+ bundle! :install, flag => true
- expect(out).to include "Using bundler"
- expect(out).to include "Using foo 1.0 from #{lib_path("foo-1.0")} (at master@#{ref[0, 7]})"
- expect(foo_lib.open(&:read)).to eq("FOO = '1.0'\n")
- expect(the_bundle).to include_gems "foo 1.0"
- end
+ expect(foo_lib.open(&:read)).to eq("FOO = '1.0'\n")
+ expect(the_bundle).to include_gems "foo 1.0"
+ end
- it "works on first bundle install" do
- bundle! "install --force"
+ it "works on first bundle install" do
+ bundle! :install, flag => true
- expect(out).to include "Using bundler"
- expect(out).to include "Using foo 1.0 from #{lib_path("foo-1.0")} (at master@#{ref[0, 7]})"
- expect(the_bundle).to include_gems "foo 1.0"
+ expect(the_bundle).to include_gems "foo 1.0"
+ end
end
end
end
diff --git a/spec/bundler/install/gemfile/eval_gemfile_spec.rb b/spec/bundler/install/gemfile/eval_gemfile_spec.rb
index f02223d34d..035d3692aa 100644
--- a/spec/bundler/install/gemfile/eval_gemfile_spec.rb
+++ b/spec/bundler/install/gemfile/eval_gemfile_spec.rb
@@ -1,5 +1,4 @@
# frozen_string_literal: true
-require "spec_helper"
RSpec.describe "bundle install with gemfile that uses eval_gemfile" do
before do
@@ -21,8 +20,9 @@ RSpec.describe "bundle install with gemfile that uses eval_gemfile" do
eval_gemfile 'Gemfile-other'
G
expect(out).to include("Resolving dependencies")
- expect(out).to include("Using gunks 0.0.1 from source at `gems/gunks`")
expect(out).to include("Bundle complete")
+
+ expect(the_bundle).to include_gem "gunks 0.0.1", :source => "path@#{bundled_app("gems", "gunks")}"
end
end
@@ -47,7 +47,7 @@ RSpec.describe "bundle install with gemfile that uses eval_gemfile" do
# parsed lockfile and the evaluated gemfile.
it "bundles with --deployment" do
bundle! :install
- bundle! "install --deployment"
+ bundle! :install, forgotten_command_line_options(:deployment => true)
end
end
@@ -60,8 +60,23 @@ RSpec.describe "bundle install with gemfile that uses eval_gemfile" do
gemspec :path => 'gems/gunks'
G
expect(out).to include("Resolving dependencies")
- expect(out).to include("Using gunks 0.0.1 from source at `gems/gunks`")
expect(out).to include("Bundle complete")
+
+ expect(the_bundle).to include_gem "gunks 0.0.1", :source => "path@#{bundled_app("gems", "gunks")}"
+ end
+ end
+
+ context "eval-ed Gemfile references other gemfiles" do
+ it "works with relative paths" do
+ create_file "other/Gemfile-other", "gem 'rack'"
+ create_file "other/Gemfile", "eval_gemfile 'Gemfile-other'"
+ create_file "Gemfile-alt", <<-G
+ source "file:#{gem_repo1}"
+ eval_gemfile "other/Gemfile"
+ G
+ install_gemfile! "eval_gemfile File.expand_path('Gemfile-alt')"
+
+ expect(the_bundle).to include_gem "rack 1.0.0"
end
end
end
diff --git a/spec/bundler/install/gemfile/gemspec_spec.rb b/spec/bundler/install/gemfile/gemspec_spec.rb
index 1ea613c9d2..1dc016ed23 100644
--- a/spec/bundler/install/gemfile/gemspec_spec.rb
+++ b/spec/bundler/install/gemfile/gemspec_spec.rb
@@ -1,10 +1,11 @@
# frozen_string_literal: true
-require "spec_helper"
RSpec.describe "bundle install from an existing gemspec" do
before(:each) do
- build_gem "bar", :to_system => true
- build_gem "bar-dev", :to_system => true
+ build_repo2 do
+ build_gem "bar"
+ build_gem "bar-dev"
+ end
end
it "should install runtime and development dependencies" do
@@ -40,8 +41,10 @@ RSpec.describe "bundle install from an existing gemspec" do
end
it "should handle a list of requirements" do
- build_gem "baz", "1.0", :to_system => true
- build_gem "baz", "1.1", :to_system => true
+ update_repo2 do
+ build_gem "baz", "1.0"
+ build_gem "baz", "1.1"
+ end
build_lib("foo", :path => tmp.join("foo")) do |s|
s.write("Gemfile", "source :rubygems\ngemspec")
@@ -58,11 +61,11 @@ RSpec.describe "bundle install from an existing gemspec" do
it "should raise if there are no gemspecs available" do
build_lib("foo", :path => tmp.join("foo"), :gemspec => false)
- error = install_gemfile(<<-G)
+ install_gemfile(<<-G)
source "file://#{gem_repo2}"
gemspec :path => '#{tmp.join("foo")}'
G
- expect(error).to match(/There are no gemspecs at #{tmp.join('foo')}/)
+ expect(last_command.bundler_err).to match(/There are no gemspecs at #{tmp.join('foo')}/)
end
it "should raise if there are too many gemspecs available" do
@@ -70,11 +73,11 @@ RSpec.describe "bundle install from an existing gemspec" do
s.write("foo2.gemspec", build_spec("foo", "4.0").first.to_ruby)
end
- error = install_gemfile(<<-G)
+ install_gemfile(<<-G)
source "file://#{gem_repo2}"
gemspec :path => '#{tmp.join("foo")}'
G
- expect(error).to match(/There are multiple gemspecs at #{tmp.join('foo')}/)
+ expect(last_command.bundler_err).to match(/There are multiple gemspecs at #{tmp.join('foo')}/)
end
it "should pick a specific gemspec" do
@@ -142,7 +145,9 @@ RSpec.describe "bundle install from an existing gemspec" do
G
bundle! "install", :verbose => true
- expect(out).to include("Found no changes, using resolution from the lockfile")
+
+ message = "Found no changes, using resolution from the lockfile"
+ expect(out.scan(message).size).to eq(1)
end
it "should match a lockfile without needing to re-resolve with development dependencies" do
@@ -159,7 +164,9 @@ RSpec.describe "bundle install from an existing gemspec" do
G
bundle! "install", :verbose => true
- expect(out).to include("Found no changes, using resolution from the lockfile")
+
+ message = "Found no changes, using resolution from the lockfile"
+ expect(out.scan(message).size).to eq(1)
end
it "should match a lockfile on non-ruby platforms with a transitive platform dependency" do
@@ -170,7 +177,7 @@ RSpec.describe "bundle install from an existing gemspec" do
s.add_dependency "platform_specific"
end
- install_gem "platform_specific-1.0-java"
+ system_gems "platform_specific-1.0-java", :path => :bundle_path, :keep_path => true
install_gemfile! <<-G
gemspec :path => '#{tmp.join("foo")}'
@@ -189,15 +196,16 @@ RSpec.describe "bundle install from an existing gemspec" do
install_gemfile <<-G
gemspec :path => '#{tmp.join("foo")}'
G
- expect(@err).not_to match(/ahh/)
+ expect(last_command.stdboth).not_to include("ahh")
end
it "allows the gemspec to activate other gems" do
+ ENV["BUNDLE_PATH__SYSTEM"] = "true"
# see https://github.com/bundler/bundler/issues/5409
#
# issue was caused by rubygems having an unresolved gem during a require,
# so emulate that
- system_gems %w(rack-1.0.0 rack-0.9.1 rack-obama-1.0)
+ system_gems %w[rack-1.0.0 rack-0.9.1 rack-obama-1.0]
build_lib("foo", :path => bundled_app)
gemspec = bundled_app("foo.gemspec").read
@@ -217,10 +225,10 @@ RSpec.describe "bundle install from an existing gemspec" do
s.version = "1.0.0"
s.add_dependency "bar", "= 1.0.0"
end
- build_gem "deps", :to_system => true do |s|
+ build_gem "deps", :to_bundle => true do |s|
s.add_dependency "foo", "= 0.0.1"
end
- build_gem "foo", "0.0.1", :to_system => true
+ build_gem "foo", "0.0.1", :to_bundle => true
install_gemfile <<-G
source "file://#{gem_repo2}"
@@ -236,7 +244,7 @@ RSpec.describe "bundle install from an existing gemspec" do
s.version = "1.0.0"
s.add_dependency "bar", "= 1.0.0"
end
- build_repo2 do
+ update_repo2 do
build_gem "deps" do |s|
s.add_dependency "foo", "= 0.0.1"
end
@@ -273,7 +281,7 @@ RSpec.describe "bundle install from an existing gemspec" do
s.add_dependency "activesupport", ">= 1.0.1"
end
- bundle "install --deployment"
+ bundle :install, forgotten_command_line_options(:deployment => true)
expect(out).to include("changed")
end
@@ -415,7 +423,7 @@ RSpec.describe "bundle install from an existing gemspec" do
end
end
- %w(ruby jruby).each do |platform|
+ %w[ruby jruby].each do |platform|
simulate_platform(platform) do
install_gemfile <<-G
source "file://#{gem_repo2}"
@@ -425,7 +433,7 @@ RSpec.describe "bundle install from an existing gemspec" do
end
end
- context "on ruby" do
+ context "on ruby", :bundler => "< 2" do
before do
simulate_platform("ruby")
bundle :install
@@ -525,6 +533,107 @@ RSpec.describe "bundle install from an existing gemspec" do
end
end
end
+
+ context "on ruby", :bundler => "2" do
+ before do
+ simulate_platform("ruby")
+ bundle :install
+ end
+
+ context "as a runtime dependency" do
+ it "keeps java dependencies in the lockfile" do
+ expect(the_bundle).to include_gems "foo 1.0", "platform_specific 1.0 RUBY"
+ expect(lockfile).to eq strip_whitespace(<<-L)
+ GEM
+ remote: file:#{gem_repo2}/
+ specs:
+ platform_specific (1.0)
+ platform_specific (1.0-java)
+
+ PATH
+ remote: .
+ specs:
+ foo (1.0)
+ platform_specific
+
+ PLATFORMS
+ java
+ ruby
+
+ DEPENDENCIES
+ foo!
+
+ BUNDLED WITH
+ #{Bundler::VERSION}
+ L
+ end
+ end
+
+ context "as a development dependency" do
+ let(:platform_specific_type) { :development }
+
+ it "keeps java dependencies in the lockfile" do
+ expect(the_bundle).to include_gems "foo 1.0", "platform_specific 1.0 RUBY"
+ expect(lockfile).to eq strip_whitespace(<<-L)
+ GEM
+ remote: file:#{gem_repo2}/
+ specs:
+ platform_specific (1.0)
+ platform_specific (1.0-java)
+
+ PATH
+ remote: .
+ specs:
+ foo (1.0)
+
+ PLATFORMS
+ java
+ ruby
+
+ DEPENDENCIES
+ foo!
+ platform_specific
+
+ BUNDLED WITH
+ #{Bundler::VERSION}
+ L
+ end
+ end
+
+ context "with an indirect platform-specific development dependency" do
+ let(:platform_specific_type) { :development }
+ let(:dependency) { "indirect_platform_specific" }
+
+ it "keeps java dependencies in the lockfile" do
+ expect(the_bundle).to include_gems "foo 1.0", "indirect_platform_specific 1.0", "platform_specific 1.0 RUBY"
+ expect(lockfile).to eq strip_whitespace(<<-L)
+ GEM
+ remote: file:#{gem_repo2}/
+ specs:
+ indirect_platform_specific (1.0)
+ platform_specific
+ platform_specific (1.0)
+ platform_specific (1.0-java)
+
+ PATH
+ remote: .
+ specs:
+ foo (1.0)
+
+ PLATFORMS
+ java
+ ruby
+
+ DEPENDENCIES
+ foo!
+ indirect_platform_specific
+
+ BUNDLED WITH
+ #{Bundler::VERSION}
+ L
+ end
+ end
+ end
end
end
@@ -551,7 +660,7 @@ RSpec.describe "bundle install from an existing gemspec" do
it "installs the ruby platform gemspec and skips dev deps with --without development" do
simulate_platform "ruby"
- install_gemfile! <<-G, :without => "development"
+ install_gemfile! <<-G, forgotten_command_line_options(:without => "development")
source "file://#{gem_repo1}"
gemspec :path => '#{tmp.join("foo")}', :name => 'foo'
G
diff --git a/spec/bundler/install/gemfile/git_spec.rb b/spec/bundler/install/gemfile/git_spec.rb
index 5868c76570..57d83a5295 100644
--- a/spec/bundler/install/gemfile/git_spec.rb
+++ b/spec/bundler/install/gemfile/git_spec.rb
@@ -1,5 +1,4 @@
# frozen_string_literal: true
-require "spec_helper"
RSpec.describe "bundle install with git sources" do
describe "when floating on master" do
@@ -27,8 +26,15 @@ RSpec.describe "bundle install with git sources" do
expect(out).to eq("WIN")
end
- it "caches the git repo" do
- expect(Dir["#{default_bundle_path}/cache/bundler/git/foo-1.0-*"].size).to eq(1)
+ it "caches the git repo", :bundler => "< 2" do
+ expect(Dir["#{default_bundle_path}/cache/bundler/git/foo-1.0-*"]).to have_attributes :size => 1
+ end
+
+ it "caches the git repo globally" do
+ simulate_new_machine
+ bundle! "config global_gem_cache true"
+ bundle! :install
+ expect(Dir["#{home}/.bundle/cache/git/foo-1.0-*"]).to have_attributes :size => 1
end
it "caches the evaluated gemspec" do
@@ -81,7 +87,7 @@ RSpec.describe "bundle install with git sources" do
gem "foo", "1.1", :git => "#{lib_path("foo-1.0")}"
G
- expect(out).to include("Source contains 'foo' at: 1.0 ruby")
+ expect(out).to include("The source contains 'foo' at: 1.0")
end
it "complains with version and platform if pinned specs don't exist in the git repo" do
@@ -97,7 +103,7 @@ RSpec.describe "bundle install with git sources" do
end
G
- expect(out).to include("Source contains 'only_java' at: 1.0 java")
+ expect(out).to include("The source contains 'only_java' at: 1.0 java")
end
it "complains with multiple versions and platforms if pinned specs don't exist in the git repo" do
@@ -118,7 +124,7 @@ RSpec.describe "bundle install with git sources" do
end
G
- expect(out).to include("Source contains 'only_java' at: 1.0 java, 1.1 java")
+ expect(out).to include("The source contains 'only_java' at: 1.0 java, 1.1 java")
end
it "still works after moving the application directory" do
@@ -207,6 +213,95 @@ RSpec.describe "bundle install with git sources" do
expect(out).to eq("WIN")
end
+
+ it "works when the revision is a non-head ref" do
+ # want to ensure we don't fallback to master
+ update_git "foo", :path => lib_path("foo-1.0") do |s|
+ s.write("lib/foo.rb", "raise 'FAIL'")
+ end
+
+ Dir.chdir(lib_path("foo-1.0")) do
+ `git update-ref -m 'Bundler Spec!' refs/bundler/1 master~1`
+ end
+
+ # want to ensure we don't fallback to HEAD
+ update_git "foo", :path => lib_path("foo-1.0"), :branch => "rando" do |s|
+ s.write("lib/foo.rb", "raise 'FAIL'")
+ end
+
+ install_gemfile! <<-G
+ git "#{lib_path("foo-1.0")}", :ref => "refs/bundler/1" do
+ gem "foo"
+ end
+ G
+ expect(err).to lack_errors
+
+ run! <<-RUBY
+ require 'foo'
+ puts "WIN" if defined?(FOO)
+ RUBY
+
+ expect(out).to eq("WIN")
+ end
+
+ it "works when the revision is a non-head ref and it was previously downloaded" do
+ install_gemfile! <<-G
+ git "#{lib_path("foo-1.0")}" do
+ gem "foo"
+ end
+ G
+
+ # want to ensure we don't fallback to master
+ update_git "foo", :path => lib_path("foo-1.0") do |s|
+ s.write("lib/foo.rb", "raise 'FAIL'")
+ end
+
+ Dir.chdir(lib_path("foo-1.0")) do
+ `git update-ref -m 'Bundler Spec!' refs/bundler/1 master~1`
+ end
+
+ # want to ensure we don't fallback to HEAD
+ update_git "foo", :path => lib_path("foo-1.0"), :branch => "rando" do |s|
+ s.write("lib/foo.rb", "raise 'FAIL'")
+ end
+
+ install_gemfile! <<-G
+ git "#{lib_path("foo-1.0")}", :ref => "refs/bundler/1" do
+ gem "foo"
+ end
+ G
+ expect(err).to lack_errors
+
+ run! <<-RUBY
+ require 'foo'
+ puts "WIN" if defined?(FOO)
+ RUBY
+
+ expect(out).to eq("WIN")
+ end
+
+ it "does not download random non-head refs" do
+ Dir.chdir(lib_path("foo-1.0")) do
+ sys_exec!("git update-ref -m 'Bundler Spec!' refs/bundler/1 master~1")
+ end
+
+ bundle! "config global_gem_cache true"
+
+ install_gemfile! <<-G
+ git "#{lib_path("foo-1.0")}" do
+ gem "foo"
+ end
+ G
+
+ # ensure we also git fetch after cloning
+ bundle! :update, :all => bundle_update_requires_all?
+
+ Dir.chdir(Dir[home(".bundle/cache/git/foo-*")].first) do
+ sys_exec("git ls-remote .")
+ end
+
+ expect(out).not_to include("refs/bundler/1")
+ end
end
describe "when specifying a branch" do
@@ -311,9 +406,8 @@ RSpec.describe "bundle install with git sources" do
gem "rack", :git => "#{lib_path("rack-0.8")}", :branch => "master"
G
- bundle %(config local.rack #{lib_path("local-rack")})
- bundle :install
- expect(out).to match(/at #{lib_path('local-rack')}/)
+ bundle! %(config local.rack #{lib_path("local-rack")})
+ bundle! :install
run "require 'rack'"
expect(out).to eq("LOCAL")
@@ -704,14 +798,14 @@ RSpec.describe "bundle install with git sources" do
s.write "lib/forced.rb", "FORCED = '1.1'"
end
- bundle "update"
+ bundle "update", :all => bundle_update_requires_all?
expect(the_bundle).to include_gems "forced 1.1"
Dir.chdir(lib_path("forced-1.0")) do
`git reset --hard HEAD^`
end
- bundle "update"
+ bundle "update", :all => bundle_update_requires_all?
expect(the_bundle).to include_gems "forced 1.0"
end
@@ -808,6 +902,7 @@ RSpec.describe "bundle install with git sources" do
it "prints a friendly error if a file blocks the git repo" do
build_git "foo"
+ FileUtils.mkdir_p(default_bundle_path)
FileUtils.touch(default_bundle_path("bundler"))
install_gemfile <<-G
@@ -937,8 +1032,7 @@ RSpec.describe "bundle install with git sources" do
simulate_new_machine
- bundle "install --deployment"
- expect(exitstatus).to eq(0) if exitstatus
+ bundle! :install, forgotten_command_line_options(:deployment => true)
end
end
@@ -1034,7 +1128,7 @@ RSpec.describe "bundle install with git sources" do
run! <<-R
puts $:.grep(/ext/)
R
- expect(out).to eq(Pathname.glob(system_gem_path("bundler/gems/extensions/**/foo-1.0-*")).first.to_s)
+ expect(out).to eq(Pathname.glob(default_bundle_path("bundler/gems/extensions/**/foo-1.0-*")).first.to_s)
end
it "does not use old extension after ref changes", :ruby_repo do
@@ -1058,11 +1152,11 @@ RSpec.describe "bundle install with git sources" do
end
`git commit -m 'commit for iteration #{i}' ext/foo.c`
end
- git_sha = git_reader.ref_for("HEAD")
+ git_commit_sha = git_reader.ref_for("HEAD")
install_gemfile <<-G
source "file://#{gem_repo1}"
- gem "foo", :git => "#{lib_path("foo-1.0")}", :ref => "#{git_sha}"
+ gem "foo", :git => "#{lib_path("foo-1.0")}", :ref => "#{git_commit_sha}"
G
run <<-R
@@ -1090,7 +1184,7 @@ RSpec.describe "bundle install with git sources" do
gem "foo", :git => "#{lib_path("foo-1.0")}"
G
- expect(out).to end_with(<<-M.strip)
+ expect(last_command.bundler_err).to end_with(<<-M.strip)
An error occurred while installing foo (1.0), and Bundler cannot continue.
In Gemfile:
@@ -1174,9 +1268,10 @@ In Gemfile:
G
with_path_as("") do
- bundle "update"
+ bundle "update", :all => bundle_update_requires_all?
end
- expect(out).to include("You need to install git to be able to use gems from git repositories. For help installing git, please refer to GitHub's tutorial at https://help.github.com/articles/set-up-git")
+ expect(last_command.bundler_err).
+ to include("You need to install git to be able to use gems from git repositories. For help installing git, please refer to GitHub's tutorial at https://help.github.com/articles/set-up-git")
end
it "installs a packaged git gem successfully" do
@@ -1187,18 +1282,17 @@ In Gemfile:
gem 'foo'
end
G
- bundle "package --all"
+ bundle :package, forgotten_command_line_options([:all, :cache_all] => true)
simulate_new_machine
- bundle "install", :env => { "PATH" => "" }
+ bundle! "install", :env => { "PATH" => "" }
expect(out).to_not include("You need to install git to be able to use gems from git repositories.")
- expect(exitstatus).to be_zero if exitstatus
end
end
- describe "when the git source is overriden with a local git repo" do
+ describe "when the git source is overridden with a local git repo" do
before do
- bundle "config --global local.foo #{lib_path("foo")}"
+ bundle! "config --global local.foo #{lib_path("foo")}"
end
describe "and git output is colorized" do
@@ -1233,9 +1327,8 @@ In Gemfile:
G
bundle :install
- expect(out).to_not include("password1")
- expect(err).to_not include("password1")
- expect(out).to include("Fetching https://user1@github.com/company/private-repo")
+ expect(last_command.stdboth).to_not include("password1")
+ expect(last_command.stdout).to include("Fetching https://user1@github.com/company/private-repo")
end
end
@@ -1250,9 +1343,8 @@ In Gemfile:
G
bundle :install
- expect(out).to_not include("oauth_token")
- expect(err).to_not include("oauth_token")
- expect(out).to include("Fetching https://x-oauth-basic@github.com/company/private-repo")
+ expect(last_command.stdboth).to_not include("oauth_token")
+ expect(last_command.stdout).to include("Fetching https://x-oauth-basic@github.com/company/private-repo")
end
end
end
diff --git a/spec/bundler/install/gemfile/groups_spec.rb b/spec/bundler/install/gemfile/groups_spec.rb
index a3a5eeefdf..19c379e188 100644
--- a/spec/bundler/install/gemfile/groups_spec.rb
+++ b/spec/bundler/install/gemfile/groups_spec.rb
@@ -1,5 +1,4 @@
# frozen_string_literal: true
-require "spec_helper"
RSpec.describe "bundle install with groups" do
describe "installing with no options" do
@@ -87,7 +86,7 @@ RSpec.describe "bundle install with groups" do
end
it "installs gems in the default group" do
- bundle :install, :without => "emo"
+ bundle! :install, forgotten_command_line_options(:without => "emo")
expect(the_bundle).to include_gems "rack 1.0.0", :groups => [:default]
end
@@ -97,20 +96,20 @@ RSpec.describe "bundle install with groups" do
end
it "does not install gems from the previously excluded group" do
- bundle :install, :without => "emo"
+ bundle :install, forgotten_command_line_options(:without => "emo")
expect(the_bundle).not_to include_gems "activesupport 2.3.5"
bundle :install
expect(the_bundle).not_to include_gems "activesupport 2.3.5"
end
it "does not say it installed gems from the excluded group" do
- bundle :install, :without => "emo"
+ bundle! :install, forgotten_command_line_options(:without => "emo")
expect(out).not_to include("activesupport")
end
it "allows Bundler.setup for specific groups" do
- bundle :install, :without => "emo"
- run("require 'rack'; puts RACK", :default)
+ bundle :install, forgotten_command_line_options(:without => "emo")
+ run!("require 'rack'; puts RACK", :default)
expect(out).to eq("1.0.0")
end
@@ -123,15 +122,15 @@ RSpec.describe "bundle install with groups" do
end
G
- bundle :install, :without => "emo"
+ bundle :install, forgotten_command_line_options(:without => "emo")
expect(the_bundle).to include_gems "activesupport 2.3.2", :groups => [:default]
end
it "still works on a different machine and excludes gems" do
- bundle :install, :without => "emo"
+ bundle :install, forgotten_command_line_options(:without => "emo")
simulate_new_machine
- bundle :install, :without => "emo"
+ bundle :install, forgotten_command_line_options(:without => "emo")
expect(the_bundle).to include_gems "rack 1.0.0", :groups => [:default]
expect(the_bundle).not_to include_gems "activesupport 2.3.5", :groups => [:default]
@@ -150,14 +149,14 @@ RSpec.describe "bundle install with groups" do
end
it "clears without when passed an empty list" do
- bundle :install, :without => "emo"
+ bundle :install, forgotten_command_line_options(:without => "emo")
- bundle 'install --without ""'
+ bundle :install, forgotten_command_line_options(:without => "")
expect(the_bundle).to include_gems "activesupport 2.3.5"
end
it "doesn't clear without when nothing is passed" do
- bundle :install, :without => "emo"
+ bundle :install, forgotten_command_line_options(:without => "emo")
bundle :install
expect(the_bundle).not_to include_gems "activesupport 2.3.5"
@@ -169,12 +168,12 @@ RSpec.describe "bundle install with groups" do
end
it "does install gems from the optional group when requested" do
- bundle :install, :with => "debugging"
+ bundle :install, forgotten_command_line_options(:with => "debugging")
expect(the_bundle).to include_gems "thin 1.0"
end
it "does install gems from the previously requested group" do
- bundle :install, :with => "debugging"
+ bundle :install, forgotten_command_line_options(:with => "debugging")
expect(the_bundle).to include_gems "thin 1.0"
bundle :install
expect(the_bundle).to include_gems "thin 1.0"
@@ -188,41 +187,55 @@ RSpec.describe "bundle install with groups" do
end
it "clears with when passed an empty list" do
- bundle :install, :with => "debugging"
- bundle 'install --with ""'
+ bundle :install, forgotten_command_line_options(:with => "debugging")
+ bundle :install, forgotten_command_line_options(:with => "")
expect(the_bundle).not_to include_gems "thin 1.0"
end
- it "does remove groups from without when passed at with" do
- bundle :install, :without => "emo"
- bundle :install, :with => "emo"
+ it "does remove groups from without when passed at --with", :bundler => "< 2" do
+ bundle :install, forgotten_command_line_options(:without => "emo")
+ bundle :install, forgotten_command_line_options(:with => "emo")
expect(the_bundle).to include_gems "activesupport 2.3.5"
end
- it "does remove groups from with when passed at without" do
- bundle :install, :with => "debugging"
- bundle :install, :without => "debugging"
- expect(the_bundle).not_to include_gems "thin 1.0"
+ it "does remove groups from with when passed at --without", :bundler => "< 2" do
+ bundle :install, forgotten_command_line_options(:with => "debugging")
+ bundle :install, forgotten_command_line_options(:without => "debugging")
+ expect(the_bundle).not_to include_gem "thin 1.0"
end
- it "errors out when passing a group to with and without" do
- bundle :install, :with => "emo debugging", :without => "emo"
+ it "errors out when passing a group to with and without via CLI flags", :bundler => "< 2" do
+ bundle :install, forgotten_command_line_options(:with => "emo debugging", :without => "emo")
+ expect(last_command).to be_failure
expect(out).to include("The offending groups are: emo")
end
+ it "allows the BUNDLE_WITH setting to override BUNDLE_WITHOUT" do
+ ENV["BUNDLE_WITH"] = "debugging"
+
+ bundle! :install
+ expect(the_bundle).to include_gem "thin 1.0"
+
+ ENV["BUNDLE_WITHOUT"] = "debugging"
+ expect(the_bundle).to include_gem "thin 1.0"
+
+ bundle! :install
+ expect(the_bundle).to include_gem "thin 1.0"
+ end
+
it "can add and remove a group at the same time" do
- bundle :install, :with => "debugging", :without => "emo"
+ bundle :install, forgotten_command_line_options(:with => "debugging", :without => "emo")
expect(the_bundle).to include_gems "thin 1.0"
expect(the_bundle).not_to include_gems "activesupport 2.3.5"
end
it "does have no effect when listing a not optional group in with" do
- bundle :install, :with => "emo"
+ bundle :install, forgotten_command_line_options(:with => "emo")
expect(the_bundle).to include_gems "activesupport 2.3.5"
end
it "does have no effect when listing an optional group in without" do
- bundle :install, :without => "debugging"
+ bundle :install, forgotten_command_line_options(:without => "debugging")
expect(the_bundle).not_to include_gems "thin 1.0"
end
end
@@ -239,12 +252,12 @@ RSpec.describe "bundle install with groups" do
end
it "installs gems in the default group" do
- bundle :install, :without => "emo lolercoaster"
+ bundle! :install, forgotten_command_line_options(:without => "emo lolercoaster")
expect(the_bundle).to include_gems "rack 1.0.0"
end
it "installs the gem if any of its groups are installed" do
- bundle "install --without emo"
+ bundle! :install, forgotten_command_line_options(:without => "emo")
expect(the_bundle).to include_gems "rack 1.0.0", "activesupport 2.3.5"
end
@@ -265,22 +278,22 @@ RSpec.describe "bundle install with groups" do
end
it "installs the gem w/ option --without emo" do
- bundle "install --without emo"
+ bundle :install, forgotten_command_line_options(:without => "emo")
expect(the_bundle).to include_gems "activesupport 2.3.5"
end
it "installs the gem w/ option --without lolercoaster" do
- bundle "install --without lolercoaster"
+ bundle :install, forgotten_command_line_options(:without => "lolercoaster")
expect(the_bundle).to include_gems "activesupport 2.3.5"
end
it "does not install the gem w/ option --without emo lolercoaster" do
- bundle "install --without emo lolercoaster"
+ bundle :install, forgotten_command_line_options(:without => "emo lolercoaster")
expect(the_bundle).not_to include_gems "activesupport 2.3.5"
end
it "does not install the gem w/ option --without 'emo lolercoaster'" do
- bundle "install --without 'emo lolercoaster'"
+ bundle :install, forgotten_command_line_options(:without => "'emo lolercoaster'")
expect(the_bundle).not_to include_gems "activesupport 2.3.5"
end
end
@@ -300,12 +313,12 @@ RSpec.describe "bundle install with groups" do
end
it "installs gems in the default group" do
- bundle :install, :without => "emo lolercoaster"
+ bundle! :install, forgotten_command_line_options(:without => "emo lolercoaster")
expect(the_bundle).to include_gems "rack 1.0.0"
end
it "installs the gem if any of its groups are installed" do
- bundle "install --without emo"
+ bundle! :install, forgotten_command_line_options(:without => "emo")
expect(the_bundle).to include_gems "rack 1.0.0", "activesupport 2.3.5"
end
end
@@ -340,7 +353,7 @@ RSpec.describe "bundle install with groups" do
before(:each) do
build_repo2
system_gems "rack-0.9.1" do
- install_gemfile <<-G, :without => :rack
+ install_gemfile <<-G, forgotten_command_line_options(:without => "rack")
source "file://#{gem_repo2}"
gem "rack"
@@ -364,8 +377,8 @@ RSpec.describe "bundle install with groups" do
it "does not hit the remote a second time" do
FileUtils.rm_rf gem_repo2
- bundle "install --without rack"
- expect(err).to lack_errors
+ bundle! :install, forgotten_command_line_options(:without => "rack").merge(:verbose => true)
+ expect(last_command.stdboth).not_to match(/fetching/i)
end
end
end
diff --git a/spec/bundler/install/gemfile/install_if.rb b/spec/bundler/install/gemfile/install_if.rb
index b1717ad583..1319051fdb 100644
--- a/spec/bundler/install/gemfile/install_if.rb
+++ b/spec/bundler/install/gemfile/install_if.rb
@@ -1,5 +1,4 @@
# frozen_string_literal: true
-require "spec_helper"
describe "bundle install with install_if conditionals" do
it "follows the install_if DSL" do
diff --git a/spec/bundler/install/gemfile/lockfile_spec.rb b/spec/bundler/install/gemfile/lockfile_spec.rb
new file mode 100644
index 0000000000..dc1baca6ea
--- /dev/null
+++ b/spec/bundler/install/gemfile/lockfile_spec.rb
@@ -0,0 +1,48 @@
+# frozen_string_literal: true
+
+RSpec.describe "bundle install with a lockfile present" do
+ let(:gf) { <<-G }
+ source "file://#{gem_repo1}"
+
+ gem "rack", "1.0.0"
+ G
+
+ subject do
+ install_gemfile(gf)
+ end
+
+ context "gemfile evaluation" do
+ let(:gf) { super() + "\n\n File.open('evals', 'a') {|f| f << %(1\n) } unless ENV['BUNDLER_SPEC_NO_APPEND']" }
+
+ context "with plugins disabled" do
+ before do
+ bundle! "config plugins false"
+ subject
+ end
+
+ it "does not evaluate the gemfile twice" do
+ bundle! :install
+
+ with_env_vars("BUNDLER_SPEC_NO_APPEND" => "1") { expect(the_bundle).to include_gem "rack 1.0.0" }
+
+ # The first eval is from the initial install, we're testing that the
+ # second install doesn't double-eval
+ expect(bundled_app("evals").read.lines.to_a.size).to eq(2)
+ end
+
+ context "when the gem is not installed" do
+ before { FileUtils.rm_rf ".bundle" }
+
+ it "does not evaluate the gemfile twice" do
+ bundle! :install
+
+ with_env_vars("BUNDLER_SPEC_NO_APPEND" => "1") { expect(the_bundle).to include_gem "rack 1.0.0" }
+
+ # The first eval is from the initial install, we're testing that the
+ # second install doesn't double-eval
+ expect(bundled_app("evals").read.lines.to_a.size).to eq(2)
+ end
+ end
+ end
+ end
+end
diff --git a/spec/bundler/install/gemfile/path_spec.rb b/spec/bundler/install/gemfile/path_spec.rb
index a1c41aebbb..f7789e7ea5 100644
--- a/spec/bundler/install/gemfile/path_spec.rb
+++ b/spec/bundler/install/gemfile/path_spec.rb
@@ -1,8 +1,7 @@
# frozen_string_literal: true
-require "spec_helper"
RSpec.describe "bundle install with explicit source paths" do
- it "fetches gems" do
+ it "fetches gems with a global path source", :bundler => "< 2" do
build_lib "foo"
install_gemfile <<-G
@@ -13,6 +12,18 @@ RSpec.describe "bundle install with explicit source paths" do
expect(the_bundle).to include_gems("foo 1.0")
end
+ it "fetches gems" do
+ build_lib "foo"
+
+ install_gemfile <<-G
+ path "#{lib_path("foo-1.0")}" do
+ gem 'foo'
+ end
+ G
+
+ expect(the_bundle).to include_gems("foo 1.0")
+ end
+
it "supports pinned paths" do
build_lib "foo"
@@ -79,7 +90,7 @@ RSpec.describe "bundle install with explicit source paths" do
gem 'foo', :path => File.expand_path("../foo-1.0", __FILE__)
G
- bundle "install --frozen"
+ bundle! :install, forgotten_command_line_options(:frozen => true)
expect(exitstatus).to eq(0) if exitstatus
end
@@ -270,8 +281,9 @@ RSpec.describe "bundle install with explicit source paths" do
end
install_gemfile <<-G
- path "#{lib_path("foo-1.0")}"
- gem 'foo'
+ path "#{lib_path("foo-1.0")}" do
+ gem 'foo'
+ end
G
expect(the_bundle).to include_gems "foo 1.0"
@@ -591,5 +603,28 @@ RSpec.describe "bundle install with explicit source paths" do
:requires => [lib_path("install_hooks.rb")]
expect(out).to include("failed for foo-1.0")
end
+
+ it "loads plugins from the path gem" do
+ foo_file = home("foo_plugin_loaded")
+ bar_file = home("bar_plugin_loaded")
+ expect(foo_file).not_to be_file
+ expect(bar_file).not_to be_file
+
+ build_lib "foo" do |s|
+ s.write("lib/rubygems_plugin.rb", "FileUtils.touch('#{foo_file}')")
+ end
+
+ build_git "bar" do |s|
+ s.write("lib/rubygems_plugin.rb", "FileUtils.touch('#{bar_file}')")
+ end
+
+ install_gemfile! <<-G
+ gem "foo", :path => "#{lib_path("foo-1.0")}"
+ gem "bar", :path => "#{lib_path("bar-1.0")}"
+ G
+
+ expect(foo_file).to be_file
+ expect(bar_file).to be_file
+ end
end
end
diff --git a/spec/bundler/install/gemfile/platform_spec.rb b/spec/bundler/install/gemfile/platform_spec.rb
index c6eaec7ca6..d7d4e0a53c 100644
--- a/spec/bundler/install/gemfile/platform_spec.rb
+++ b/spec/bundler/install/gemfile/platform_spec.rb
@@ -1,5 +1,4 @@
# frozen_string_literal: true
-require "spec_helper"
RSpec.describe "bundle install across platforms" do
it "maintains the same lockfile if all gems are compatible across platforms" do
@@ -88,7 +87,7 @@ RSpec.describe "bundle install across platforms" do
expect(the_bundle).to include_gems "nokogiri 1.4.2 JAVA", "weakling 0.0.3"
end
- it "works with gems that have extra platform-specific runtime dependencies" do
+ it "works with gems that have extra platform-specific runtime dependencies", :bundler => "< 2" do
simulate_platform x64_mac
update_repo2 do
@@ -121,12 +120,12 @@ RSpec.describe "bundle install across platforms" do
gem "rack", "1.0.0"
G
- bundle "install --path vendor/bundle"
+ bundle! :install, forgotten_command_line_options(:path => "vendor/bundle")
new_version = Gem::ConfigMap[:ruby_version] == "1.8" ? "1.9.1" : "1.8"
FileUtils.mv(vendored_gems, bundled_app("vendor/bundle", Gem.ruby_engine, new_version))
- bundle "install --path vendor/bundle"
+ bundle! :install
expect(vendored_gems("gems/rack-1.0.0")).to exist
end
end
@@ -200,7 +199,7 @@ RSpec.describe "bundle install with platform conditionals" do
end
G
- bundle :show
+ bundle :list
expect(exitstatus).to eq(0) if exitstatus
end
diff --git a/spec/bundler/install/gemfile/ruby_spec.rb b/spec/bundler/install/gemfile/ruby_spec.rb
index b9d9683758..24fe021fa3 100644
--- a/spec/bundler/install/gemfile/ruby_spec.rb
+++ b/spec/bundler/install/gemfile/ruby_spec.rb
@@ -1,5 +1,4 @@
# frozen_string_literal: true
-require "spec_helper"
RSpec.describe "ruby requirement" do
def locked_ruby_version
diff --git a/spec/bundler/install/gemfile/sources_spec.rb b/spec/bundler/install/gemfile/sources_spec.rb
index c5375b4abf..0b837f87a1 100644
--- a/spec/bundler/install/gemfile/sources_spec.rb
+++ b/spec/bundler/install/gemfile/sources_spec.rb
@@ -1,5 +1,4 @@
# frozen_string_literal: true
-require "spec_helper"
RSpec.describe "bundle install with gems on multiple sources" do
# repo1 is built automatically before all of the specs run
@@ -29,7 +28,7 @@ RSpec.describe "bundle install with gems on multiple sources" do
bundle "config major_deprecations true"
end
- it "warns about ambiguous gems, but installs anyway, prioritizing sources last to first" do
+ it "warns about ambiguous gems, but installs anyway, prioritizing sources last to first", :bundler => "< 2" do
bundle :install
expect(out).to have_major_deprecation a_string_including("Your Gemfile contains multiple primary sources.")
@@ -59,7 +58,7 @@ RSpec.describe "bundle install with gems on multiple sources" do
bundle "config major_deprecations true"
end
- it "warns about ambiguous gems, but installs anyway" do
+ it "warns about ambiguous gems, but installs anyway", :bundler => "< 2" do
bundle :install
expect(out).to have_major_deprecation a_string_including("Your Gemfile contains multiple primary sources.")
@@ -79,6 +78,10 @@ RSpec.describe "bundle install with gems on multiple sources" do
build_gem "rack", "1.0.0" do |s|
s.write "lib/rack.rb", "RACK = 'FAIL'"
end
+
+ build_gem "rack-obama" do |s|
+ s.add_dependency "rack"
+ end
end
gemfile <<-G
@@ -92,21 +95,20 @@ RSpec.describe "bundle install with gems on multiple sources" do
end
it "installs the gems without any warning" do
- bundle :install
+ bundle! :install
expect(out).not_to include("Warning")
expect(the_bundle).to include_gems("rack-obama 1.0.0")
expect(the_bundle).to include_gems("rack 1.0.0", :source => "remote1")
end
it "can cache and deploy" do
- bundle :package
+ bundle! :package
expect(bundled_app("vendor/cache/rack-1.0.0.gem")).to exist
expect(bundled_app("vendor/cache/rack-obama-1.0.gem")).to exist
- bundle "install --deployment"
+ bundle! :install, forgotten_command_line_options(:deployment => true)
- expect(exitstatus).to eq(0) if exitstatus
expect(the_bundle).to include_gems("rack-obama 1.0.0", "rack 1.0.0")
end
end
@@ -119,6 +121,10 @@ RSpec.describe "bundle install with gems on multiple sources" do
build_gem "rack", "1.0.0" do |s|
s.write "lib/rack.rb", "RACK = 'FAIL'"
end
+
+ build_gem "rack-obama" do |s|
+ s.add_dependency "rack"
+ end
end
gemfile <<-G
@@ -135,7 +141,7 @@ RSpec.describe "bundle install with gems on multiple sources" do
end
end
- context "with an indirect dependency" do
+ context "when a pinned gem has an indirect dependency" do
before do
build_repo gem_repo3 do
build_gem "depends_on_rack", "1.0.1" do |s|
@@ -181,10 +187,27 @@ RSpec.describe "bundle install with gems on multiple sources" do
end
end
- it "installs from the same source without any warning" do
- bundle :install
- expect(out).not_to include("Warning")
- expect(the_bundle).to include_gems("depends_on_rack 1.0.1", "rack 1.0.0")
+ context "when lockfile_uses_separate_rubygems_sources is set" do
+ before do
+ bundle! "config lockfile_uses_separate_rubygems_sources true"
+ bundle! "config disable_multisource true"
+ end
+
+ it "installs from the same source without any warning" do
+ bundle! :install
+
+ expect(out).not_to include("Warning: the gem 'rack' was found in multiple sources.")
+ expect(err).not_to include("Warning: the gem 'rack' was found in multiple sources.")
+ expect(the_bundle).to include_gems("depends_on_rack 1.0.1", "rack 1.0.0")
+
+ # when there is already a lock file, and the gems are missing, so try again
+ system_gems []
+ bundle! :install
+
+ expect(out).not_to include("Warning: the gem 'rack' was found in multiple sources.")
+ expect(err).not_to include("Warning: the gem 'rack' was found in multiple sources.")
+ expect(the_bundle).to include_gems("depends_on_rack 1.0.1", "rack 1.0.0")
+ end
end
end
end
@@ -225,7 +248,7 @@ RSpec.describe "bundle install with gems on multiple sources" do
G
end
- it "installs from the other source and warns about ambiguous gems" do
+ it "installs from the other source and warns about ambiguous gems", :bundler => "< 2" do
bundle "config major_deprecations true"
bundle :install
expect(out).to have_major_deprecation a_string_including("Your Gemfile contains multiple primary sources.")
@@ -253,7 +276,7 @@ RSpec.describe "bundle install with gems on multiple sources" do
G
end
- it "installs the dependency from the pinned source without warning" do
+ it "installs the dependency from the pinned source without warning", :bundler => "< 2" do
bundle :install
expect(out).not_to include("Warning: the gem 'rack' was found in multiple sources.")
@@ -271,6 +294,86 @@ RSpec.describe "bundle install with gems on multiple sources" do
end
end
+ context "when a top-level gem has an indirect dependency" do
+ context "when lockfile_uses_separate_rubygems_sources is set" do
+ before do
+ bundle! "config lockfile_uses_separate_rubygems_sources true"
+ bundle! "config disable_multisource true"
+ end
+
+ before do
+ build_repo gem_repo2 do
+ build_gem "depends_on_rack", "1.0.1" do |s|
+ s.add_dependency "rack"
+ end
+ end
+
+ build_repo gem_repo3 do
+ build_gem "unrelated_gem", "1.0.0"
+ end
+
+ gemfile <<-G
+ source "file://#{gem_repo2}"
+
+ gem "depends_on_rack"
+
+ source "file://#{gem_repo3}" do
+ gem "unrelated_gem"
+ end
+ G
+ end
+
+ context "and the dependency is only in the top-level source" do
+ before do
+ update_repo gem_repo2 do
+ build_gem "rack", "1.0.0"
+ end
+ end
+
+ it "installs all gems without warning" do
+ bundle :install
+ expect(out).not_to include("Warning")
+ expect(the_bundle).to include_gems("depends_on_rack 1.0.1", "rack 1.0.0", "unrelated_gem 1.0.0")
+ end
+ end
+
+ context "and the dependency is only in a pinned source" do
+ before do
+ update_repo gem_repo3 do
+ build_gem "rack", "1.0.0" do |s|
+ s.write "lib/rack.rb", "RACK = 'FAIL'"
+ end
+ end
+ end
+
+ it "does not find the dependency" do
+ bundle :install
+ expect(out).to include("Could not find gem 'rack', which is required by gem 'depends_on_rack', in any of the relevant sources")
+ end
+ end
+
+ context "and the dependency is in both the top-level and a pinned source" do
+ before do
+ update_repo gem_repo2 do
+ build_gem "rack", "1.0.0"
+ end
+
+ update_repo gem_repo3 do
+ build_gem "rack", "1.0.0" do |s|
+ s.write "lib/rack.rb", "RACK = 'FAIL'"
+ end
+ end
+ end
+
+ it "installs the dependency from the top-level source without warning" do
+ bundle :install
+ expect(out).not_to include("Warning")
+ expect(the_bundle).to include_gems("depends_on_rack 1.0.1", "rack 1.0.0", "unrelated_gem 1.0.0")
+ end
+ end
+ end
+ end
+
context "with a gem that is only found in the wrong source" do
before do
build_repo gem_repo3 do
@@ -291,7 +394,7 @@ RSpec.describe "bundle install with gems on multiple sources" do
context "with an existing lockfile" do
before do
- system_gems "rack-0.9.1", "rack-1.0.0"
+ system_gems "rack-0.9.1", "rack-1.0.0", :path => :bundle_path
lockfile <<-L
GEM
@@ -394,7 +497,7 @@ RSpec.describe "bundle install with gems on multiple sources" do
rack
L
- bundle "install --path ../gems/system"
+ bundle! :install, forgotten_command_line_options(:path => "../gems/system")
# 4. Then we add some new versions...
update_repo4 do
@@ -413,8 +516,7 @@ RSpec.describe "bundle install with gems on multiple sources" do
G
# 6. Which should update foo to 0.2, but not the (locked) bar 0.1
- expect(the_bundle).to include_gems("foo 0.2")
- expect(the_bundle).to include_gems("bar 0.1")
+ expect(the_bundle).to include_gems("foo 0.2", "bar 0.1")
end
end
diff --git a/spec/bundler/install/gemfile/specific_platform_spec.rb b/spec/bundler/install/gemfile/specific_platform_spec.rb
index cc6c82c0ff..9c725416d5 100644
--- a/spec/bundler/install/gemfile/specific_platform_spec.rb
+++ b/spec/bundler/install/gemfile/specific_platform_spec.rb
@@ -1,5 +1,4 @@
# frozen_string_literal: true
-require "spec_helper"
RSpec.describe "bundle install with specific_platform enabled" do
before do
@@ -61,10 +60,10 @@ RSpec.describe "bundle install with specific_platform enabled" do
install_gemfile!(google_protobuf)
expect(the_bundle.locked_gems.platforms).to eq([pl("ruby"), pl("x86_64-darwin-15")])
expect(the_bundle).to include_gem("google-protobuf 3.0.0.alpha.5.0.5.1 universal-darwin")
- expect(the_bundle.locked_gems.specs.map(&:full_name)).to eq(%w(
+ expect(the_bundle.locked_gems.specs.map(&:full_name)).to eq(%w[
google-protobuf-3.0.0.alpha.5.0.5.1
google-protobuf-3.0.0.alpha.5.0.5.1-universal-darwin
- ))
+ ])
end
it "caches both the universal-darwin and ruby gems when --all-platforms is passed" do
@@ -93,11 +92,11 @@ RSpec.describe "bundle install with specific_platform enabled" do
bundle! "lock --add-platform=#{x64_mingw}"
expect(the_bundle.locked_gems.platforms).to eq([rb, x64_mingw, pl("x86_64-darwin-15")])
- expect(the_bundle.locked_gems.specs.map(&:full_name)).to eq(%w(
+ expect(the_bundle.locked_gems.specs.map(&:full_name)).to eq(%w[
google-protobuf-3.0.0.alpha.5.0.5.1
google-protobuf-3.0.0.alpha.5.0.5.1-universal-darwin
google-protobuf-3.0.0.alpha.5.0.5.1-x64-mingw32
- ))
+ ])
end
it "falls back on plain ruby when that version doesnt have a platform-specific gem" do
@@ -105,10 +104,10 @@ RSpec.describe "bundle install with specific_platform enabled" do
bundle! "lock --add-platform=#{java}"
expect(the_bundle.locked_gems.platforms).to eq([java, rb, pl("x86_64-darwin-15")])
- expect(the_bundle.locked_gems.specs.map(&:full_name)).to eq(%w(
+ expect(the_bundle.locked_gems.specs.map(&:full_name)).to eq(%w[
google-protobuf-3.0.0.alpha.5.0.5.1
google-protobuf-3.0.0.alpha.5.0.5.1-universal-darwin
- ))
+ ])
end
end
end
diff --git a/spec/bundler/install/gemfile_spec.rb b/spec/bundler/install/gemfile_spec.rb
index bc49053081..945d9f485d 100644
--- a/spec/bundler/install/gemfile_spec.rb
+++ b/spec/bundler/install/gemfile_spec.rb
@@ -1,5 +1,4 @@
# frozen_string_literal: true
-require "spec_helper"
RSpec.describe "bundle install" do
context "with duplicated gems" do
@@ -37,7 +36,7 @@ RSpec.describe "bundle install" do
end
it "uses the gemfile to install" do
bundle "install"
- bundle "show"
+ bundle "list"
expect(out).to include("rack (1.0.0)")
end
@@ -45,7 +44,7 @@ RSpec.describe "bundle install" do
bundled_app("subdir").mkpath
Dir.chdir(bundled_app("subdir")) do
bundle "install"
- bundle "show"
+ bundle "list"
expect(out).to include("rack (1.0.0)")
end
@@ -67,6 +66,22 @@ RSpec.describe "bundle install" do
end
end
+ context "with prefer_gems_rb set" do
+ before { bundle! "config prefer_gems_rb true" }
+
+ it "prefers gems.rb to Gemfile" do
+ create_file("gems.rb", "gem 'bundler'")
+ create_file("Gemfile", "raise 'wrong Gemfile!'")
+
+ bundle! :install
+
+ expect(bundled_app("gems.rb")).to be_file
+ expect(bundled_app("Gemfile.lock")).not_to be_file
+
+ expect(the_bundle).to include_gem "bundler #{Bundler::VERSION}"
+ end
+ end
+
context "with engine specified in symbol" do
it "does not raise any error parsing Gemfile" do
simulate_ruby_version "2.3.0" do
diff --git a/spec/bundler/install/gems/compact_index_spec.rb b/spec/bundler/install/gems/compact_index_spec.rb
index 825185c82e..07700f5030 100644
--- a/spec/bundler/install/gems/compact_index_spec.rb
+++ b/spec/bundler/install/gems/compact_index_spec.rb
@@ -1,5 +1,4 @@
# frozen_string_literal: true
-require "spec_helper"
RSpec.describe "compact index api" do
let(:source_hostname) { "localgemserver.test" }
@@ -61,7 +60,7 @@ RSpec.describe "compact index api" do
# can't use `include_gems` here since the `require` will conflict on a
# case-insensitive FS
run! "Bundler.require; puts Gem.loaded_specs.values_at('rack', 'Rack').map(&:full_name)"
- expect(out).to eq("rack-1.0\nRack-0.1")
+ expect(last_command.stdout).to eq("rack-1.0\nRack-0.1")
end
it "should handle multiple gem dependencies on the same gem" do
@@ -81,7 +80,7 @@ RSpec.describe "compact index api" do
G
bundle! :install, :artifice => "compact_index"
- bundle "install --deployment", :artifice => "compact_index"
+ bundle! :install, forgotten_command_line_options(:deployment => true, :path => "vendor/bundle").merge(:artifice => "compact_index")
expect(out).to include("Fetching gem metadata from #{source_uri}")
expect(the_bundle).to include_gems "rack 1.0.0"
end
@@ -130,9 +129,8 @@ RSpec.describe "compact index api" do
G
bundle "install", :artifice => "compact_index"
- bundle "install --deployment", :artifice => "compact_index"
+ bundle! :install, forgotten_command_line_options(:deployment => true).merge(:artifice => "compact_index")
- expect(exitstatus).to eq(0) if exitstatus
expect(the_bundle).to include_gems("foo 1.0")
end
@@ -175,7 +173,7 @@ The checksum of /versions does not match the checksum provided by the server! So
end
it "falls back when the user's home directory does not exist or is not writable" do
- ENV["HOME"] = nil
+ ENV["HOME"] = tmp("missing_home").to_s
gemfile <<-G
source "#{source_uri}"
@@ -249,13 +247,29 @@ The checksum of /versions does not match the checksum provided by the server! So
gem "rack"
G
- bundle "update --full-index", :artifice => "compact_index"
+ bundle! "update --full-index", :artifice => "compact_index", :all => bundle_update_requires_all?
expect(out).to include("Fetching source index from #{source_uri}")
expect(the_bundle).to include_gems "rack 1.0.0"
end
end
- it "fetches again when more dependencies are found in subsequent sources" do
+ it "does not double check for gems that are only installed locally" do
+ system_gems %w[rack-1.0.0 thin-1.0 net_a-1.0]
+ bundle! "config --local path.system true"
+ ENV["BUNDLER_SPEC_ALL_REQUESTS"] = strip_whitespace(<<-EOS).strip
+ #{source_uri}/versions
+ #{source_uri}/info/rack
+ EOS
+
+ install_gemfile! <<-G, :artifice => "compact_index", :verbose => true
+ source "#{source_uri}"
+ gem "rack"
+ G
+
+ expect(last_command.stdboth).not_to include "Double checking"
+ end
+
+ it "fetches again when more dependencies are found in subsequent sources", :bundler => "< 2" do
build_repo2 do
build_gem "back_deps" do |s|
s.add_dependency "foo"
@@ -270,7 +284,25 @@ The checksum of /versions does not match the checksum provided by the server! So
G
bundle! :install, :artifice => "compact_index_extra"
- expect(the_bundle).to include_gems "back_deps 1.0"
+ expect(the_bundle).to include_gems "back_deps 1.0", "foo 1.0"
+ end
+
+ it "fetches again when more dependencies are found in subsequent sources with source blocks" do
+ build_repo2 do
+ build_gem "back_deps" do |s|
+ s.add_dependency "foo"
+ end
+ FileUtils.rm_rf Dir[gem_repo2("gems/foo-*.gem")]
+ end
+
+ install_gemfile! <<-G, :artifice => "compact_index_extra", :verbose => true
+ source "#{source_uri}"
+ source "#{source_uri}/extra" do
+ gem "back_deps"
+ end
+ G
+
+ expect(the_bundle).to include_gems "back_deps 1.0", "foo 1.0"
end
it "fetches gem versions even when those gems are already installed" do
@@ -296,7 +328,7 @@ The checksum of /versions does not match the checksum provided by the server! So
expect(the_bundle).to include_gems "rack 1.2"
end
- it "considers all possible versions of dependencies from all api gem sources" do
+ it "considers all possible versions of dependencies from all api gem sources", :bundler => "< 2" do
# In this scenario, the gem "somegem" only exists in repo4. It depends on specific version of activesupport that
# exists only in repo1. There happens also be a version of activesupport in repo4, but not the one that version 1.0.0
# of somegem wants. This test makes sure that bundler actually finds version 1.2.3 of active support in the other
@@ -320,6 +352,31 @@ The checksum of /versions does not match the checksum provided by the server! So
expect(the_bundle).to include_gems "activesupport 1.2.3"
end
+ it "considers all possible versions of dependencies from all api gem sources when using blocks", :bundler => "< 2" do
+ # In this scenario, the gem "somegem" only exists in repo4. It depends on specific version of activesupport that
+ # exists only in repo1. There happens also be a version of activesupport in repo4, but not the one that version 1.0.0
+ # of somegem wants. This test makes sure that bundler actually finds version 1.2.3 of active support in the other
+ # repo and installs it.
+ build_repo4 do
+ build_gem "activesupport", "1.2.0"
+ build_gem "somegem", "1.0.0" do |s|
+ s.add_dependency "activesupport", "1.2.3" # This version exists only in repo1
+ end
+ end
+
+ gemfile <<-G
+ source "#{source_uri}"
+ source "#{source_uri}/extra" do
+ gem 'somegem', '1.0.0'
+ end
+ G
+
+ bundle! :install, :artifice => "compact_index_extra_api"
+
+ expect(the_bundle).to include_gems "somegem 1.0.0"
+ expect(the_bundle).to include_gems "activesupport 1.2.3"
+ end
+
it "prints API output properly with back deps" do
build_repo2 do
build_gem "back_deps" do |s|
@@ -330,8 +387,9 @@ The checksum of /versions does not match the checksum provided by the server! So
gemfile <<-G
source "#{source_uri}"
- source "#{source_uri}/extra"
- gem "back_deps"
+ source "#{source_uri}/extra" do
+ gem "back_deps"
+ end
G
bundle! :install, :artifice => "compact_index_extra"
@@ -356,14 +414,39 @@ The checksum of /versions does not match the checksum provided by the server! So
gemfile <<-G
source "#{source_uri}"
- source "#{source_uri}/extra"
- gem "back_deps"
+ source "#{source_uri}/extra" do
+ gem "back_deps"
+ end
G
bundle! :install, :artifice => "compact_index_extra_missing"
expect(the_bundle).to include_gems "back_deps 1.0"
end
+ it "does not fetch every spec if the index of gems is large when doing back deps & everything is the compact index" do
+ build_repo4 do
+ build_gem "back_deps" do |s|
+ s.add_dependency "foo"
+ end
+ build_gem "missing"
+ # need to hit the limit
+ 1.upto(Bundler::Source::Rubygems::API_REQUEST_LIMIT) do |i|
+ build_gem "gem#{i}"
+ end
+
+ FileUtils.rm_rf Dir[gem_repo4("gems/foo-*.gem")]
+ end
+
+ install_gemfile! <<-G, :artifice => "compact_index_extra_api_missing"
+ source "#{source_uri}"
+ source "#{source_uri}/extra" do
+ gem "back_deps"
+ end
+ G
+
+ expect(the_bundle).to include_gem "back_deps 1.0"
+ end
+
it "uses the endpoint if all sources support it" do
gemfile <<-G
source "#{source_uri}"
@@ -375,7 +458,7 @@ The checksum of /versions does not match the checksum provided by the server! So
expect(the_bundle).to include_gems "foo 1.0"
end
- it "fetches again when more dependencies are found in subsequent sources using --deployment" do
+ it "fetches again when more dependencies are found in subsequent sources using --deployment", :bundler => "< 2" do
build_repo2 do
build_gem "back_deps" do |s|
s.add_dependency "foo"
@@ -395,6 +478,27 @@ The checksum of /versions does not match the checksum provided by the server! So
expect(the_bundle).to include_gems "back_deps 1.0"
end
+ it "fetches again when more dependencies are found in subsequent sources using --deployment with blocks" do
+ build_repo2 do
+ build_gem "back_deps" do |s|
+ s.add_dependency "foo"
+ end
+ FileUtils.rm_rf Dir[gem_repo2("gems/foo-*.gem")]
+ end
+
+ gemfile <<-G
+ source "#{source_uri}"
+ source "#{source_uri}/extra" do
+ gem "back_deps"
+ end
+ G
+
+ bundle! :install, :artifice => "compact_index_extra"
+
+ bundle "install --deployment", :artifice => "compact_index_extra"
+ expect(the_bundle).to include_gems "back_deps 1.0"
+ end
+
it "does not refetch if the only unmet dependency is bundler" do
gemfile <<-G
source "#{source_uri}"
@@ -418,7 +522,7 @@ The checksum of /versions does not match the checksum provided by the server! So
expect(the_bundle).to include_gems "rails 2.3.2"
end
- it "installs the binstubs" do
+ it "installs the binstubs", :bundler => "< 2" do
gemfile <<-G
source "#{source_uri}"
gem "rack"
@@ -430,7 +534,7 @@ The checksum of /versions does not match the checksum provided by the server! So
expect(out).to eq("1.0.0")
end
- it "installs the bins when using --path and uses autoclean" do
+ it "installs the bins when using --path and uses autoclean", :bundler => "< 2" do
gemfile <<-G
source "#{source_uri}"
gem "rack"
@@ -441,7 +545,7 @@ The checksum of /versions does not match the checksum provided by the server! So
expect(vendored_gems("bin/rackup")).to exist
end
- it "installs the bins when using --path and uses bundle clean" do
+ it "installs the bins when using --path and uses bundle clean", :bundler => "< 2" do
gemfile <<-G
source "#{source_uri}"
gem "rack"
@@ -516,7 +620,7 @@ The checksum of /versions does not match the checksum provided by the server! So
expect(out).not_to include("#{user}:#{password}")
end
- it "strips http basic auth creds when warning about ambiguous sources" do
+ it "strips http basic auth creds when warning about ambiguous sources", :bundler => "< 2" do
gemfile <<-G
source "#{basic_auth_source_uri}"
source "file://#{gem_repo1}"
@@ -613,7 +717,7 @@ The checksum of /versions does not match the checksum provided by the server! So
end
end
- context "when ruby is compiled without openssl" do
+ context "when ruby is compiled without openssl", :ruby_repo do
before do
# Install a monkeypatch that reproduces the effects of openssl being
# missing when the fetcher runs, as happens in real life. The reason
@@ -640,7 +744,7 @@ The checksum of /versions does not match the checksum provided by the server! So
context "when SSL certificate verification fails" do
it "explains what happened" do
# Install a monkeypatch that reproduces the effects of openssl raising
- # a certificate validation error when Rubygems tries to connect.
+ # a certificate validation error when RubyGems tries to connect.
gemfile <<-G
class Net::HTTP
def start
@@ -741,7 +845,7 @@ The checksum of /versions does not match the checksum provided by the server! So
and include("The checksum for the downloaded `rack-1.0.0.gem` does not match the checksum given by the server.").
and include("This means the contents of the downloaded gem is different from what was uploaded to the server, and could be a potential security issue.").
and include("To resolve this issue:").
- and include("1. delete the downloaded gem located at: `#{system_gem_path}/gems/rack-1.0.0/rack-1.0.0.gem`").
+ and include("1. delete the downloaded gem located at: `#{default_bundle_path}/gems/rack-1.0.0/rack-1.0.0.gem`").
and include("2. run `bundle install`").
and include("If you wish to continue installing the downloaded gem, and are certain it does not pose a security issue despite the mismatching checksum, do the following:").
and include("1. run `bundle config disable_checksum_validation true` to turn off checksum verification").
diff --git a/spec/bundler/install/gems/dependency_api_spec.rb b/spec/bundler/install/gems/dependency_api_spec.rb
index d2de0d358b..fe696f38c3 100644
--- a/spec/bundler/install/gems/dependency_api_spec.rb
+++ b/spec/bundler/install/gems/dependency_api_spec.rb
@@ -1,5 +1,4 @@
# frozen_string_literal: true
-require "spec_helper"
RSpec.describe "gemcutter's dependency API" do
let(:source_hostname) { "localgemserver.test" }
@@ -61,7 +60,7 @@ RSpec.describe "gemcutter's dependency API" do
G
bundle :install, :artifice => "endpoint"
- bundle "install --deployment", :artifice => "endpoint"
+ bundle! :install, forgotten_command_line_options(:deployment => true, :path => "vendor/bundle").merge(:artifice => "endpoint")
expect(out).to include("Fetching gem metadata from #{source_uri}")
expect(the_bundle).to include_gems "rack 1.0.0"
end
@@ -110,9 +109,8 @@ RSpec.describe "gemcutter's dependency API" do
G
bundle "install", :artifice => "endpoint"
- bundle "install --deployment", :artifice => "endpoint"
+ bundle! :install, forgotten_command_line_options(:deployment => true).merge(:artifice => "endpoint")
- expect(exitstatus).to eq(0) if exitstatus
expect(the_bundle).to include_gems("foo 1.0")
end
@@ -239,13 +237,13 @@ RSpec.describe "gemcutter's dependency API" do
gem "rack"
G
- bundle "update --full-index", :artifice => "endpoint"
+ bundle! "update --full-index", :artifice => "endpoint", :all => bundle_update_requires_all?
expect(out).to include("Fetching source index from #{source_uri}")
expect(the_bundle).to include_gems "rack 1.0.0"
end
end
- it "fetches again when more dependencies are found in subsequent sources" do
+ it "fetches again when more dependencies are found in subsequent sources", :bundler => "< 2" do
build_repo2 do
build_gem "back_deps" do |s|
s.add_dependency "foo"
@@ -260,7 +258,26 @@ RSpec.describe "gemcutter's dependency API" do
G
bundle :install, :artifice => "endpoint_extra"
- expect(the_bundle).to include_gems "back_deps 1.0"
+ expect(the_bundle).to include_gems "back_deps 1.0", "foo 1.0"
+ end
+
+ it "fetches again when more dependencies are found in subsequent sources using blocks" do
+ build_repo2 do
+ build_gem "back_deps" do |s|
+ s.add_dependency "foo"
+ end
+ FileUtils.rm_rf Dir[gem_repo2("gems/foo-*.gem")]
+ end
+
+ gemfile <<-G
+ source "#{source_uri}"
+ source "#{source_uri}/extra" do
+ gem "back_deps"
+ end
+ G
+
+ bundle :install, :artifice => "endpoint_extra"
+ expect(the_bundle).to include_gems "back_deps 1.0", "foo 1.0"
end
it "fetches gem versions even when those gems are already installed" do
@@ -285,7 +302,7 @@ RSpec.describe "gemcutter's dependency API" do
expect(the_bundle).to include_gems "rack 1.2"
end
- it "considers all possible versions of dependencies from all api gem sources" do
+ it "considers all possible versions of dependencies from all api gem sources", :bundler => "< 2" do
# In this scenario, the gem "somegem" only exists in repo4. It depends on specific version of activesupport that
# exists only in repo1. There happens also be a version of activesupport in repo4, but not the one that version 1.0.0
# of somegem wants. This test makes sure that bundler actually finds version 1.2.3 of active support in the other
@@ -303,6 +320,31 @@ RSpec.describe "gemcutter's dependency API" do
gem 'somegem', '1.0.0'
G
+ bundle! :install, :artifice => "endpoint_extra_api"
+
+ expect(the_bundle).to include_gems "somegem 1.0.0"
+ expect(the_bundle).to include_gems "activesupport 1.2.3"
+ end
+
+ it "considers all possible versions of dependencies from all api gem sources using blocks" do
+ # In this scenario, the gem "somegem" only exists in repo4. It depends on specific version of activesupport that
+ # exists only in repo1. There happens also be a version of activesupport in repo4, but not the one that version 1.0.0
+ # of somegem wants. This test makes sure that bundler actually finds version 1.2.3 of active support in the other
+ # repo and installs it.
+ build_repo4 do
+ build_gem "activesupport", "1.2.0"
+ build_gem "somegem", "1.0.0" do |s|
+ s.add_dependency "activesupport", "1.2.3" # This version exists only in repo1
+ end
+ end
+
+ gemfile <<-G
+ source "#{source_uri}"
+ source "#{source_uri}/extra" do
+ gem 'somegem', '1.0.0'
+ end
+ G
+
bundle :install, :artifice => "endpoint_extra_api"
expect(the_bundle).to include_gems "somegem 1.0.0"
@@ -319,17 +361,18 @@ RSpec.describe "gemcutter's dependency API" do
gemfile <<-G
source "#{source_uri}"
- source "#{source_uri}/extra"
- gem "back_deps"
+ source "#{source_uri}/extra" do
+ gem "back_deps"
+ end
G
bundle :install, :artifice => "endpoint_extra"
- expect(out).to include("Fetching gem metadata from http://localgemserver.test/..")
+ expect(out).to include("Fetching gem metadata from http://localgemserver.test/.")
expect(out).to include("Fetching source index from http://localgemserver.test/extra")
end
- it "does not fetch every spec if the index of gems is large when doing back deps" do
+ it "does not fetch every spec if the index of gems is large when doing back deps", :bundler => "< 2" do
build_repo2 do
build_gem "back_deps" do |s|
s.add_dependency "foo"
@@ -353,6 +396,31 @@ RSpec.describe "gemcutter's dependency API" do
expect(the_bundle).to include_gems "back_deps 1.0"
end
+ it "does not fetch every spec if the index of gems is large when doing back deps using blocks" do
+ build_repo2 do
+ build_gem "back_deps" do |s|
+ s.add_dependency "foo"
+ end
+ build_gem "missing"
+ # need to hit the limit
+ 1.upto(Bundler::Source::Rubygems::API_REQUEST_LIMIT) do |i|
+ build_gem "gem#{i}"
+ end
+
+ FileUtils.rm_rf Dir[gem_repo2("gems/foo-*.gem")]
+ end
+
+ gemfile <<-G
+ source "#{source_uri}"
+ source "#{source_uri}/extra" do
+ gem "back_deps"
+ end
+ G
+
+ bundle :install, :artifice => "endpoint_extra_missing"
+ expect(the_bundle).to include_gems "back_deps 1.0"
+ end
+
it "uses the endpoint if all sources support it" do
gemfile <<-G
source "#{source_uri}"
@@ -364,7 +432,7 @@ RSpec.describe "gemcutter's dependency API" do
expect(the_bundle).to include_gems "foo 1.0"
end
- it "fetches again when more dependencies are found in subsequent sources using --deployment" do
+ it "fetches again when more dependencies are found in subsequent sources using --deployment", :bundler => "< 2" do
build_repo2 do
build_gem "back_deps" do |s|
s.add_dependency "foo"
@@ -384,6 +452,27 @@ RSpec.describe "gemcutter's dependency API" do
expect(the_bundle).to include_gems "back_deps 1.0"
end
+ it "fetches again when more dependencies are found in subsequent sources using --deployment with blocks" do
+ build_repo2 do
+ build_gem "back_deps" do |s|
+ s.add_dependency "foo"
+ end
+ FileUtils.rm_rf Dir[gem_repo2("gems/foo-*.gem")]
+ end
+
+ gemfile <<-G
+ source "#{source_uri}"
+ source "#{source_uri}/extra" do
+ gem "back_deps"
+ end
+ G
+
+ bundle :install, :artifice => "endpoint_extra"
+
+ bundle "install --deployment", :artifice => "endpoint_extra"
+ expect(the_bundle).to include_gems "back_deps 1.0"
+ end
+
it "does not refetch if the only unmet dependency is bundler" do
gemfile <<-G
source "#{source_uri}"
@@ -407,7 +496,7 @@ RSpec.describe "gemcutter's dependency API" do
expect(the_bundle).to include_gems "rails 2.3.2"
end
- it "installs the binstubs" do
+ it "installs the binstubs", :bundler => "< 2" do
gemfile <<-G
source "#{source_uri}"
gem "rack"
@@ -419,7 +508,7 @@ RSpec.describe "gemcutter's dependency API" do
expect(out).to eq("1.0.0")
end
- it "installs the bins when using --path and uses autoclean" do
+ it "installs the bins when using --path and uses autoclean", :bundler => "< 2" do
gemfile <<-G
source "#{source_uri}"
gem "rack"
@@ -430,7 +519,7 @@ RSpec.describe "gemcutter's dependency API" do
expect(vendored_gems("bin/rackup")).to exist
end
- it "installs the bins when using --path and uses bundle clean" do
+ it "installs the bins when using --path and uses bundle clean", :bundler => "< 2" do
gemfile <<-G
source "#{source_uri}"
gem "rack"
@@ -505,7 +594,7 @@ RSpec.describe "gemcutter's dependency API" do
expect(out).not_to include("#{user}:#{password}")
end
- it "strips http basic auth creds when warning about ambiguous sources" do
+ it "strips http basic auth creds when warning about ambiguous sources", :bundler => "< 2" do
gemfile <<-G
source "#{basic_auth_source_uri}"
source "file://#{gem_repo1}"
@@ -602,7 +691,7 @@ RSpec.describe "gemcutter's dependency API" do
end
end
- context "when ruby is compiled without openssl" do
+ context "when ruby is compiled without openssl", :ruby_repo do
before do
# Install a monkeypatch that reproduces the effects of openssl being
# missing when the fetcher runs, as happens in real life. The reason
@@ -629,7 +718,7 @@ RSpec.describe "gemcutter's dependency API" do
context "when SSL certificate verification fails" do
it "explains what happened" do
# Install a monkeypatch that reproduces the effects of openssl raising
- # a certificate validation error when Rubygems tries to connect.
+ # a certificate validation error when RubyGems tries to connect.
gemfile <<-G
class Net::HTTP
def start
diff --git a/spec/bundler/install/gems/env_spec.rb b/spec/bundler/install/gems/env_spec.rb
index 9b1d8e5424..0dccbbfd24 100644
--- a/spec/bundler/install/gems/env_spec.rb
+++ b/spec/bundler/install/gems/env_spec.rb
@@ -1,5 +1,4 @@
# frozen_string_literal: true
-require "spec_helper"
RSpec.describe "bundle install with ENV conditionals" do
describe "when just setting an ENV key as a string" do
diff --git a/spec/bundler/install/gems/flex_spec.rb b/spec/bundler/install/gems/flex_spec.rb
index 2c2d3c16a1..f6af806154 100644
--- a/spec/bundler/install/gems/flex_spec.rb
+++ b/spec/bundler/install/gems/flex_spec.rb
@@ -1,5 +1,4 @@
# frozen_string_literal: true
-require "spec_helper"
RSpec.describe "bundle flex_install" do
it "installs the gems as expected" do
@@ -194,8 +193,6 @@ RSpec.describe "bundle flex_install" do
it "suggests bundle update when the Gemfile requires different versions than the lock" do
nice_error = <<-E.strip.gsub(/^ {8}/, "")
- Fetching source index from file:#{gem_repo2}/
- Resolving dependencies...
Bundler could not find compatible versions for gem "rack":
In snapshot (Gemfile.lock):
rack (= 0.9.1)
@@ -212,7 +209,7 @@ RSpec.describe "bundle flex_install" do
E
bundle :install, :retry => 0
- expect(out).to eq(nice_error)
+ expect(last_command.bundler_err).to end_with(nice_error)
end
end
@@ -247,13 +244,13 @@ RSpec.describe "bundle flex_install" do
end
describe "when adding a new source" do
- it "updates the lockfile" do
+ it "updates the lockfile", :bundler => "< 2" do
build_repo2
- install_gemfile <<-G
+ install_gemfile! <<-G
source "file://#{gem_repo1}"
gem "rack"
G
- install_gemfile <<-G
+ install_gemfile! <<-G
source "file://#{gem_repo1}"
source "file://#{gem_repo2}"
gem "rack"
@@ -276,6 +273,41 @@ RSpec.describe "bundle flex_install" do
#{Bundler::VERSION}
L
end
+
+ it "updates the lockfile", :bundler => "2" do
+ build_repo2
+ install_gemfile! <<-G
+ source "file://#{gem_repo1}"
+ gem "rack"
+ G
+
+ install_gemfile! <<-G
+ source "file://#{gem_repo1}"
+ source "file://#{gem_repo2}" do
+ end
+ gem "rack"
+ G
+
+ lockfile_should_be <<-L
+ GEM
+ remote: file:#{gem_repo1}/
+ specs:
+ rack (1.0.0)
+
+ GEM
+ remote: file:#{gem_repo2}/
+ specs:
+
+ PLATFORMS
+ #{lockfile_platforms}
+
+ DEPENDENCIES
+ rack
+
+ BUNDLED WITH
+ #{Bundler::VERSION}
+ L
+ end
end
# This was written to test github issue #636
diff --git a/spec/bundler/install/gems/mirror_spec.rb b/spec/bundler/install/gems/mirror_spec.rb
index 798156fb12..a8516a28c3 100644
--- a/spec/bundler/install/gems/mirror_spec.rb
+++ b/spec/bundler/install/gems/mirror_spec.rb
@@ -1,5 +1,4 @@
# frozen_string_literal: true
-require "spec_helper"
RSpec.describe "bundle install with a mirror configured" do
describe "when the mirror does not match the gem source" do
diff --git a/spec/bundler/install/gems/native_extensions_spec.rb b/spec/bundler/install/gems/native_extensions_spec.rb
index dcf67e976e..ea616f60d3 100644
--- a/spec/bundler/install/gems/native_extensions_spec.rb
+++ b/spec/bundler/install/gems/native_extensions_spec.rb
@@ -1,5 +1,4 @@
# frozen_string_literal: true
-require "spec_helper"
RSpec.describe "installing a gem with native extensions", :ruby_repo do
it "installs" do
@@ -84,7 +83,6 @@ RSpec.describe "installing a gem with native extensions", :ruby_repo do
G
expect(out).not_to include("extconf.rb failed")
- expect(out).to include("Using c_extension 1.0")
run! "Bundler.require; puts CExtension.new.its_true"
expect(out).to eq("true")
diff --git a/spec/bundler/install/gems/post_install_spec.rb b/spec/bundler/install/gems/post_install_spec.rb
index c3ea3e7c51..c6e348fb65 100644
--- a/spec/bundler/install/gems/post_install_spec.rb
+++ b/spec/bundler/install/gems/post_install_spec.rb
@@ -1,5 +1,4 @@
# frozen_string_literal: true
-require "spec_helper"
RSpec.describe "bundle install" do
context "with gem sources" do
diff --git a/spec/bundler/install/gems/resolving_spec.rb b/spec/bundler/install/gems/resolving_spec.rb
index 7a341fd14f..23e3caaefc 100644
--- a/spec/bundler/install/gems/resolving_spec.rb
+++ b/spec/bundler/install/gems/resolving_spec.rb
@@ -1,5 +1,4 @@
# frozen_string_literal: true
-require "spec_helper"
RSpec.describe "bundle install with install-time dependencies" do
it "installs gems with implicit rake dependencies", :ruby_repo do
@@ -92,8 +91,10 @@ RSpec.describe "bundle install with install-time dependencies" do
bundle :install, :env => { "DEBUG_RESOLVER_TREE" => "1" }
- expect(err).to include(" net_b")
- expect(err).to include(" net_build_extensions (1.0)")
+ expect(err).to include(" net_b").
+ and include("Starting resolution").
+ and include("Finished resolution").
+ and include("Attempting to activate")
end
end
end
@@ -141,9 +142,6 @@ RSpec.describe "bundle install with install-time dependencies" do
expect(out).to_not include("Gem::InstallError: require_ruby requires Ruby version > 9000")
nice_error = strip_whitespace(<<-E).strip
- Fetching gem metadata from http://localgemserver.test/.
- Fetching version metadata from http://localgemserver.test/
- Resolving dependencies...
Bundler could not find compatible versions for gem "ruby\0":
In Gemfile:
ruby\0 (#{error_message_requirement})
@@ -151,9 +149,10 @@ RSpec.describe "bundle install with install-time dependencies" do
require_ruby was resolved to 1.0, which depends on
ruby\0 (> 9000)
- Could not find gem 'ruby\0 (> 9000)', which is required by gem 'require_ruby', in any of the sources.
+ Could not find gem 'ruby\0 (> 9000)', which is required by gem 'require_ruby', in any of the relevant sources:
+ the local ruby installation
E
- expect(out).to eq(nice_error)
+ expect(last_command.bundler_err).to end_with(nice_error)
end
end
diff --git a/spec/bundler/install/gems/standalone_spec.rb b/spec/bundler/install/gems/standalone_spec.rb
index 9a79a05b32..551f07848d 100644
--- a/spec/bundler/install/gems/standalone_spec.rb
+++ b/spec/bundler/install/gems/standalone_spec.rb
@@ -1,5 +1,4 @@
# frozen_string_literal: true
-require "spec_helper"
RSpec.shared_examples "bundle install --standalone" do
shared_examples "common functionality" do
@@ -51,10 +50,11 @@ RSpec.shared_examples "bundle install --standalone" do
describe "with simple gems" do
before do
- install_gemfile <<-G, :standalone => true
+ gemfile <<-G
source "file://#{gem_repo1}"
gem "rails"
G
+ bundle! :install, forgotten_command_line_options(:path => "bundle").merge(:standalone => true)
end
let(:expected_gems) do
@@ -69,7 +69,7 @@ RSpec.shared_examples "bundle install --standalone" do
describe "with gems with native extension", :ruby_repo do
before do
- install_gemfile <<-G, :standalone => true
+ install_gemfile <<-G, forgotten_command_line_options(:path => "bundle").merge(:standalone => true)
source "file://#{gem_repo1}"
gem "very_simple_binary"
G
@@ -101,7 +101,7 @@ RSpec.shared_examples "bundle install --standalone" do
end
G
end
- install_gemfile <<-G, :standalone => true
+ install_gemfile <<-G, forgotten_command_line_options(:path => "bundle").merge(:standalone => true)
gem "bar", :git => "#{lib_path("bar-1.0")}"
G
end
@@ -116,11 +116,12 @@ RSpec.shared_examples "bundle install --standalone" do
before do
build_git "devise", "1.0"
- install_gemfile <<-G, :standalone => true
+ gemfile <<-G
source "file://#{gem_repo1}"
gem "rails"
gem "devise", :git => "#{lib_path("devise-1.0")}"
G
+ bundle! :install, forgotten_command_line_options(:path => "bundle").merge(:standalone => true)
end
let(:expected_gems) do
@@ -138,7 +139,7 @@ RSpec.shared_examples "bundle install --standalone" do
before do
build_git "devise", "1.0"
- install_gemfile <<-G, :standalone => true
+ gemfile <<-G
source "file://#{gem_repo1}"
gem "rails"
@@ -147,6 +148,7 @@ RSpec.shared_examples "bundle install --standalone" do
gem "rack-test"
end
G
+ bundle! :install, forgotten_command_line_options(:path => "bundle").merge(:standalone => true)
end
let(:expected_gems) do
@@ -159,7 +161,7 @@ RSpec.shared_examples "bundle install --standalone" do
include_examples "common functionality"
it "allows creating a standalone file with limited groups" do
- bundle "install --standalone default"
+ bundle! "install", forgotten_command_line_options(:path => "bundle").merge(:standalone => "default")
Dir.chdir(bundled_app) do
load_error_ruby <<-RUBY, "spec", :no_lib => true
@@ -172,12 +174,12 @@ RSpec.shared_examples "bundle install --standalone" do
RUBY
end
- expect(out).to eq("2.3.2")
- expect(err).to eq("ZOMG LOAD ERROR")
+ expect(last_command.stdout).to eq("2.3.2")
+ expect(last_command.stderr).to eq("ZOMG LOAD ERROR")
end
it "allows --without to limit the groups used in a standalone" do
- bundle "install --standalone --without test"
+ bundle! :install, forgotten_command_line_options(:path => "bundle", :without => "test").merge(:standalone => true)
Dir.chdir(bundled_app) do
load_error_ruby <<-RUBY, "spec", :no_lib => true
@@ -190,12 +192,12 @@ RSpec.shared_examples "bundle install --standalone" do
RUBY
end
- expect(out).to eq("2.3.2")
- expect(err).to eq("ZOMG LOAD ERROR")
+ expect(last_command.stdout).to eq("2.3.2")
+ expect(last_command.stderr).to eq("ZOMG LOAD ERROR")
end
it "allows --path to change the location of the standalone bundle" do
- bundle "install --standalone --path path/to/bundle"
+ bundle! "install", forgotten_command_line_options(:path => "path/to/bundle").merge(:standalone => true)
Dir.chdir(bundled_app) do
ruby <<-RUBY, :no_lib => true
@@ -207,12 +209,12 @@ RSpec.shared_examples "bundle install --standalone" do
RUBY
end
- expect(out).to eq("2.3.2")
+ expect(last_command.stdout).to eq("2.3.2")
end
it "allows remembered --without to limit the groups used in a standalone" do
- bundle "install --without test"
- bundle "install --standalone"
+ bundle! :install, forgotten_command_line_options(:without => "test")
+ bundle! :install, forgotten_command_line_options(:path => "bundle").merge(:standalone => true)
Dir.chdir(bundled_app) do
load_error_ruby <<-RUBY, "spec", :no_lib => true
@@ -225,8 +227,8 @@ RSpec.shared_examples "bundle install --standalone" do
RUBY
end
- expect(out).to eq("2.3.2")
- expect(err).to eq("ZOMG LOAD ERROR")
+ expect(last_command.stdout).to eq("2.3.2")
+ expect(last_command.stderr).to eq("ZOMG LOAD ERROR")
end
end
@@ -239,7 +241,7 @@ RSpec.shared_examples "bundle install --standalone" do
source "#{source_uri}"
gem "rails"
G
- bundle "install --standalone", :artifice => "endpoint"
+ bundle! :install, forgotten_command_line_options(:path => "bundle").merge(:standalone => true, :artifice => "endpoint")
end
let(:expected_gems) do
@@ -253,12 +255,13 @@ RSpec.shared_examples "bundle install --standalone" do
end
end
- describe "with --binstubs" do
+ describe "with --binstubs", :bundler => "< 2" do
before do
- install_gemfile <<-G, :standalone => true, :binstubs => true
+ gemfile <<-G
source "file://#{gem_repo1}"
gem "rails"
G
+ bundle! :install, forgotten_command_line_options(:path => "bundle").merge(:standalone => true, :binstubs => true)
end
let(:expected_gems) do
diff --git a/spec/bundler/install/gems/sudo_spec.rb b/spec/bundler/install/gems/sudo_spec.rb
index 13abffc14e..ae94eee9c6 100644
--- a/spec/bundler/install/gems/sudo_spec.rb
+++ b/spec/bundler/install/gems/sudo_spec.rb
@@ -1,10 +1,10 @@
# frozen_string_literal: true
-require "spec_helper"
RSpec.describe "when using sudo", :sudo => true do
describe "and BUNDLE_PATH is writable" do
context "but BUNDLE_PATH/build_info is not writable" do
before do
+ bundle! "config path.system true"
subdir = system_gem_path("cache")
subdir.mkpath
sudo "chmod u-w #{subdir}"
@@ -25,6 +25,7 @@ RSpec.describe "when using sudo", :sudo => true do
describe "and GEM_HOME is owned by root" do
before :each do
+ bundle! "config path.system true"
chown_system_gems_to_root
end
@@ -83,7 +84,7 @@ RSpec.describe "when using sudo", :sudo => true do
expect(the_bundle).to include_gems "rack 1.0"
end
- it "installs extensions/ compiled by Rubygems 2.2", :rubygems => "2.2" do
+ it "installs extensions/ compiled by RubyGems 2.2", :rubygems => "2.2" do
install_gemfile <<-G
source "file://#{gem_repo1}"
gem "very_simple_binary"
@@ -128,6 +129,7 @@ RSpec.describe "when using sudo", :sudo => true do
describe "and GEM_HOME is not writable" do
it "installs" do
+ bundle! "config path.system true"
gem_home = tmp("sudo_gem_home")
sudo "mkdir -p #{gem_home}"
sudo "chmod ugo-w #{gem_home}"
@@ -162,16 +164,9 @@ RSpec.describe "when using sudo", :sudo => true do
end
end
- context "when silence_root_warning is passed as an option" do
- it "skips the warning" do
- bundle :install, :sudo => true, :silence_root_warning => true
- expect(out).to_not include(warning)
- end
- end
-
context "when silence_root_warning = false" do
it "warns against that" do
- bundle :install, :sudo => true, :silence_root_warning => false
+ bundle :install, :sudo => true, :env => { "BUNDLE_SILENCE_ROOT_WARNING" => "false" }
expect(out).to include(warning)
end
end
diff --git a/spec/bundler/install/gems/win32_spec.rb b/spec/bundler/install/gems/win32_spec.rb
index cdad9a8821..ad758b94fa 100644
--- a/spec/bundler/install/gems/win32_spec.rb
+++ b/spec/bundler/install/gems/win32_spec.rb
@@ -1,5 +1,4 @@
# frozen_string_literal: true
-require "spec_helper"
RSpec.describe "bundle install with win32-generated lockfile" do
it "should read lockfile" do
diff --git a/spec/bundler/install/gemspecs_spec.rb b/spec/bundler/install/gemspecs_spec.rb
index 97eaf149c1..0c1ed99097 100644
--- a/spec/bundler/install/gemspecs_spec.rb
+++ b/spec/bundler/install/gemspecs_spec.rb
@@ -1,5 +1,4 @@
# frozen_string_literal: true
-require "spec_helper"
RSpec.describe "bundle install" do
describe "when a gem has a YAML gemspec" do
@@ -34,8 +33,8 @@ RSpec.describe "bundle install" do
gem 'rack'
G
- FileUtils.mkdir_p "#{tmp}/gems/system/specifications"
- File.open("#{tmp}/gems/system/specifications/rack-1.0.0.gemspec", "w+") do |f|
+ FileUtils.mkdir_p "#{default_bundle_path}/specifications"
+ File.open("#{default_bundle_path}/specifications/rack-1.0.0.gemspec", "w+") do |f|
spec = Gem::Specification.new do |s|
s.name = "rack"
s.version = "1.0.0"
diff --git a/spec/bundler/install/git_spec.rb b/spec/bundler/install/git_spec.rb
index 04f2380b45..6ae718c2a4 100644
--- a/spec/bundler/install/git_spec.rb
+++ b/spec/bundler/install/git_spec.rb
@@ -1,21 +1,20 @@
# frozen_string_literal: true
-require "spec_helper"
RSpec.describe "bundle install" do
context "git sources" do
- it "displays the revision hash of the gem repository" do
+ it "displays the revision hash of the gem repository", :bundler => "< 2" do
build_git "foo", "1.0", :path => lib_path("foo")
install_gemfile <<-G
gem "foo", :git => "#{lib_path("foo")}"
G
- bundle :install
+ bundle! :install
expect(out).to include("Using foo 1.0 from #{lib_path("foo")} (at master@#{revision_for(lib_path("foo"))[0..6]})")
expect(the_bundle).to include_gems "foo 1.0", :source => "git@#{lib_path("foo")}"
end
- it "displays the ref of the gem repository when using branch~num as a ref" do
+ it "displays the ref of the gem repository when using branch~num as a ref", :bundler => "< 2" do
build_git "foo", "1.0", :path => lib_path("foo")
rev = revision_for(lib_path("foo"))[0..6]
update_git "foo", "2.0", :path => lib_path("foo"), :gemspec => true
@@ -32,13 +31,13 @@ RSpec.describe "bundle install" do
update_git "foo", "4.0", :path => lib_path("foo"), :gemspec => true
- bundle! :update
+ bundle! :update, :all => bundle_update_requires_all?
expect(out).to include("Using foo 2.0 (was 1.0) from #{lib_path("foo")} (at master~2@#{rev2})")
expect(the_bundle).to include_gems "foo 2.0", :source => "git@#{lib_path("foo")}"
end
- it "should check out git repos that are missing but not being installed" do
- build_git "foo"
+ it "should allows git repos that are missing but not being installed" do
+ revision = build_git("foo").ref_for("HEAD")
gemfile <<-G
gem "foo", :git => "file://#{lib_path("foo-1.0")}", :group => :development
@@ -47,6 +46,7 @@ RSpec.describe "bundle install" do
lockfile <<-L
GIT
remote: file://#{lib_path("foo-1.0")}
+ revision: #{revision}
specs:
foo (1.0)
@@ -57,10 +57,9 @@ RSpec.describe "bundle install" do
foo!
L
- bundle "install --path=vendor/bundle --without development"
+ bundle! :install, forgotten_command_line_options(:path => "vendor/bundle", :without => "development")
expect(out).to include("Bundle complete!")
- expect(vendored_gems("bundler/gems/foo-1.0-#{revision_for(lib_path("foo-1.0"))[0..11]}")).to be_directory
end
end
end
diff --git a/spec/bundler/install/global_cache_spec.rb b/spec/bundler/install/global_cache_spec.rb
new file mode 100644
index 0000000000..7696dc788f
--- /dev/null
+++ b/spec/bundler/install/global_cache_spec.rb
@@ -0,0 +1,235 @@
+# frozen_string_literal: true
+
+RSpec.describe "global gem caching" do
+ before { bundle! "config global_gem_cache true" }
+
+ describe "using the cross-application user cache" do
+ let(:source) { "http://localgemserver.test" }
+ let(:source2) { "http://gemserver.example.org" }
+
+ def source_global_cache(*segments)
+ home(".bundle", "cache", "gems", "localgemserver.test.80.dd34752a738ee965a2a4298dc16db6c5", *segments)
+ end
+
+ def source2_global_cache(*segments)
+ home(".bundle", "cache", "gems", "gemserver.example.org.80.1ae1663619ffe0a3c9d97712f44c705b", *segments)
+ end
+
+ it "caches gems into the global cache on download" do
+ install_gemfile! <<-G, :artifice => "compact_index"
+ source "#{source}"
+ gem "rack"
+ G
+
+ expect(the_bundle).to include_gems "rack 1.0.0"
+ expect(source_global_cache("rack-1.0.0.gem")).to exist
+ end
+
+ it "uses globally cached gems if they exist" do
+ source_global_cache.mkpath
+ FileUtils.cp(gem_repo1("gems/rack-1.0.0.gem"), source_global_cache("rack-1.0.0.gem"))
+
+ install_gemfile! <<-G, :artifice => "compact_index_no_gem"
+ source "#{source}"
+ gem "rack"
+ G
+
+ expect(the_bundle).to include_gems "rack 1.0.0"
+ end
+
+ describe "when the same gem from different sources is installed" do
+ it "should use the appropriate one from the global cache" do
+ install_gemfile! <<-G, :artifice => "compact_index"
+ source "#{source}"
+ gem "rack"
+ G
+
+ FileUtils.rm_r(default_bundle_path)
+ expect(the_bundle).not_to include_gems "rack 1.0.0"
+ expect(source_global_cache("rack-1.0.0.gem")).to exist
+ # rack 1.0.0 is not installed and it is in the global cache
+
+ install_gemfile! <<-G, :artifice => "compact_index"
+ source "#{source2}"
+ gem "rack", "0.9.1"
+ G
+
+ FileUtils.rm_r(default_bundle_path)
+ expect(the_bundle).not_to include_gems "rack 0.9.1"
+ expect(source2_global_cache("rack-0.9.1.gem")).to exist
+ # rack 0.9.1 is not installed and it is in the global cache
+
+ gemfile <<-G
+ source "#{source}"
+ gem "rack", "1.0.0"
+ G
+
+ bundle! :install, :artifice => "compact_index_no_gem"
+ # rack 1.0.0 is installed and rack 0.9.1 is not
+ expect(the_bundle).to include_gems "rack 1.0.0"
+ expect(the_bundle).not_to include_gems "rack 0.9.1"
+ FileUtils.rm_r(default_bundle_path)
+
+ gemfile <<-G
+ source "#{source2}"
+ gem "rack", "0.9.1"
+ G
+
+ bundle! :install, :artifice => "compact_index_no_gem"
+ # rack 0.9.1 is installed and rack 1.0.0 is not
+ expect(the_bundle).to include_gems "rack 0.9.1"
+ expect(the_bundle).not_to include_gems "rack 1.0.0"
+ end
+
+ it "should not install if the wrong source is provided" do
+ gemfile <<-G
+ source "#{source}"
+ gem "rack"
+ G
+
+ bundle! :install, :artifice => "compact_index"
+ FileUtils.rm_r(default_bundle_path)
+ expect(the_bundle).not_to include_gems "rack 1.0.0"
+ expect(source_global_cache("rack-1.0.0.gem")).to exist
+ # rack 1.0.0 is not installed and it is in the global cache
+
+ gemfile <<-G
+ source "#{source2}"
+ gem "rack", "0.9.1"
+ G
+
+ bundle! :install, :artifice => "compact_index"
+ FileUtils.rm_r(default_bundle_path)
+ expect(the_bundle).not_to include_gems "rack 0.9.1"
+ expect(source2_global_cache("rack-0.9.1.gem")).to exist
+ # rack 0.9.1 is not installed and it is in the global cache
+
+ gemfile <<-G
+ source "#{source2}"
+ gem "rack", "1.0.0"
+ G
+
+ expect(source_global_cache("rack-1.0.0.gem")).to exist
+ expect(source2_global_cache("rack-0.9.1.gem")).to exist
+ bundle :install, :artifice => "compact_index_no_gem"
+ expect(out).to include("Internal Server Error 500")
+ # rack 1.0.0 is not installed and rack 0.9.1 is not
+ expect(the_bundle).not_to include_gems "rack 1.0.0"
+ expect(the_bundle).not_to include_gems "rack 0.9.1"
+
+ gemfile <<-G
+ source "#{source}"
+ gem "rack", "0.9.1"
+ G
+
+ expect(source_global_cache("rack-1.0.0.gem")).to exist
+ expect(source2_global_cache("rack-0.9.1.gem")).to exist
+ bundle :install, :artifice => "compact_index_no_gem"
+ expect(out).to include("Internal Server Error 500")
+ # rack 0.9.1 is not installed and rack 1.0.0 is not
+ expect(the_bundle).not_to include_gems "rack 0.9.1"
+ expect(the_bundle).not_to include_gems "rack 1.0.0"
+ end
+ end
+
+ describe "when installing gems from a different directory" do
+ it "uses the global cache as a source" do
+ install_gemfile! <<-G, :artifice => "compact_index"
+ source "#{source}"
+ gem "rack"
+ gem "activesupport"
+ G
+
+ # Both gems are installed and in the global cache
+ expect(the_bundle).to include_gems "rack 1.0.0"
+ expect(the_bundle).to include_gems "activesupport 2.3.5"
+ expect(source_global_cache("rack-1.0.0.gem")).to exist
+ expect(source_global_cache("activesupport-2.3.5.gem")).to exist
+ FileUtils.rm_r(default_bundle_path)
+ # Both gems are now only in the global cache
+ expect(the_bundle).not_to include_gems "rack 1.0.0"
+ expect(the_bundle).not_to include_gems "activesupport 2.3.5"
+
+ install_gemfile! <<-G, :artifice => "compact_index_no_gem"
+ source "#{source}"
+ gem "rack"
+ G
+
+ # rack is installed and both are in the global cache
+ expect(the_bundle).to include_gems "rack 1.0.0"
+ expect(the_bundle).not_to include_gems "activesupport 2.3.5"
+ expect(source_global_cache("rack-1.0.0.gem")).to exist
+ expect(source_global_cache("activesupport-2.3.5.gem")).to exist
+
+ Dir.chdir bundled_app2 do
+ create_file bundled_app2("gems.rb"), <<-G
+ source "#{source}"
+ gem "activesupport"
+ G
+
+ # Neither gem is installed and both are in the global cache
+ expect(the_bundle).not_to include_gems "rack 1.0.0"
+ expect(the_bundle).not_to include_gems "activesupport 2.3.5"
+ expect(source_global_cache("rack-1.0.0.gem")).to exist
+ expect(source_global_cache("activesupport-2.3.5.gem")).to exist
+
+ # Install using the global cache instead of by downloading the .gem
+ # from the server
+ bundle! :install, :artifice => "compact_index_no_gem"
+
+ # activesupport is installed and both are in the global cache
+ expect(the_bundle).not_to include_gems "rack 1.0.0"
+ expect(the_bundle).to include_gems "activesupport 2.3.5"
+ expect(source_global_cache("rack-1.0.0.gem")).to exist
+ expect(source_global_cache("activesupport-2.3.5.gem")).to exist
+ end
+ end
+ end
+ end
+
+ describe "extension caching", :rubygems => "2.2", :ruby_repo do
+ it "works" do
+ build_git "very_simple_git_binary", &:add_c_extension
+ build_lib "very_simple_path_binary", &:add_c_extension
+ revision = revision_for(lib_path("very_simple_git_binary-1.0"))[0, 12]
+
+ install_gemfile! <<-G
+ source "file:#{gem_repo1}"
+
+ gem "very_simple_binary"
+ gem "very_simple_git_binary", :git => "#{lib_path("very_simple_git_binary-1.0")}"
+ gem "very_simple_path_binary", :path => "#{lib_path("very_simple_path_binary-1.0")}"
+ G
+
+ gem_binary_cache = home(".bundle", "cache", "extensions", specific_local_platform.to_s, Bundler.ruby_scope,
+ Digest(:MD5).hexdigest("#{gem_repo1}/"), "very_simple_binary-1.0")
+ git_binary_cache = home(".bundle", "cache", "extensions", specific_local_platform.to_s, Bundler.ruby_scope,
+ "very_simple_git_binary-1.0-#{revision}", "very_simple_git_binary-1.0")
+
+ cached_extensions = Pathname.glob(home(".bundle", "cache", "extensions", "*", "*", "*", "*", "*")).sort
+ expect(cached_extensions).to eq [gem_binary_cache, git_binary_cache].sort
+
+ run! <<-R
+ require 'very_simple_binary_c'; puts ::VERY_SIMPLE_BINARY_IN_C
+ require 'very_simple_git_binary_c'; puts ::VERY_SIMPLE_GIT_BINARY_IN_C
+ R
+ expect(out).to eq "VERY_SIMPLE_BINARY_IN_C\nVERY_SIMPLE_GIT_BINARY_IN_C"
+
+ FileUtils.rm Dir[home(".bundle", "cache", "extensions", "**", "*binary_c*")]
+
+ gem_binary_cache.join("very_simple_binary_c.rb").open("w") {|f| f << "puts File.basename(__FILE__)" }
+ git_binary_cache.join("very_simple_git_binary_c.rb").open("w") {|f| f << "puts File.basename(__FILE__)" }
+
+ bundle! "config --local path different_path"
+ bundle! :install
+
+ expect(Dir[home(".bundle", "cache", "extensions", "**", "*binary_c*")]).to all(end_with(".rb"))
+
+ run! <<-R
+ require 'very_simple_binary_c'
+ require 'very_simple_git_binary_c'
+ R
+ expect(out).to eq "very_simple_binary_c.rb\nvery_simple_git_binary_c.rb"
+ end
+ end
+end
diff --git a/spec/bundler/install/path_spec.rb b/spec/bundler/install/path_spec.rb
index 7a501d42b3..fc39068f6a 100644
--- a/spec/bundler/install/path_spec.rb
+++ b/spec/bundler/install/path_spec.rb
@@ -1,5 +1,4 @@
# frozen_string_literal: true
-require "spec_helper"
RSpec.describe "bundle install" do
describe "with --path" do
@@ -14,8 +13,8 @@ RSpec.describe "bundle install" do
G
end
- it "does not use available system gems with bundle --path vendor/bundle" do
- bundle "install --path vendor/bundle"
+ it "does not use available system gems with bundle --path vendor/bundle", :bundler => "< 2" do
+ bundle! :install, forgotten_command_line_options(:path => "vendor/bundle")
expect(the_bundle).to include_gems "rack 1.0.0"
end
@@ -24,25 +23,25 @@ RSpec.describe "bundle install" do
dir.mkpath
Dir.chdir(dir) do
- bundle "install --path vendor/bundle"
- expect(out).to include("installed into ./vendor/bundle")
+ bundle! :install, forgotten_command_line_options(:path => "vendor/bundle")
+ expect(out).to include("installed into `./vendor/bundle`")
end
dir.rmtree
end
it "prints a warning to let the user know what has happened with bundle --path vendor/bundle" do
- bundle "install --path vendor/bundle"
- expect(out).to include("gems are installed into ./vendor")
+ bundle! :install, forgotten_command_line_options(:path => "vendor/bundle")
+ expect(out).to include("gems are installed into `./vendor/bundle`")
end
- it "disallows --path vendor/bundle --system" do
+ it "disallows --path vendor/bundle --system", :bundler => "< 2" do
bundle "install --path vendor/bundle --system"
expect(out).to include("Please choose only one option.")
expect(exitstatus).to eq(15) if exitstatus
end
- it "remembers to disable system gems after the first time with bundle --path vendor/bundle" do
+ it "remembers to disable system gems after the first time with bundle --path vendor/bundle", :bundler => "< 2" do
bundle "install --path vendor/bundle"
FileUtils.rm_rf bundled_app("vendor")
bundle "install"
@@ -75,7 +74,7 @@ RSpec.describe "bundle install" do
[:env, :global].each do |type|
it "installs gems to a path if one is specified" do
set_bundle_path(type, bundled_app("vendor2").to_s)
- bundle "install --path vendor/bundle"
+ bundle! :install, forgotten_command_line_options(:path => "vendor/bundle")
expect(vendored_gems("gems/rack-1.0.0")).to be_directory
expect(bundled_app("vendor2")).not_to be_directory
@@ -114,7 +113,7 @@ RSpec.describe "bundle install" do
end
it "sets BUNDLE_PATH as the first argument to bundle install" do
- bundle "install --path ./vendor/bundle"
+ bundle! :install, forgotten_command_line_options(:path => "./vendor/bundle")
expect(vendored_gems("gems/rack-1.0.0")).to be_directory
expect(the_bundle).to include_gems "rack 1.0.0"
@@ -123,7 +122,7 @@ RSpec.describe "bundle install" do
it "disables system gems when passing a path to install" do
# This is so that vendored gems can be distributed to others
build_gem "rack", "1.1.0", :to_system => true
- bundle "install --path ./vendor/bundle"
+ bundle! :install, forgotten_command_line_options(:path => "./vendor/bundle")
expect(vendored_gems("gems/rack-1.0.0")).to be_directory
expect(the_bundle).to include_gems "rack 1.0.0"
@@ -139,7 +138,7 @@ RSpec.describe "bundle install" do
gem "very_simple_binary"
G
- bundle "install --path ./vendor/bundle"
+ bundle! :install, forgotten_command_line_options(:path => "./vendor/bundle")
expect(vendored_gems("gems/very_simple_binary-1.0")).to be_directory
expect(vendored_gems("extensions")).to be_directory
@@ -150,7 +149,7 @@ RSpec.describe "bundle install" do
run "require 'very_simple_binary_c'"
expect(err).to include("Bundler::GemNotFound")
- bundle "install --path ./vendor/bundle"
+ bundle :install, forgotten_command_line_options(:path => "./vendor/bundle")
expect(vendored_gems("gems/very_simple_binary-1.0")).to be_directory
expect(vendored_gems("extensions")).to be_directory
@@ -171,7 +170,7 @@ RSpec.describe "bundle install" do
gem "rack"
G
- bundle "install --path bundle"
+ bundle :install, forgotten_command_line_options(:path => "bundle")
expect(out).to match(/file already exists/)
end
end
diff --git a/spec/bundler/install/post_bundle_message_spec.rb b/spec/bundler/install/post_bundle_message_spec.rb
index 4453e4190f..a953847bac 100644
--- a/spec/bundler/install/post_bundle_message_spec.rb
+++ b/spec/bundler/install/post_bundle_message_spec.rb
@@ -1,5 +1,4 @@
# frozen_string_literal: true
-require "spec_helper"
RSpec.describe "post bundle message" do
before :each do
@@ -14,11 +13,13 @@ RSpec.describe "post bundle message" do
G
end
- let(:bundle_show_message) { "Use `bundle info [gemname]` to see where a bundled gem is installed." }
- let(:bundle_deployment_message) { "Bundled gems are installed into ./vendor" }
- let(:bundle_complete_message) { "Bundle complete!" }
- let(:bundle_updated_message) { "Bundle updated!" }
- let(:installed_gems_stats) { "4 Gemfile dependencies, 5 gems now installed." }
+ let(:bundle_path) { "./.bundle" }
+ let(:bundle_show_system_message) { "Use `bundle info [gemname]` to see where a bundled gem is installed." }
+ let(:bundle_show_path_message) { "Bundled gems are installed into `#{bundle_path}`" }
+ let(:bundle_complete_message) { "Bundle complete!" }
+ let(:bundle_updated_message) { "Bundle updated!" }
+ let(:installed_gems_stats) { "4 Gemfile dependencies, 5 gems now installed." }
+ let(:bundle_show_message) { Bundler::VERSION.split(".").first.to_i < 2 ? bundle_show_system_message : bundle_show_path_message }
describe "for fresh bundle install" do
it "without any options" do
@@ -30,7 +31,7 @@ RSpec.describe "post bundle message" do
end
it "with --without one group" do
- bundle "install --without emo"
+ bundle! :install, forgotten_command_line_options(:without => "emo")
expect(out).to include(bundle_show_message)
expect(out).to include("Gems in the group emo were not installed")
expect(out).to include(bundle_complete_message)
@@ -38,7 +39,7 @@ RSpec.describe "post bundle message" do
end
it "with --without two groups" do
- bundle "install --without emo test"
+ bundle! :install, forgotten_command_line_options(:without => "emo test")
expect(out).to include(bundle_show_message)
expect(out).to include("Gems in the groups emo and test were not installed")
expect(out).to include(bundle_complete_message)
@@ -46,7 +47,7 @@ RSpec.describe "post bundle message" do
end
it "with --without more groups" do
- bundle "install --without emo obama test"
+ bundle! :install, forgotten_command_line_options(:without => "emo obama test")
expect(out).to include(bundle_show_message)
expect(out).to include("Gems in the groups emo, obama and test were not installed")
expect(out).to include(bundle_complete_message)
@@ -54,51 +55,53 @@ RSpec.describe "post bundle message" do
end
describe "with --path and" do
+ let(:bundle_path) { "./vendor" }
+
it "without any options" do
- bundle "install --path vendor"
- expect(out).to include(bundle_deployment_message)
+ bundle! :install, forgotten_command_line_options(:path => "vendor")
+ expect(out).to include(bundle_show_path_message)
expect(out).to_not include("Gems in the group")
expect(out).to include(bundle_complete_message)
end
it "with --without one group" do
- bundle "install --without emo --path vendor"
- expect(out).to include(bundle_deployment_message)
+ bundle! :install, forgotten_command_line_options(:without => "emo", :path => "vendor")
+ expect(out).to include(bundle_show_path_message)
expect(out).to include("Gems in the group emo were not installed")
expect(out).to include(bundle_complete_message)
end
it "with --without two groups" do
- bundle "install --without emo test --path vendor"
- expect(out).to include(bundle_deployment_message)
+ bundle! :install, forgotten_command_line_options(:without => "emo test", :path => "vendor")
+ expect(out).to include(bundle_show_path_message)
expect(out).to include("Gems in the groups emo and test were not installed")
expect(out).to include(bundle_complete_message)
end
it "with --without more groups" do
- bundle "install --without emo obama test --path vendor"
- expect(out).to include(bundle_deployment_message)
+ bundle! :install, forgotten_command_line_options(:without => "emo obama test", :path => "vendor")
+ expect(out).to include(bundle_show_path_message)
expect(out).to include("Gems in the groups emo, obama and test were not installed")
expect(out).to include(bundle_complete_message)
end
it "with an absolute --path inside the cwd" do
- bundle "install --path #{bundled_app}/cache"
- expect(out).to include("Bundled gems are installed into ./cache")
+ bundle! :install, forgotten_command_line_options(:path => bundled_app("cache"))
+ expect(out).to include("Bundled gems are installed into `./cache`")
expect(out).to_not include("Gems in the group")
expect(out).to include(bundle_complete_message)
end
it "with an absolute --path outside the cwd" do
- bundle "install --path #{bundled_app}_cache"
- expect(out).to include("Bundled gems are installed into #{bundled_app}_cache")
+ bundle! :install, forgotten_command_line_options(:path => tmp("not_bundled_app"))
+ expect(out).to include("Bundled gems are installed into `#{tmp("not_bundled_app")}`")
expect(out).to_not include("Gems in the group")
expect(out).to include(bundle_complete_message)
end
end
describe "with misspelled or non-existent gem name" do
- it "should report a helpful error message" do
+ it "should report a helpful error message", :bundler => "< 2" do
install_gemfile <<-G
source "file://#{gem_repo1}"
gem "rack"
@@ -107,6 +110,18 @@ RSpec.describe "post bundle message" do
expect(out).to include("Could not find gem 'not-a-gem' in any of the gem sources listed in your Gemfile.")
end
+ it "should report a helpful error message", :bundler => "2" do
+ install_gemfile <<-G
+ source "file://#{gem_repo1}"
+ gem "rack"
+ gem "not-a-gem", :group => :development
+ G
+ expect(out).to include <<-EOS.strip
+Could not find gem 'not-a-gem' in rubygems repository file:#{gem_repo1}/ or installed locally.
+The source does not contain any versions of 'not-a-gem'
+ EOS
+ end
+
it "should report a helpful error message with reference to cache if available" do
install_gemfile <<-G
source "file://#{gem_repo1}"
@@ -119,7 +134,8 @@ RSpec.describe "post bundle message" do
gem "rack"
gem "not-a-gem", :group => :development
G
- expect(out).to include("Could not find gem 'not-a-gem' in any of the gem sources listed in your Gemfile or in gems cached in vendor/cache.")
+ expect(out).to include("Could not find gem 'not-a-gem' in").
+ and include("or in gems cached in vendor/cache.")
end
end
end
@@ -134,8 +150,8 @@ RSpec.describe "post bundle message" do
end
it "with --without one group" do
- bundle "install --without emo"
- bundle :install
+ bundle! :install, forgotten_command_line_options(:without => "emo")
+ bundle! :install
expect(out).to include(bundle_show_message)
expect(out).to include("Gems in the group emo were not installed")
expect(out).to include(bundle_complete_message)
@@ -143,15 +159,15 @@ RSpec.describe "post bundle message" do
end
it "with --without two groups" do
- bundle "install --without emo test"
- bundle :install
+ bundle! :install, forgotten_command_line_options(:without => "emo test")
+ bundle! :install
expect(out).to include(bundle_show_message)
expect(out).to include("Gems in the groups emo and test were not installed")
expect(out).to include(bundle_complete_message)
end
it "with --without more groups" do
- bundle "install --without emo obama test"
+ bundle! :install, forgotten_command_line_options(:without => "emo obama test")
bundle :install
expect(out).to include(bundle_show_message)
expect(out).to include("Gems in the groups emo, obama and test were not installed")
@@ -161,28 +177,28 @@ RSpec.describe "post bundle message" do
describe "for bundle update" do
it "without any options" do
- bundle :update
+ bundle! :update, :all => bundle_update_requires_all?
expect(out).not_to include("Gems in the groups")
expect(out).to include(bundle_updated_message)
end
it "with --without one group" do
- bundle :install, :without => :emo
- bundle :update
+ bundle! :install, forgotten_command_line_options(:without => "emo")
+ bundle! :update, :all => bundle_update_requires_all?
expect(out).to include("Gems in the group emo were not installed")
expect(out).to include(bundle_updated_message)
end
it "with --without two groups" do
- bundle "install --without emo test"
- bundle :update
+ bundle! :install, forgotten_command_line_options(:without => "emo test")
+ bundle! :update, :all => bundle_update_requires_all?
expect(out).to include("Gems in the groups emo and test were not installed")
expect(out).to include(bundle_updated_message)
end
it "with --without more groups" do
- bundle "install --without emo obama test"
- bundle :update
+ bundle! :install, forgotten_command_line_options(:without => "emo obama test")
+ bundle! :update, :all => bundle_update_requires_all?
expect(out).to include("Gems in the groups emo, obama and test were not installed")
expect(out).to include(bundle_updated_message)
end
diff --git a/spec/bundler/install/prereleases_spec.rb b/spec/bundler/install/prereleases_spec.rb
index 6c32094d90..7af8c3b304 100644
--- a/spec/bundler/install/prereleases_spec.rb
+++ b/spec/bundler/install/prereleases_spec.rb
@@ -1,5 +1,4 @@
# frozen_string_literal: true
-require "spec_helper"
RSpec.describe "bundle install" do
describe "when prerelease gems are available" do
diff --git a/spec/bundler/install/process_lock_spec.rb b/spec/bundler/install/process_lock_spec.rb
new file mode 100644
index 0000000000..02217f493b
--- /dev/null
+++ b/spec/bundler/install/process_lock_spec.rb
@@ -0,0 +1,24 @@
+# frozen_string_literal: true
+
+RSpec.describe "process lock spec" do
+ describe "when an install operation is already holding a process lock" do
+ before { FileUtils.mkdir_p(default_bundle_path) }
+
+ it "will not run a second concurrent bundle install until the lock is released" do
+ thread = Thread.new do
+ Bundler::ProcessLock.lock(default_bundle_path) do
+ sleep 1 # ignore quality_spec
+ expect(the_bundle).not_to include_gems "rack 1.0"
+ end
+ end
+
+ install_gemfile! <<-G
+ source "file://#{gem_repo1}"
+ gem "rack"
+ G
+
+ thread.join
+ expect(the_bundle).to include_gems "rack 1.0"
+ end
+ end
+end
diff --git a/spec/bundler/install/security_policy_spec.rb b/spec/bundler/install/security_policy_spec.rb
index ab531bdad6..7be09d6bd4 100644
--- a/spec/bundler/install/security_policy_spec.rb
+++ b/spec/bundler/install/security_policy_spec.rb
@@ -1,5 +1,5 @@
# frozen_string_literal: true
-require "spec_helper"
+
require "rubygems/security"
# unfortunately, testing signed gems with a provided CA is extremely difficult
@@ -24,7 +24,7 @@ RSpec.describe "policies with unsigned gems" do
it "will fail when given invalid security policy" do
bundle "install --trust-policy=InvalidPolicyName"
- expect(out).to include("Rubygems doesn't know about trust policy")
+ expect(out).to include("RubyGems doesn't know about trust policy")
end
it "will fail with High Security setting due to presence of unsigned gem" do
@@ -32,7 +32,7 @@ RSpec.describe "policies with unsigned gems" do
expect(out).to include("security policy didn't allow")
end
- # This spec will fail on Rubygems 2 rc1 due to a bug in policy.rb. the bug is fixed in rc3.
+ # This spec will fail on RubyGems 2 rc1 due to a bug in policy.rb. the bug is fixed in rc3.
it "will fail with Medium Security setting due to presence of unsigned gem", :unless => ENV["RGV"] == "v2.0.0.rc.1" do
bundle "install --trust-policy=MediumSecurity"
expect(out).to include("security policy didn't allow")
diff --git a/spec/bundler/install/yanked_spec.rb b/spec/bundler/install/yanked_spec.rb
index d42978ce4c..7c4b98bfdf 100644
--- a/spec/bundler/install/yanked_spec.rb
+++ b/spec/bundler/install/yanked_spec.rb
@@ -1,5 +1,4 @@
# frozen_string_literal: true
-require "spec_helper"
RSpec.context "when installing a bundle that includes yanked gems" do
before(:each) do
@@ -38,7 +37,7 @@ RSpec.context "when installing a bundle that includes yanked gems" do
G
expect(out).not_to include("Your bundle is locked to foo (10.0.0)")
- expect(out).to include("Could not find gem 'foo (= 10.0.0)' in any of the gem sources")
+ expect(out).to include("Could not find gem 'foo (= 10.0.0)' in")
end
end
diff --git a/spec/bundler/lock/git_spec.rb b/spec/bundler/lock/git_spec.rb
index b36f61338d..14b80483ee 100644
--- a/spec/bundler/lock/git_spec.rb
+++ b/spec/bundler/lock/git_spec.rb
@@ -1,5 +1,4 @@
# frozen_string_literal: true
-require "spec_helper"
RSpec.describe "bundle lock with git gems" do
before :each do
@@ -30,6 +29,6 @@ RSpec.describe "bundle lock with git gems" do
run <<-RUBY
puts Bundler.rubygems.find_name('foo').first.full_gem_path
RUBY
- expect(out).to eq(bundle("show foo"))
+ expect(out).to eq(bundle("info foo --path"))
end
end
diff --git a/spec/bundler/lock/lockfile_bundler_1_spec.rb b/spec/bundler/lock/lockfile_bundler_1_spec.rb
new file mode 100644
index 0000000000..3be45e29dc
--- /dev/null
+++ b/spec/bundler/lock/lockfile_bundler_1_spec.rb
@@ -0,0 +1,1386 @@
+# frozen_string_literal: true
+
+RSpec.describe "the lockfile format", :bundler => "< 2" do
+ include Bundler::GemHelpers
+
+ before { ENV["BUNDLER_SPEC_IGNORE_COMPATIBILITY_GUARD"] = "TRUE" }
+
+ it "generates a simple lockfile for a single source, gem" do
+ install_gemfile <<-G
+ source "file://#{gem_repo1}"
+
+ gem "rack"
+ G
+
+ lockfile_should_be <<-G
+ GEM
+ remote: file:#{gem_repo1}/
+ specs:
+ rack (1.0.0)
+
+ PLATFORMS
+ #{generic_local_platform}
+
+ DEPENDENCIES
+ rack
+
+ BUNDLED WITH
+ #{Bundler::VERSION}
+ G
+ end
+
+ it "updates the lockfile's bundler version if current ver. is newer" do
+ lockfile <<-L
+ GIT
+ remote: git://github.com/nex3/haml.git
+ revision: 8a2271f
+ specs:
+
+ GEM
+ remote: file://#{gem_repo1}/
+ specs:
+ rack (1.0.0)
+
+ PLATFORMS
+ #{generic_local_platform}
+
+ DEPENDENCIES
+ omg!
+ rack
+
+ BUNDLED WITH
+ 1.8.2
+ L
+
+ install_gemfile <<-G
+ source "file://#{gem_repo1}"
+
+ gem "rack"
+ G
+
+ lockfile_should_be <<-G
+ GEM
+ remote: file:#{gem_repo1}/
+ specs:
+ rack (1.0.0)
+
+ PLATFORMS
+ #{generic_local_platform}
+
+ DEPENDENCIES
+ rack
+
+ BUNDLED WITH
+ #{Bundler::VERSION}
+ G
+ end
+
+ it "does not update the lockfile's bundler version if nothing changed during bundle install" do
+ version = "#{Bundler::VERSION.split(".").first}.0.0.0.a"
+
+ lockfile <<-L
+ GEM
+ remote: file:#{gem_repo1}/
+ specs:
+ rack (1.0.0)
+
+ PLATFORMS
+ #{generic_local_platform}
+
+ DEPENDENCIES
+ rack
+
+ BUNDLED WITH
+ #{version}
+ L
+
+ install_gemfile <<-G
+ source "file://#{gem_repo1}"
+
+ gem "rack"
+ G
+
+ lockfile_should_be <<-G
+ GEM
+ remote: file:#{gem_repo1}/
+ specs:
+ rack (1.0.0)
+
+ PLATFORMS
+ #{generic_local_platform}
+
+ DEPENDENCIES
+ rack
+
+ BUNDLED WITH
+ #{version}
+ G
+ end
+
+ it "updates the lockfile's bundler version if not present" do
+ lockfile <<-L
+ GEM
+ remote: file:#{gem_repo1}/
+ specs:
+ rack (1.0.0)
+
+ PLATFORMS
+ #{generic_local_platform}
+
+ DEPENDENCIES
+ rack
+ L
+
+ install_gemfile <<-G
+ source "file://#{gem_repo1}"
+
+ gem "rack", "> 0"
+ G
+
+ lockfile_should_be <<-G
+ GEM
+ remote: file:#{gem_repo1}/
+ specs:
+ rack (1.0.0)
+
+ PLATFORMS
+ #{generic_local_platform}
+
+ DEPENDENCIES
+ rack (> 0)
+
+ BUNDLED WITH
+ #{Bundler::VERSION}
+ G
+ end
+
+ it "outputs a warning if the current is older than lockfile's bundler version" do
+ lockfile <<-L
+ GEM
+ remote: file:#{gem_repo1}/
+ specs:
+ rack (1.0.0)
+
+ PLATFORMS
+ #{generic_local_platform}
+
+ DEPENDENCIES
+ rack
+
+ BUNDLED WITH
+ 9999999.1.0
+ L
+
+ simulate_bundler_version "9999999.0.0" do
+ install_gemfile <<-G
+ source "file://#{gem_repo1}"
+
+ gem "rack"
+ G
+ end
+
+ warning_message = "the running version of Bundler (9999999.0.0) is older " \
+ "than the version that created the lockfile (9999999.1.0)"
+ expect(out.scan(warning_message).size).to eq(1)
+
+ lockfile_should_be <<-G
+ GEM
+ remote: file:#{gem_repo1}/
+ specs:
+ rack (1.0.0)
+
+ PLATFORMS
+ #{generic_local_platform}
+ #{specific_local_platform}
+
+ DEPENDENCIES
+ rack
+
+ BUNDLED WITH
+ 9999999.1.0
+ G
+ end
+
+ it "errors if the current is a major version older than lockfile's bundler version" do
+ lockfile <<-L
+ GEM
+ remote: file:#{gem_repo1}/
+ specs:
+ rack (1.0.0)
+
+ PLATFORMS
+ #{generic_local_platform}
+
+ DEPENDENCIES
+ rack
+
+ BUNDLED WITH
+ 9999999.0.0
+ L
+
+ install_gemfile <<-G
+ source "file://#{gem_repo1}"
+
+ gem "rack"
+ G
+
+ expect(exitstatus > 0) if exitstatus
+ expect(out).to include("You must use Bundler 9999999 or greater with this lockfile.")
+ end
+
+ it "shows a friendly error when running with a new bundler 2 lockfile" do
+ lockfile <<-L
+ GEM
+ remote: https://rails-assets.org/
+ specs:
+ rails-assets-bootstrap (3.3.4)
+ rails-assets-jquery (>= 1.9.1)
+ rails-assets-jquery (2.1.4)
+
+ GEM
+ remote: https://rubygems.org/
+ specs:
+ rake (10.4.2)
+
+ PLATFORMS
+ ruby
+
+ DEPENDENCIES
+ rails-assets-bootstrap!
+ rake
+
+ BUNDLED WITH
+ 9999999.0.0
+ L
+
+ install_gemfile <<-G
+ source 'https://rubygems.org'
+ gem 'rake'
+
+ source 'https://rails-assets.org' do
+ gem 'rails-assets-bootstrap'
+ end
+ G
+
+ expect(exitstatus > 0) if exitstatus
+ expect(out).to include("You must use Bundler 9999999 or greater with this lockfile.")
+ end
+
+ it "warns when updating bundler major version" do
+ lockfile <<-L
+ GEM
+ remote: file:#{gem_repo1}/
+ specs:
+ rack (1.0.0)
+
+ PLATFORMS
+ #{generic_local_platform}
+
+ DEPENDENCIES
+ rack
+
+ BUNDLED WITH
+ 1.10.0
+ L
+
+ simulate_bundler_version "9999999.0.0" do
+ install_gemfile <<-G
+ source "file://#{gem_repo1}"
+
+ gem "rack"
+ G
+ end
+
+ expect(out).to include("Warning: the lockfile is being updated to Bundler " \
+ "9999999, after which you will be unable to return to Bundler 1.")
+
+ lockfile_should_be <<-G
+ GEM
+ remote: file:#{gem_repo1}/
+ specs:
+ rack (1.0.0)
+
+ PLATFORMS
+ #{generic_local_platform}
+ #{specific_local_platform}
+
+ DEPENDENCIES
+ rack
+
+ BUNDLED WITH
+ 9999999.0.0
+ G
+ end
+
+ it "generates a simple lockfile for a single source, gem with dependencies" do
+ install_gemfile <<-G
+ source "file://#{gem_repo1}"
+
+ gem "rack-obama"
+ G
+
+ lockfile_should_be <<-G
+ GEM
+ remote: file:#{gem_repo1}/
+ specs:
+ rack (1.0.0)
+ rack-obama (1.0)
+ rack
+
+ PLATFORMS
+ #{generic_local_platform}
+
+ DEPENDENCIES
+ rack-obama
+
+ BUNDLED WITH
+ #{Bundler::VERSION}
+ G
+ end
+
+ it "generates a simple lockfile for a single source, gem with a version requirement" do
+ install_gemfile <<-G
+ source "file://#{gem_repo1}"
+
+ gem "rack-obama", ">= 1.0"
+ G
+
+ lockfile_should_be <<-G
+ GEM
+ remote: file:#{gem_repo1}/
+ specs:
+ rack (1.0.0)
+ rack-obama (1.0)
+ rack
+
+ PLATFORMS
+ #{generic_local_platform}
+
+ DEPENDENCIES
+ rack-obama (>= 1.0)
+
+ BUNDLED WITH
+ #{Bundler::VERSION}
+ G
+ end
+
+ it "generates a lockfile wihout credentials for a configured source" do
+ bundle "config http://localgemserver.test/ user:pass"
+
+ install_gemfile(<<-G, :artifice => "endpoint_strict_basic_authentication", :quiet => true)
+ source "http://localgemserver.test/"
+ source "http://user:pass@othergemserver.test/"
+
+ gem "rack-obama", ">= 1.0"
+ G
+
+ lockfile_should_be <<-G
+ GEM
+ remote: http://localgemserver.test/
+ remote: http://user:pass@othergemserver.test/
+ specs:
+ rack (1.0.0)
+ rack-obama (1.0)
+ rack
+
+ PLATFORMS
+ #{generic_local_platform}
+
+ DEPENDENCIES
+ rack-obama (>= 1.0)
+
+ BUNDLED WITH
+ #{Bundler::VERSION}
+ G
+ end
+
+ it "generates lockfiles with multiple requirements" do
+ install_gemfile <<-G
+ source "file://#{gem_repo1}"
+ gem "net-sftp"
+ G
+
+ lockfile_should_be <<-G
+ GEM
+ remote: file:#{gem_repo1}/
+ specs:
+ net-sftp (1.1.1)
+ net-ssh (>= 1.0.0, < 1.99.0)
+ net-ssh (1.0)
+
+ PLATFORMS
+ ruby
+
+ DEPENDENCIES
+ net-sftp
+
+ BUNDLED WITH
+ #{Bundler::VERSION}
+ G
+
+ expect(the_bundle).to include_gems "net-sftp 1.1.1", "net-ssh 1.0.0"
+ end
+
+ it "generates a simple lockfile for a single pinned source, gem with a version requirement" do
+ git = build_git "foo"
+
+ install_gemfile <<-G
+ gem "foo", :git => "#{lib_path("foo-1.0")}"
+ G
+
+ lockfile_should_be <<-G
+ GIT
+ remote: #{lib_path("foo-1.0")}
+ revision: #{git.ref_for("master")}
+ specs:
+ foo (1.0)
+
+ GEM
+ specs:
+
+ PLATFORMS
+ #{generic_local_platform}
+
+ DEPENDENCIES
+ foo!
+
+ BUNDLED WITH
+ #{Bundler::VERSION}
+ G
+ end
+
+ it "does not asplode when a platform specific dependency is present and the Gemfile has not been resolved on that platform" do
+ build_lib "omg", :path => lib_path("omg")
+
+ gemfile <<-G
+ source "file://#{gem_repo1}"
+
+ platforms :#{not_local_tag} do
+ gem "omg", :path => "#{lib_path("omg")}"
+ end
+
+ gem "rack"
+ G
+
+ lockfile <<-L
+ GIT
+ remote: git://github.com/nex3/haml.git
+ revision: 8a2271f
+ specs:
+
+ GEM
+ remote: file://#{gem_repo1}/
+ specs:
+ rack (1.0.0)
+
+ PLATFORMS
+ #{not_local}
+
+ DEPENDENCIES
+ omg!
+ rack
+
+ BUNDLED WITH
+ #{Bundler::VERSION}
+ L
+
+ bundle "install"
+ expect(the_bundle).to include_gems "rack 1.0.0"
+ end
+
+ it "serializes global git sources" do
+ git = build_git "foo"
+
+ install_gemfile <<-G
+ git "#{lib_path("foo-1.0")}" do
+ gem "foo"
+ end
+ G
+
+ lockfile_should_be <<-G
+ GIT
+ remote: #{lib_path("foo-1.0")}
+ revision: #{git.ref_for("master")}
+ specs:
+ foo (1.0)
+
+ GEM
+ specs:
+
+ PLATFORMS
+ #{generic_local_platform}
+
+ DEPENDENCIES
+ foo!
+
+ BUNDLED WITH
+ #{Bundler::VERSION}
+ G
+ end
+
+ it "generates a lockfile with a ref for a single pinned source, git gem with a branch requirement" do
+ git = build_git "foo"
+ update_git "foo", :branch => "omg"
+
+ install_gemfile <<-G
+ gem "foo", :git => "#{lib_path("foo-1.0")}", :branch => "omg"
+ G
+
+ lockfile_should_be <<-G
+ GIT
+ remote: #{lib_path("foo-1.0")}
+ revision: #{git.ref_for("omg")}
+ branch: omg
+ specs:
+ foo (1.0)
+
+ GEM
+ specs:
+
+ PLATFORMS
+ #{generic_local_platform}
+
+ DEPENDENCIES
+ foo!
+
+ BUNDLED WITH
+ #{Bundler::VERSION}
+ G
+ end
+
+ it "generates a lockfile with a ref for a single pinned source, git gem with a tag requirement" do
+ git = build_git "foo"
+ update_git "foo", :tag => "omg"
+
+ install_gemfile <<-G
+ gem "foo", :git => "#{lib_path("foo-1.0")}", :tag => "omg"
+ G
+
+ lockfile_should_be <<-G
+ GIT
+ remote: #{lib_path("foo-1.0")}
+ revision: #{git.ref_for("omg")}
+ tag: omg
+ specs:
+ foo (1.0)
+
+ GEM
+ specs:
+
+ PLATFORMS
+ #{generic_local_platform}
+
+ DEPENDENCIES
+ foo!
+
+ BUNDLED WITH
+ #{Bundler::VERSION}
+ G
+ end
+
+ it "serializes pinned path sources to the lockfile" do
+ build_lib "foo"
+
+ install_gemfile <<-G
+ gem "foo", :path => "#{lib_path("foo-1.0")}"
+ G
+
+ lockfile_should_be <<-G
+ PATH
+ remote: #{lib_path("foo-1.0")}
+ specs:
+ foo (1.0)
+
+ GEM
+ specs:
+
+ PLATFORMS
+ #{generic_local_platform}
+
+ DEPENDENCIES
+ foo!
+
+ BUNDLED WITH
+ #{Bundler::VERSION}
+ G
+ end
+
+ it "serializes pinned path sources to the lockfile even when packaging" do
+ build_lib "foo"
+
+ install_gemfile! <<-G
+ gem "foo", :path => "#{lib_path("foo-1.0")}"
+ G
+
+ bundle! :package, forgotten_command_line_options([:all, :cache_all] => true)
+ bundle! :install, :local => true
+
+ lockfile_should_be <<-G
+ PATH
+ remote: #{lib_path("foo-1.0")}
+ specs:
+ foo (1.0)
+
+ GEM
+ specs:
+
+ PLATFORMS
+ #{generic_local_platform}
+
+ DEPENDENCIES
+ foo!
+
+ BUNDLED WITH
+ #{Bundler::VERSION}
+ G
+ end
+
+ it "sorts serialized sources by type" do
+ build_lib "foo"
+ bar = build_git "bar"
+
+ install_gemfile <<-G
+ source "file://#{gem_repo1}"
+
+ gem "rack"
+ gem "foo", :path => "#{lib_path("foo-1.0")}"
+ gem "bar", :git => "#{lib_path("bar-1.0")}"
+ G
+
+ lockfile_should_be <<-G
+ GIT
+ remote: #{lib_path("bar-1.0")}
+ revision: #{bar.ref_for("master")}
+ specs:
+ bar (1.0)
+
+ PATH
+ remote: #{lib_path("foo-1.0")}
+ specs:
+ foo (1.0)
+
+ GEM
+ remote: file:#{gem_repo1}/
+ specs:
+ rack (1.0.0)
+
+ PLATFORMS
+ #{generic_local_platform}
+
+ DEPENDENCIES
+ bar!
+ foo!
+ rack
+
+ BUNDLED WITH
+ #{Bundler::VERSION}
+ G
+ end
+
+ it "lists gems alphabetically" do
+ install_gemfile <<-G
+ source "file://#{gem_repo1}"
+
+ gem "thin"
+ gem "actionpack"
+ gem "rack-obama"
+ G
+
+ lockfile_should_be <<-G
+ GEM
+ remote: file:#{gem_repo1}/
+ specs:
+ actionpack (2.3.2)
+ activesupport (= 2.3.2)
+ activesupport (2.3.2)
+ rack (1.0.0)
+ rack-obama (1.0)
+ rack
+ thin (1.0)
+ rack
+
+ PLATFORMS
+ #{generic_local_platform}
+
+ DEPENDENCIES
+ actionpack
+ rack-obama
+ thin
+
+ BUNDLED WITH
+ #{Bundler::VERSION}
+ G
+ end
+
+ it "orders dependencies' dependencies in alphabetical order" do
+ install_gemfile <<-G
+ source "file://#{gem_repo1}"
+
+ gem "rails"
+ G
+
+ lockfile_should_be <<-G
+ GEM
+ remote: file:#{gem_repo1}/
+ specs:
+ actionmailer (2.3.2)
+ activesupport (= 2.3.2)
+ actionpack (2.3.2)
+ activesupport (= 2.3.2)
+ activerecord (2.3.2)
+ activesupport (= 2.3.2)
+ activeresource (2.3.2)
+ activesupport (= 2.3.2)
+ activesupport (2.3.2)
+ rails (2.3.2)
+ actionmailer (= 2.3.2)
+ actionpack (= 2.3.2)
+ activerecord (= 2.3.2)
+ activeresource (= 2.3.2)
+ rake (= 10.0.2)
+ rake (10.0.2)
+
+ PLATFORMS
+ #{generic_local_platform}
+
+ DEPENDENCIES
+ rails
+
+ BUNDLED WITH
+ #{Bundler::VERSION}
+ G
+ end
+
+ it "orders dependencies by version" do
+ install_gemfile <<-G
+ source "file://#{gem_repo1}"
+ gem 'double_deps'
+ G
+
+ lockfile_should_be <<-G
+ GEM
+ remote: file:#{gem_repo1}/
+ specs:
+ double_deps (1.0)
+ net-ssh
+ net-ssh (>= 1.0.0)
+ net-ssh (1.0)
+
+ PLATFORMS
+ #{generic_local_platform}
+
+ DEPENDENCIES
+ double_deps
+
+ BUNDLED WITH
+ #{Bundler::VERSION}
+ G
+ end
+
+ it "does not add the :require option to the lockfile" do
+ install_gemfile <<-G
+ source "file://#{gem_repo1}"
+
+ gem "rack-obama", ">= 1.0", :require => "rack/obama"
+ G
+
+ lockfile_should_be <<-G
+ GEM
+ remote: file:#{gem_repo1}/
+ specs:
+ rack (1.0.0)
+ rack-obama (1.0)
+ rack
+
+ PLATFORMS
+ #{generic_local_platform}
+
+ DEPENDENCIES
+ rack-obama (>= 1.0)
+
+ BUNDLED WITH
+ #{Bundler::VERSION}
+ G
+ end
+
+ it "does not add the :group option to the lockfile" do
+ install_gemfile <<-G
+ source "file://#{gem_repo1}"
+
+ gem "rack-obama", ">= 1.0", :group => :test
+ G
+
+ lockfile_should_be <<-G
+ GEM
+ remote: file:#{gem_repo1}/
+ specs:
+ rack (1.0.0)
+ rack-obama (1.0)
+ rack
+
+ PLATFORMS
+ #{generic_local_platform}
+
+ DEPENDENCIES
+ rack-obama (>= 1.0)
+
+ BUNDLED WITH
+ #{Bundler::VERSION}
+ G
+ end
+
+ it "stores relative paths when the path is provided in a relative fashion and in Gemfile dir" do
+ build_lib "foo", :path => bundled_app("foo")
+
+ install_gemfile <<-G
+ path "foo"
+ gem "foo"
+ G
+
+ lockfile_should_be <<-G
+ PATH
+ remote: foo
+ specs:
+ foo (1.0)
+
+ GEM
+ specs:
+
+ PLATFORMS
+ #{generic_local_platform}
+
+ DEPENDENCIES
+ foo
+
+ BUNDLED WITH
+ #{Bundler::VERSION}
+ G
+ end
+
+ it "stores relative paths when the path is provided in a relative fashion and is above Gemfile dir" do
+ build_lib "foo", :path => bundled_app(File.join("..", "foo"))
+
+ install_gemfile <<-G
+ path "../foo"
+ gem "foo"
+ G
+
+ lockfile_should_be <<-G
+ PATH
+ remote: ../foo
+ specs:
+ foo (1.0)
+
+ GEM
+ specs:
+
+ PLATFORMS
+ #{generic_local_platform}
+
+ DEPENDENCIES
+ foo
+
+ BUNDLED WITH
+ #{Bundler::VERSION}
+ G
+ end
+
+ it "stores relative paths when the path is provided in an absolute fashion but is relative" do
+ build_lib "foo", :path => bundled_app("foo")
+
+ install_gemfile <<-G
+ path File.expand_path("../foo", __FILE__)
+ gem "foo"
+ G
+
+ lockfile_should_be <<-G
+ PATH
+ remote: foo
+ specs:
+ foo (1.0)
+
+ GEM
+ specs:
+
+ PLATFORMS
+ #{generic_local_platform}
+
+ DEPENDENCIES
+ foo
+
+ BUNDLED WITH
+ #{Bundler::VERSION}
+ G
+ end
+
+ it "stores relative paths when the path is provided for gemspec" do
+ build_lib("foo", :path => tmp.join("foo"))
+
+ install_gemfile <<-G
+ gemspec :path => "../foo"
+ G
+
+ lockfile_should_be <<-G
+ PATH
+ remote: ../foo
+ specs:
+ foo (1.0)
+
+ GEM
+ specs:
+
+ PLATFORMS
+ #{generic_local_platform}
+
+ DEPENDENCIES
+ foo!
+
+ BUNDLED WITH
+ #{Bundler::VERSION}
+ G
+ end
+
+ it "keeps existing platforms in the lockfile" do
+ lockfile <<-G
+ GEM
+ remote: file:#{gem_repo1}/
+ specs:
+ rack (1.0.0)
+
+ PLATFORMS
+ java
+
+ DEPENDENCIES
+ rack
+
+ BUNDLED WITH
+ #{Bundler::VERSION}
+ G
+
+ install_gemfile <<-G
+ source "file://#{gem_repo1}"
+
+ gem "rack"
+ G
+
+ platforms = ["java", generic_local_platform.to_s].sort
+
+ lockfile_should_be <<-G
+ GEM
+ remote: file:#{gem_repo1}/
+ specs:
+ rack (1.0.0)
+
+ PLATFORMS
+ #{platforms[0]}
+ #{platforms[1]}
+
+ DEPENDENCIES
+ rack
+
+ BUNDLED WITH
+ #{Bundler::VERSION}
+ G
+ end
+
+ it "persists the spec's platform to the lockfile" do
+ build_gem "platform_specific", "1.0.0", :to_system => true do |s|
+ s.platform = Gem::Platform.new("universal-java-16")
+ end
+
+ simulate_platform "universal-java-16"
+
+ install_gemfile <<-G
+ source "file://#{gem_repo1}"
+ gem "platform_specific"
+ G
+
+ lockfile_should_be <<-G
+ GEM
+ remote: file:#{gem_repo1}/
+ specs:
+ platform_specific (1.0-java)
+
+ PLATFORMS
+ java
+
+ DEPENDENCIES
+ platform_specific
+
+ BUNDLED WITH
+ #{Bundler::VERSION}
+ G
+ end
+
+ it "does not add duplicate gems" do
+ install_gemfile <<-G
+ source "file://#{gem_repo1}"
+ gem "rack"
+ G
+
+ install_gemfile <<-G
+ source "file://#{gem_repo1}"
+ gem "rack"
+ gem "activesupport"
+ G
+
+ lockfile_should_be <<-G
+ GEM
+ remote: file:#{gem_repo1}/
+ specs:
+ activesupport (2.3.5)
+ rack (1.0.0)
+
+ PLATFORMS
+ ruby
+
+ DEPENDENCIES
+ activesupport
+ rack
+
+ BUNDLED WITH
+ #{Bundler::VERSION}
+ G
+ end
+
+ it "does not add duplicate dependencies" do
+ install_gemfile <<-G
+ source "file://#{gem_repo1}"
+ gem "rack"
+ gem "rack"
+ G
+
+ lockfile_should_be <<-G
+ GEM
+ remote: file:#{gem_repo1}/
+ specs:
+ rack (1.0.0)
+
+ PLATFORMS
+ ruby
+
+ DEPENDENCIES
+ rack
+
+ BUNDLED WITH
+ #{Bundler::VERSION}
+ G
+ end
+
+ it "does not add duplicate dependencies with versions" do
+ install_gemfile <<-G
+ source "file://#{gem_repo1}"
+ gem "rack", "1.0"
+ gem "rack", "1.0"
+ G
+
+ lockfile_should_be <<-G
+ GEM
+ remote: file:#{gem_repo1}/
+ specs:
+ rack (1.0.0)
+
+ PLATFORMS
+ ruby
+
+ DEPENDENCIES
+ rack (= 1.0)
+
+ BUNDLED WITH
+ #{Bundler::VERSION}
+ G
+ end
+
+ it "does not add duplicate dependencies in different groups" do
+ install_gemfile <<-G
+ source "file://#{gem_repo1}"
+ gem "rack", "1.0", :group => :one
+ gem "rack", "1.0", :group => :two
+ G
+
+ lockfile_should_be <<-G
+ GEM
+ remote: file:#{gem_repo1}/
+ specs:
+ rack (1.0.0)
+
+ PLATFORMS
+ ruby
+
+ DEPENDENCIES
+ rack (= 1.0)
+
+ BUNDLED WITH
+ #{Bundler::VERSION}
+ G
+ end
+
+ it "raises if two different versions are used" do
+ install_gemfile <<-G
+ source "file://#{gem_repo1}"
+ gem "rack", "1.0"
+ gem "rack", "1.1"
+ G
+
+ expect(bundled_app("Gemfile.lock")).not_to exist
+ expect(out).to include "rack (= 1.0) and rack (= 1.1)"
+ end
+
+ it "raises if two different sources are used" do
+ install_gemfile <<-G
+ source "file://#{gem_repo1}"
+ gem "rack"
+ gem "rack", :git => "git://hubz.com"
+ G
+
+ expect(bundled_app("Gemfile.lock")).not_to exist
+ expect(out).to include "rack (>= 0) should come from an unspecified source and git://hubz.com (at master)"
+ end
+
+ it "works correctly with multiple version dependencies" do
+ install_gemfile <<-G
+ source "file://#{gem_repo1}"
+ gem "rack", "> 0.9", "< 1.0"
+ G
+
+ lockfile_should_be <<-G
+ GEM
+ remote: file:#{gem_repo1}/
+ specs:
+ rack (0.9.1)
+
+ PLATFORMS
+ ruby
+
+ DEPENDENCIES
+ rack (> 0.9, < 1.0)
+
+ BUNDLED WITH
+ #{Bundler::VERSION}
+ G
+ end
+
+ it "captures the Ruby version in the lockfile" do
+ install_gemfile <<-G
+ source "file://#{gem_repo1}"
+ ruby '#{RUBY_VERSION}'
+ gem "rack", "> 0.9", "< 1.0"
+ G
+
+ lockfile_should_be <<-G
+ GEM
+ remote: file:#{gem_repo1}/
+ specs:
+ rack (0.9.1)
+
+ PLATFORMS
+ ruby
+
+ DEPENDENCIES
+ rack (> 0.9, < 1.0)
+
+ RUBY VERSION
+ ruby #{RUBY_VERSION}p#{RUBY_PATCHLEVEL}
+
+ BUNDLED WITH
+ #{Bundler::VERSION}
+ G
+ end
+
+ # Some versions of the Bundler 1.1 RC series introduced corrupted
+ # lockfiles. There were two major problems:
+ #
+ # * multiple copies of the same GIT section appeared in the lockfile
+ # * when this happened, those sections got multiple copies of gems
+ # in those sections.
+ it "fixes corrupted lockfiles" do
+ build_git "omg", :path => lib_path("omg")
+ revision = revision_for(lib_path("omg"))
+
+ gemfile <<-G
+ source "file://#{gem_repo1}"
+ gem "omg", :git => "#{lib_path("omg")}", :branch => 'master'
+ G
+
+ bundle "install --path vendor"
+ expect(the_bundle).to include_gems "omg 1.0"
+
+ # Create a Gemfile.lock that has duplicate GIT sections
+ lockfile <<-L
+ GIT
+ remote: #{lib_path("omg")}
+ revision: #{revision}
+ branch: master
+ specs:
+ omg (1.0)
+
+ GIT
+ remote: #{lib_path("omg")}
+ revision: #{revision}
+ branch: master
+ specs:
+ omg (1.0)
+
+ GEM
+ remote: file:#{gem_repo1}/
+ specs:
+
+ PLATFORMS
+ #{local}
+
+ DEPENDENCIES
+ omg!
+
+ BUNDLED WITH
+ #{Bundler::VERSION}
+ L
+
+ FileUtils.rm_rf(bundled_app("vendor"))
+ bundle "install"
+ expect(the_bundle).to include_gems "omg 1.0"
+
+ # Confirm that duplicate specs do not appear
+ expect(File.read(bundled_app("Gemfile.lock"))).to eq(strip_whitespace(<<-L))
+ GIT
+ remote: #{lib_path("omg")}
+ revision: #{revision}
+ branch: master
+ specs:
+ omg (1.0)
+
+ GEM
+ remote: file:#{gem_repo1}/
+ specs:
+
+ PLATFORMS
+ #{local}
+
+ DEPENDENCIES
+ omg!
+
+ BUNDLED WITH
+ #{Bundler::VERSION}
+ L
+ end
+
+ it "raises a helpful error message when the lockfile is missing deps" do
+ lockfile <<-L
+ GEM
+ remote: file:#{gem_repo1}/
+ specs:
+ rack_middleware (1.0)
+
+ PLATFORMS
+ #{local}
+
+ DEPENDENCIES
+ rack_middleware
+ L
+
+ install_gemfile <<-G
+ source "file:#{gem_repo1}"
+ gem "rack_middleware"
+ G
+
+ expect(out).to include("Downloading rack_middleware-1.0 revealed dependencies not in the API or the lockfile (#{Gem::Dependency.new("rack", "= 0.9.1")}).").
+ and include("Either installing with `--full-index` or running `bundle update rack_middleware` should fix the problem.")
+ end
+
+ describe "a line ending" do
+ def set_lockfile_mtime_to_known_value
+ time = Time.local(2000, 1, 1, 0, 0, 0)
+ File.utime(time, time, bundled_app("Gemfile.lock"))
+ end
+ before(:each) do
+ build_repo2
+
+ install_gemfile <<-G
+ source "file://#{gem_repo2}"
+ gem "rack"
+ G
+ set_lockfile_mtime_to_known_value
+ end
+
+ it "generates Gemfile.lock with \\n line endings" do
+ expect(File.read(bundled_app("Gemfile.lock"))).not_to match("\r\n")
+ expect(the_bundle).to include_gems "rack 1.0"
+ end
+
+ context "during updates" do
+ it "preserves Gemfile.lock \\n line endings" do
+ update_repo2
+
+ expect { bundle "update", :all => true }.to change { File.mtime(bundled_app("Gemfile.lock")) }
+ expect(File.read(bundled_app("Gemfile.lock"))).not_to match("\r\n")
+ expect(the_bundle).to include_gems "rack 1.2"
+ end
+
+ it "preserves Gemfile.lock \\n\\r line endings" do
+ update_repo2
+ win_lock = File.read(bundled_app("Gemfile.lock")).gsub(/\n/, "\r\n")
+ File.open(bundled_app("Gemfile.lock"), "wb") {|f| f.puts(win_lock) }
+ set_lockfile_mtime_to_known_value
+
+ expect { bundle "update", :all => true }.to change { File.mtime(bundled_app("Gemfile.lock")) }
+ expect(File.read(bundled_app("Gemfile.lock"))).to match("\r\n")
+ expect(the_bundle).to include_gems "rack 1.2"
+ end
+ end
+
+ context "when nothing changes" do
+ it "preserves Gemfile.lock \\n line endings" do
+ expect do
+ ruby <<-RUBY
+ require 'rubygems'
+ require 'bundler'
+ Bundler.setup
+ RUBY
+ end.not_to change { File.mtime(bundled_app("Gemfile.lock")) }
+ end
+
+ it "preserves Gemfile.lock \\n\\r line endings" do
+ win_lock = File.read(bundled_app("Gemfile.lock")).gsub(/\n/, "\r\n")
+ File.open(bundled_app("Gemfile.lock"), "wb") {|f| f.puts(win_lock) }
+ set_lockfile_mtime_to_known_value
+
+ expect do
+ ruby <<-RUBY
+ require 'rubygems'
+ require 'bundler'
+ Bundler.setup
+ RUBY
+ end.not_to change { File.mtime(bundled_app("Gemfile.lock")) }
+ end
+ end
+ end
+
+ it "refuses to install if Gemfile.lock contains conflict markers" do
+ lockfile <<-L
+ GEM
+ remote: file://#{gem_repo1}/
+ specs:
+ <<<<<<<
+ rack (1.0.0)
+ =======
+ rack (1.0.1)
+ >>>>>>>
+
+ PLATFORMS
+ ruby
+
+ DEPENDENCIES
+ rack
+
+ BUNDLED WITH
+ #{Bundler::VERSION}
+ L
+
+ install_gemfile(<<-G)
+ source "file://#{gem_repo1}"
+ gem "rack"
+ G
+
+ expect(last_command.bundler_err).to match(/your Gemfile.lock contains merge conflicts/i)
+ expect(last_command.bundler_err).to match(/git checkout HEAD -- Gemfile.lock/i)
+ end
+end
diff --git a/spec/bundler/lock/lockfile_spec.rb b/spec/bundler/lock/lockfile_spec.rb
index 968c969a55..b4bf81ded2 100644
--- a/spec/bundler/lock/lockfile_spec.rb
+++ b/spec/bundler/lock/lockfile_spec.rb
@@ -1,9 +1,10 @@
# frozen_string_literal: true
-require "spec_helper"
-RSpec.describe "the lockfile format" do
+RSpec.describe "the lockfile format", :bundler => "2" do
include Bundler::GemHelpers
+ before { ENV["BUNDLER_SPEC_IGNORE_COMPATIBILITY_GUARD"] = "TRUE" }
+
it "generates a simple lockfile for a single source, gem" do
install_gemfile <<-G
source "file://#{gem_repo1}"
@@ -18,7 +19,7 @@ RSpec.describe "the lockfile format" do
rack (1.0.0)
PLATFORMS
- #{generic_local_platform}
+ #{lockfile_platforms}
DEPENDENCIES
rack
@@ -41,7 +42,7 @@ RSpec.describe "the lockfile format" do
rack (1.0.0)
PLATFORMS
- #{generic_local_platform}
+ #{lockfile_platforms}
DEPENDENCIES
omg!
@@ -64,7 +65,7 @@ RSpec.describe "the lockfile format" do
rack (1.0.0)
PLATFORMS
- #{generic_local_platform}
+ #{lockfile_platforms}
DEPENDENCIES
rack
@@ -75,6 +76,8 @@ RSpec.describe "the lockfile format" do
end
it "does not update the lockfile's bundler version if nothing changed during bundle install" do
+ version = "#{Bundler::VERSION.split(".").first}.0.0.0.a"
+
lockfile <<-L
GEM
remote: file:#{gem_repo1}/
@@ -82,13 +85,13 @@ RSpec.describe "the lockfile format" do
rack (1.0.0)
PLATFORMS
- #{generic_local_platform}
+ #{lockfile_platforms}
DEPENDENCIES
rack
BUNDLED WITH
- 1.10.0
+ #{version}
L
install_gemfile <<-G
@@ -104,13 +107,13 @@ RSpec.describe "the lockfile format" do
rack (1.0.0)
PLATFORMS
- #{generic_local_platform}
+ #{lockfile_platforms}
DEPENDENCIES
rack
BUNDLED WITH
- 1.10.0
+ #{version}
G
end
@@ -122,7 +125,7 @@ RSpec.describe "the lockfile format" do
rack (1.0.0)
PLATFORMS
- #{generic_local_platform}
+ #{lockfile_platforms}
DEPENDENCIES
rack
@@ -141,7 +144,7 @@ RSpec.describe "the lockfile format" do
rack (1.0.0)
PLATFORMS
- #{generic_local_platform}
+ #{lockfile_platforms}
DEPENDENCIES
rack (> 0)
@@ -178,7 +181,7 @@ RSpec.describe "the lockfile format" do
warning_message = "the running version of Bundler (9999999.0.0) is older " \
"than the version that created the lockfile (9999999.1.0)"
- expect(out.scan(warning_message).size).to eq(1)
+ expect(last_command.bundler_err).to include warning_message
lockfile_should_be <<-G
GEM
@@ -187,7 +190,7 @@ RSpec.describe "the lockfile format" do
rack (1.0.0)
PLATFORMS
- #{generic_local_platform}
+ #{lockfile_platforms}
DEPENDENCIES
rack
@@ -205,7 +208,7 @@ RSpec.describe "the lockfile format" do
rack (1.0.0)
PLATFORMS
- #{generic_local_platform}
+ #{lockfile_platforms}
DEPENDENCIES
rack
@@ -220,8 +223,8 @@ RSpec.describe "the lockfile format" do
gem "rack"
G
- expect(exitstatus > 0) if exitstatus
- expect(out).to include("You must use Bundler 9999999 or greater with this lockfile.")
+ expect(last_command).to be_failure
+ expect(last_command.bundler_err).to include("You must use Bundler 9999999 or greater with this lockfile.")
end
it "shows a friendly error when running with a new bundler 2 lockfile" do
@@ -258,7 +261,7 @@ RSpec.describe "the lockfile format" do
end
G
- expect(exitstatus > 0) if exitstatus
+ expect(last_command).to be_failure
expect(out).to include("You must use Bundler 9999999 or greater with this lockfile.")
end
@@ -297,7 +300,7 @@ RSpec.describe "the lockfile format" do
rack (1.0.0)
PLATFORMS
- #{generic_local_platform}
+ #{lockfile_platforms}
DEPENDENCIES
rack
@@ -323,7 +326,7 @@ RSpec.describe "the lockfile format" do
rack
PLATFORMS
- #{generic_local_platform}
+ #{lockfile_platforms}
DEPENDENCIES
rack-obama
@@ -349,7 +352,7 @@ RSpec.describe "the lockfile format" do
rack
PLATFORMS
- #{generic_local_platform}
+ #{lockfile_platforms}
DEPENDENCIES
rack-obama (>= 1.0)
@@ -359,19 +362,28 @@ RSpec.describe "the lockfile format" do
G
end
- it "generates a lockfile wihout credentials for a configured source" do
+ it "generates a lockfile without credentials for a configured source" do
bundle "config http://localgemserver.test/ user:pass"
install_gemfile(<<-G, :artifice => "endpoint_strict_basic_authentication", :quiet => true)
- source "http://localgemserver.test/"
- source "http://user:pass@othergemserver.test/"
+ source "http://localgemserver.test/" do
- gem "rack-obama", ">= 1.0"
+ end
+
+ source "http://user:pass@othergemserver.test/" do
+ gem "rack-obama", ">= 1.0"
+ end
G
lockfile_should_be <<-G
GEM
+ specs:
+
+ GEM
remote: http://localgemserver.test/
+ specs:
+
+ GEM
remote: http://user:pass@othergemserver.test/
specs:
rack (1.0.0)
@@ -379,10 +391,10 @@ RSpec.describe "the lockfile format" do
rack
PLATFORMS
- #{generic_local_platform}
+ #{lockfile_platforms}
DEPENDENCIES
- rack-obama (>= 1.0)
+ rack-obama (>= 1.0)!
BUNDLED WITH
#{Bundler::VERSION}
@@ -404,7 +416,7 @@ RSpec.describe "the lockfile format" do
net-ssh (1.0)
PLATFORMS
- ruby
+ #{lockfile_platforms}
DEPENDENCIES
net-sftp
@@ -416,7 +428,7 @@ RSpec.describe "the lockfile format" do
expect(the_bundle).to include_gems "net-sftp 1.1.1", "net-ssh 1.0.0"
end
- it "generates a simple lockfile for a single pinned source, gem with a version requirement" do
+ it "generates a simple lockfile for a single pinned source, gem with a version requirement", :bundler => "< 2" do
git = build_git "foo"
install_gemfile <<-G
@@ -434,7 +446,35 @@ RSpec.describe "the lockfile format" do
specs:
PLATFORMS
- #{generic_local_platform}
+ #{lockfile_platforms}
+
+ DEPENDENCIES
+ foo!
+
+ BUNDLED WITH
+ #{Bundler::VERSION}
+ G
+ end
+
+ it "generates a simple lockfile for a single pinned source, gem with a version requirement" do
+ git = build_git "foo"
+
+ install_gemfile <<-G
+ gem "foo", :git => "#{lib_path("foo-1.0")}"
+ G
+
+ lockfile_should_be <<-G
+ GEM
+ specs:
+
+ GIT
+ remote: #{lib_path("foo-1.0")}
+ revision: #{git.ref_for("master")}
+ specs:
+ foo (1.0)
+
+ PLATFORMS
+ #{lockfile_platforms}
DEPENDENCIES
foo!
@@ -479,7 +519,7 @@ RSpec.describe "the lockfile format" do
#{Bundler::VERSION}
L
- bundle "install"
+ bundle! "install"
expect(the_bundle).to include_gems "rack 1.0.0"
end
@@ -493,17 +533,17 @@ RSpec.describe "the lockfile format" do
G
lockfile_should_be <<-G
+ GEM
+ specs:
+
GIT
remote: #{lib_path("foo-1.0")}
revision: #{git.ref_for("master")}
specs:
foo (1.0)
- GEM
- specs:
-
PLATFORMS
- #{generic_local_platform}
+ #{lockfile_platforms}
DEPENDENCIES
foo!
@@ -522,6 +562,9 @@ RSpec.describe "the lockfile format" do
G
lockfile_should_be <<-G
+ GEM
+ specs:
+
GIT
remote: #{lib_path("foo-1.0")}
revision: #{git.ref_for("omg")}
@@ -529,11 +572,8 @@ RSpec.describe "the lockfile format" do
specs:
foo (1.0)
- GEM
- specs:
-
PLATFORMS
- #{generic_local_platform}
+ #{lockfile_platforms}
DEPENDENCIES
foo!
@@ -552,6 +592,9 @@ RSpec.describe "the lockfile format" do
G
lockfile_should_be <<-G
+ GEM
+ specs:
+
GIT
remote: #{lib_path("foo-1.0")}
revision: #{git.ref_for("omg")}
@@ -559,11 +602,8 @@ RSpec.describe "the lockfile format" do
specs:
foo (1.0)
- GEM
- specs:
-
PLATFORMS
- #{generic_local_platform}
+ #{lockfile_platforms}
DEPENDENCIES
foo!
@@ -581,16 +621,16 @@ RSpec.describe "the lockfile format" do
G
lockfile_should_be <<-G
+ GEM
+ specs:
+
PATH
remote: #{lib_path("foo-1.0")}
specs:
foo (1.0)
- GEM
- specs:
-
PLATFORMS
- #{generic_local_platform}
+ #{lockfile_platforms}
DEPENDENCIES
foo!
@@ -607,20 +647,20 @@ RSpec.describe "the lockfile format" do
gem "foo", :path => "#{lib_path("foo-1.0")}"
G
- bundle! "package --all"
- bundle! "install --local"
+ bundle! :package, forgotten_command_line_options([:all, :cache_all] => true)
+ bundle! :install, :local => true
lockfile_should_be <<-G
+ GEM
+ specs:
+
PATH
remote: #{lib_path("foo-1.0")}
specs:
foo (1.0)
- GEM
- specs:
-
PLATFORMS
- #{generic_local_platform}
+ #{lockfile_platforms}
DEPENDENCIES
foo!
@@ -643,6 +683,11 @@ RSpec.describe "the lockfile format" do
G
lockfile_should_be <<-G
+ GEM
+ remote: file:#{gem_repo1}/
+ specs:
+ rack (1.0.0)
+
GIT
remote: #{lib_path("bar-1.0")}
revision: #{bar.ref_for("master")}
@@ -654,13 +699,8 @@ RSpec.describe "the lockfile format" do
specs:
foo (1.0)
- GEM
- remote: file:#{gem_repo1}/
- specs:
- rack (1.0.0)
-
PLATFORMS
- #{generic_local_platform}
+ #{lockfile_platforms}
DEPENDENCIES
bar!
@@ -695,7 +735,7 @@ RSpec.describe "the lockfile format" do
rack
PLATFORMS
- #{generic_local_platform}
+ #{lockfile_platforms}
DEPENDENCIES
actionpack
@@ -736,7 +776,7 @@ RSpec.describe "the lockfile format" do
rake (10.0.2)
PLATFORMS
- #{generic_local_platform}
+ #{lockfile_platforms}
DEPENDENCIES
rails
@@ -762,7 +802,7 @@ RSpec.describe "the lockfile format" do
net-ssh (1.0)
PLATFORMS
- #{generic_local_platform}
+ #{lockfile_platforms}
DEPENDENCIES
double_deps
@@ -788,7 +828,7 @@ RSpec.describe "the lockfile format" do
rack
PLATFORMS
- #{generic_local_platform}
+ #{lockfile_platforms}
DEPENDENCIES
rack-obama (>= 1.0)
@@ -814,7 +854,7 @@ RSpec.describe "the lockfile format" do
rack
PLATFORMS
- #{generic_local_platform}
+ #{lockfile_platforms}
DEPENDENCIES
rack-obama (>= 1.0)
@@ -828,24 +868,25 @@ RSpec.describe "the lockfile format" do
build_lib "foo", :path => bundled_app("foo")
install_gemfile <<-G
- path "foo"
- gem "foo"
+ path "foo" do
+ gem "foo"
+ end
G
lockfile_should_be <<-G
+ GEM
+ specs:
+
PATH
remote: foo
specs:
foo (1.0)
- GEM
- specs:
-
PLATFORMS
- #{generic_local_platform}
+ #{lockfile_platforms}
DEPENDENCIES
- foo
+ foo!
BUNDLED WITH
#{Bundler::VERSION}
@@ -856,24 +897,25 @@ RSpec.describe "the lockfile format" do
build_lib "foo", :path => bundled_app(File.join("..", "foo"))
install_gemfile <<-G
- path "../foo"
- gem "foo"
+ path "../foo" do
+ gem "foo"
+ end
G
lockfile_should_be <<-G
+ GEM
+ specs:
+
PATH
remote: ../foo
specs:
foo (1.0)
- GEM
- specs:
-
PLATFORMS
- #{generic_local_platform}
+ #{lockfile_platforms}
DEPENDENCIES
- foo
+ foo!
BUNDLED WITH
#{Bundler::VERSION}
@@ -884,24 +926,25 @@ RSpec.describe "the lockfile format" do
build_lib "foo", :path => bundled_app("foo")
install_gemfile <<-G
- path File.expand_path("../foo", __FILE__)
- gem "foo"
+ path File.expand_path("../foo", __FILE__) do
+ gem "foo"
+ end
G
lockfile_should_be <<-G
+ GEM
+ specs:
+
PATH
remote: foo
specs:
foo (1.0)
- GEM
- specs:
-
PLATFORMS
- #{generic_local_platform}
+ #{lockfile_platforms}
DEPENDENCIES
- foo
+ foo!
BUNDLED WITH
#{Bundler::VERSION}
@@ -916,16 +959,16 @@ RSpec.describe "the lockfile format" do
G
lockfile_should_be <<-G
+ GEM
+ specs:
+
PATH
remote: ../foo
specs:
foo (1.0)
- GEM
- specs:
-
PLATFORMS
- #{generic_local_platform}
+ #{lockfile_platforms}
DEPENDENCIES
foo!
@@ -958,8 +1001,6 @@ RSpec.describe "the lockfile format" do
gem "rack"
G
- platforms = ["java", generic_local_platform.to_s].sort
-
lockfile_should_be <<-G
GEM
remote: file:#{gem_repo1}/
@@ -967,8 +1008,7 @@ RSpec.describe "the lockfile format" do
rack (1.0.0)
PLATFORMS
- #{platforms[0]}
- #{platforms[1]}
+ #{lockfile_platforms "java", generic_local_platform, specific_local_platform}
DEPENDENCIES
rack
@@ -979,25 +1019,29 @@ RSpec.describe "the lockfile format" do
end
it "persists the spec's platform to the lockfile" do
- build_gem "platform_specific", "1.0.0", :to_system => true do |s|
- s.platform = Gem::Platform.new("universal-java-16")
+ build_repo2 do
+ build_gem "platform_specific", "1.0" do |s|
+ s.platform = Gem::Platform.new("universal-java-16")
+ end
end
simulate_platform "universal-java-16"
- install_gemfile <<-G
- source "file://#{gem_repo1}"
+ install_gemfile! <<-G
+ source "file://#{gem_repo2}"
gem "platform_specific"
G
lockfile_should_be <<-G
GEM
- remote: file:#{gem_repo1}/
+ remote: file:#{gem_repo2}/
specs:
platform_specific (1.0-java)
+ platform_specific (1.0-universal-java-16)
PLATFORMS
java
+ universal-java-16
DEPENDENCIES
platform_specific
@@ -1027,7 +1071,7 @@ RSpec.describe "the lockfile format" do
rack (1.0.0)
PLATFORMS
- ruby
+ #{lockfile_platforms}
DEPENDENCIES
activesupport
@@ -1052,7 +1096,7 @@ RSpec.describe "the lockfile format" do
rack (1.0.0)
PLATFORMS
- ruby
+ #{lockfile_platforms}
DEPENDENCIES
rack
@@ -1076,7 +1120,7 @@ RSpec.describe "the lockfile format" do
rack (1.0.0)
PLATFORMS
- ruby
+ #{lockfile_platforms}
DEPENDENCIES
rack (= 1.0)
@@ -1100,7 +1144,7 @@ RSpec.describe "the lockfile format" do
rack (1.0.0)
PLATFORMS
- ruby
+ #{lockfile_platforms}
DEPENDENCIES
rack (= 1.0)
@@ -1145,7 +1189,7 @@ RSpec.describe "the lockfile format" do
rack (0.9.1)
PLATFORMS
- ruby
+ #{lockfile_platforms}
DEPENDENCIES
rack (> 0.9, < 1.0)
@@ -1169,7 +1213,7 @@ RSpec.describe "the lockfile format" do
rack (0.9.1)
PLATFORMS
- ruby
+ #{lockfile_platforms}
DEPENDENCIES
rack (> 0.9, < 1.0)
@@ -1197,11 +1241,15 @@ RSpec.describe "the lockfile format" do
gem "omg", :git => "#{lib_path("omg")}", :branch => 'master'
G
- bundle "install --path vendor"
+ bundle! :install, forgotten_command_line_options(:path => "vendor")
expect(the_bundle).to include_gems "omg 1.0"
# Create a Gemfile.lock that has duplicate GIT sections
lockfile <<-L
+ GEM
+ remote: file:#{gem_repo1}/
+ specs:
+
GIT
remote: #{lib_path("omg")}
revision: #{revision}
@@ -1216,12 +1264,8 @@ RSpec.describe "the lockfile format" do
specs:
omg (1.0)
- GEM
- remote: file:#{gem_repo1}/
- specs:
-
PLATFORMS
- #{local}
+ #{lockfile_platforms}
DEPENDENCIES
omg!
@@ -1236,6 +1280,10 @@ RSpec.describe "the lockfile format" do
# Confirm that duplicate specs do not appear
expect(File.read(bundled_app("Gemfile.lock"))).to eq(strip_whitespace(<<-L))
+ GEM
+ remote: file:#{gem_repo1}/
+ specs:
+
GIT
remote: #{lib_path("omg")}
revision: #{revision}
@@ -1243,12 +1291,8 @@ RSpec.describe "the lockfile format" do
specs:
omg (1.0)
- GEM
- remote: file:#{gem_repo1}/
- specs:
-
PLATFORMS
- #{local}
+ #{lockfile_platforms}
DEPENDENCIES
omg!
@@ -1266,7 +1310,7 @@ RSpec.describe "the lockfile format" do
rack_middleware (1.0)
PLATFORMS
- #{local}
+ #{lockfile_platforms}
DEPENDENCIES
rack_middleware
@@ -1305,7 +1349,7 @@ RSpec.describe "the lockfile format" do
it "preserves Gemfile.lock \\n line endings" do
update_repo2
- expect { bundle "update" }.to change { File.mtime(bundled_app("Gemfile.lock")) }
+ expect { bundle "update", :all => true }.to change { File.mtime(bundled_app("Gemfile.lock")) }
expect(File.read(bundled_app("Gemfile.lock"))).not_to match("\r\n")
expect(the_bundle).to include_gems "rack 1.2"
end
@@ -1316,7 +1360,7 @@ RSpec.describe "the lockfile format" do
File.open(bundled_app("Gemfile.lock"), "wb") {|f| f.puts(win_lock) }
set_lockfile_mtime_to_known_value
- expect { bundle "update" }.to change { File.mtime(bundled_app("Gemfile.lock")) }
+ expect { bundle "update", :all => true }.to change { File.mtime(bundled_app("Gemfile.lock")) }
expect(File.read(bundled_app("Gemfile.lock"))).to match("\r\n")
expect(the_bundle).to include_gems "rack 1.2"
end
@@ -1361,7 +1405,7 @@ RSpec.describe "the lockfile format" do
>>>>>>>
PLATFORMS
- ruby
+ #{lockfile_platforms}
DEPENDENCIES
rack
@@ -1370,12 +1414,12 @@ RSpec.describe "the lockfile format" do
#{Bundler::VERSION}
L
- error = install_gemfile(<<-G)
+ install_gemfile(<<-G)
source "file://#{gem_repo1}"
gem "rack"
G
- expect(error).to match(/your Gemfile.lock contains merge conflicts/i)
- expect(error).to match(/git checkout HEAD -- Gemfile.lock/i)
+ expect(last_command.bundler_err).to match(/your Gemfile.lock contains merge conflicts/i)
+ expect(last_command.bundler_err).to match(/git checkout HEAD -- Gemfile.lock/i)
end
end
diff --git a/spec/bundler/other/bundle_ruby_spec.rb b/spec/bundler/other/bundle_ruby_spec.rb
index 0ef6f407bf..6cc33f60ac 100644
--- a/spec/bundler/other/bundle_ruby_spec.rb
+++ b/spec/bundler/other/bundle_ruby_spec.rb
@@ -1,7 +1,6 @@
# frozen_string_literal: true
-require "spec_helper"
-RSpec.describe "bundle_ruby", :ruby_repo do
+RSpec.describe "bundle_ruby", :bundler => "< 2" do
context "without patchlevel" do
it "returns the ruby version" do
gemfile <<-G
diff --git a/spec/bundler/other/cli_dispatch_spec.rb b/spec/bundler/other/cli_dispatch_spec.rb
index 8b34a457ef..a9d0bf7462 100644
--- a/spec/bundler/other/cli_dispatch_spec.rb
+++ b/spec/bundler/other/cli_dispatch_spec.rb
@@ -1,22 +1,29 @@
# frozen_string_literal: true
-require "spec_helper"
RSpec.describe "bundle command names" do
it "work when given fully" do
bundle "install"
- expect(err).to lack_errors
- expect(out).not_to match(/Ambiguous command/)
+ expect(last_command.bundler_err).to eq("Could not locate Gemfile")
+ expect(last_command.stdboth).not_to include("Ambiguous command")
end
it "work when not ambiguous" do
bundle "ins"
- expect(err).to lack_errors
- expect(out).not_to match(/Ambiguous command/)
+ expect(last_command.bundler_err).to eq("Could not locate Gemfile")
+ expect(last_command.stdboth).not_to include("Ambiguous command")
end
it "print a friendly error when ambiguous" do
bundle "in"
- expect(err).to lack_errors
- expect(out).to match(/Ambiguous command/)
+ expect(last_command.bundler_err).to eq("Ambiguous command in matches [info, init, inject, install]")
+ end
+
+ context "when cache_command_is_package is set" do
+ before { bundle! "config cache_command_is_package true" }
+
+ it "dispatches `bundle cache` to the package command" do
+ bundle "cache --verbose"
+ expect(last_command.stdout).to start_with "Running `bundle package --no-color --verbose`"
+ end
end
end
diff --git a/spec/bundler/other/compatibility_guard_spec.rb b/spec/bundler/other/compatibility_guard_spec.rb
new file mode 100644
index 0000000000..ac05ebd918
--- /dev/null
+++ b/spec/bundler/other/compatibility_guard_spec.rb
@@ -0,0 +1,25 @@
+# frozen_string_literal: true
+
+RSpec.describe "bundler compatibility guard" do
+ context "when the bundler version is 2+" do
+ before { simulate_bundler_version "2.0.a" }
+
+ context "when running on Ruby < 2.3", :ruby => "< 2.3" do
+ before { simulate_rubygems_version "2.6.11" }
+
+ it "raises a friendly error" do
+ bundle :version
+ expect(err).to eq("Bundler 2 requires Ruby 2.3 or later. Either install bundler 1 or update to a supported Ruby version.")
+ end
+ end
+
+ context "when running on RubyGems < 2.5", :ruby => ">= 2.5" do
+ before { simulate_rubygems_version "1.3.6" }
+
+ it "raises a friendly error" do
+ bundle :version
+ expect(err).to eq("Bundler 2 requires RubyGems 2.5 or later. Either install bundler 1 or update to a supported RubyGems version.")
+ end
+ end
+ end
+end
diff --git a/spec/bundler/other/ext_spec.rb b/spec/bundler/other/ext_spec.rb
index 2d6ab941b8..3f6f8b4928 100644
--- a/spec/bundler/other/ext_spec.rb
+++ b/spec/bundler/other/ext_spec.rb
@@ -1,5 +1,4 @@
# frozen_string_literal: true
-require "spec_helper"
RSpec.describe "Gem::Specification#match_platform" do
it "does not match platforms other than the gem platform" do
diff --git a/spec/bundler/other/major_deprecation_spec.rb b/spec/bundler/other/major_deprecation_spec.rb
index 196fbe0c31..fba177b497 100644
--- a/spec/bundler/other/major_deprecation_spec.rb
+++ b/spec/bundler/other/major_deprecation_spec.rb
@@ -1,8 +1,8 @@
# frozen_string_literal: true
-require "spec_helper"
-RSpec.describe "major deprecations" do
- let(:warnings) { out } # change to err in 2.0
+RSpec.describe "major deprecations", :bundler => "< 2" do
+ let(:warnings) { last_command.bundler_err } # change to err in 2.0
+ let(:warnings_without_version_messages) { warnings.gsub(/#{Spec::Matchers::MAJOR_DEPRECATION}Bundler will only support ruby(gems)? >= .*/, "") }
context "in a .99 version" do
before do
@@ -23,17 +23,18 @@ RSpec.describe "major deprecations" do
before do
bundle "config major_deprecations true"
- install_gemfile <<-G
+ create_file "gems.rb", <<-G
source "file:#{gem_repo1}"
ruby #{RUBY_VERSION.dump}
gem "rack"
G
+ bundle! "install"
end
- describe "bundle_ruby", :ruby_repo do
+ describe "bundle_ruby" do
it "prints a deprecation" do
bundle_ruby
- out.gsub! "\nruby #{RUBY_VERSION}", ""
+ warnings.gsub! "\nruby #{RUBY_VERSION}", ""
expect(warnings).to have_major_deprecation "the bundle_ruby executable has been removed in favor of `bundle platform --ruby`"
end
end
@@ -86,7 +87,24 @@ RSpec.describe "major deprecations" do
describe "bundle update --quiet" do
it "does not print any deprecations" do
bundle :update, :quiet => true
- expect(warnings).not_to have_major_deprecation
+ expect(warnings_without_version_messages).not_to have_major_deprecation
+ end
+ end
+
+ describe "bundle update" do
+ before do
+ create_file("gems.rb", "")
+ bundle! "install"
+ end
+
+ it "warns when no options are given" do
+ bundle! "update"
+ expect(warnings).to have_major_deprecation a_string_including("Pass --all to `bundle update` to update everything")
+ end
+
+ it "does not warn when --all is passed" do
+ bundle! "update --all"
+ expect(warnings_without_version_messages).not_to have_major_deprecation
end
end
@@ -110,17 +128,18 @@ RSpec.describe "major deprecations" do
G
bundle :install
- expect(err).not_to have_major_deprecation
- expect(out).not_to have_major_deprecation
+ expect(warnings_without_version_messages).not_to have_major_deprecation
end
it "should print a Gemfile deprecation warning" do
- install_gemfile <<-G
+ create_file "gems.rb"
+ install_gemfile! <<-G
source "file://#{gem_repo1}"
gem "rack"
G
+ expect(the_bundle).to include_gem "rack 1.0"
- expect(warnings).to have_major_deprecation("gems.rb and gems.locked will be preferred to Gemfile and Gemfile.lock.")
+ expect(warnings).to have_major_deprecation a_string_including("gems.rb and gems.locked will be preferred to Gemfile and Gemfile.lock.")
end
context "with flags" do
@@ -139,7 +158,8 @@ RSpec.describe "major deprecations" do
context "when Bundler.setup is run in a ruby script" do
it "should print a single deprecation warning" do
- install_gemfile <<-G
+ create_file "gems.rb"
+ install_gemfile! <<-G
source "file://#{gem_repo1}"
gem "rack", :group => :test
G
@@ -154,7 +174,7 @@ RSpec.describe "major deprecations" do
Bundler.setup
RUBY
- expect(warnings).to have_major_deprecation("gems.rb and gems.locked will be preferred to Gemfile and Gemfile.lock.")
+ expect(warnings_without_version_messages).to have_major_deprecation("gems.rb and gems.locked will be preferred to Gemfile and Gemfile.lock.")
end
end
@@ -179,17 +199,27 @@ RSpec.describe "major deprecations" do
context "with github gems" do
it "warns about the https change" do
- msg = "The :github option uses the git: protocol, which is not secure. " \
- "Bundler 2.0 will use the https: protocol, which is secure. Enable this change now by " \
- "running `bundle config github.https true`."
- expect(Bundler::SharedHelpers).to receive(:major_deprecation).with(msg)
+ msg = <<-EOS
+The :github git source is deprecated, and will be removed in Bundler 2.0. Change any "reponame" :github sources to "username/reponame". Add this code to the top of your Gemfile to ensure it continues to work:
+
+ git_source(:github) {|repo_name| "https://github.com/\#{repo_name}.git" }
+
+ EOS
+ expect(Bundler::SharedHelpers).to receive(:major_deprecation).with(2, msg)
subject.gem("sparks", :github => "indirect/sparks")
end
it "upgrades to https on request" do
- Bundler.settings["github.https"] = true
+ Bundler.settings.temporary "github.https" => true
+ msg = <<-EOS
+The :github git source is deprecated, and will be removed in Bundler 2.0. Change any "reponame" :github sources to "username/reponame". Add this code to the top of your Gemfile to ensure it continues to work:
+
+ git_source(:github) {|repo_name| "https://github.com/\#{repo_name}.git" }
+
+ EOS
+ expect(Bundler::SharedHelpers).to receive(:major_deprecation).with(2, msg)
+ expect(Bundler::SharedHelpers).to receive(:major_deprecation).with(2, "The `github.https` setting will be removed")
subject.gem("sparks", :github => "indirect/sparks")
- expect(Bundler::SharedHelpers).to receive(:major_deprecation).never
github_uri = "https://github.com/indirect/sparks.git"
expect(subject.dependencies.first.source.uri).to eq(github_uri)
end
@@ -198,12 +228,17 @@ RSpec.describe "major deprecations" do
context "with bitbucket gems" do
it "warns about removal" do
allow(Bundler.ui).to receive(:deprecate)
- msg = "The :bitbucket git source is deprecated, and will be removed " \
- "in Bundler 2.0. Add this code to your Gemfile to ensure it " \
- "continues to work:\n git_source(:bitbucket) do |repo_name|\n " \
- " \"https://\#{user_name}@bitbucket.org/\#{user_name}/\#{repo_name}" \
- ".git\"\n end\n"
- expect(Bundler::SharedHelpers).to receive(:major_deprecation).with(msg)
+ msg = <<-EOS
+The :bitbucket git source is deprecated, and will be removed in Bundler 2.0. Add this code to the top of your Gemfile to ensure it continues to work:
+
+ git_source(:bitbucket) do |repo_name|
+ user_name, repo_name = repo_name.split("/")
+ repo_name ||= user_name
+ "https://\#{user_name}@bitbucket.org/\#{user_name}/\#{repo_name}.git"
+ end
+
+ EOS
+ expect(Bundler::SharedHelpers).to receive(:major_deprecation).with(2, msg)
subject.gem("not-really-a-gem", :bitbucket => "mcorp/flatlab-rails")
end
end
@@ -212,28 +247,27 @@ RSpec.describe "major deprecations" do
it "warns about removal" do
allow(Bundler.ui).to receive(:deprecate)
msg = "The :gist git source is deprecated, and will be removed " \
- "in Bundler 2.0. Add this code to your Gemfile to ensure it " \
- "continues to work:\n git_source(:gist) do |repo_name|\n " \
- " \"https://gist.github.com/\#{repo_name}.git\"\n" \
- " end\n"
- expect(Bundler::SharedHelpers).to receive(:major_deprecation).with(msg)
+ "in Bundler 2.0. Add this code to the top of your Gemfile to ensure it " \
+ "continues to work:\n\n git_source(:gist) {|repo_name| " \
+ "\"https://gist.github.com/\#{repo_name}.git\" }\n\n"
+ expect(Bundler::SharedHelpers).to receive(:major_deprecation).with(2, msg)
subject.gem("not-really-a-gem", :gist => "1234")
end
end
end
- context "bundle list" do
+ context "bundle show" do
it "prints a deprecation warning" do
- install_gemfile <<-G
+ install_gemfile! <<-G
source "file://#{gem_repo1}"
gem "rack"
G
- bundle :list
+ bundle! :show
- out.gsub!(/gems included.*?\[DEPRECATED/im, "[DEPRECATED")
+ warnings.gsub!(/gems included.*?\[DEPRECATED/im, "[DEPRECATED")
- expect(warnings).to have_major_deprecation("use `bundle show` instead of `bundle list`")
+ expect(warnings).to have_major_deprecation a_string_including("use `bundle list` instead of `bundle show`")
end
end
@@ -242,7 +276,7 @@ RSpec.describe "major deprecations" do
bundle "console"
expect(warnings).to have_major_deprecation \
- "bundle console will be replaced by `bin/console` generated by `bundle gem <name>`"
+ a_string_including("bundle console will be replaced by `bin/console` generated by `bundle gem <name>`")
end
end
end
diff --git a/spec/bundler/other/platform_spec.rb b/spec/bundler/other/platform_spec.rb
index 6adbcef111..fea5daf5ac 100644
--- a/spec/bundler/other/platform_spec.rb
+++ b/spec/bundler/other/platform_spec.rb
@@ -1,8 +1,13 @@
# frozen_string_literal: true
-require "spec_helper"
RSpec.describe "bundle platform" do
context "without flags" do
+ let(:bundle_platform_platforms_string) do
+ platforms = [rb]
+ platforms.unshift(specific_local_platform) if Bundler.feature_flag.bundler_2_mode?
+ platforms.map {|pl| "* #{pl}" }.join("\n")
+ end
+
it "returns all the output" do
gemfile <<-G
source "file://#{gem_repo1}"
@@ -17,7 +22,7 @@ RSpec.describe "bundle platform" do
Your platform is: #{RUBY_PLATFORM}
Your app has gems that work on these platforms:
-* ruby
+#{bundle_platform_platforms_string}
Your Gemfile specifies a Ruby version requirement:
* ruby #{RUBY_VERSION}
@@ -40,7 +45,7 @@ G
Your platform is: #{RUBY_PLATFORM}
Your app has gems that work on these platforms:
-* ruby
+#{bundle_platform_platforms_string}
Your Gemfile specifies a Ruby version requirement:
* ruby #{RUBY_VERSION}p#{RUBY_PATCHLEVEL}
@@ -61,7 +66,7 @@ G
Your platform is: #{RUBY_PLATFORM}
Your app has gems that work on these platforms:
-* ruby
+#{bundle_platform_platforms_string}
Your Gemfile does not specify a Ruby version requirement.
G
@@ -81,7 +86,7 @@ G
Your platform is: #{RUBY_PLATFORM}
Your app has gems that work on these platforms:
-* ruby
+#{bundle_platform_platforms_string}
Your Gemfile specifies a Ruby version requirement:
* ruby #{not_local_ruby_version}
@@ -493,7 +498,7 @@ G
build_gem "activesupport", "3.0"
end
- bundle "update"
+ bundle "update", :all => bundle_update_requires_all?
expect(the_bundle).to include_gems "rack 1.2", "rack-obama 1.0", "activesupport 3.0"
end
@@ -510,7 +515,7 @@ G
build_gem "activesupport", "3.0"
end
- bundle "update"
+ bundle "update", :all => bundle_update_requires_all?
expect(the_bundle).to include_gems "rack 1.2", "rack-obama 1.0", "activesupport 3.0"
end
end
@@ -527,7 +532,7 @@ G
build_gem "activesupport", "3.0"
end
- bundle :update
+ bundle :update, :all => bundle_update_requires_all?
should_be_ruby_version_incorrect
end
@@ -543,7 +548,7 @@ G
build_gem "activesupport", "3.0"
end
- bundle :update
+ bundle :update, :all => bundle_update_requires_all?
should_be_engine_incorrect
end
@@ -560,7 +565,7 @@ G
build_gem "activesupport", "3.0"
end
- bundle :update
+ bundle :update, :all => bundle_update_requires_all?
should_be_engine_version_incorrect
end
end
@@ -576,12 +581,12 @@ G
build_gem "activesupport", "3.0"
end
- bundle :update
+ bundle :update, :all => bundle_update_requires_all?
should_be_patchlevel_incorrect
end
end
- context "bundle show" do
+ context "bundle info" do
before do
install_gemfile <<-G
source "file://#{gem_repo1}"
@@ -590,32 +595,32 @@ G
end
it "prints path if ruby version is correct" do
- gemfile <<-G
+ install_gemfile! <<-G
source "file://#{gem_repo1}"
gem "rails"
#{ruby_version_correct}
G
- bundle "show rails"
+ bundle "info rails --path"
expect(out).to eq(default_bundle_path("gems", "rails-2.3.2").to_s)
end
it "prints path if ruby version is correct for any engine" do
simulate_ruby_engine "jruby" do
- gemfile <<-G
+ install_gemfile! <<-G
source "file://#{gem_repo1}"
gem "rails"
#{ruby_version_correct_engineless}
G
- bundle "show rails"
+ bundle "info rails --path"
expect(out).to eq(default_bundle_path("gems", "rails-2.3.2").to_s)
end
end
- it "fails if ruby version doesn't match" do
+ it "fails if ruby version doesn't match", :bundler => "< 2" do
gemfile <<-G
source "file://#{gem_repo1}"
gem "rails"
@@ -627,7 +632,7 @@ G
should_be_ruby_version_incorrect
end
- it "fails if engine doesn't match" do
+ it "fails if engine doesn't match", :bundler => "< 2" do
gemfile <<-G
source "file://#{gem_repo1}"
gem "rails"
@@ -639,7 +644,7 @@ G
should_be_engine_incorrect
end
- it "fails if engine version doesn't match" do
+ it "fails if engine version doesn't match", :bundler => "< 2" do
simulate_ruby_engine "jruby" do
gemfile <<-G
source "file://#{gem_repo1}"
@@ -653,7 +658,7 @@ G
end
end
- it "fails when patchlevel doesn't match" do
+ it "fails when patchlevel doesn't match", :bundler => "< 2" do
gemfile <<-G
source "file://#{gem_repo1}"
gem "rack"
@@ -671,11 +676,10 @@ G
context "bundle cache" do
before do
- gemfile <<-G
+ install_gemfile <<-G
+ source "file:#{gem_repo1}"
gem 'rack'
G
-
- system_gems "rack-1.0.0"
end
it "copies the .gem file to vendor/cache when ruby version matches" do
@@ -691,13 +695,14 @@ G
it "copies the .gem file to vendor/cache when ruby version matches for any engine" do
simulate_ruby_engine "jruby" do
- gemfile <<-G
+ install_gemfile! <<-G
+ source "file:#{gem_repo1}"
gem 'rack'
#{ruby_version_correct_engineless}
G
- bundle :cache
+ bundle! :cache
expect(bundled_app("vendor/cache/rack-1.0.0.gem")).to exist
end
end
@@ -752,11 +757,10 @@ G
context "bundle pack" do
before do
- gemfile <<-G
+ install_gemfile! <<-G
+ source "file:#{gem_repo1}"
gem 'rack'
G
-
- system_gems "rack-1.0.0"
end
it "copies the .gem file to vendor/cache when ruby version matches" do
@@ -772,7 +776,8 @@ G
it "copies the .gem file to vendor/cache when ruby version matches any engine" do
simulate_ruby_engine "jruby" do
- gemfile <<-G
+ install_gemfile! <<-G
+ source "file:#{gem_repo1}"
gem 'rack'
#{ruby_version_correct_engineless}
@@ -834,7 +839,7 @@ G
context "bundle exec" do
before do
ENV["BUNDLER_FORCE_TTY"] = "true"
- system_gems "rack-1.0.0", "rack-0.9.1"
+ system_gems "rack-1.0.0", "rack-0.9.1", :path => :bundle_path
end
it "activates the correct gem when ruby version matches" do
@@ -850,6 +855,7 @@ G
it "activates the correct gem when ruby version matches any engine" do
simulate_ruby_engine "jruby" do
+ system_gems "rack-1.0.0", "rack-0.9.1", :path => :bundle_path
gemfile <<-G
gem "rack", "0.9.1"
@@ -909,7 +915,7 @@ G
end
end
- context "bundle console" do
+ context "bundle console", :bundler => "< 2" do
before do
install_gemfile <<-G
source "file://#{gem_repo1}"
@@ -1174,6 +1180,7 @@ G
it "returns list of outdated gems when the ruby version matches for any engine" do
simulate_ruby_engine "jruby" do
+ bundle! :install
update_repo2 do
build_gem "activesupport", "3.0"
update_git "foo", :path => lib_path("foo")
diff --git a/spec/bundler/other/ssl_cert_spec.rb b/spec/bundler/other/ssl_cert_spec.rb
index 2de4dfdd0c..6d957276fc 100644
--- a/spec/bundler/other/ssl_cert_spec.rb
+++ b/spec/bundler/other/ssl_cert_spec.rb
@@ -1,14 +1,14 @@
# frozen_string_literal: true
-require "spec_helper"
+
require "bundler/ssl_certs/certificate_manager"
RSpec.describe "SSL Certificates", :rubygems_master do
- hosts = %w(
+ hosts = %w[
rubygems.org
index.rubygems.org
rubygems.global.ssl.fastly.net
staging.rubygems.org
- )
+ ]
hosts.each do |host|
it "can securely connect to #{host}", :realworld do
diff --git a/spec/bundler/plugins/command_spec.rb b/spec/bundler/plugins/command_spec.rb
index 6ad782b758..8275351d19 100644
--- a/spec/bundler/plugins/command_spec.rb
+++ b/spec/bundler/plugins/command_spec.rb
@@ -1,5 +1,4 @@
# frozen_string_literal: true
-require "spec_helper"
RSpec.describe "command plugins" do
before do
diff --git a/spec/bundler/plugins/hook_spec.rb b/spec/bundler/plugins/hook_spec.rb
index 9850d850ac..8bdf61a8ab 100644
--- a/spec/bundler/plugins/hook_spec.rb
+++ b/spec/bundler/plugins/hook_spec.rb
@@ -1,5 +1,4 @@
# frozen_string_literal: true
-require "spec_helper"
RSpec.describe "hook plugins" do
before do
diff --git a/spec/bundler/plugins/install_spec.rb b/spec/bundler/plugins/install_spec.rb
index e2d351181c..9304d78062 100644
--- a/spec/bundler/plugins/install_spec.rb
+++ b/spec/bundler/plugins/install_spec.rb
@@ -1,5 +1,4 @@
# frozen_string_literal: true
-require "spec_helper"
RSpec.describe "bundler plugin install" do
before do
@@ -58,7 +57,7 @@ RSpec.describe "bundler plugin install" do
end
end
RUBY
- s.require_paths = %w(lib src)
+ s.require_paths = %w[lib src]
s.write("src/fubar.rb")
end
end
diff --git a/spec/bundler/plugins/source/example_spec.rb b/spec/bundler/plugins/source/example_spec.rb
index 2ae34caf73..0dbd9a2a0f 100644
--- a/spec/bundler/plugins/source/example_spec.rb
+++ b/spec/bundler/plugins/source/example_spec.rb
@@ -1,5 +1,4 @@
# frozen_string_literal: true
-require "spec_helper"
RSpec.describe "real source plugins" do
context "with a minimal source plugin" do
@@ -7,7 +6,7 @@ RSpec.describe "real source plugins" do
build_repo2 do
build_plugin "bundler-source-mpath" do |s|
s.write "plugins.rb", <<-RUBY
- require "fileutils"
+ require "bundler/vendored_fileutils"
require "bundler-source-mpath"
class MPath < Bundler::Plugin::API
@@ -37,6 +36,10 @@ RSpec.describe "real source plugins" do
mkdir_p(install_path.parent)
FileUtils.cp_r(path, install_path)
+ spec_path = install_path.join("\#{spec.full_name}.gemspec")
+ spec_path.open("wb") {|f| f.write spec.to_ruby }
+ spec.loaded_from = spec_path.to_s
+
post_install(spec)
nil
@@ -64,7 +67,7 @@ RSpec.describe "real source plugins" do
expect(the_bundle).to include_gems("a-path-gem 1.0")
end
- it "writes to lock file" do
+ it "writes to lock file", :bundler => "< 2" do
bundle "install"
lockfile_should_be <<-G
@@ -89,12 +92,37 @@ RSpec.describe "real source plugins" do
G
end
+ it "writes to lock file", :bundler => "2" do
+ bundle "install"
+
+ lockfile_should_be <<-G
+ GEM
+ remote: file:#{gem_repo2}/
+ specs:
+
+ PLUGIN SOURCE
+ remote: #{lib_path("a-path-gem-1.0")}
+ type: mpath
+ specs:
+ a-path-gem (1.0)
+
+ PLATFORMS
+ #{lockfile_platforms}
+
+ DEPENDENCIES
+ a-path-gem!
+
+ BUNDLED WITH
+ #{Bundler::VERSION}
+ G
+ end
+
it "provides correct #full_gem_path" do
bundle "install"
run <<-RUBY
puts Bundler.rubygems.find_name('a-path-gem').first.full_gem_path
RUBY
- expect(out).to eq(bundle("show a-path-gem"))
+ expect(out).to eq(bundle("info a-path-gem --path"))
end
it "installs the gem executables" do
@@ -114,10 +142,10 @@ RSpec.describe "real source plugins" do
end
describe "bundle cache/package" do
- let(:uri_hash) { Digest::SHA1.hexdigest(lib_path("a-path-gem-1.0").to_s) }
+ let(:uri_hash) { Digest(:SHA1).hexdigest(lib_path("a-path-gem-1.0").to_s) }
it "copies repository to vendor cache and uses it" do
bundle "install"
- bundle "cache --all"
+ bundle :cache, forgotten_command_line_options([:all, :cache_all] => true)
expect(bundled_app("vendor/cache/a-path-gem-1.0-#{uri_hash}")).to exist
expect(bundled_app("vendor/cache/a-path-gem-1.0-#{uri_hash}/.git")).not_to exist
@@ -128,8 +156,8 @@ RSpec.describe "real source plugins" do
end
it "copies repository to vendor cache and uses it even when installed with bundle --path" do
- bundle "install --path vendor/bundle"
- bundle "cache --all"
+ bundle! :install, forgotten_command_line_options(:path => "vendor/bundle")
+ bundle! :cache, forgotten_command_line_options([:all, :cache_all] => true)
expect(bundled_app("vendor/cache/a-path-gem-1.0-#{uri_hash}")).to exist
@@ -138,8 +166,8 @@ RSpec.describe "real source plugins" do
end
it "bundler package copies repository to vendor cache" do
- bundle "install --path vendor/bundle"
- bundle "package --all"
+ bundle! :install, forgotten_command_line_options(:path => "vendor/bundle")
+ bundle! :package, forgotten_command_line_options([:all, :cache_all] => true)
expect(bundled_app("vendor/cache/a-path-gem-1.0-#{uri_hash}")).to exist
@@ -173,7 +201,7 @@ RSpec.describe "real source plugins" do
end
it "installs" do
- bundle "install"
+ bundle! "install"
expect(the_bundle).to include_gems("a-path-gem 1.0")
end
@@ -228,6 +256,10 @@ RSpec.describe "real source plugins" do
`git reset --hard \#{revision}`
end
+ spec_path = install_path.join("\#{spec.full_name}.gemspec")
+ spec_path.open("wb") {|f| f.write spec.to_ruby }
+ spec.loaded_from = spec_path.to_s
+
post_install(spec)
nil
@@ -327,7 +359,7 @@ RSpec.describe "real source plugins" do
expect(the_bundle).to include_gems("ma-gitp-gem 1.0")
end
- it "writes to lock file" do
+ it "writes to lock file", :bundler => "< 2" do
revision = revision_for(lib_path("ma-gitp-gem-1.0"))
bundle "install"
@@ -354,6 +386,33 @@ RSpec.describe "real source plugins" do
G
end
+ it "writes to lock file", :bundler => "2" do
+ revision = revision_for(lib_path("ma-gitp-gem-1.0"))
+ bundle "install"
+
+ lockfile_should_be <<-G
+ GEM
+ remote: file:#{gem_repo2}/
+ specs:
+
+ PLUGIN SOURCE
+ remote: file://#{lib_path("ma-gitp-gem-1.0")}
+ type: gitp
+ revision: #{revision}
+ specs:
+ ma-gitp-gem (1.0)
+
+ PLATFORMS
+ #{lockfile_platforms}
+
+ DEPENDENCIES
+ ma-gitp-gem!
+
+ BUNDLED WITH
+ #{Bundler::VERSION}
+ G
+ end
+
context "with lockfile" do
before do
revision = revision_for(lib_path("ma-gitp-gem-1.0"))
@@ -433,7 +492,7 @@ RSpec.describe "real source plugins" do
end
G
- bundle "cache --all"
+ bundle :cache, forgotten_command_line_options([:all, :cache_all] => true)
expect(bundled_app("vendor/cache/foo-1.0-#{ref}")).to exist
expect(bundled_app("vendor/cache/foo-1.0-#{ref}/.git")).not_to exist
expect(bundled_app("vendor/cache/foo-1.0-#{ref}/.bundlecache")).to be_file
diff --git a/spec/bundler/plugins/source_spec.rb b/spec/bundler/plugins/source_spec.rb
index 0448bc409a..543e90eb60 100644
--- a/spec/bundler/plugins/source_spec.rb
+++ b/spec/bundler/plugins/source_spec.rb
@@ -1,5 +1,4 @@
# frozen_string_literal: true
-require "spec_helper"
RSpec.describe "bundler source plugin" do
describe "plugins dsl eval for #source with :type option" do
diff --git a/spec/bundler/quality_spec.rb b/spec/bundler/quality_spec.rb
index b87b4a0731..9fc03b486b 100644
--- a/spec/bundler/quality_spec.rb
+++ b/spec/bundler/quality_spec.rb
@@ -1,5 +1,4 @@
# frozen_string_literal: true
-require "spec_helper"
if defined?(Encoding) && Encoding.default_external.name != "UTF-8"
# Poor man's ruby -E UTF-8, since it works on 1.8.7
@@ -7,17 +6,6 @@ if defined?(Encoding) && Encoding.default_external.name != "UTF-8"
end
RSpec.describe "The library itself" do
- def check_for_spec_defs_with_single_quotes(filename)
- failing_lines = []
-
- File.readlines(filename).each_with_index do |line, number|
- failing_lines << number + 1 if line =~ /^ *(describe|it|context) {1}'{1}/
- end
-
- return if failing_lines.empty?
- "#{filename} uses inconsistent single quotes on lines #{failing_lines.join(", ")}"
- end
-
def check_for_debugging_mechanisms(filename)
debugging_mechanisms_regex = /
(binding\.pry)|
@@ -67,7 +55,7 @@ RSpec.describe "The library itself" do
failing_lines = []
File.readlines(filename).each_with_index do |line, number|
next if line =~ /^\s+#.*\s+\n$/
- next if %w(LICENCE.md).include?(line)
+ next if %w[LICENCE.md].include?(line)
failing_lines << number + 1 if line =~ /\s+\n$/
end
@@ -77,7 +65,7 @@ RSpec.describe "The library itself" do
def check_for_expendable_words(filename)
failing_line_message = []
- useless_words = %w(
+ useless_words = %w[
actually
basically
clearly
@@ -85,12 +73,12 @@ RSpec.describe "The library itself" do
obviously
really
simply
- )
+ ]
pattern = /\b#{Regexp.union(useless_words)}\b/i
File.readlines(filename).each_with_index do |line, number|
next unless word_found = pattern.match(line)
- failing_line_message << "#{filename} has '#{word_found}' on line #{number + 1}. Avoid using these kinds of weak modifiers."
+ failing_line_message << "#{filename}:#{number.succ} has '#{word_found}'. Avoid using these kinds of weak modifiers."
end
failing_line_message unless failing_line_message.empty?
@@ -102,7 +90,7 @@ RSpec.describe "The library itself" do
File.readlines(filename).each_with_index do |line, number|
next unless word_found = specific_pronouns.match(line)
- failing_line_message << "#{filename} has '#{word_found}' on line #{number + 1}. Use more generic pronouns in documentation."
+ failing_line_message << "#{filename}:#{number.succ} has '#{word_found}'. Use more generic pronouns in documentation."
end
failing_line_message unless failing_line_message.empty?
@@ -117,9 +105,9 @@ RSpec.describe "The library itself" do
end
it "has no malformed whitespace", :ruby_repo do
- exempt = /\.gitmodules|\.marshal|fixtures|vendor|ssl_certs|LICENSE/
+ exempt = /\.gitmodules|\.marshal|fixtures|vendor|ssl_certs|LICENSE|vcr_cassettes/
error_messages = []
- Dir.chdir(File.expand_path("../..", __FILE__)) do
+ Dir.chdir(root) do
`git ls-files -z`.split("\x0").each do |filename|
next if filename =~ exempt
error_messages << check_for_tab_characters(filename)
@@ -129,22 +117,10 @@ RSpec.describe "The library itself" do
expect(error_messages.compact).to be_well_formed
end
- it "uses double-quotes consistently in specs", :ruby_repo do
- included = /spec/
- error_messages = []
- Dir.chdir(File.expand_path("../", __FILE__)) do
- `git ls-files -z`.split("\x0").each do |filename|
- next unless filename =~ included
- error_messages << check_for_spec_defs_with_single_quotes(filename)
- end
- end
- expect(error_messages.compact).to be_well_formed
- end
-
it "does not include any leftover debugging or development mechanisms", :ruby_repo do
- exempt = %r{quality_spec.rb|support/helpers}
+ exempt = %r{quality_spec.rb|support/helpers|vcr_cassettes|\.md|\.ronn}
error_messages = []
- Dir.chdir(File.expand_path("../", __FILE__)) do
+ Dir.chdir(root) do
`git ls-files -z`.split("\x0").each do |filename|
next if filename =~ exempt
error_messages << check_for_debugging_mechanisms(filename)
@@ -155,8 +131,8 @@ RSpec.describe "The library itself" do
it "does not include any unresolved merge conflicts", :ruby_repo do
error_messages = []
- exempt = %r{lock/lockfile_spec|quality_spec}
- Dir.chdir(File.expand_path("../", __FILE__)) do
+ exempt = %r{lock/lockfile_(bundler_1_)?spec|quality_spec|vcr_cassettes|\.ronn|lockfile_parser\.rb}
+ Dir.chdir(root) do
`git ls-files -z`.split("\x0").each do |filename|
next if filename =~ exempt
error_messages << check_for_git_merge_conflicts(filename)
@@ -168,8 +144,8 @@ RSpec.describe "The library itself" do
it "maintains language quality of the documentation", :ruby_repo do
included = /ronn/
error_messages = []
- Dir.chdir(File.expand_path("../../man", __FILE__)) do
- `git ls-files -z`.split("\x0").each do |filename|
+ Dir.chdir(root) do
+ `git ls-files -z -- man`.split("\x0").each do |filename|
next unless filename =~ included
error_messages << check_for_expendable_words(filename)
error_messages << check_for_specific_pronouns(filename)
@@ -181,8 +157,8 @@ RSpec.describe "The library itself" do
it "maintains language quality of sentences used in source code", :ruby_repo do
error_messages = []
exempt = /vendor/
- Dir.chdir(File.expand_path("../../lib", __FILE__)) do
- `git ls-files -z`.split("\x0").each do |filename|
+ Dir.chdir(root) do
+ `git ls-files -z -- lib`.split("\x0").each do |filename|
next if filename =~ exempt
error_messages << check_for_expendable_words(filename)
error_messages << check_for_specific_pronouns(filename)
@@ -192,27 +168,34 @@ RSpec.describe "The library itself" do
end
it "documents all used settings", :ruby_repo do
- exemptions = %w(
+ exemptions = %w[
+ cache_command_is_package
+ console_command
+ default_cli_command
+ deployment_means_frozen
+ forget_cli_options
gem.coc
gem.mit
inline
+ lockfile_uses_separate_rubygems_sources
warned_version
- )
+ ]
all_settings = Hash.new {|h, k| h[k] = [] }
documented_settings = exemptions
Bundler::Settings::BOOL_KEYS.each {|k| all_settings[k] << "in Bundler::Settings::BOOL_KEYS" }
Bundler::Settings::NUMBER_KEYS.each {|k| all_settings[k] << "in Bundler::Settings::NUMBER_KEYS" }
+ Bundler::Settings::ARRAY_KEYS.each {|k| all_settings[k] << "in Bundler::Settings::ARRAY_KEYS" }
- Dir.chdir(File.expand_path("../../lib", __FILE__)) do
+ Dir.chdir(root) do
key_pattern = /([a-z\._-]+)/i
- `git ls-files -z`.split("\x0").each do |filename|
+ `git ls-files -z -- lib`.split("\x0").each do |filename|
File.readlines(filename).each_with_index do |line, number|
- line.scan(/Bundler\.settings\[:#{key_pattern}\]/).flatten.each {|s| all_settings[s] << "referenced at `lib/#{filename}:#{number.succ}`" }
+ line.scan(/Bundler\.settings\[:#{key_pattern}\]/).flatten.each {|s| all_settings[s] << "referenced at `#{filename}:#{number.succ}`" }
end
end
- documented_settings = File.read("../man/bundle-config.ronn").scan(/^\* `#{key_pattern}`/).flatten
+ documented_settings = File.read("man/bundle-config.ronn")[/LIST OF AVAILABLE KEYS.*/m].scan(/^\* `#{key_pattern}`/).flatten
end
documented_settings.each {|s| all_settings.delete(s) }
@@ -222,6 +205,8 @@ RSpec.describe "The library itself" do
end
expect(error_messages.sort).to be_well_formed
+
+ expect(documented_settings).to be_sorted
end
it "can still be built", :ruby_repo do
@@ -229,9 +214,12 @@ RSpec.describe "The library itself" do
begin
gem_command! :build, "bundler.gemspec"
if Bundler.rubygems.provides?(">= 2.4")
+ # there's no way aroudn this warning
+ last_command.stderr.sub!(/^YAML safe loading.*/, "")
+
# older rubygems have weird warnings, and we won't actually be using them
# to build the gem for releases anyways
- expect(err).to be_empty, "bundler should build as a gem without warnings, but\n#{err}"
+ expect(last_command.stderr).to be_empty, "bundler should build as a gem without warnings, but\n#{err}"
end
ensure
# clean up the .gem generated
@@ -241,23 +229,24 @@ RSpec.describe "The library itself" do
end
it "does not contain any warnings", :ruby_repo do
- Dir.chdir(root.join("lib")) do
- exclusions = %w(
- bundler/capistrano.rb
- bundler/gem_tasks.rb
- bundler/vlad.rb
- )
- lib_files = `git ls-files -z`.split("\x0").grep(/\.rb$/) - exclusions
- lib_files.reject! {|f| f.start_with?("bundler/vendor") }
+ Dir.chdir(root) do
+ exclusions = %w[
+ lib/bundler/capistrano.rb
+ lib/bundler/deployment.rb
+ lib/bundler/gem_tasks.rb
+ lib/bundler/vlad.rb
+ lib/bundler/templates/gems.rb
+ ]
+ lib_files = `git ls-files -z -- lib`.split("\x0").grep(/\.rb$/) - exclusions
+ lib_files.reject! {|f| f.start_with?("lib/bundler/vendor") }
lib_files.map! {|f| f.chomp(".rb") }
- sys_exec!("ruby -w -I.") do |input, _, _|
+ sys_exec!("ruby -w -Ilib") do |input, _, _|
lib_files.each do |f|
- input.puts "require '#{f}'"
+ input.puts "require '#{f.sub(%r{\Alib/}, "")}'"
end
end
- expect(@err.split("\n")).to be_well_formed
- expect(@out.split("\n")).to be_well_formed
+ expect(last_command.stdboth.split("\n")).to be_well_formed
end
end
end
diff --git a/spec/bundler/realworld/dependency_api_spec.rb b/spec/bundler/realworld/dependency_api_spec.rb
index 468fa3644c..13527ce5d1 100644
--- a/spec/bundler/realworld/dependency_api_spec.rb
+++ b/spec/bundler/realworld/dependency_api_spec.rb
@@ -1,5 +1,4 @@
# frozen_string_literal: true
-require "spec_helper"
RSpec.describe "gemcutter's dependency API", :realworld => true do
context "when Gemcutter API takes too long to respond" do
@@ -23,6 +22,7 @@ RSpec.describe "gemcutter's dependency API", :realworld => true do
@t.run
wait_for_server("127.0.0.1", port)
+ bundle! "config timeout 1"
end
after do
@@ -32,16 +32,11 @@ RSpec.describe "gemcutter's dependency API", :realworld => true do
end
it "times out and falls back on the modern index" do
- gemfile <<-G
+ install_gemfile! <<-G, :artifice => nil
source "#{@server_uri}"
gem "rack"
-
- old_v, $VERBOSE = $VERBOSE, nil
- Bundler::Fetcher.api_timeout = 1
- $VERBOSE = old_v
G
- bundle :install
expect(out).to include("Fetching source index from #{@server_uri}/")
expect(the_bundle).to include_gems "rack 1.0.0"
end
diff --git a/spec/bundler/realworld/edgecases_spec.rb b/spec/bundler/realworld/edgecases_spec.rb
index 302fd57cf0..aa60e20b8a 100644
--- a/spec/bundler/realworld/edgecases_spec.rb
+++ b/spec/bundler/realworld/edgecases_spec.rb
@@ -1,19 +1,22 @@
# frozen_string_literal: true
-require "spec_helper"
RSpec.describe "real world edgecases", :realworld => true, :sometimes => true do
def rubygems_version(name, requirement)
- require "bundler/source/rubygems/remote"
- require "bundler/fetcher"
- source = Bundler::Source::Rubygems::Remote.new(URI("https://rubygems.org"))
- fetcher = Bundler::Fetcher.new(source)
- index = fetcher.specs([name], nil)
- rubygem = index.search(Gem::Dependency.new(name, requirement)).last
- if rubygem.nil?
- raise "Could not find #{name} (#{requirement}) on rubygems.org!\n" \
- "Found specs:\n#{index.send(:specs).inspect}"
- end
- "#{name} (#{rubygem.version})"
+ ruby! <<-RUBY
+ require #{File.expand_path("../../support/artifice/vcr.rb", __FILE__).dump}
+ require "bundler"
+ require "bundler/source/rubygems/remote"
+ require "bundler/fetcher"
+ source = Bundler::Source::Rubygems::Remote.new(URI("https://rubygems.org"))
+ fetcher = Bundler::Fetcher.new(source)
+ index = fetcher.specs([#{name.dump}], nil)
+ rubygem = index.search(Gem::Dependency.new(#{name.dump}, #{requirement.dump})).last
+ if rubygem.nil?
+ raise "Could not find #{name} (#{requirement}) on rubygems.org!\n" \
+ "Found specs:\n\#{index.send(:specs).inspect}"
+ end
+ "#{name} (\#{rubygem.version})"
+ RUBY
end
# there is no rbx-relative-require gem that will install on 1.9
@@ -76,7 +79,7 @@ RSpec.describe "real world edgecases", :realworld => true, :sometimes => true do
gem "gxapi_rails", "< 0.1.0" # 0.1.0 was released way after the test was written
gem 'rack-cache', '1.2.0' # last version that works on Ruby 1.9
G
- bundle :lock
+ bundle! :lock
expect(lockfile).to include("gxapi_rails (0.0.6)")
end
@@ -89,7 +92,7 @@ RSpec.describe "real world edgecases", :realworld => true, :sometimes => true do
gem "activerecord", "~> 3.0"
gem "builder", "~> 2.1.2"
G
- bundle :lock
+ bundle! :lock
expect(lockfile).to include(rubygems_version("i18n", "~> 0.6.0"))
expect(lockfile).to include(rubygems_version("activesupport", "~> 3.0"))
end
@@ -220,9 +223,6 @@ RSpec.describe "real world edgecases", :realworld => true, :sometimes => true do
DEPENDENCIES
paperclip (~> 5.1.0)
rails (~> 4.2.7.1)
-
- BUNDLED WITH
- 1.13.1
L
bundle! "lock --update paperclip"
@@ -239,7 +239,7 @@ RSpec.describe "real world edgecases", :realworld => true, :sometimes => true do
gem 'rack', '1.0.1'
G
- bundle "install --path vendor/bundle"
+ bundle! :install, forgotten_command_line_options(:path => "vendor/bundle")
expect(err).not_to include("Could not find rake")
expect(err).to lack_errors
end
@@ -247,6 +247,7 @@ RSpec.describe "real world edgecases", :realworld => true, :sometimes => true do
it "checks out git repos when the lockfile is corrupted" do
gemfile <<-G
source "https://rubygems.org"
+ git_source(:github) {|repo| "https://github.com/\#{repo}.git" }
gem 'activerecord', :github => 'carlhuda/rails-bundler-test', :branch => 'master'
gem 'activesupport', :github => 'carlhuda/rails-bundler-test', :branch => 'master'
@@ -255,7 +256,7 @@ RSpec.describe "real world edgecases", :realworld => true, :sometimes => true do
lockfile <<-L
GIT
- remote: git://github.com/carlhuda/rails-bundler-test.git
+ remote: https://github.com/carlhuda/rails-bundler-test.git
revision: 369e28a87419565f1940815219ea9200474589d4
branch: master
specs:
@@ -282,7 +283,7 @@ RSpec.describe "real world edgecases", :realworld => true, :sometimes => true do
multi_json (~> 1.0)
GIT
- remote: git://github.com/carlhuda/rails-bundler-test.git
+ remote: https://github.com/carlhuda/rails-bundler-test.git
revision: 369e28a87419565f1940815219ea9200474589d4
branch: master
specs:
@@ -309,7 +310,7 @@ RSpec.describe "real world edgecases", :realworld => true, :sometimes => true do
multi_json (~> 1.0)
GIT
- remote: git://github.com/carlhuda/rails-bundler-test.git
+ remote: https://github.com/carlhuda/rails-bundler-test.git
revision: 369e28a87419565f1940815219ea9200474589d4
branch: master
specs:
@@ -366,9 +367,8 @@ RSpec.describe "real world edgecases", :realworld => true, :sometimes => true do
activesupport!
L
- bundle :lock
- expect(err).to eq("")
- expect(exitstatus).to eq(0) if exitstatus
+ bundle! :lock
+ expect(last_command.stderr).to lack_errors
end
it "outputs a helpful error message when gems have invalid gemspecs" do
diff --git a/spec/bundler/realworld/gemfile_source_header_spec.rb b/spec/bundler/realworld/gemfile_source_header_spec.rb
index ba888d43bd..59c1916874 100644
--- a/spec/bundler/realworld/gemfile_source_header_spec.rb
+++ b/spec/bundler/realworld/gemfile_source_header_spec.rb
@@ -1,5 +1,5 @@
# frozen_string_literal: true
-require "spec_helper"
+
require "thread"
RSpec.describe "fetching dependencies with a mirrored source", :realworld => true, :rubygems => ">= 2.0" do
@@ -23,7 +23,7 @@ RSpec.describe "fetching dependencies with a mirrored source", :realworld => tru
gem 'weakling'
G
- bundle :install
+ bundle :install, :artifice => nil
expect(out).to include("Installing weakling")
expect(out).to include("Bundle complete")
diff --git a/spec/bundler/realworld/mirror_probe_spec.rb b/spec/bundler/realworld/mirror_probe_spec.rb
index 93dca0c173..ab74886329 100644
--- a/spec/bundler/realworld/mirror_probe_spec.rb
+++ b/spec/bundler/realworld/mirror_probe_spec.rb
@@ -1,5 +1,5 @@
# frozen_string_literal: true
-require "spec_helper"
+
require "thread"
RSpec.describe "fetching dependencies with a not available mirror", :realworld => true do
@@ -32,7 +32,7 @@ RSpec.describe "fetching dependencies with a not available mirror", :realworld =
gem 'weakling'
G
- bundle :install
+ bundle :install, :artifice => nil
expect(out).to include("Installing weakling")
expect(out).to include("Bundle complete")
@@ -52,7 +52,7 @@ RSpec.describe "fetching dependencies with a not available mirror", :realworld =
gem 'weakling'
G
- bundle :install
+ bundle :install, :artifice => nil
expect(out).to include("Installing weakling")
expect(out).to include("Bundle complete")
@@ -71,7 +71,7 @@ RSpec.describe "fetching dependencies with a not available mirror", :realworld =
gem 'weakling'
G
- bundle :install
+ bundle :install, :artifice => nil
expect(out).to include("Fetching source index from #{mirror}")
expect(out).to include("Retrying fetcher due to error (2/4): Bundler::HTTPError Could not fetch specs from #{mirror}")
@@ -86,14 +86,15 @@ RSpec.describe "fetching dependencies with a not available mirror", :realworld =
gem 'weakling'
G
- bundle :install
-
- expect(out).to eq "Fetching source index from #{mirror}/
+ bundle :install, :artifice => nil
+ expect(last_command.stdout).to include "Fetching source index from #{mirror}/"
+ expect(last_command.bundler_err).to include <<-EOS.strip
Retrying fetcher due to error (2/4): Bundler::HTTPError Could not fetch specs from #{mirror}/
Retrying fetcher due to error (3/4): Bundler::HTTPError Could not fetch specs from #{mirror}/
Retrying fetcher due to error (4/4): Bundler::HTTPError Could not fetch specs from #{mirror}/
-Could not fetch specs from #{mirror}/"
+Could not fetch specs from #{mirror}/
+ EOS
end
end
@@ -108,7 +109,7 @@ Could not fetch specs from #{mirror}/"
gem 'weakling'
G
- bundle :install
+ bundle :install, :artifice => nil
expect(out).to include("Fetching source index from #{mirror}")
expect(out).to include("Retrying fetcher due to error (2/4): Bundler::HTTPError Could not fetch specs from #{mirror}")
diff --git a/spec/bundler/realworld/parallel_spec.rb b/spec/bundler/realworld/parallel_spec.rb
index 6950bead19..ed4430c68b 100644
--- a/spec/bundler/realworld/parallel_spec.rb
+++ b/spec/bundler/realworld/parallel_spec.rb
@@ -1,5 +1,4 @@
# frozen_string_literal: true
-require "spec_helper"
RSpec.describe "parallel", :realworld => true, :sometimes => true do
it "installs" do
@@ -18,14 +17,11 @@ RSpec.describe "parallel", :realworld => true, :sometimes => true do
expect(out).to include("is not threadsafe")
end
- bundle "show activesupport"
+ bundle "info activesupport --path"
expect(out).to match(/activesupport/)
- bundle "show faker"
+ bundle "info faker --path"
expect(out).to match(/faker/)
-
- bundle "config jobs"
- expect(out).to match(/: "4"/)
end
it "updates" do
@@ -42,7 +38,7 @@ RSpec.describe "parallel", :realworld => true, :sometimes => true do
gem 'i18n', '~> 0.6.0' # Because 0.7+ requires Ruby 1.9.3+
G
- bundle :update, :jobs => 4, :env => { "DEBUG" => "1" }
+ bundle :update, :jobs => 4, :env => { "DEBUG" => "1" }, :all => bundle_update_requires_all?
if Bundler.rubygems.provides?(">= 2.1.0")
expect(out).to match(/[1-3]: /)
@@ -50,14 +46,11 @@ RSpec.describe "parallel", :realworld => true, :sometimes => true do
expect(out).to include("is not threadsafe")
end
- bundle "show activesupport"
+ bundle "info activesupport --path"
expect(out).to match(/activesupport-3\.2\.\d+/)
- bundle "show faker"
+ bundle "info faker --path"
expect(out).to match(/faker/)
-
- bundle "config jobs"
- expect(out).to match(/: "4"/)
end
it "works with --standalone" do
diff --git a/spec/bundler/resolver/basic_spec.rb b/spec/bundler/resolver/basic_spec.rb
index 9e93847ab5..d5658824ba 100644
--- a/spec/bundler/resolver/basic_spec.rb
+++ b/spec/bundler/resolver/basic_spec.rb
@@ -1,5 +1,4 @@
# frozen_string_literal: true
-require "spec_helper"
RSpec.describe "Resolving" do
before :each do
@@ -9,31 +8,38 @@ RSpec.describe "Resolving" do
it "resolves a single gem" do
dep "rack"
- should_resolve_as %w(rack-1.1)
+ should_resolve_as %w[rack-1.1]
end
it "resolves a gem with dependencies" do
dep "actionpack"
- should_resolve_as %w(actionpack-2.3.5 activesupport-2.3.5 rack-1.0)
+ should_resolve_as %w[actionpack-2.3.5 activesupport-2.3.5 rack-1.0]
end
it "resolves a conflicting index" do
@index = a_conflict_index
dep "my_app"
- should_resolve_as %w(activemodel-3.2.11 builder-3.0.4 grape-0.2.6 my_app-1.0.0)
+ should_resolve_as %w[activemodel-3.2.11 builder-3.0.4 grape-0.2.6 my_app-1.0.0]
end
it "resolves a complex conflicting index" do
@index = a_complex_conflict_index
dep "my_app"
- should_resolve_as %w(a-1.4.0 b-0.3.5 c-3.2 d-0.9.8 my_app-1.1.0)
+ should_resolve_as %w[a-1.4.0 b-0.3.5 c-3.2 d-0.9.8 my_app-1.1.0]
end
it "resolves a index with conflict on child" do
@index = index_with_conflict_on_child
dep "chef_app"
- should_resolve_as %w(berkshelf-2.0.7 chef-10.26 chef_app-1.0.0 json-1.7.7)
+ should_resolve_as %w[berkshelf-2.0.7 chef-10.26 chef_app-1.0.0 json-1.7.7]
+ end
+
+ it "prefers expicitly requested dependencies when resolving an index which would otherwise be ambiguous" do
+ @index = an_ambiguous_index
+ dep "a"
+ dep "b"
+ should_resolve_as %w[a-1.0.0 b-2.0.0 c-1.0.0 d-1.0.0]
end
it "resolves a index with root level conflict on child" do
@@ -42,7 +48,29 @@ RSpec.describe "Resolving" do
dep "activesupport", "~> 3.0"
dep "activerecord", "~> 3.0"
dep "builder", "~> 2.1.2"
- should_resolve_as %w(activesupport-3.0.5 i18n-0.4.2 builder-2.1.2 activerecord-3.0.5 activemodel-3.0.5)
+ should_resolve_as %w[activesupport-3.0.5 i18n-0.4.2 builder-2.1.2 activerecord-3.0.5 activemodel-3.0.5]
+ end
+
+ it "resolves a gem specified with a pre-release version" do
+ dep "activesupport", "~> 3.0.0.beta"
+ dep "activemerchant"
+ should_resolve_as %w[activemerchant-2.3.5 activesupport-3.0.0.beta1]
+ end
+
+ it "doesn't select a pre-release if not specified in the Gemfile" do
+ dep "activesupport"
+ dep "reform"
+ should_resolve_as %w[reform-1.0.0 activesupport-2.3.5]
+ end
+
+ it "doesn't select a pre-release for sub-dependencies" do
+ dep "reform"
+ should_resolve_as %w[reform-1.0.0 activesupport-2.3.5]
+ end
+
+ it "selects a pre-release for sub-dependencies if it's the only option" do
+ dep "need-pre"
+ should_resolve_as %w[need-pre-1.0.0 activesupport-3.0.0.beta1]
end
it "raises an exception if a child dependency is not resolved" do
@@ -55,7 +83,7 @@ RSpec.describe "Resolving" do
it "raises an exception with the minimal set of conflicting dependencies" do
@index = build_index do
- %w(0.9 1.0 2.0).each {|v| gem("a", v) }
+ %w[0.9 1.0 2.0].each {|v| gem("a", v) }
gem("b", "1.0") { dep "a", ">= 2" }
gem("c", "1.0") { dep "a", "< 1" }
end
@@ -88,14 +116,14 @@ Bundler could not find compatible versions for gem "a":
it "should install the latest possible version of a direct requirement with no constraints given" do
@index = a_complicated_index
dep "foo"
- should_resolve_and_include %w(foo-3.0.5)
+ should_resolve_and_include %w[foo-3.0.5]
end
# Issue #3459
it "should install the latest possible version of a direct requirement with constraints given" do
@index = a_complicated_index
dep "foo", ">= 3.0.0"
- should_resolve_and_include %w(foo-3.0.5)
+ should_resolve_and_include %w[foo-3.0.5]
end
it "takes into account required_ruby_version" do
@@ -125,7 +153,7 @@ Bundler could not find compatible versions for gem "a":
deps << Bundler::DepProxy.new(d, "ruby")
end
- should_resolve_and_include %w(foo-1.0.0 bar-1.0.0), [{}, []]
+ should_resolve_and_include %w[foo-1.0.0 bar-1.0.0], [[]]
end
context "conservative" do
@@ -139,7 +167,7 @@ Bundler could not find compatible versions for gem "a":
gem("foo", "1.5.0") { dep "bar", "~> 2.1" }
gem("foo", "1.5.1") { dep "bar", "~> 3.0" }
gem("foo", "2.0.0") { dep "bar", "~> 3.0" }
- gem "bar", %w(2.0.3 2.0.4 2.0.5 2.1.0 2.1.1 3.0.0)
+ gem "bar", %w[2.0.3 2.0.4 2.0.5 2.1.0 2.1.1 3.0.0]
end
dep "foo"
@@ -147,23 +175,23 @@ Bundler could not find compatible versions for gem "a":
@base = Bundler::SpecSet.new([])
# locked represents versions in lockfile
- @locked = locked(%w(foo 1.4.3), %w(bar 2.0.3))
+ @locked = locked(%w[foo 1.4.3], %w[bar 2.0.3])
end
it "resolves all gems to latest patch" do
# strict is not set, so bar goes up a minor version due to dependency from foo 1.4.5
- should_conservative_resolve_and_include :patch, [], %w(foo-1.4.5 bar-2.1.1)
+ should_conservative_resolve_and_include :patch, [], %w[foo-1.4.5 bar-2.1.1]
end
it "resolves all gems to latest patch strict" do
# strict is set, so foo can only go up to 1.4.4 to avoid bar going up a minor version, and bar can go up to 2.0.5
- should_conservative_resolve_and_include [:patch, :strict], [], %w(foo-1.4.4 bar-2.0.5)
+ should_conservative_resolve_and_include [:patch, :strict], [], %w[foo-1.4.4 bar-2.0.5]
end
it "resolves foo only to latest patch - same dependency case" do
- @locked = locked(%w(foo 1.3.7), %w(bar 2.0.3))
+ @locked = locked(%w[foo 1.3.7], %w[bar 2.0.3])
# bar is locked, and the lock holds here because the dependency on bar doesn't change on the matching foo version.
- should_conservative_resolve_and_include :patch, ["foo"], %w(foo-1.3.8 bar-2.0.3)
+ should_conservative_resolve_and_include :patch, ["foo"], %w[foo-1.3.8 bar-2.0.3]
end
it "resolves foo only to latest patch - changing dependency not declared case" do
@@ -173,44 +201,44 @@ Bundler could not find compatible versions for gem "a":
# dependency of "bar", "~> 2.1" -- bar-2.1.1 -- is selected. This is not a bug and follows
# the long-standing documented Conservative Updating behavior of bundle install.
# http://bundler.io/v1.12/man/bundle-install.1.html#CONSERVATIVE-UPDATING
- should_conservative_resolve_and_include :patch, ["foo"], %w(foo-1.4.5 bar-2.1.1)
+ should_conservative_resolve_and_include :patch, ["foo"], %w[foo-1.4.5 bar-2.1.1]
end
it "resolves foo only to latest patch - changing dependency declared case" do
# bar is locked AND a declared dependency in the Gemfile, so it will not move, and therefore
# foo can only move up to 1.4.4.
@base << build_spec("bar", "2.0.3").first
- should_conservative_resolve_and_include :patch, ["foo"], %w(foo-1.4.4 bar-2.0.3)
+ should_conservative_resolve_and_include :patch, ["foo"], %w[foo-1.4.4 bar-2.0.3]
end
it "resolves foo only to latest patch strict" do
# adding strict helps solve the possibly unexpected behavior of bar changing in the prior test case,
# because no versions will be returned for bar ~> 2.1, so the engine falls back to ~> 2.0 (turn on
# debugging to see this happen).
- should_conservative_resolve_and_include [:patch, :strict], ["foo"], %w(foo-1.4.4 bar-2.0.3)
+ should_conservative_resolve_and_include [:patch, :strict], ["foo"], %w[foo-1.4.4 bar-2.0.3]
end
it "resolves bar only to latest patch" do
# bar is locked, so foo can only go up to 1.4.4
- should_conservative_resolve_and_include :patch, ["bar"], %w(foo-1.4.3 bar-2.0.5)
+ should_conservative_resolve_and_include :patch, ["bar"], %w[foo-1.4.3 bar-2.0.5]
end
it "resolves all gems to latest minor" do
# strict is not set, so bar goes up a major version due to dependency from foo 1.4.5
- should_conservative_resolve_and_include :minor, [], %w(foo-1.5.1 bar-3.0.0)
+ should_conservative_resolve_and_include :minor, [], %w[foo-1.5.1 bar-3.0.0]
end
it "resolves all gems to latest minor strict" do
# strict is set, so foo can only go up to 1.5.0 to avoid bar going up a major version
- should_conservative_resolve_and_include [:minor, :strict], [], %w(foo-1.5.0 bar-2.1.1)
+ should_conservative_resolve_and_include [:minor, :strict], [], %w[foo-1.5.0 bar-2.1.1]
end
it "resolves all gems to latest major" do
- should_conservative_resolve_and_include :major, [], %w(foo-2.0.0 bar-3.0.0)
+ should_conservative_resolve_and_include :major, [], %w[foo-2.0.0 bar-3.0.0]
end
it "resolves all gems to latest major strict" do
- should_conservative_resolve_and_include [:major, :strict], [], %w(foo-2.0.0 bar-3.0.0)
+ should_conservative_resolve_and_include [:major, :strict], [], %w[foo-2.0.0 bar-3.0.0]
end
# Why would this happen in real life? If bar 2.2 has a bug that the author of foo wants to bypass
@@ -221,7 +249,7 @@ Bundler could not find compatible versions for gem "a":
gem("foo", "1.4.3") { dep "bar", "~> 2.2" }
gem("foo", "1.4.4") { dep "bar", "~> 2.1.0" }
gem("foo", "1.5.0") { dep "bar", "~> 2.0.0" }
- gem "bar", %w(2.0.5 2.1.1 2.2.3)
+ gem "bar", %w[2.0.5 2.1.1 2.2.3]
end
dep "foo"
@@ -229,29 +257,25 @@ Bundler could not find compatible versions for gem "a":
@base = Bundler::SpecSet.new([])
# locked represents versions in lockfile
- @locked = locked(%w(foo 1.4.3), %w(bar 2.2.3))
+ @locked = locked(%w[foo 1.4.3], %w[bar 2.2.3])
end
it "could revert to a previous version level patch" do
- should_conservative_resolve_and_include :patch, [], %w(foo-1.4.4 bar-2.1.1)
+ should_conservative_resolve_and_include :patch, [], %w[foo-1.4.4 bar-2.1.1]
end
it "cannot revert to a previous version in strict mode level patch" do
- # the strict option removes the version required to match, so a version conflict results
- expect do
- should_conservative_resolve_and_include [:patch, :strict], [], %w(foo-1.4.3 bar-2.1.1)
- end.to raise_error Bundler::VersionConflict, /#{Regexp.escape("Could not find gem 'bar (~> 2.1.0)'")}/
+ # fall back to the locked resolution since strict means we can't regress either version
+ should_conservative_resolve_and_include [:patch, :strict], [], %w[foo-1.4.3 bar-2.2.3]
end
it "could revert to a previous version level minor" do
- should_conservative_resolve_and_include :minor, [], %w(foo-1.5.0 bar-2.0.5)
+ should_conservative_resolve_and_include :minor, [], %w[foo-1.5.0 bar-2.0.5]
end
it "cannot revert to a previous version in strict mode level minor" do
- # the strict option removes the version required to match, so a version conflict results
- expect do
- should_conservative_resolve_and_include [:minor, :strict], [], %w(foo-1.4.3 bar-2.1.1)
- end.to raise_error Bundler::VersionConflict, /#{Regexp.escape("Could not find gem 'bar (~> 2.0.0)'")}/
+ # fall back to the locked resolution since strict means we can't regress either version
+ should_conservative_resolve_and_include [:minor, :strict], [], %w[foo-1.4.3 bar-2.2.3]
end
end
end
diff --git a/spec/bundler/resolver/platform_spec.rb b/spec/bundler/resolver/platform_spec.rb
index 90d6f637ce..fee0cf1f1c 100644
--- a/spec/bundler/resolver/platform_spec.rb
+++ b/spec/bundler/resolver/platform_spec.rb
@@ -1,5 +1,4 @@
# frozen_string_literal: true
-require "spec_helper"
RSpec.describe "Resolving platform craziness" do
describe "with cross-platform gems" do
@@ -11,21 +10,21 @@ RSpec.describe "Resolving platform craziness" do
dep "nokogiri"
platforms "ruby", "java"
- should_resolve_as %w(nokogiri-1.4.2 nokogiri-1.4.2-java weakling-0.0.3)
+ should_resolve_as %w[nokogiri-1.4.2 nokogiri-1.4.2-java weakling-0.0.3]
end
it "doesn't pull gems that don't exist for the current platform" do
dep "nokogiri"
platforms "ruby"
- should_resolve_as %w(nokogiri-1.4.2)
+ should_resolve_as %w[nokogiri-1.4.2]
end
it "doesn't pull gems when the version is available for all requested platforms" do
dep "nokogiri"
platforms "mswin32"
- should_resolve_as %w(nokogiri-1.4.2.1-x86-mswin32)
+ should_resolve_as %w[nokogiri-1.4.2.1-x86-mswin32]
end
end
@@ -43,32 +42,32 @@ RSpec.describe "Resolving platform craziness" do
# win32 is hardcoded to get CPU x86 in rubygems
platforms "mswin32"
dep "thin"
- should_resolve_as %w(thin-1.2.7-x86-mswin32)
+ should_resolve_as %w[thin-1.2.7-x86-mswin32]
end
it "finds mingw gems" do
# mingw is _not_ hardcoded to add CPU x86 in rubygems
platforms "x86-mingw32"
dep "thin"
- should_resolve_as %w(thin-1.2.7-mingw32)
+ should_resolve_as %w[thin-1.2.7-mingw32]
end
it "finds x64-mingw gems" do
platforms "x64-mingw32"
dep "thin"
- should_resolve_as %w(thin-1.2.7-x64-mingw32)
+ should_resolve_as %w[thin-1.2.7-x64-mingw32]
end
it "finds universal-mingw gems on x86-mingw" do
platform "x86-mingw32"
dep "win32-api"
- should_resolve_as %w(win32-api-1.5.1-universal-mingw32)
+ should_resolve_as %w[win32-api-1.5.1-universal-mingw32]
end
it "finds universal-mingw gems on x64-mingw" do
platform "x64-mingw32"
dep "win32-api"
- should_resolve_as %w(win32-api-1.5.1-universal-mingw32)
+ should_resolve_as %w[win32-api-1.5.1-universal-mingw32]
end
end
@@ -87,7 +86,7 @@ RSpec.describe "Resolving platform craziness" do
dep "baz", " ~> 1.1.0"
end
- gem "baz", %w(1.0.0 1.1.0 1.2.0)
+ gem "baz", %w[1.0.0 1.1.0 1.2.0]
end
end
diff --git a/spec/bundler/runtime/executable_spec.rb b/spec/bundler/runtime/executable_spec.rb
index ff27d0b415..388ee049d0 100644
--- a/spec/bundler/runtime/executable_spec.rb
+++ b/spec/bundler/runtime/executable_spec.rb
@@ -1,16 +1,15 @@
# frozen_string_literal: true
-require "spec_helper"
RSpec.describe "Running bin/* commands" do
before :each do
- gemfile <<-G
+ install_gemfile! <<-G
source "file://#{gem_repo1}"
gem "rack"
G
end
it "runs the bundled command when in the bundle" do
- bundle "install --binstubs"
+ bundle! "binstubs rack"
build_gem "rack", "2.0", :to_system => true do |s|
s.executables = "rackup"
@@ -21,7 +20,7 @@ RSpec.describe "Running bin/* commands" do
end
it "allows the location of the gem stubs to be specified" do
- bundle "install --binstubs gbin"
+ bundle! "binstubs rack", :path => "gbin"
expect(bundled_app("bin")).not_to exist
expect(bundled_app("gbin/rackup")).to exist
@@ -31,24 +30,24 @@ RSpec.describe "Running bin/* commands" do
end
it "allows absolute paths as a specification of where to install bin stubs" do
- bundle "install --binstubs #{tmp}/bin"
+ bundle! "binstubs rack", :path => tmp("bin")
gembin tmp("bin/rackup")
expect(out).to eq("1.0.0")
end
it "uses the default ruby install name when shebang is not specified" do
- bundle "install --binstubs"
+ bundle! "binstubs rack"
expect(File.open("bin/rackup").gets).to eq("#!/usr/bin/env #{RbConfig::CONFIG["ruby_install_name"]}\n")
end
it "allows the name of the shebang executable to be specified" do
- bundle "install --binstubs --shebang ruby-foo"
+ bundle! "binstubs rack", :shebang => "ruby-foo"
expect(File.open("bin/rackup").gets).to eq("#!/usr/bin/env ruby-foo\n")
end
it "runs the bundled command when out of the bundle" do
- bundle "install --binstubs"
+ bundle! "binstubs rack"
build_gem "rack", "2.0", :to_system => true do |s|
s.executables = "rackup"
@@ -69,7 +68,7 @@ RSpec.describe "Running bin/* commands" do
gem "rack", :path => "#{lib_path("rack")}"
G
- bundle "install --binstubs"
+ bundle! "binstubs rack"
build_gem "rack", "2.0", :to_system => true do |s|
s.executables = "rackup"
@@ -79,7 +78,7 @@ RSpec.describe "Running bin/* commands" do
expect(out).to eq("1.0")
end
- it "don't bundle da bundla" do
+ it "creates a bundle binstub" do
build_gem "bundler", Bundler::VERSION, :to_system => true do |s|
s.executables = "bundle"
end
@@ -89,35 +88,35 @@ RSpec.describe "Running bin/* commands" do
gem "bundler"
G
- bundle "install --binstubs"
+ bundle! "binstubs bundler"
- expect(bundled_app("bin/bundle")).not_to exist
+ expect(bundled_app("bin/bundle")).to exist
end
it "does not generate bin stubs if the option was not specified" do
- bundle "install"
+ bundle! "install"
expect(bundled_app("bin/rackup")).not_to exist
end
- it "allows you to stop installing binstubs" do
- bundle "install --binstubs bin/"
+ it "allows you to stop installing binstubs", :bundler => "< 2" do
+ bundle! "install --binstubs bin/"
bundled_app("bin/rackup").rmtree
- bundle "install --binstubs \"\""
+ bundle! "install --binstubs \"\""
expect(bundled_app("bin/rackup")).not_to exist
- bundle "config bin"
+ bundle! "config bin"
expect(out).to include("You have not configured a value for `bin`")
end
- it "remembers that the option was specified" do
+ it "remembers that the option was specified", :bundler => "< 2" do
gemfile <<-G
source "file://#{gem_repo1}"
gem "activesupport"
G
- bundle "install --binstubs"
+ bundle! :install, forgotten_command_line_options([:binstubs, :bin] => "bin")
gemfile <<-G
source "file://#{gem_repo1}"
@@ -130,13 +129,13 @@ RSpec.describe "Running bin/* commands" do
expect(bundled_app("bin/rackup")).to exist
end
- it "rewrites bins on --binstubs (to maintain backwards compatibility)" do
+ it "rewrites bins on --binstubs (to maintain backwards compatibility)", :bundler => "< 2" do
gemfile <<-G
source "file://#{gem_repo1}"
gem "rack"
G
- bundle "install --binstubs bin/"
+ bundle! :install, forgotten_command_line_options([:binstubs, :bin] => "bin")
File.open(bundled_app("bin/rackup"), "wb") do |file|
file.print "OMG"
@@ -146,4 +145,17 @@ RSpec.describe "Running bin/* commands" do
expect(bundled_app("bin/rackup").read).to_not eq("OMG")
end
+
+ it "rewrites bins on binstubs (to maintain backwards compatibility)" do
+ install_gemfile! <<-G
+ source "file://#{gem_repo1}"
+ gem "rack"
+ G
+
+ create_file("bin/rackup", "OMG")
+
+ bundle! "binstubs rack"
+
+ expect(bundled_app("bin/rackup").read).to_not eq("OMG")
+ end
end
diff --git a/spec/bundler/runtime/gem_tasks_spec.rb b/spec/bundler/runtime/gem_tasks_spec.rb
index 7cb0f32c0c..500c3128fd 100644
--- a/spec/bundler/runtime/gem_tasks_spec.rb
+++ b/spec/bundler/runtime/gem_tasks_spec.rb
@@ -1,5 +1,4 @@
# frozen_string_literal: true
-require "spec_helper"
RSpec.describe "require 'bundler/gem_tasks'" do
before :each do
diff --git a/spec/bundler/runtime/inline_spec.rb b/spec/bundler/runtime/inline_spec.rb
index e816799d08..dcaba3ab9d 100644
--- a/spec/bundler/runtime/inline_spec.rb
+++ b/spec/bundler/runtime/inline_spec.rb
@@ -1,5 +1,4 @@
# frozen_string_literal: true
-require "spec_helper"
RSpec.describe "bundler/inline#gemfile" do
def script(code, options = {})
@@ -53,8 +52,9 @@ RSpec.describe "bundler/inline#gemfile" do
it "requires the gems" do
script <<-RUBY
gemfile do
- path "#{lib_path}"
- gem "two"
+ path "#{lib_path}" do
+ gem "two"
+ end
end
RUBY
@@ -63,8 +63,9 @@ RSpec.describe "bundler/inline#gemfile" do
script <<-RUBY
gemfile do
- path "#{lib_path}"
- gem "eleven"
+ path "#{lib_path}" do
+ gem "eleven"
+ end
end
puts "success"
@@ -133,8 +134,9 @@ RSpec.describe "bundler/inline#gemfile" do
require 'bundler'
options = { :ui => Bundler::UI::Shell.new }
gemfile(false, options) do
- path "#{lib_path}"
- gem "two"
+ path "#{lib_path}" do
+ gem "two"
+ end
end
puts "OKAY" if options.key?(:ui)
RUBY
@@ -262,7 +264,7 @@ RSpec.describe "bundler/inline#gemfile" do
puts RACK
RUBY
- expect(exitstatus).to eq(0) if exitstatus
- expect(out).to eq "1.0.0"
+ expect(last_command).to be_success
+ expect(last_command.stdout).to eq "1.0.0"
end
end
diff --git a/spec/bundler/runtime/load_spec.rb b/spec/bundler/runtime/load_spec.rb
index d0e308ed3e..b74dbde3f6 100644
--- a/spec/bundler/runtime/load_spec.rb
+++ b/spec/bundler/runtime/load_spec.rb
@@ -1,14 +1,9 @@
# frozen_string_literal: true
-require "spec_helper"
RSpec.describe "Bundler.load" do
- before :each do
- system_gems "rack-1.0.0"
- end
-
describe "with a gemfile" do
before(:each) do
- gemfile <<-G
+ install_gemfile! <<-G
source "file://#{gem_repo1}"
gem "rack"
G
@@ -36,6 +31,7 @@ RSpec.describe "Bundler.load" do
source "file://#{gem_repo1}"
gem "rack"
G
+ bundle! :install
end
it "provides a list of the env dependencies" do
@@ -77,13 +73,13 @@ RSpec.describe "Bundler.load" do
describe "when called twice" do
it "doesn't try to load the runtime twice" do
- system_gems "rack-1.0.0", "activesupport-2.3.5"
- gemfile <<-G
+ install_gemfile! <<-G
+ source "file:#{gem_repo1}"
gem "rack"
gem "activesupport", :group => :test
G
- ruby <<-RUBY
+ ruby! <<-RUBY
require "bundler"
Bundler.setup :default
Bundler.require :default
@@ -101,8 +97,8 @@ RSpec.describe "Bundler.load" do
describe "not hurting brittle rubygems" do
it "does not inject #source into the generated YAML of the gem specs" do
- system_gems "activerecord-2.3.2", "activesupport-2.3.2"
- gemfile <<-G
+ install_gemfile! <<-G
+ source "file:#{gem_repo1}"
gem "activerecord"
G
diff --git a/spec/bundler/runtime/platform_spec.rb b/spec/bundler/runtime/platform_spec.rb
index 4df934e71f..f38f733845 100644
--- a/spec/bundler/runtime/platform_spec.rb
+++ b/spec/bundler/runtime/platform_spec.rb
@@ -1,5 +1,4 @@
# frozen_string_literal: true
-require "spec_helper"
RSpec.describe "Bundler.setup with multi platform stuff" do
it "raises a friendly error when gems are missing locally" do
@@ -33,7 +32,7 @@ RSpec.describe "Bundler.setup with multi platform stuff" do
expect(out).to eq("WIN")
end
- it "will resolve correctly on the current platform when the lockfile was targetted for a different one" do
+ it "will resolve correctly on the current platform when the lockfile was targeted for a different one" do
lockfile <<-G
GEM
remote: file:#{gem_repo1}/
@@ -49,10 +48,8 @@ RSpec.describe "Bundler.setup with multi platform stuff" do
nokogiri
G
- system_gems "nokogiri-1.4.2"
-
simulate_platform "x86-darwin-10"
- gemfile <<-G
+ install_gemfile! <<-G
source "file://#{gem_repo1}"
gem "nokogiri"
G
@@ -78,9 +75,7 @@ RSpec.describe "Bundler.setup with multi platform stuff" do
simulate_platform "x86-darwin-100"
- system_gems "nokogiri-1.4.2", "platform_specific-1.0-x86-darwin-100"
-
- gemfile <<-G
+ install_gemfile! <<-G
source "file://#{gem_repo1}"
gem "nokogiri"
gem "platform_specific"
diff --git a/spec/bundler/runtime/require_spec.rb b/spec/bundler/runtime/require_spec.rb
index b68313726b..3eccd60fba 100644
--- a/spec/bundler/runtime/require_spec.rb
+++ b/spec/bundler/runtime/require_spec.rb
@@ -1,5 +1,4 @@
# frozen_string_literal: true
-require "spec_helper"
RSpec.describe "Bundler.require" do
before :each do
@@ -47,19 +46,20 @@ RSpec.describe "Bundler.require" do
end
gemfile <<-G
- path "#{lib_path}"
- gem "one", :group => :bar, :require => %w[baz qux]
- gem "two"
- gem "three", :group => :not
- gem "four", :require => false
- gem "five"
- gem "six", :group => "string"
- gem "seven", :group => :not
- gem "eight", :require => true, :group => :require_true
- env "BUNDLER_TEST" => "nine" do
- gem "nine", :require => true
+ path "#{lib_path}" do
+ gem "one", :group => :bar, :require => %w[baz qux]
+ gem "two"
+ gem "three", :group => :not
+ gem "four", :require => false
+ gem "five"
+ gem "six", :group => "string"
+ gem "seven", :group => :not
+ gem "eight", :require => true, :group => :require_true
+ env "BUNDLER_TEST" => "nine" do
+ gem "nine", :require => true
+ end
+ gem "ten", :install_if => lambda { ENV["BUNDLER_TEST"] == "ten" }
end
- gem "ten", :install_if => lambda { ENV["BUNDLER_TEST"] == "ten" }
G
end
@@ -86,7 +86,7 @@ RSpec.describe "Bundler.require" do
# required in resolver order instead of gemfile order
run("Bundler.require(:not)")
- expect(out.split("\n").sort).to eq(%w(seven three))
+ expect(out.split("\n").sort).to eq(%w[seven three])
# test require: true
run "Bundler.require(:require_true)"
@@ -112,8 +112,9 @@ RSpec.describe "Bundler.require" do
it "raises an exception if a require is specified but the file does not exist" do
gemfile <<-G
- path "#{lib_path}"
- gem "two", :require => 'fail'
+ path "#{lib_path}" do
+ gem "two", :require => 'fail'
+ end
G
load_error_run <<-R, "fail"
@@ -129,8 +130,9 @@ RSpec.describe "Bundler.require" do
end
gemfile <<-G
- path "#{lib_path}"
- gem "faulty"
+ path "#{lib_path}" do
+ gem "faulty"
+ end
G
run "Bundler.require"
@@ -144,8 +146,9 @@ RSpec.describe "Bundler.require" do
end
gemfile <<-G
- path "#{lib_path}"
- gem "loadfuuu"
+ path "#{lib_path}" do
+ gem "loadfuuu"
+ end
G
cmd = <<-RUBY
@@ -170,8 +173,9 @@ RSpec.describe "Bundler.require" do
it "requires gem names that are namespaced" do
gemfile <<-G
- path '#{lib_path}'
- gem 'jquery-rails'
+ path '#{lib_path}' do
+ gem 'jquery-rails'
+ end
G
run "Bundler.require"
@@ -183,8 +187,9 @@ RSpec.describe "Bundler.require" do
s.write "lib/brcrypt.rb", "BCrypt = '1.0.0'"
end
gemfile <<-G
- path "#{lib_path}"
- gem "bcrypt-ruby"
+ path "#{lib_path}" do
+ gem "bcrypt-ruby"
+ end
G
cmd = <<-RUBY
@@ -198,8 +203,9 @@ RSpec.describe "Bundler.require" do
it "does not mangle explicitly given requires" do
gemfile <<-G
- path "#{lib_path}"
- gem 'jquery-rails', :require => 'jquery-rails'
+ path "#{lib_path}" do
+ gem 'jquery-rails', :require => 'jquery-rails'
+ end
G
load_error_run <<-R, "jquery-rails"
@@ -214,8 +220,9 @@ RSpec.describe "Bundler.require" do
end
gemfile <<-G
- path "#{lib_path}"
- gem "load-fuuu"
+ path "#{lib_path}" do
+ gem "load-fuuu"
+ end
G
cmd = <<-RUBY
@@ -237,8 +244,9 @@ RSpec.describe "Bundler.require" do
lib_path("load-fuuu-1.0.0/lib/load-fuuu.rb").rmtree
gemfile <<-G
- path "#{lib_path}"
- gem "load-fuuu"
+ path "#{lib_path}" do
+ gem "load-fuuu"
+ end
G
cmd = <<-RUBY
@@ -294,9 +302,10 @@ RSpec.describe "Bundler.require" do
it "works when the gems are in the Gemfile in the correct order" do
gemfile <<-G
- path "#{lib_path}"
- gem "two"
- gem "one"
+ path "#{lib_path}" do
+ gem "two"
+ gem "one"
+ end
G
run "Bundler.require"
@@ -305,7 +314,7 @@ RSpec.describe "Bundler.require" do
describe "a gem with different requires for different envs" do
before(:each) do
- build_gem "multi_gem", :to_system => true do |s|
+ build_gem "multi_gem", :to_bundle => true do |s|
s.write "lib/one.rb", "puts 'ONE'"
s.write "lib/two.rb", "puts 'TWO'"
end
@@ -334,9 +343,10 @@ RSpec.describe "Bundler.require" do
it "fails when the gems are in the Gemfile in the wrong order" do
gemfile <<-G
- path "#{lib_path}"
- gem "one"
- gem "two"
+ path "#{lib_path}" do
+ gem "one"
+ gem "two"
+ end
G
run "Bundler.require"
@@ -345,7 +355,7 @@ RSpec.describe "Bundler.require" do
describe "with busted gems" do
it "should be busted" do
- build_gem "busted_require", :to_system => true do |s|
+ build_gem "busted_require", :to_bundle => true do |s|
s.write "lib/busted_require.rb", "require 'no_such_file_omg'"
end
diff --git a/spec/bundler/runtime/setup_spec.rb b/spec/bundler/runtime/setup_spec.rb
index dc7af07188..8f6f656359 100644
--- a/spec/bundler/runtime/setup_spec.rb
+++ b/spec/bundler/runtime/setup_spec.rb
@@ -1,5 +1,4 @@
# frozen_string_literal: true
-require "spec_helper"
RSpec.describe "Bundler.setup" do
describe "with no arguments" do
@@ -117,7 +116,7 @@ RSpec.describe "Bundler.setup" do
tmp("rubygems/lib").to_s,
root.join("../lib").expand_path.to_s,
] - without_bundler_load_path
- lp.map! {|p| p.sub(/^#{system_gem_path}/, "") }
+ lp.map! {|p| p.sub(/^#{Regexp.union system_gem_path.to_s, default_bundle_path.to_s}/i, "") }
end
it "puts loaded gems after -I and RUBYLIB", :ruby_repo do
@@ -270,21 +269,51 @@ RSpec.describe "Bundler.setup" do
expect(bundled_app("Gemfile.lock")).to exist
end
- it "uses BUNDLE_GEMFILE to locate the gemfile if present" do
- gemfile <<-G
- source "file://#{gem_repo1}"
- gem "rack"
- G
+ describe "$BUNDLE_GEMFILE" do
+ context "user provides an absolute path" do
+ it "uses BUNDLE_GEMFILE to locate the gemfile if present" do
+ gemfile <<-G
+ source "file://#{gem_repo1}"
+ gem "rack"
+ G
- gemfile bundled_app("4realz"), <<-G
- source "file://#{gem_repo1}"
- gem "activesupport", "2.3.5"
- G
+ gemfile bundled_app("4realz"), <<-G
+ source "file://#{gem_repo1}"
+ gem "activesupport", "2.3.5"
+ G
+
+ ENV["BUNDLE_GEMFILE"] = bundled_app("4realz").to_s
+ bundle :install
+
+ expect(the_bundle).to include_gems "activesupport 2.3.5"
+ end
+ end
+
+ context "an absolute path is not provided" do
+ it "uses BUNDLE_GEMFILE to locate the gemfile if present" do
+ gemfile <<-G
+ source "file://#{gem_repo1}"
+ G
+
+ bundle "install"
+ bundle "install --deployment"
+
+ ENV["BUNDLE_GEMFILE"] = "Gemfile"
+ ruby <<-R
+ require 'rubygems'
+ require 'bundler'
- ENV["BUNDLE_GEMFILE"] = bundled_app("4realz").to_s
- bundle :install
+ begin
+ Bundler.setup
+ puts "WIN"
+ rescue ArgumentError => e
+ puts "FAIL"
+ end
+ R
- expect(the_bundle).to include_gems "activesupport 2.3.5"
+ expect(out).to eq("WIN")
+ end
+ end
end
it "prioritizes gems in BUNDLE_PATH over gems in GEM_HOME" do
@@ -396,9 +425,10 @@ RSpec.describe "Bundler.setup" do
end
gemfile <<-G
- path "#{lib_path("rack-1.0.0")}"
source "file://#{gem_repo1}"
- gem "rack"
+ path "#{lib_path("rack-1.0.0")}" do
+ gem "rack"
+ end
G
run "require 'rack'"
@@ -465,13 +495,13 @@ RSpec.describe "Bundler.setup" do
end
it "works even when the cache directory has been deleted" do
- bundle "install --path vendor/bundle"
+ bundle! :install, forgotten_command_line_options(:path => "vendor/bundle")
FileUtils.rm_rf vendored_gems("cache")
expect(the_bundle).to include_gems "rack 1.0.0"
end
it "does not randomly change the path when specifying --path and the bundle directory becomes read only" do
- bundle "install --path vendor/bundle"
+ bundle! :install, forgotten_command_line_options(:path => "vendor/bundle")
with_read_only("**/*") do
expect(the_bundle).to include_gems "rack 1.0.0"
@@ -499,8 +529,7 @@ RSpec.describe "Bundler.setup" do
G
bundle %(config local.rack #{lib_path("local-rack")})
- bundle :install
- expect(out).to match(/at #{lib_path('local-rack')}/)
+ bundle! :install
FileUtils.rm_rf(lib_path("local-rack"))
run "require 'rack'"
@@ -518,8 +547,7 @@ RSpec.describe "Bundler.setup" do
G
bundle %(config local.rack #{lib_path("local-rack")})
- bundle :install
- expect(out).to match(/at #{lib_path('local-rack')}/)
+ bundle! :install
gemfile <<-G
source "file://#{gem_repo1}"
@@ -541,8 +569,7 @@ RSpec.describe "Bundler.setup" do
G
bundle %(config local.rack #{lib_path("local-rack")})
- bundle :install
- expect(out).to match(/at #{lib_path('local-rack')}/)
+ bundle! :install
gemfile <<-G
source "file://#{gem_repo1}"
@@ -576,7 +603,7 @@ RSpec.describe "Bundler.setup" do
describe "when excluding groups" do
it "doesn't change the resolve if --without is used" do
- install_gemfile <<-G, :without => :rails
+ install_gemfile <<-G, forgotten_command_line_options(:without => :rails)
source "file://#{gem_repo1}"
gem "activesupport"
@@ -591,7 +618,7 @@ RSpec.describe "Bundler.setup" do
end
it "remembers --without and does not bail on bare Bundler.setup" do
- install_gemfile <<-G, :without => :rails
+ install_gemfile <<-G, forgotten_command_line_options(:without => :rails)
source "file://#{gem_repo1}"
gem "activesupport"
@@ -606,7 +633,7 @@ RSpec.describe "Bundler.setup" do
end
it "remembers --without and does not include groups passed to Bundler.setup" do
- install_gemfile <<-G, :without => :rails
+ install_gemfile <<-G, forgotten_command_line_options(:without => :rails)
source "file://#{gem_repo1}"
gem "activesupport"
@@ -680,7 +707,7 @@ RSpec.describe "Bundler.setup" do
end
end
- # Rubygems returns loaded_from as a string
+ # RubyGems returns loaded_from as a string
it "has loaded_from as a string on all specs" do
build_git "foo"
build_git "no-gemspec", :gemspec => false
@@ -741,12 +768,50 @@ end
expect(err).to lack_errors
end
+ describe "$MANPATH" do
+ before do
+ build_repo4 do
+ build_gem "with_man" do |s|
+ s.write("man/man1/page.1", "MANPAGE")
+ end
+ end
+ end
+
+ context "when the user has one set" do
+ before { ENV["MANPATH"] = "/foo:" }
+
+ it "adds the gem's man dir to the MANPATH" do
+ install_gemfile! <<-G
+ source "file:#{gem_repo4}"
+ gem "with_man"
+ G
+
+ run! "puts ENV['MANPATH']"
+ expect(out).to eq("#{default_bundle_path("gems/with_man-1.0/man")}:/foo")
+ end
+ end
+
+ context "when the user does not have one set" do
+ before { ENV.delete("MANPATH") }
+
+ it "adds the gem's man dir to the MANPATH" do
+ install_gemfile! <<-G
+ source "file:#{gem_repo4}"
+ gem "with_man"
+ G
+
+ run! "puts ENV['MANPATH']"
+ expect(out).to eq(default_bundle_path("gems/with_man-1.0/man").to_s)
+ end
+ end
+ end
+
it "should prepend gemspec require paths to $LOAD_PATH in order" do
update_repo2 do
build_gem("requirepaths") do |s|
s.write("lib/rq.rb", "puts 'yay'")
s.write("src/rq.rb", "puts 'nooo'")
- s.require_paths = %w(lib src)
+ s.require_paths = %w[lib src]
end
end
@@ -930,6 +995,7 @@ end
describe "with system gems in the bundle" do
before :each do
+ bundle! "config path.system true"
system_gems "rack-1.0.0"
install_gemfile <<-G
@@ -943,7 +1009,6 @@ end
run "puts Gem.path"
paths = out.split("\n")
expect(paths).to include(system_gem_path.to_s)
- expect(paths).to include(default_bundle_path.to_s)
end
end
@@ -1027,7 +1092,7 @@ end
rack (1.0.0)
PLATFORMS
- #{generic_local_platform}
+ #{lockfile_platforms}
DEPENDENCIES
rack
@@ -1085,7 +1150,7 @@ end
rack (1.0.0)
PLATFORMS
- #{generic_local_platform}
+ #{lockfile_platforms}
DEPENDENCIES
rack
@@ -1166,11 +1231,11 @@ end
if Gem::Version.new(Gem::VERSION) >= Gem::Version.new("2.7") || ENV["RGV"] == "master"
[]
else
- %w(io-console openssl)
+ %w[io-console openssl]
end << "bundler"
end
- let(:code) { strip_whitespace(<<-RUBY) }
+ let(:activation_warning_hack) { strip_whitespace(<<-RUBY) }
require "rubygems"
if Gem::Specification.instance_methods.map(&:to_sym).include?(:activate)
@@ -1185,7 +1250,14 @@ end
bundler_spec_activate
end
end
+ RUBY
+
+ let(:activation_warning_hack_rubyopt) do
+ create_file("activation_warning_hack.rb", activation_warning_hack)
+ "-r#{bundled_app("activation_warning_hack.rb")} #{ENV["RUBYOPT"]}"
+ end
+ let(:code) { strip_whitespace(<<-RUBY) }
require "bundler/setup"
require "pp"
loaded_specs = Gem.loaded_specs.dup
@@ -1201,17 +1273,15 @@ end
it "activates no gems with -rbundler/setup" do
install_gemfile! ""
- ruby!(code)
- expect(err).to eq("")
- expect(out).to eq("{}")
+ ruby! code, :env => { :RUBYOPT => activation_warning_hack_rubyopt }
+ expect(last_command.stdout).to eq("{}")
end
it "activates no gems with bundle exec" do
install_gemfile! ""
create_file("script.rb", code)
- bundle! "exec ruby ./script.rb"
- expect(err).to eq("")
- expect(out).to eq("{}")
+ bundle! "exec ruby ./script.rb", :env => { :RUBYOPT => activation_warning_hack_rubyopt }
+ expect(last_command.stdout).to eq("{}")
end
it "activates no gems with bundle exec that is loaded" do
@@ -1221,9 +1291,8 @@ end
install_gemfile! ""
create_file("script.rb", "#!/usr/bin/env ruby\n\n#{code}")
FileUtils.chmod(0o777, bundled_app("script.rb"))
- bundle! "exec ./script.rb", :artifice => nil
- expect(err).to eq("")
- expect(out).to eq("{}")
+ bundle! "exec ./script.rb", :artifice => nil, :env => { :RUBYOPT => activation_warning_hack_rubyopt }
+ expect(last_command.stdout).to eq("{}")
end
let(:default_gems) do
@@ -1241,6 +1310,8 @@ end
end
end
+ default_gems.reject! {|g| exemptions.include?(g) }
+
install_gemfile! <<-G
source "file:#{gem_repo4}"
#{default_gems}.each do |g|
@@ -1273,17 +1344,51 @@ end
end
describe "after setup" do
- it "allows calling #gem on random objects" do
+ it "allows calling #gem on random objects", :bundler => "< 2" do
install_gemfile <<-G
source "file:#{gem_repo1}"
gem "rack"
G
+
ruby! <<-RUBY
require "bundler/setup"
Object.new.gem "rack"
puts Gem.loaded_specs["rack"].full_name
RUBY
+
expect(out).to eq("rack-1.0.0")
end
+
+ it "keeps Kernel#gem private", :bundler => "2" do
+ install_gemfile! <<-G
+ source "file:#{gem_repo1}"
+ gem "rack"
+ G
+
+ ruby <<-RUBY
+ require "bundler/setup"
+ Object.new.gem "rack"
+ puts "FAIL"
+ RUBY
+
+ expect(last_command.stdboth).not_to include "FAIL"
+ expect(last_command.stderr).to include "private method `gem'"
+ end
+
+ it "keeps Kernel#require private" do
+ install_gemfile! <<-G
+ source "file:#{gem_repo1}"
+ gem "rack"
+ G
+
+ ruby <<-RUBY
+ require "bundler/setup"
+ Object.new.require "rack"
+ puts "FAIL"
+ RUBY
+
+ expect(last_command.stdboth).not_to include "FAIL"
+ expect(last_command.stderr).to include "private method `require'"
+ end
end
end
diff --git a/spec/bundler/runtime/with_clean_env_spec.rb b/spec/bundler/runtime/with_clean_env_spec.rb
index d18a0de485..55e45460db 100644
--- a/spec/bundler/runtime/with_clean_env_spec.rb
+++ b/spec/bundler/runtime/with_clean_env_spec.rb
@@ -1,18 +1,18 @@
# frozen_string_literal: true
-require "spec_helper"
RSpec.describe "Bundler.with_env helpers" do
describe "Bundler.original_env" do
before do
+ bundle "config path vendor/bundle"
gemfile ""
- bundle "install --path vendor/bundle"
+ bundle "install"
end
it "should return the PATH present before bundle was activated", :ruby_repo do
code = "print Bundler.original_env['PATH']"
path = `getconf PATH`.strip + "#{File::PATH_SEPARATOR}/foo"
with_path_as(path) do
- result = bundle("exec ruby -e #{code.dump}")
+ result = bundle("exec '#{Gem.ruby}' -e #{code.dump}")
expect(result).to eq(path)
end
end
@@ -21,7 +21,7 @@ RSpec.describe "Bundler.with_env helpers" do
code = "print Bundler.original_env['GEM_PATH']"
gem_path = ENV["GEM_PATH"] + ":/foo"
with_gem_path_as(gem_path) do
- result = bundle("exec ruby -e #{code.inspect}")
+ result = bundle("exec '#{Gem.ruby}' -e #{code.inspect}")
expect(result).to eq(gem_path)
end
end
@@ -34,11 +34,11 @@ RSpec.describe "Bundler.with_env helpers" do
if count == 2
ENV["PATH"] = "#{ENV["PATH"]}:/foo"
end
- exec("ruby", __FILE__, (count - 1).to_s)
+ exec(Gem.ruby, __FILE__, (count - 1).to_s)
RB
path = `getconf PATH`.strip + File::PATH_SEPARATOR + File.dirname(Gem.ruby)
with_path_as(path) do
- bundle!("exec ruby #{bundled_app("exe.rb")} 2")
+ bundle!("exec '#{Gem.ruby}' #{bundled_app("exe.rb")} 2")
end
expect(err).to eq <<-EOS.strip
2 false
@@ -46,25 +46,34 @@ RSpec.describe "Bundler.with_env helpers" do
0 true
EOS
end
+
+ it "removes variables that bundler added", :ruby_repo do
+ system_gems :bundler
+ original = ruby!('puts ENV.to_a.map {|e| e.join("=") }.sort.join("\n")')
+ code = 'puts Bundler.original_env.to_a.map {|e| e.join("=") }.sort.join("\n")'
+ bundle!("exec '#{Gem.ruby}' -e #{code.inspect}", :system_bundler => true)
+ expect(out).to eq original
+ end
end
- describe "Bundler.clean_env" do
+ describe "Bundler.clean_env", :bundler => "< 2" do
before do
+ bundle "config path vendor/bundle"
gemfile ""
- bundle "install --path vendor/bundle"
+ bundle "install"
end
it "should delete BUNDLE_PATH" do
code = "print Bundler.clean_env.has_key?('BUNDLE_PATH')"
ENV["BUNDLE_PATH"] = "./foo"
- result = bundle("exec ruby -e #{code.inspect}")
+ result = bundle("exec '#{Gem.ruby}' -e #{code.inspect}")
expect(result).to eq("false")
end
it "should remove '-rbundler/setup' from RUBYOPT" do
code = "print Bundler.clean_env['RUBYOPT']"
ENV["RUBYOPT"] = "-W2 -rbundler/setup"
- result = bundle("exec ruby -e #{code.inspect}")
+ result = bundle("exec '#{Gem.ruby}' -e #{code.inspect}")
expect(result).not_to include("-rbundler/setup")
end
@@ -79,7 +88,7 @@ RSpec.describe "Bundler.with_env helpers" do
code = "print Bundler.clean_env['MANPATH']"
ENV["MANPATH"] = "/foo"
ENV["BUNDLER_ORIG_MANPATH"] = "/foo-original"
- result = bundle("exec ruby -e #{code.inspect}")
+ result = bundle("exec '#{Gem.ruby}' -e #{code.inspect}")
expect(result).to eq("/foo-original")
end
end
@@ -100,7 +109,7 @@ RSpec.describe "Bundler.with_env helpers" do
end
end
- describe "Bundler.with_clean_env" do
+ describe "Bundler.with_clean_env", :bundler => "< 2" do
it "should set ENV to clean_env in the block" do
expected = Bundler.clean_env
actual = Bundler.with_clean_env { ENV.to_hash }
@@ -116,14 +125,14 @@ RSpec.describe "Bundler.with_env helpers" do
end
end
- describe "Bundler.clean_system", :ruby => ">= 1.9" do
+ describe "Bundler.clean_system", :ruby => ">= 1.9", :bundler => "< 2" do
it "runs system inside with_clean_env" do
Bundler.clean_system(%(echo 'if [ "$BUNDLE_PATH" = "" ]; then exit 42; else exit 1; fi' | /bin/sh))
expect($?.exitstatus).to eq(42)
end
end
- describe "Bundler.clean_exec", :ruby => ">= 1.9" do
+ describe "Bundler.clean_exec", :ruby => ">= 1.9", :bundler => "< 2" do
it "runs exec inside with_clean_env" do
pid = Kernel.fork do
Bundler.clean_exec(%(echo 'if [ "$BUNDLE_PATH" = "" ]; then exit 42; else exit 1; fi' | /bin/sh))
diff --git a/spec/bundler/spec_helper.rb b/spec/bundler/spec_helper.rb
index 7293f0e57b..cd87a65d54 100644
--- a/spec/bundler/spec_helper.rb
+++ b/spec/bundler/spec_helper.rb
@@ -1,19 +1,21 @@
# frozen_string_literal: true
+
$:.unshift File.expand_path("..", __FILE__)
$:.unshift File.expand_path("../../lib", __FILE__)
+require "rubygems"
require "bundler/psyched_yaml"
-require "fileutils"
+require "bundler/vendored_fileutils"
require "uri"
-require "digest/sha1"
+require "digest"
require File.expand_path("../support/path.rb", __FILE__)
begin
- require "rubygems"
spec = Gem::Specification.load(Spec::Path.gemspec.to_s)
rspec = spec.dependencies.find {|d| d.name == "rspec" }
gem "rspec", rspec.requirement.to_s
require "rspec"
+ require "diff/lcs"
rescue LoadError
abort "Run rake spec:deps to install development dependencies"
end
@@ -36,16 +38,17 @@ else
end
Dir["#{File.expand_path("../support", __FILE__)}/*.rb"].each do |file|
+ file = file.gsub(%r{\A#{Regexp.escape File.expand_path("..", __FILE__)}/}, "")
require file unless file.end_with?("hax.rb")
end
$debug = false
+Spec::Manpages.setup
Spec::Rubygems.setup
FileUtils.rm_rf(Spec::Path.gem_repo1)
ENV["RUBYOPT"] = "#{ENV["RUBYOPT"]} -r#{Spec::Path.spec_dir}/support/hax.rb"
ENV["BUNDLE_SPEC_RUN"] = "true"
-ENV["BUNDLE_PLUGINS"] = "true"
# Don't wrap output in tests
ENV["THOR_COLUMNS"] = "10000"
@@ -78,7 +81,7 @@ RSpec.configure do |config|
# once we have a large number of failures (indicative of core pieces of
# bundler being broken) so that running the full test suite doesn't take
# forever due to memory constraints
- config.fail_fast ||= 25
+ config.fail_fast ||= 25 if ENV["CI"]
if ENV["BUNDLER_SUDO_TESTS"] && Spec::Sudo.present?
config.filter_run :sudo => true
@@ -98,49 +101,41 @@ RSpec.configure do |config|
config.filter_run_excluding :rubygems => LessThanProc.with(Gem::VERSION)
config.filter_run_excluding :git => LessThanProc.with(git_version)
config.filter_run_excluding :rubygems_master => (ENV["RGV"] != "master")
+ config.filter_run_excluding :bundler => LessThanProc.with(Bundler::VERSION.split(".")[0, 2].join("."))
config.filter_run_excluding :ruby_repo => !!(ENV["BUNDLE_RUBY"] && ENV["BUNDLE_GEM"])
config.filter_run_when_matching :focus unless ENV["CI"]
original_wd = Dir.pwd
- original_env = ENV.to_hash
+ original_env = ENV.to_hash.delete_if {|k, _v| k.start_with?(Bundler::EnvironmentPreserver::BUNDLER_PREFIX) }
config.expect_with :rspec do |c|
c.syntax = :expect
end
config.before :suite do
- @orig_ruby = if ENV['BUNDLE_RUBY']
- ruby = Gem.ruby
- Gem.ruby = ENV['BUNDLE_RUBY']
- ruby
- end
+ if ENV['BUNDLE_RUBY']
+ @orig_ruby = Gem.ruby
+ Gem.ruby = ENV['BUNDLE_RUBY']
+ end
end
config.before :all do
build_repo1
- # HACK: necessary until rspec-mocks > 3.5.0 is used
- # see https://github.com/bundler/bundler/pull/5363#issuecomment-278089256
- if RUBY_VERSION < "1.9"
- FileUtils.module_eval do
- alias_method :mkpath, :mkdir_p
- module_function :mkpath
- end
- end
end
config.before :each do
reset!
system_gems []
in_app_root
- @all_output = String.new
+ @command_executions = []
end
config.after :each do |example|
- @all_output.strip!
- if example.exception && !@all_output.empty?
- warn @all_output unless config.formatters.grep(RSpec::Core::Formatters::DocumentationFormatter).empty?
- message = example.exception.message + "\n\nCommands:\n#{@all_output}"
+ all_output = @command_executions.map(&:to_s_verbose).join("\n\n")
+ if example.exception && !all_output.empty?
+ warn all_output unless config.formatters.grep(RSpec::Core::Formatters::DocumentationFormatter).empty?
+ message = example.exception.message + "\n\nCommands:\n#{all_output}"
(class << example.exception; self; end).send(:define_method, :message) do
message
end
@@ -151,6 +146,8 @@ RSpec.configure do |config|
end
config.after :suite do
- Gem.ruby = @orig_ruby
+ if ENV['BUNDLE_RUBY']
+ Gem.ruby = @orig_ruby
+ end
end
end
diff --git a/spec/bundler/support/artifice/compact_index.rb b/spec/bundler/support/artifice/compact_index.rb
index 9111ed8211..123efe3c58 100644
--- a/spec/bundler/support/artifice/compact_index.rb
+++ b/spec/bundler/support/artifice/compact_index.rb
@@ -1,4 +1,5 @@
# frozen_string_literal: true
+
require File.expand_path("../endpoint", __FILE__)
$LOAD_PATH.unshift Dir[base_system_gems.join("gems/compact_index*/lib")].first.to_s
@@ -14,7 +15,7 @@ class CompactIndexAPI < Endpoint
def etag_response
response_body = yield
- checksum = Digest::MD5.hexdigest(response_body)
+ checksum = Digest(:MD5).hexdigest(response_body)
return if not_modified?(checksum)
headers "ETag" => quote(checksum)
headers "Surrogate-Control" => "max-age=2592000, stale-while-revalidate=60"
@@ -67,7 +68,7 @@ class CompactIndexAPI < Endpoint
@gems ||= {}
@gems[gem_repo] ||= begin
specs = Bundler::Deprecate.skip_during do
- %w(specs.4.8 prerelease_specs.4.8).map do |filename|
+ %w[specs.4.8 prerelease_specs.4.8].map do |filename|
Marshal.load(File.open(gem_repo.join(filename)).read).map do |name, version, platform|
load_spec(name, version, platform, gem_repo)
end
diff --git a/spec/bundler/support/artifice/compact_index_api_missing.rb b/spec/bundler/support/artifice/compact_index_api_missing.rb
index 6d15b54b85..d4e68c38e8 100644
--- a/spec/bundler/support/artifice/compact_index_api_missing.rb
+++ b/spec/bundler/support/artifice/compact_index_api_missing.rb
@@ -1,4 +1,5 @@
# frozen_string_literal: true
+
require File.expand_path("../compact_index", __FILE__)
Artifice.deactivate
diff --git a/spec/bundler/support/artifice/compact_index_basic_authentication.rb b/spec/bundler/support/artifice/compact_index_basic_authentication.rb
index bffb5b9e2b..97aa6cbd84 100644
--- a/spec/bundler/support/artifice/compact_index_basic_authentication.rb
+++ b/spec/bundler/support/artifice/compact_index_basic_authentication.rb
@@ -1,4 +1,5 @@
# frozen_string_literal: true
+
require File.expand_path("../compact_index", __FILE__)
Artifice.deactivate
diff --git a/spec/bundler/support/artifice/compact_index_checksum_mismatch.rb b/spec/bundler/support/artifice/compact_index_checksum_mismatch.rb
index 4ac328736c..62feb9f164 100644
--- a/spec/bundler/support/artifice/compact_index_checksum_mismatch.rb
+++ b/spec/bundler/support/artifice/compact_index_checksum_mismatch.rb
@@ -1,4 +1,5 @@
# frozen_string_literal: true
+
require File.expand_path("../compact_index", __FILE__)
Artifice.deactivate
diff --git a/spec/bundler/support/artifice/compact_index_concurrent_download.rb b/spec/bundler/support/artifice/compact_index_concurrent_download.rb
index b788a852cf..972ecb88b7 100644
--- a/spec/bundler/support/artifice/compact_index_concurrent_download.rb
+++ b/spec/bundler/support/artifice/compact_index_concurrent_download.rb
@@ -1,4 +1,5 @@
# frozen_string_literal: true
+
require File.expand_path("../compact_index", __FILE__)
Artifice.deactivate
diff --git a/spec/bundler/support/artifice/compact_index_creds_diff_host.rb b/spec/bundler/support/artifice/compact_index_creds_diff_host.rb
index 0c417f0580..0d349bcc1e 100644
--- a/spec/bundler/support/artifice/compact_index_creds_diff_host.rb
+++ b/spec/bundler/support/artifice/compact_index_creds_diff_host.rb
@@ -1,4 +1,5 @@
# frozen_string_literal: true
+
require File.expand_path("../compact_index", __FILE__)
Artifice.deactivate
@@ -10,7 +11,7 @@ class CompactIndexCredsDiffHost < CompactIndexAPI
end
def authorized?
- auth.provided? && auth.basic? && auth.credentials && auth.credentials == %w(user pass)
+ auth.provided? && auth.basic? && auth.credentials && auth.credentials == %w[user pass]
end
def protected!
diff --git a/spec/bundler/support/artifice/compact_index_extra.rb b/spec/bundler/support/artifice/compact_index_extra.rb
index 8a87fc4343..84d1859235 100644
--- a/spec/bundler/support/artifice/compact_index_extra.rb
+++ b/spec/bundler/support/artifice/compact_index_extra.rb
@@ -1,4 +1,5 @@
# frozen_string_literal: true
+
require File.expand_path("../compact_index", __FILE__)
Artifice.deactivate
diff --git a/spec/bundler/support/artifice/compact_index_extra_api.rb b/spec/bundler/support/artifice/compact_index_extra_api.rb
index 844a9ca9f2..903aa900fb 100644
--- a/spec/bundler/support/artifice/compact_index_extra_api.rb
+++ b/spec/bundler/support/artifice/compact_index_extra_api.rb
@@ -1,4 +1,5 @@
# frozen_string_literal: true
+
require File.expand_path("../compact_index", __FILE__)
Artifice.deactivate
diff --git a/spec/bundler/support/artifice/compact_index_extra_api_missing.rb b/spec/bundler/support/artifice/compact_index_extra_api_missing.rb
new file mode 100644
index 0000000000..e72040f604
--- /dev/null
+++ b/spec/bundler/support/artifice/compact_index_extra_api_missing.rb
@@ -0,0 +1,17 @@
+# frozen_string_literal: true
+
+require File.expand_path("../compact_index_extra_api", __FILE__)
+
+Artifice.deactivate
+
+class CompactIndexExtraAPIMissing < CompactIndexExtraApi
+ get "/extra/fetch/actual/gem/:id" do
+ if params[:id] == "missing-1.0.gemspec.rz"
+ halt 404
+ else
+ File.read("#{gem_repo2}/quick/Marshal.4.8/#{params[:id]}")
+ end
+ end
+end
+
+Artifice.activate_with(CompactIndexExtraAPIMissing)
diff --git a/spec/bundler/support/artifice/compact_index_extra_missing.rb b/spec/bundler/support/artifice/compact_index_extra_missing.rb
index 2af5ce9c27..67a9d23691 100644
--- a/spec/bundler/support/artifice/compact_index_extra_missing.rb
+++ b/spec/bundler/support/artifice/compact_index_extra_missing.rb
@@ -1,4 +1,5 @@
# frozen_string_literal: true
+
require File.expand_path("../compact_index_extra", __FILE__)
Artifice.deactivate
diff --git a/spec/bundler/support/artifice/compact_index_forbidden.rb b/spec/bundler/support/artifice/compact_index_forbidden.rb
index b25eea94e7..0a4dfdb2e8 100644
--- a/spec/bundler/support/artifice/compact_index_forbidden.rb
+++ b/spec/bundler/support/artifice/compact_index_forbidden.rb
@@ -1,4 +1,5 @@
# frozen_string_literal: true
+
require File.expand_path("../compact_index", __FILE__)
Artifice.deactivate
diff --git a/spec/bundler/support/artifice/compact_index_host_redirect.rb b/spec/bundler/support/artifice/compact_index_host_redirect.rb
index 6c1ab2def6..ab371117de 100644
--- a/spec/bundler/support/artifice/compact_index_host_redirect.rb
+++ b/spec/bundler/support/artifice/compact_index_host_redirect.rb
@@ -1,4 +1,5 @@
# frozen_string_literal: true
+
require File.expand_path("../compact_index", __FILE__)
Artifice.deactivate
diff --git a/spec/bundler/support/artifice/compact_index_no_gem.rb b/spec/bundler/support/artifice/compact_index_no_gem.rb
new file mode 100644
index 0000000000..01c5be1b3d
--- /dev/null
+++ b/spec/bundler/support/artifice/compact_index_no_gem.rb
@@ -0,0 +1,13 @@
+# frozen_string_literal: true
+
+require File.expand_path("../compact_index", __FILE__)
+
+Artifice.deactivate
+
+class CompactIndexNoGem < CompactIndexAPI
+ get "/gems/:id" do
+ halt 500
+ end
+end
+
+Artifice.activate_with(CompactIndexNoGem)
diff --git a/spec/bundler/support/artifice/compact_index_partial_update.rb b/spec/bundler/support/artifice/compact_index_partial_update.rb
index bf6feab877..eaedff5105 100644
--- a/spec/bundler/support/artifice/compact_index_partial_update.rb
+++ b/spec/bundler/support/artifice/compact_index_partial_update.rb
@@ -1,4 +1,5 @@
# frozen_string_literal: true
+
require File.expand_path("../compact_index", __FILE__)
Artifice.deactivate
diff --git a/spec/bundler/support/artifice/compact_index_redirects.rb b/spec/bundler/support/artifice/compact_index_redirects.rb
index ff1d3e43bc..e83451b5b6 100644
--- a/spec/bundler/support/artifice/compact_index_redirects.rb
+++ b/spec/bundler/support/artifice/compact_index_redirects.rb
@@ -1,4 +1,5 @@
# frozen_string_literal: true
+
require File.expand_path("../compact_index", __FILE__)
Artifice.deactivate
diff --git a/spec/bundler/support/artifice/compact_index_strict_basic_authentication.rb b/spec/bundler/support/artifice/compact_index_strict_basic_authentication.rb
index 49a072d2b9..abbf3258e7 100644
--- a/spec/bundler/support/artifice/compact_index_strict_basic_authentication.rb
+++ b/spec/bundler/support/artifice/compact_index_strict_basic_authentication.rb
@@ -1,4 +1,5 @@
# frozen_string_literal: true
+
require File.expand_path("../compact_index", __FILE__)
Artifice.deactivate
diff --git a/spec/bundler/support/artifice/compact_index_wrong_dependencies.rb b/spec/bundler/support/artifice/compact_index_wrong_dependencies.rb
index 25935f5e5d..7e1d3686e2 100644
--- a/spec/bundler/support/artifice/compact_index_wrong_dependencies.rb
+++ b/spec/bundler/support/artifice/compact_index_wrong_dependencies.rb
@@ -1,4 +1,5 @@
# frozen_string_literal: true
+
require File.expand_path("../compact_index", __FILE__)
Artifice.deactivate
diff --git a/spec/bundler/support/artifice/compact_index_wrong_gem_checksum.rb b/spec/bundler/support/artifice/compact_index_wrong_gem_checksum.rb
index 3a12a59ae7..db4d8e3974 100644
--- a/spec/bundler/support/artifice/compact_index_wrong_gem_checksum.rb
+++ b/spec/bundler/support/artifice/compact_index_wrong_gem_checksum.rb
@@ -1,4 +1,5 @@
# frozen_string_literal: true
+
require File.expand_path("../compact_index", __FILE__)
Artifice.deactivate
diff --git a/spec/bundler/support/artifice/endopint_marshal_fail_basic_authentication.rb b/spec/bundler/support/artifice/endopint_marshal_fail_basic_authentication.rb
index f1f8dc5700..12a6fa153f 100644
--- a/spec/bundler/support/artifice/endopint_marshal_fail_basic_authentication.rb
+++ b/spec/bundler/support/artifice/endopint_marshal_fail_basic_authentication.rb
@@ -1,4 +1,5 @@
# frozen_string_literal: true
+
require File.expand_path("../endpoint_marshal_fail", __FILE__)
Artifice.deactivate
diff --git a/spec/bundler/support/artifice/endpoint.rb b/spec/bundler/support/artifice/endpoint.rb
index 771d431f22..9afecff8e6 100644
--- a/spec/bundler/support/artifice/endpoint.rb
+++ b/spec/bundler/support/artifice/endpoint.rb
@@ -1,4 +1,5 @@
# frozen_string_literal: true
+
require File.expand_path("../../path.rb", __FILE__)
require Spec::Path.root.join("lib/bundler/deprecate")
include Spec::Path
@@ -7,11 +8,37 @@ $LOAD_PATH.unshift(*Dir[Spec::Path.base_system_gems.join("gems/{artifice,rack,ti
require "artifice"
require "sinatra/base"
+ALL_REQUESTS = [] # rubocop:disable Style/MutableConstant
+ALL_REQUESTS_MUTEX = Mutex.new
+
+at_exit do
+ if expected = ENV["BUNDLER_SPEC_ALL_REQUESTS"]
+ expected = expected.split("\n").sort
+ actual = ALL_REQUESTS.sort
+
+ unless expected == actual
+ raise "Unexpected requests!\nExpected:\n\t#{expected.join("\n\t")}\n\nActual:\n\t#{actual.join("\n\t")}"
+ end
+ end
+end
+
class Endpoint < Sinatra::Base
+ def self.all_requests
+ @all_requests ||= []
+ end
+
GEM_REPO = Pathname.new(ENV["BUNDLER_SPEC_GEM_REPO"] || Spec::Path.gem_repo1)
set :raise_errors, true
set :show_exceptions, false
+ def call!(*)
+ super.tap do
+ ALL_REQUESTS_MUTEX.synchronize do
+ ALL_REQUESTS << @request.url
+ end
+ end
+ end
+
helpers do
def dependencies_for(gem_names, gem_repo = GEM_REPO)
return [] if gem_names.nil? || gem_names.empty?
@@ -19,7 +46,7 @@ class Endpoint < Sinatra::Base
require "rubygems"
require "bundler"
Bundler::Deprecate.skip_during do
- all_specs = %w(specs.4.8 prerelease_specs.4.8).map do |filename|
+ all_specs = %w[specs.4.8 prerelease_specs.4.8].map do |filename|
Marshal.load(File.open(gem_repo.join(filename)).read)
end.inject(:+)
diff --git a/spec/bundler/support/artifice/endpoint_500.rb b/spec/bundler/support/artifice/endpoint_500.rb
index 993630b79e..202ccfc829 100644
--- a/spec/bundler/support/artifice/endpoint_500.rb
+++ b/spec/bundler/support/artifice/endpoint_500.rb
@@ -1,4 +1,5 @@
# frozen_string_literal: true
+
require File.expand_path("../../path.rb", __FILE__)
include Spec::Path
diff --git a/spec/bundler/support/artifice/endpoint_api_forbidden.rb b/spec/bundler/support/artifice/endpoint_api_forbidden.rb
index 21ad9117ed..bb89747adc 100644
--- a/spec/bundler/support/artifice/endpoint_api_forbidden.rb
+++ b/spec/bundler/support/artifice/endpoint_api_forbidden.rb
@@ -1,4 +1,5 @@
# frozen_string_literal: true
+
require File.expand_path("../endpoint", __FILE__)
Artifice.deactivate
diff --git a/spec/bundler/support/artifice/endpoint_api_missing.rb b/spec/bundler/support/artifice/endpoint_api_missing.rb
index 6f5b5f1323..95db8e2a7e 100644
--- a/spec/bundler/support/artifice/endpoint_api_missing.rb
+++ b/spec/bundler/support/artifice/endpoint_api_missing.rb
@@ -1,4 +1,5 @@
# frozen_string_literal: true
+
require File.expand_path("../endpoint", __FILE__)
Artifice.deactivate
diff --git a/spec/bundler/support/artifice/endpoint_basic_authentication.rb b/spec/bundler/support/artifice/endpoint_basic_authentication.rb
index 9fafd51a3d..223671bc29 100644
--- a/spec/bundler/support/artifice/endpoint_basic_authentication.rb
+++ b/spec/bundler/support/artifice/endpoint_basic_authentication.rb
@@ -1,4 +1,5 @@
# frozen_string_literal: true
+
require File.expand_path("../endpoint", __FILE__)
Artifice.deactivate
diff --git a/spec/bundler/support/artifice/endpoint_creds_diff_host.rb b/spec/bundler/support/artifice/endpoint_creds_diff_host.rb
index cd152848fe..925954b12d 100644
--- a/spec/bundler/support/artifice/endpoint_creds_diff_host.rb
+++ b/spec/bundler/support/artifice/endpoint_creds_diff_host.rb
@@ -1,4 +1,5 @@
# frozen_string_literal: true
+
require File.expand_path("../endpoint", __FILE__)
Artifice.deactivate
@@ -10,7 +11,7 @@ class EndpointCredsDiffHost < Endpoint
end
def authorized?
- auth.provided? && auth.basic? && auth.credentials && auth.credentials == %w(user pass)
+ auth.provided? && auth.basic? && auth.credentials && auth.credentials == %w[user pass]
end
def protected!
diff --git a/spec/bundler/support/artifice/endpoint_extra.rb b/spec/bundler/support/artifice/endpoint_extra.rb
index ed4e87e65f..422f65401b 100644
--- a/spec/bundler/support/artifice/endpoint_extra.rb
+++ b/spec/bundler/support/artifice/endpoint_extra.rb
@@ -1,4 +1,5 @@
# frozen_string_literal: true
+
require File.expand_path("../endpoint", __FILE__)
Artifice.deactivate
diff --git a/spec/bundler/support/artifice/endpoint_extra_api.rb b/spec/bundler/support/artifice/endpoint_extra_api.rb
index 1e9e1dc60d..62e2c2bb93 100644
--- a/spec/bundler/support/artifice/endpoint_extra_api.rb
+++ b/spec/bundler/support/artifice/endpoint_extra_api.rb
@@ -1,4 +1,5 @@
# frozen_string_literal: true
+
require File.expand_path("../endpoint", __FILE__)
Artifice.deactivate
diff --git a/spec/bundler/support/artifice/endpoint_extra_missing.rb b/spec/bundler/support/artifice/endpoint_extra_missing.rb
index dc79705a26..038a12610a 100644
--- a/spec/bundler/support/artifice/endpoint_extra_missing.rb
+++ b/spec/bundler/support/artifice/endpoint_extra_missing.rb
@@ -1,4 +1,5 @@
# frozen_string_literal: true
+
require File.expand_path("../endpoint_extra", __FILE__)
Artifice.deactivate
diff --git a/spec/bundler/support/artifice/endpoint_fallback.rb b/spec/bundler/support/artifice/endpoint_fallback.rb
index 8a85a41784..554c08f0a2 100644
--- a/spec/bundler/support/artifice/endpoint_fallback.rb
+++ b/spec/bundler/support/artifice/endpoint_fallback.rb
@@ -1,4 +1,5 @@
# frozen_string_literal: true
+
require File.expand_path("../endpoint", __FILE__)
Artifice.deactivate
diff --git a/spec/bundler/support/artifice/endpoint_host_redirect.rb b/spec/bundler/support/artifice/endpoint_host_redirect.rb
index 250416d8cc..cda5664be2 100644
--- a/spec/bundler/support/artifice/endpoint_host_redirect.rb
+++ b/spec/bundler/support/artifice/endpoint_host_redirect.rb
@@ -1,4 +1,5 @@
# frozen_string_literal: true
+
require File.expand_path("../endpoint", __FILE__)
Artifice.deactivate
diff --git a/spec/bundler/support/artifice/endpoint_marshal_fail.rb b/spec/bundler/support/artifice/endpoint_marshal_fail.rb
index 0fb75ebf31..2a5dcdc2fd 100644
--- a/spec/bundler/support/artifice/endpoint_marshal_fail.rb
+++ b/spec/bundler/support/artifice/endpoint_marshal_fail.rb
@@ -1,4 +1,5 @@
# frozen_string_literal: true
+
require File.expand_path("../endpoint_fallback", __FILE__)
Artifice.deactivate
diff --git a/spec/bundler/support/artifice/endpoint_mirror_source.rb b/spec/bundler/support/artifice/endpoint_mirror_source.rb
index 9fb58ecb29..64452f198d 100644
--- a/spec/bundler/support/artifice/endpoint_mirror_source.rb
+++ b/spec/bundler/support/artifice/endpoint_mirror_source.rb
@@ -1,4 +1,5 @@
# frozen_string_literal: true
+
require File.expand_path("../endpoint", __FILE__)
class EndpointMirrorSource < Endpoint
diff --git a/spec/bundler/support/artifice/endpoint_redirect.rb b/spec/bundler/support/artifice/endpoint_redirect.rb
index f80d7600c2..ebf01458ba 100644
--- a/spec/bundler/support/artifice/endpoint_redirect.rb
+++ b/spec/bundler/support/artifice/endpoint_redirect.rb
@@ -1,4 +1,5 @@
# frozen_string_literal: true
+
require File.expand_path("../endpoint", __FILE__)
Artifice.deactivate
diff --git a/spec/bundler/support/artifice/endpoint_strict_basic_authentication.rb b/spec/bundler/support/artifice/endpoint_strict_basic_authentication.rb
index 4b32cbbf5b..905a519f3f 100644
--- a/spec/bundler/support/artifice/endpoint_strict_basic_authentication.rb
+++ b/spec/bundler/support/artifice/endpoint_strict_basic_authentication.rb
@@ -1,4 +1,5 @@
# frozen_string_literal: true
+
require File.expand_path("../endpoint", __FILE__)
Artifice.deactivate
diff --git a/spec/bundler/support/artifice/endpoint_timeout.rb b/spec/bundler/support/artifice/endpoint_timeout.rb
index b15650f226..3f60471c90 100644
--- a/spec/bundler/support/artifice/endpoint_timeout.rb
+++ b/spec/bundler/support/artifice/endpoint_timeout.rb
@@ -1,10 +1,11 @@
# frozen_string_literal: true
+
require File.expand_path("../endpoint_fallback", __FILE__)
Artifice.deactivate
class EndpointTimeout < EndpointFallback
- SLEEP_TIMEOUT = 15
+ SLEEP_TIMEOUT = 3
get "/api/v1/dependencies" do
sleep(SLEEP_TIMEOUT)
diff --git a/spec/bundler/support/artifice/vcr.rb b/spec/bundler/support/artifice/vcr.rb
new file mode 100644
index 0000000000..edd2f49a91
--- /dev/null
+++ b/spec/bundler/support/artifice/vcr.rb
@@ -0,0 +1,158 @@
+# frozen_string_literal: true
+
+require "net/http"
+if RUBY_VERSION < "1.9"
+ begin
+ require "net/https"
+ rescue LoadError
+ nil # net/https or openssl
+ end
+end # but only for 1.8
+
+CASSETTE_PATH = File.expand_path("../vcr_cassettes", __FILE__)
+CASSETTE_NAME = ENV.fetch("BUNDLER_SPEC_VCR_CASSETTE_NAME") { "realworld" }
+
+class BundlerVCRHTTP < Net::HTTP
+ class RequestHandler
+ attr_reader :http, :request, :body, :response_block
+ def initialize(http, request, body = nil, &response_block)
+ @http = http
+ @request = request
+ @body = body
+ @response_block = response_block
+ end
+
+ def handle_request
+ handler = self
+ request.instance_eval do
+ @__vcr_request_handler = handler
+ end
+
+ if recorded_response?
+ recorded_response
+ else
+ record_response
+ end
+ end
+
+ def recorded_response?
+ return true if ENV["BUNDLER_SPEC_PRE_RECORDED"]
+ return false if ENV["BUNDLER_SPEC_FORCE_RECORD"]
+ request_pair_paths.all? {|f| File.exist?(f) }
+ end
+
+ def recorded_response
+ File.open(request_pair_paths.last, "rb:ASCII-8BIT") do |response_file|
+ response_io = ::Net::BufferedIO.new(response_file)
+ ::Net::HTTPResponse.read_new(response_io).tap do |response|
+ response.decode_content = request.decode_content if request.respond_to?(:decode_content)
+ response.uri = request.uri if request.respond_to?(:uri)
+
+ response.reading_body(response_io, request.response_body_permitted?) do
+ response_block.call(response) if response_block
+ end
+ end
+ end
+ end
+
+ def record_response
+ request_path, response_path = *request_pair_paths
+
+ @recording = true
+
+ response = http.request_without_vcr(request, body, &response_block)
+ @recording = false
+ unless @recording
+ FileUtils.mkdir_p(File.dirname(request_path))
+ binwrite(request_path, request_to_string(request))
+ binwrite(response_path, response_to_string(response))
+ end
+ response
+ end
+
+ def key
+ [request["host"] || http.address, request.path, request.method].compact
+ end
+
+ def file_name_for_key(key)
+ key.join("/").gsub(/[\:*?"<>|]/, "-")
+ end
+
+ def request_pair_paths
+ %w[request response].map do |kind|
+ File.join(CASSETTE_PATH, CASSETTE_NAME, file_name_for_key(key + [kind]))
+ end
+ end
+
+ def read_stored_request(path)
+ contents = File.read(path)
+ headers = {}
+ method = nil
+ path = nil
+ contents.lines.grep(/^> /).each do |line|
+ if line =~ /^> (GET|HEAD|POST|PATCH|PUT|DELETE) (.*)/
+ method = $1
+ path = $2.strip
+ elsif line =~ /^> (.*?): (.*)/
+ headers[$1] = $2
+ end
+ end
+ body = contents =~ /^([^>].*)/m && $1
+ Net::HTTP.const_get(method.capitalize).new(path, headers).tap {|r| r.body = body if body }
+ end
+
+ def request_to_string(request)
+ request_string = []
+ request_string << "> #{request.method.upcase} #{request.path}"
+ request.to_hash.each do |key, value|
+ request_string << "> #{key}: #{Array(value).first}"
+ end
+ request << "" << request.body if request.body
+ request_string.join("\n")
+ end
+
+ def response_to_string(response)
+ headers = response.to_hash
+ body = response.body
+
+ response_string = []
+ response_string << "HTTP/1.1 #{response.code} #{response.message}"
+
+ headers["content-length"] = [body.bytesize.to_s] if body
+
+ headers.each do |header, value|
+ response_string << "#{header}: #{value.join(", ")}"
+ end
+
+ response_string << "" << body
+
+ response_string = response_string.join("\n")
+ if response_string.respond_to?(:force_encoding)
+ response_string.force_encoding("ASCII-8BIT")
+ else
+ response_string
+ end
+ end
+
+ def binwrite(path, contents)
+ File.open(path, "wb:ASCII-8BIT") {|f| f.write(contents) }
+ end
+ end
+
+ def request_with_vcr(request, *args, &block)
+ handler = request.instance_eval do
+ remove_instance_variable(:@__vcr_request_handler) if defined?(@__vcr_request_handler)
+ end || RequestHandler.new(self, request, *args, &block)
+
+ handler.handle_request
+ end
+
+ alias_method :request_without_vcr, :request
+ alias_method :request, :request_with_vcr
+end
+
+# Replace Net::HTTP with our VCR subclass
+::Net.class_eval do
+ remove_const(:HTTP)
+ const_set(:HTTP, BundlerVCRHTTP)
+end
diff --git a/spec/bundler/support/artifice/vcr_cassettes/realworld/api.rubygems.org/api/v1/dependencies-gems=bundler/GET/request b/spec/bundler/support/artifice/vcr_cassettes/realworld/api.rubygems.org/api/v1/dependencies-gems=bundler/GET/request
new file mode 100644
index 0000000000..00dcd51750
--- /dev/null
+++ b/spec/bundler/support/artifice/vcr_cassettes/realworld/api.rubygems.org/api/v1/dependencies-gems=bundler/GET/request
@@ -0,0 +1,7 @@
+> GET /api/v1/dependencies?gems=bundler
+> accept-encoding: gzip;q=1.0,deflate;q=0.6,identity;q=0.3
+> accept: */*
+> user-agent: Ruby
+> connection: keep-alive
+> keep-alive: 30
+> host: api.rubygems.org \ No newline at end of file
diff --git a/spec/bundler/support/artifice/vcr_cassettes/realworld/api.rubygems.org/api/v1/dependencies-gems=bundler/GET/response b/spec/bundler/support/artifice/vcr_cassettes/realworld/api.rubygems.org/api/v1/dependencies-gems=bundler/GET/response
new file mode 100644
index 0000000000..2dd5aa76f8
--- /dev/null
+++ b/spec/bundler/support/artifice/vcr_cassettes/realworld/api.rubygems.org/api/v1/dependencies-gems=bundler/GET/response
Binary files differ
diff --git a/spec/bundler/support/artifice/vcr_cassettes/realworld/api.rubygems.org/api/v1/dependencies/HEAD/request b/spec/bundler/support/artifice/vcr_cassettes/realworld/api.rubygems.org/api/v1/dependencies/HEAD/request
new file mode 100644
index 0000000000..13b3c98dd2
--- /dev/null
+++ b/spec/bundler/support/artifice/vcr_cassettes/realworld/api.rubygems.org/api/v1/dependencies/HEAD/request
@@ -0,0 +1,6 @@
+> HEAD /api/v1/dependencies
+> accept: */*
+> user-agent: Ruby
+> connection: keep-alive
+> keep-alive: 30
+> host: api.rubygems.org \ No newline at end of file
diff --git a/spec/bundler/support/artifice/vcr_cassettes/realworld/api.rubygems.org/api/v1/dependencies/HEAD/response b/spec/bundler/support/artifice/vcr_cassettes/realworld/api.rubygems.org/api/v1/dependencies/HEAD/response
new file mode 100644
index 0000000000..fa6cc543da
--- /dev/null
+++ b/spec/bundler/support/artifice/vcr_cassettes/realworld/api.rubygems.org/api/v1/dependencies/HEAD/response
@@ -0,0 +1,24 @@
+HTTP/1.1 200 OK
+content-type: text/plain; charset=utf-8
+x-frame-options: SAMEORIGIN
+x-xss-protection: 1; mode=block
+x-content-type-options: nosniff
+content-security-policy: default-src 'self'; script-src 'self' https://secure.gaug.es; style-src 'self' https://fonts.googleapis.com; img-src 'self' https://secure.gaug.es https://gravatar.com https://secure.gravatar.com; font-src 'self' https://fonts.gstatic.com; connect-src https://s3-us-west-2.amazonaws.com/rubygems-dumps/; frame-src https://ghbtns.com
+cache-control: no-cache
+x-request-id: a7d87e66-6bb3-4b7a-9d3a-89ee68784d0e
+x-runtime: 0.003648
+x-ua-compatible: IE=Edge,chrome=1
+x-backend: F_Rails 54.186.104.15:443
+content-length: 0
+accept-ranges: bytes
+date: Fri, 28 Apr 2017 09:22:23 GMT
+via: 1.1 varnish
+age: 3103
+connection: keep-alive
+x-served-by: cache-fra1243-FRA
+x-cache: HIT
+x-cache-hits: 107
+x-timer: S1493371344.878545,VS0,VE0
+vary: Accept-Encoding,Fastly-SSL
+server: RubyGems.org
+
diff --git a/spec/bundler/support/artifice/vcr_cassettes/realworld/api.rubygems.org/gems/bundler-1.12.3.gem/GET/request b/spec/bundler/support/artifice/vcr_cassettes/realworld/api.rubygems.org/gems/bundler-1.12.3.gem/GET/request
new file mode 100644
index 0000000000..230892854c
--- /dev/null
+++ b/spec/bundler/support/artifice/vcr_cassettes/realworld/api.rubygems.org/gems/bundler-1.12.3.gem/GET/request
@@ -0,0 +1,7 @@
+> GET /gems/bundler-1.12.3.gem
+> accept-encoding: gzip;q=1.0,deflate;q=0.6,identity;q=0.3
+> accept: */*
+> user-agent: Ruby
+> connection: keep-alive
+> keep-alive: 30
+> host: api.rubygems.org \ No newline at end of file
diff --git a/spec/bundler/support/artifice/vcr_cassettes/realworld/api.rubygems.org/gems/bundler-1.12.3.gem/GET/response b/spec/bundler/support/artifice/vcr_cassettes/realworld/api.rubygems.org/gems/bundler-1.12.3.gem/GET/response
new file mode 100644
index 0000000000..8f5d12c8eb
--- /dev/null
+++ b/spec/bundler/support/artifice/vcr_cassettes/realworld/api.rubygems.org/gems/bundler-1.12.3.gem/GET/response
Binary files differ
diff --git a/spec/bundler/support/artifice/vcr_cassettes/realworld/api.rubygems.org/quick/Marshal.4.8/bundler-1.12.3.gemspec.rz/GET/request b/spec/bundler/support/artifice/vcr_cassettes/realworld/api.rubygems.org/quick/Marshal.4.8/bundler-1.12.3.gemspec.rz/GET/request
new file mode 100644
index 0000000000..c9337e9a6b
--- /dev/null
+++ b/spec/bundler/support/artifice/vcr_cassettes/realworld/api.rubygems.org/quick/Marshal.4.8/bundler-1.12.3.gemspec.rz/GET/request
@@ -0,0 +1,7 @@
+> GET /quick/Marshal.4.8/bundler-1.12.3.gemspec.rz
+> accept-encoding: gzip;q=1.0,deflate;q=0.6,identity;q=0.3
+> accept: */*
+> user-agent: Ruby
+> connection: keep-alive
+> keep-alive: 30
+> host: api.rubygems.org \ No newline at end of file
diff --git a/spec/bundler/support/artifice/vcr_cassettes/realworld/api.rubygems.org/quick/Marshal.4.8/bundler-1.12.3.gemspec.rz/GET/response b/spec/bundler/support/artifice/vcr_cassettes/realworld/api.rubygems.org/quick/Marshal.4.8/bundler-1.12.3.gemspec.rz/GET/response
new file mode 100644
index 0000000000..d6b53b54a0
--- /dev/null
+++ b/spec/bundler/support/artifice/vcr_cassettes/realworld/api.rubygems.org/quick/Marshal.4.8/bundler-1.12.3.gemspec.rz/GET/response
Binary files differ
diff --git a/spec/bundler/support/artifice/vcr_cassettes/realworld/api.rubygems.org/specs.4.8.gz/GET/request b/spec/bundler/support/artifice/vcr_cassettes/realworld/api.rubygems.org/specs.4.8.gz/GET/request
new file mode 100644
index 0000000000..94f2b68688
--- /dev/null
+++ b/spec/bundler/support/artifice/vcr_cassettes/realworld/api.rubygems.org/specs.4.8.gz/GET/request
@@ -0,0 +1,7 @@
+> GET /specs.4.8.gz
+> accept-encoding: gzip;q=1.0,deflate;q=0.6,identity;q=0.3
+> accept: */*
+> user-agent: Ruby
+> connection: keep-alive
+> keep-alive: 30
+> host: api.rubygems.org \ No newline at end of file
diff --git a/spec/bundler/support/artifice/vcr_cassettes/realworld/api.rubygems.org/specs.4.8.gz/GET/response b/spec/bundler/support/artifice/vcr_cassettes/realworld/api.rubygems.org/specs.4.8.gz/GET/response
new file mode 100644
index 0000000000..bd54f4d8cd
--- /dev/null
+++ b/spec/bundler/support/artifice/vcr_cassettes/realworld/api.rubygems.org/specs.4.8.gz/GET/response
Binary files differ
diff --git a/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/CFPropertyList/GET/request b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/CFPropertyList/GET/request
new file mode 100644
index 0000000000..a92b8bb55f
--- /dev/null
+++ b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/CFPropertyList/GET/request
@@ -0,0 +1,7 @@
+> GET /info/CFPropertyList
+> accept-encoding: gzip
+> accept: */*
+> user-agent: bundler/1.15.0.pre.2 rubygems/2.6.11 ruby/2.4.1 (x86_64-apple-darwin16.5.0) command/lock options/spec_run,plugins,trampoline_disable 7edfb7e0938d0c35
+> connection: keep-alive
+> keep-alive: 30
+> host: index.rubygems.org \ No newline at end of file
diff --git a/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/CFPropertyList/GET/response b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/CFPropertyList/GET/response
new file mode 100644
index 0000000000..3e4ec8fdfb
--- /dev/null
+++ b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/CFPropertyList/GET/response
Binary files differ
diff --git a/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/ParseTree/GET/request b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/ParseTree/GET/request
new file mode 100644
index 0000000000..278c2103b3
--- /dev/null
+++ b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/ParseTree/GET/request
@@ -0,0 +1,7 @@
+> GET /info/ParseTree
+> accept-encoding: gzip
+> accept: */*
+> user-agent: bundler/1.15.0.pre.2 rubygems/2.6.11 ruby/2.4.1 (x86_64-apple-darwin16.5.0) command/lock options/spec_run,plugins,trampoline_disable 7edfb7e0938d0c35
+> connection: keep-alive
+> keep-alive: 30
+> host: index.rubygems.org \ No newline at end of file
diff --git a/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/ParseTree/GET/response b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/ParseTree/GET/response
new file mode 100644
index 0000000000..10fc08ccb2
--- /dev/null
+++ b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/ParseTree/GET/response
Binary files differ
diff --git a/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/RedCloth/GET/request b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/RedCloth/GET/request
new file mode 100644
index 0000000000..895b7dfd54
--- /dev/null
+++ b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/RedCloth/GET/request
@@ -0,0 +1,7 @@
+> GET /info/RedCloth
+> accept-encoding: gzip
+> accept: */*
+> user-agent: bundler/1.15.0.pre.2 rubygems/2.6.11 ruby/2.4.1 (x86_64-apple-darwin16.5.0) command/install options/retry,path,disable_shared_gems,spec_run,plugins,trampoline_disable d59b382d069fc94f
+> connection: keep-alive
+> keep-alive: 30
+> host: index.rubygems.org \ No newline at end of file
diff --git a/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/RedCloth/GET/response b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/RedCloth/GET/response
new file mode 100644
index 0000000000..dac79849bf
--- /dev/null
+++ b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/RedCloth/GET/response
Binary files differ
diff --git a/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/RubyInline/GET/request b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/RubyInline/GET/request
new file mode 100644
index 0000000000..6bf0e6d3af
--- /dev/null
+++ b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/RubyInline/GET/request
@@ -0,0 +1,7 @@
+> GET /info/RubyInline
+> accept-encoding: gzip
+> accept: */*
+> user-agent: bundler/1.15.0.pre.2 rubygems/2.6.11 ruby/2.4.1 (x86_64-apple-darwin16.5.0) command/lock options/spec_run,plugins,trampoline_disable 7edfb7e0938d0c35
+> connection: keep-alive
+> keep-alive: 30
+> host: index.rubygems.org \ No newline at end of file
diff --git a/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/RubyInline/GET/response b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/RubyInline/GET/response
new file mode 100644
index 0000000000..03a6377fc5
--- /dev/null
+++ b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/RubyInline/GET/response
Binary files differ
diff --git a/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/SexpProcessor/GET/request b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/SexpProcessor/GET/request
new file mode 100644
index 0000000000..30a9943801
--- /dev/null
+++ b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/SexpProcessor/GET/request
@@ -0,0 +1,7 @@
+> GET /info/SexpProcessor
+> accept-encoding: gzip
+> accept: */*
+> user-agent: bundler/1.15.0.pre.2 rubygems/2.6.11 ruby/2.4.1 (x86_64-apple-darwin16.5.0) command/lock options/spec_run,plugins,trampoline_disable 7edfb7e0938d0c35
+> connection: keep-alive
+> keep-alive: 30
+> host: index.rubygems.org \ No newline at end of file
diff --git a/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/SexpProcessor/GET/response b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/SexpProcessor/GET/response
new file mode 100644
index 0000000000..47e0c3e7e4
--- /dev/null
+++ b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/SexpProcessor/GET/response
Binary files differ
diff --git a/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/ZenTest/GET/request b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/ZenTest/GET/request
new file mode 100644
index 0000000000..927fce847b
--- /dev/null
+++ b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/ZenTest/GET/request
@@ -0,0 +1,7 @@
+> GET /info/ZenTest
+> accept-encoding: gzip
+> accept: */*
+> user-agent: bundler/1.15.0.pre.2 rubygems/2.6.11 ruby/2.4.1 (x86_64-apple-darwin16.5.0) command/lock options/spec_run,plugins,trampoline_disable 7edfb7e0938d0c35
+> connection: keep-alive
+> keep-alive: 30
+> host: index.rubygems.org \ No newline at end of file
diff --git a/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/ZenTest/GET/response b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/ZenTest/GET/response
new file mode 100644
index 0000000000..669b149feb
--- /dev/null
+++ b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/ZenTest/GET/response
Binary files differ
diff --git a/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/abstract/GET/request b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/abstract/GET/request
new file mode 100644
index 0000000000..33ba985fc9
--- /dev/null
+++ b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/abstract/GET/request
@@ -0,0 +1,7 @@
+> GET /info/abstract
+> accept-encoding: gzip
+> accept: */*
+> user-agent: bundler/1.15.0.pre.2 rubygems/2.6.11 ruby/2.4.1 (x86_64-apple-darwin16.5.0) command/lock options/spec_run,plugins,trampoline_disable 7edfb7e0938d0c35
+> connection: keep-alive
+> keep-alive: 30
+> host: index.rubygems.org \ No newline at end of file
diff --git a/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/abstract/GET/response b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/abstract/GET/response
new file mode 100644
index 0000000000..1edf821062
--- /dev/null
+++ b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/abstract/GET/response
Binary files differ
diff --git a/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/actioncable/GET/request b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/actioncable/GET/request
new file mode 100644
index 0000000000..67f6acff19
--- /dev/null
+++ b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/actioncable/GET/request
@@ -0,0 +1,7 @@
+> GET /info/actioncable
+> accept-encoding: gzip
+> accept: */*
+> user-agent: bundler/1.15.0.pre.2 rubygems/2.6.11 ruby/2.4.1 (x86_64-apple-darwin16.5.0) command/lock options/spec_run,plugins,trampoline_disable 7edfb7e0938d0c35
+> connection: keep-alive
+> keep-alive: 30
+> host: index.rubygems.org \ No newline at end of file
diff --git a/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/actioncable/GET/response b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/actioncable/GET/response
new file mode 100644
index 0000000000..ea6d8e5c4d
--- /dev/null
+++ b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/actioncable/GET/response
Binary files differ
diff --git a/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/actionmailer/GET/request b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/actionmailer/GET/request
new file mode 100644
index 0000000000..ff277f113a
--- /dev/null
+++ b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/actionmailer/GET/request
@@ -0,0 +1,7 @@
+> GET /info/actionmailer
+> accept-encoding: gzip
+> accept: */*
+> user-agent: bundler/1.15.0.pre.2 rubygems/2.6.11 ruby/2.4.1 (x86_64-apple-darwin16.5.0) command/lock options/spec_run,plugins,trampoline_disable 7edfb7e0938d0c35
+> connection: keep-alive
+> keep-alive: 30
+> host: index.rubygems.org \ No newline at end of file
diff --git a/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/actionmailer/GET/response b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/actionmailer/GET/response
new file mode 100644
index 0000000000..0cdee06fda
--- /dev/null
+++ b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/actionmailer/GET/response
Binary files differ
diff --git a/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/actionpack/GET/request b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/actionpack/GET/request
new file mode 100644
index 0000000000..85c039b7eb
--- /dev/null
+++ b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/actionpack/GET/request
@@ -0,0 +1,7 @@
+> GET /info/actionpack
+> accept-encoding: gzip
+> accept: */*
+> user-agent: bundler/1.15.0.pre.2 rubygems/2.6.11 ruby/2.4.1 (x86_64-apple-darwin16.5.0) command/lock options/spec_run,plugins,trampoline_disable 7edfb7e0938d0c35
+> connection: keep-alive
+> keep-alive: 30
+> host: index.rubygems.org \ No newline at end of file
diff --git a/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/actionpack/GET/response b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/actionpack/GET/response
new file mode 100644
index 0000000000..d95b8da544
--- /dev/null
+++ b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/actionpack/GET/response
Binary files differ
diff --git a/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/actionview/GET/request b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/actionview/GET/request
new file mode 100644
index 0000000000..8b11f69250
--- /dev/null
+++ b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/actionview/GET/request
@@ -0,0 +1,7 @@
+> GET /info/actionview
+> accept-encoding: gzip
+> accept: */*
+> user-agent: bundler/1.15.0.pre.2 rubygems/2.6.11 ruby/2.4.1 (x86_64-apple-darwin16.5.0) command/lock options/spec_run,plugins,trampoline_disable 7edfb7e0938d0c35
+> connection: keep-alive
+> keep-alive: 30
+> host: index.rubygems.org \ No newline at end of file
diff --git a/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/actionview/GET/response b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/actionview/GET/response
new file mode 100644
index 0000000000..7edc784c99
--- /dev/null
+++ b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/actionview/GET/response
Binary files differ
diff --git a/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/actionwebservice/GET/request b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/actionwebservice/GET/request
new file mode 100644
index 0000000000..2ec89cf1b2
--- /dev/null
+++ b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/actionwebservice/GET/request
@@ -0,0 +1,7 @@
+> GET /info/actionwebservice
+> accept-encoding: gzip
+> accept: */*
+> user-agent: bundler/1.15.0.pre.2 rubygems/2.6.11 ruby/2.4.1 (x86_64-apple-darwin16.5.0) command/lock options/spec_run,plugins,trampoline_disable 7edfb7e0938d0c35
+> connection: keep-alive
+> keep-alive: 30
+> host: index.rubygems.org \ No newline at end of file
diff --git a/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/actionwebservice/GET/response b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/actionwebservice/GET/response
new file mode 100644
index 0000000000..817028d7c4
--- /dev/null
+++ b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/actionwebservice/GET/response
Binary files differ
diff --git a/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/activejob/GET/request b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/activejob/GET/request
new file mode 100644
index 0000000000..a215f0abf9
--- /dev/null
+++ b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/activejob/GET/request
@@ -0,0 +1,7 @@
+> GET /info/activejob
+> accept-encoding: gzip
+> accept: */*
+> user-agent: bundler/1.15.0.pre.2 rubygems/2.6.11 ruby/2.4.1 (x86_64-apple-darwin16.5.0) command/lock options/spec_run,plugins,trampoline_disable 7edfb7e0938d0c35
+> connection: keep-alive
+> keep-alive: 30
+> host: index.rubygems.org \ No newline at end of file
diff --git a/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/activejob/GET/response b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/activejob/GET/response
new file mode 100644
index 0000000000..0aa7649bd3
--- /dev/null
+++ b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/activejob/GET/response
Binary files differ
diff --git a/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/activemodel-globalid/GET/request b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/activemodel-globalid/GET/request
new file mode 100644
index 0000000000..ceae0f0950
--- /dev/null
+++ b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/activemodel-globalid/GET/request
@@ -0,0 +1,7 @@
+> GET /info/activemodel-globalid
+> accept-encoding: gzip
+> accept: */*
+> user-agent: bundler/1.15.0.pre.2 rubygems/2.6.11 ruby/2.4.1 (x86_64-apple-darwin16.5.0) command/lock options/spec_run,plugins,trampoline_disable 7edfb7e0938d0c35
+> connection: keep-alive
+> keep-alive: 30
+> host: index.rubygems.org \ No newline at end of file
diff --git a/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/activemodel-globalid/GET/response b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/activemodel-globalid/GET/response
new file mode 100644
index 0000000000..e21616fdef
--- /dev/null
+++ b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/activemodel-globalid/GET/response
Binary files differ
diff --git a/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/activemodel/GET/request b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/activemodel/GET/request
new file mode 100644
index 0000000000..e4b113569e
--- /dev/null
+++ b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/activemodel/GET/request
@@ -0,0 +1,7 @@
+> GET /info/activemodel
+> accept-encoding: gzip
+> accept: */*
+> user-agent: bundler/1.15.0.pre.2 rubygems/2.6.11 ruby/2.4.1 (x86_64-apple-darwin16.5.0) command/lock options/spec_run,plugins,trampoline_disable 7edfb7e0938d0c35
+> connection: keep-alive
+> keep-alive: 30
+> host: index.rubygems.org \ No newline at end of file
diff --git a/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/activemodel/GET/response b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/activemodel/GET/response
new file mode 100644
index 0000000000..6600b05e58
--- /dev/null
+++ b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/activemodel/GET/response
Binary files differ
diff --git a/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/activerecord-deprecated_finders/GET/request b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/activerecord-deprecated_finders/GET/request
new file mode 100644
index 0000000000..095307216d
--- /dev/null
+++ b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/activerecord-deprecated_finders/GET/request
@@ -0,0 +1,7 @@
+> GET /info/activerecord-deprecated_finders
+> accept-encoding: gzip
+> accept: */*
+> user-agent: bundler/1.15.0.pre.2 rubygems/2.6.11 ruby/2.4.1 (x86_64-apple-darwin16.5.0) command/lock options/spec_run,plugins,trampoline_disable 7edfb7e0938d0c35
+> connection: keep-alive
+> keep-alive: 30
+> host: index.rubygems.org \ No newline at end of file
diff --git a/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/activerecord-deprecated_finders/GET/response b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/activerecord-deprecated_finders/GET/response
new file mode 100644
index 0000000000..fa5752cd5a
--- /dev/null
+++ b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/activerecord-deprecated_finders/GET/response
Binary files differ
diff --git a/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/activerecord/GET/request b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/activerecord/GET/request
new file mode 100644
index 0000000000..72983afdb3
--- /dev/null
+++ b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/activerecord/GET/request
@@ -0,0 +1,7 @@
+> GET /info/activerecord
+> accept-encoding: gzip
+> accept: */*
+> user-agent: bundler/1.15.0.pre.2 rubygems/2.6.11 ruby/2.4.1 (x86_64-apple-darwin16.5.0) command/lock options/spec_run,plugins,trampoline_disable 7edfb7e0938d0c35
+> connection: keep-alive
+> keep-alive: 30
+> host: index.rubygems.org \ No newline at end of file
diff --git a/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/activerecord/GET/response b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/activerecord/GET/response
new file mode 100644
index 0000000000..bff1e60a3d
--- /dev/null
+++ b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/activerecord/GET/response
Binary files differ
diff --git a/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/activeresource/GET/request b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/activeresource/GET/request
new file mode 100644
index 0000000000..6da07e07c1
--- /dev/null
+++ b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/activeresource/GET/request
@@ -0,0 +1,7 @@
+> GET /info/activeresource
+> accept-encoding: gzip
+> accept: */*
+> user-agent: bundler/1.15.0.pre.2 rubygems/2.6.11 ruby/2.4.1 (x86_64-apple-darwin16.5.0) command/lock options/spec_run,plugins,trampoline_disable 7edfb7e0938d0c35
+> connection: keep-alive
+> keep-alive: 30
+> host: index.rubygems.org \ No newline at end of file
diff --git a/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/activeresource/GET/response b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/activeresource/GET/response
new file mode 100644
index 0000000000..eb2d07c38e
--- /dev/null
+++ b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/activeresource/GET/response
Binary files differ
diff --git a/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/activesupport/GET/request b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/activesupport/GET/request
new file mode 100644
index 0000000000..e850b19891
--- /dev/null
+++ b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/activesupport/GET/request
@@ -0,0 +1,7 @@
+> GET /info/activesupport
+> accept-encoding: gzip
+> accept: */*
+> user-agent: bundler/1.15.0.pre.2 rubygems/2.6.11 ruby/2.4.1 (x86_64-apple-darwin16.5.0) command/lock options/spec_run,plugins,trampoline_disable 7edfb7e0938d0c35
+> connection: keep-alive
+> keep-alive: 30
+> host: index.rubygems.org \ No newline at end of file
diff --git a/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/activesupport/GET/response b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/activesupport/GET/response
new file mode 100644
index 0000000000..0830e66af9
--- /dev/null
+++ b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/activesupport/GET/response
Binary files differ
diff --git a/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/adamantium/GET/request b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/adamantium/GET/request
new file mode 100644
index 0000000000..b85f0d4abc
--- /dev/null
+++ b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/adamantium/GET/request
@@ -0,0 +1,7 @@
+> GET /info/adamantium
+> accept-encoding: gzip
+> accept: */*
+> user-agent: bundler/1.15.0.pre.2 rubygems/2.6.11 ruby/2.4.1 (x86_64-apple-darwin16.5.0) command/lock options/spec_run,plugins,trampoline_disable 53c83f3e5793993c
+> connection: keep-alive
+> keep-alive: 30
+> host: index.rubygems.org \ No newline at end of file
diff --git a/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/adamantium/GET/response b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/adamantium/GET/response
new file mode 100644
index 0000000000..6a48c16d28
--- /dev/null
+++ b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/adamantium/GET/response
Binary files differ
diff --git a/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/addressable/GET/request b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/addressable/GET/request
new file mode 100644
index 0000000000..332d846d65
--- /dev/null
+++ b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/addressable/GET/request
@@ -0,0 +1,7 @@
+> GET /info/addressable
+> accept-encoding: gzip
+> accept: */*
+> user-agent: bundler/1.15.0.pre.2 rubygems/2.6.11 ruby/2.4.1 (x86_64-apple-darwin16.5.0) command/lock options/spec_run,plugins,trampoline_disable 7edfb7e0938d0c35
+> connection: keep-alive
+> keep-alive: 30
+> host: index.rubygems.org \ No newline at end of file
diff --git a/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/addressable/GET/response b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/addressable/GET/response
new file mode 100644
index 0000000000..19a91431c8
--- /dev/null
+++ b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/addressable/GET/response
Binary files differ
diff --git a/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/allison/GET/request b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/allison/GET/request
new file mode 100644
index 0000000000..8b0e9de941
--- /dev/null
+++ b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/allison/GET/request
@@ -0,0 +1,7 @@
+> GET /info/allison
+> accept-encoding: gzip
+> accept: */*
+> user-agent: bundler/1.15.0.pre.2 rubygems/2.6.11 ruby/2.4.1 (x86_64-apple-darwin16.5.0) command/lock options/spec_run,plugins,trampoline_disable 7edfb7e0938d0c35
+> connection: keep-alive
+> keep-alive: 30
+> host: index.rubygems.org \ No newline at end of file
diff --git a/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/allison/GET/response b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/allison/GET/response
new file mode 100644
index 0000000000..d3ba22327f
--- /dev/null
+++ b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/allison/GET/response
Binary files differ
diff --git a/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/ansi/GET/request b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/ansi/GET/request
new file mode 100644
index 0000000000..35a798ad01
--- /dev/null
+++ b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/ansi/GET/request
@@ -0,0 +1,7 @@
+> GET /info/ansi
+> accept-encoding: gzip
+> accept: */*
+> user-agent: bundler/1.15.0.pre.2 rubygems/2.6.11 ruby/2.4.1 (x86_64-apple-darwin16.5.0) command/lock options/spec_run,plugins,trampoline_disable 7edfb7e0938d0c35
+> connection: keep-alive
+> keep-alive: 30
+> host: index.rubygems.org \ No newline at end of file
diff --git a/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/ansi/GET/response b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/ansi/GET/response
new file mode 100644
index 0000000000..d0d16ff6dd
--- /dev/null
+++ b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/ansi/GET/response
Binary files differ
diff --git a/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/archive-tar-minitar/GET/request b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/archive-tar-minitar/GET/request
new file mode 100644
index 0000000000..15113c6b35
--- /dev/null
+++ b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/archive-tar-minitar/GET/request
@@ -0,0 +1,7 @@
+> GET /info/archive-tar-minitar
+> accept-encoding: gzip
+> accept: */*
+> user-agent: bundler/1.15.0.pre.2 rubygems/2.6.11 ruby/2.4.1 (x86_64-apple-darwin16.5.0) command/lock options/spec_run,plugins,trampoline_disable 7edfb7e0938d0c35
+> connection: keep-alive
+> keep-alive: 30
+> host: index.rubygems.org \ No newline at end of file
diff --git a/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/archive-tar-minitar/GET/response b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/archive-tar-minitar/GET/response
new file mode 100644
index 0000000000..66ba424eb4
--- /dev/null
+++ b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/archive-tar-minitar/GET/response
Binary files differ
diff --git a/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/arel/GET/request b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/arel/GET/request
new file mode 100644
index 0000000000..c8e60e5198
--- /dev/null
+++ b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/arel/GET/request
@@ -0,0 +1,7 @@
+> GET /info/arel
+> accept-encoding: gzip
+> accept: */*
+> user-agent: bundler/1.15.0.pre.2 rubygems/2.6.11 ruby/2.4.1 (x86_64-apple-darwin16.5.0) command/lock options/spec_run,plugins,trampoline_disable 7edfb7e0938d0c35
+> connection: keep-alive
+> keep-alive: 30
+> host: index.rubygems.org \ No newline at end of file
diff --git a/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/arel/GET/response b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/arel/GET/response
new file mode 100644
index 0000000000..71d017141e
--- /dev/null
+++ b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/arel/GET/response
Binary files differ
diff --git a/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/ast/GET/request b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/ast/GET/request
new file mode 100644
index 0000000000..83c157b83d
--- /dev/null
+++ b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/ast/GET/request
@@ -0,0 +1,7 @@
+> GET /info/ast
+> accept-encoding: gzip
+> accept: */*
+> user-agent: bundler/1.15.0.pre.2 rubygems/2.6.11 ruby/2.4.1 (x86_64-apple-darwin16.5.0) command/lock options/spec_run,plugins,trampoline_disable 7edfb7e0938d0c35
+> connection: keep-alive
+> keep-alive: 30
+> host: index.rubygems.org \ No newline at end of file
diff --git a/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/ast/GET/response b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/ast/GET/response
new file mode 100644
index 0000000000..34e8984f9c
--- /dev/null
+++ b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/ast/GET/response
Binary files differ
diff --git a/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/astrolabe/GET/request b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/astrolabe/GET/request
new file mode 100644
index 0000000000..eb816b9425
--- /dev/null
+++ b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/astrolabe/GET/request
@@ -0,0 +1,7 @@
+> GET /info/astrolabe
+> accept-encoding: gzip
+> accept: */*
+> user-agent: bundler/1.15.0.pre.2 rubygems/2.6.11 ruby/2.4.1 (x86_64-apple-darwin16.5.0) command/lock options/spec_run,plugins,trampoline_disable 7edfb7e0938d0c35
+> connection: keep-alive
+> keep-alive: 30
+> host: index.rubygems.org \ No newline at end of file
diff --git a/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/astrolabe/GET/response b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/astrolabe/GET/response
new file mode 100644
index 0000000000..c608b4fcb7
--- /dev/null
+++ b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/astrolabe/GET/response
Binary files differ
diff --git a/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/atomic/GET/request b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/atomic/GET/request
new file mode 100644
index 0000000000..95416a8856
--- /dev/null
+++ b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/atomic/GET/request
@@ -0,0 +1,7 @@
+> GET /info/atomic
+> accept-encoding: gzip
+> accept: */*
+> user-agent: bundler/1.15.0.pre.2 rubygems/2.6.11 ruby/2.4.1 (x86_64-apple-darwin16.5.0) command/lock options/spec_run,plugins,trampoline_disable 7edfb7e0938d0c35
+> connection: keep-alive
+> keep-alive: 30
+> host: index.rubygems.org \ No newline at end of file
diff --git a/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/atomic/GET/response b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/atomic/GET/response
new file mode 100644
index 0000000000..5d99e7e614
--- /dev/null
+++ b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/atomic/GET/response
Binary files differ
diff --git a/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/autoparse/GET/request b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/autoparse/GET/request
new file mode 100644
index 0000000000..9a7e6768c9
--- /dev/null
+++ b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/autoparse/GET/request
@@ -0,0 +1,7 @@
+> GET /info/autoparse
+> accept-encoding: gzip
+> accept: */*
+> user-agent: bundler/1.15.0.pre.2 rubygems/2.6.11 ruby/2.4.1 (x86_64-apple-darwin16.5.0) command/lock options/spec_run,plugins,trampoline_disable 53c83f3e5793993c
+> connection: keep-alive
+> keep-alive: 30
+> host: index.rubygems.org \ No newline at end of file
diff --git a/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/autoparse/GET/response b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/autoparse/GET/response
new file mode 100644
index 0000000000..04b544fda2
--- /dev/null
+++ b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/autoparse/GET/response
Binary files differ
diff --git a/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/axiom-types/GET/request b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/axiom-types/GET/request
new file mode 100644
index 0000000000..56d2f3f4be
--- /dev/null
+++ b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/axiom-types/GET/request
@@ -0,0 +1,7 @@
+> GET /info/axiom-types
+> accept-encoding: gzip
+> accept: */*
+> user-agent: bundler/1.15.0.pre.2 rubygems/2.6.11 ruby/2.4.1 (x86_64-apple-darwin16.5.0) command/lock options/spec_run,plugins,trampoline_disable 53c83f3e5793993c
+> connection: keep-alive
+> keep-alive: 30
+> host: index.rubygems.org \ No newline at end of file
diff --git a/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/axiom-types/GET/response b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/axiom-types/GET/response
new file mode 100644
index 0000000000..096e712deb
--- /dev/null
+++ b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/axiom-types/GET/response
Binary files differ
diff --git a/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/backports/GET/request b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/backports/GET/request
new file mode 100644
index 0000000000..d39a8eefed
--- /dev/null
+++ b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/backports/GET/request
@@ -0,0 +1,7 @@
+> GET /info/backports
+> accept-encoding: gzip
+> accept: */*
+> user-agent: bundler/1.15.0.pre.2 rubygems/2.6.11 ruby/2.4.1 (x86_64-apple-darwin16.5.0) command/lock options/spec_run,plugins,trampoline_disable 7edfb7e0938d0c35
+> connection: keep-alive
+> keep-alive: 30
+> host: index.rubygems.org \ No newline at end of file
diff --git a/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/backports/GET/response b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/backports/GET/response
new file mode 100644
index 0000000000..b964586e01
--- /dev/null
+++ b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/backports/GET/response
Binary files differ
diff --git a/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/bacon/GET/request b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/bacon/GET/request
new file mode 100644
index 0000000000..99b3624b68
--- /dev/null
+++ b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/bacon/GET/request
@@ -0,0 +1,7 @@
+> GET /info/bacon
+> accept-encoding: gzip
+> accept: */*
+> user-agent: bundler/1.15.0.pre.2 rubygems/2.6.11 ruby/2.4.1 (x86_64-apple-darwin16.5.0) command/install options/retry,path,disable_shared_gems,spec_run,plugins,trampoline_disable d59b382d069fc94f
+> connection: keep-alive
+> keep-alive: 30
+> host: index.rubygems.org \ No newline at end of file
diff --git a/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/bacon/GET/response b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/bacon/GET/response
new file mode 100644
index 0000000000..4e072946c4
--- /dev/null
+++ b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/bacon/GET/response
Binary files differ
diff --git a/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/bcrypt-ruby/GET/request b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/bcrypt-ruby/GET/request
new file mode 100644
index 0000000000..da2d06bb39
--- /dev/null
+++ b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/bcrypt-ruby/GET/request
@@ -0,0 +1,7 @@
+> GET /info/bcrypt-ruby
+> accept-encoding: gzip
+> accept: */*
+> user-agent: bundler/1.15.0.pre.2 rubygems/2.6.11 ruby/2.4.1 (x86_64-apple-darwin16.5.0) command/lock options/spec_run,plugins,trampoline_disable 7edfb7e0938d0c35
+> connection: keep-alive
+> keep-alive: 30
+> host: index.rubygems.org \ No newline at end of file
diff --git a/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/bcrypt-ruby/GET/response b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/bcrypt-ruby/GET/response
new file mode 100644
index 0000000000..9fd73895da
--- /dev/null
+++ b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/bcrypt-ruby/GET/response
Binary files differ
diff --git a/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/bcrypt/GET/request b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/bcrypt/GET/request
new file mode 100644
index 0000000000..6516d4f90d
--- /dev/null
+++ b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/bcrypt/GET/request
@@ -0,0 +1,7 @@
+> GET /info/bcrypt
+> accept-encoding: gzip
+> accept: */*
+> user-agent: bundler/1.15.0.pre.2 rubygems/2.6.11 ruby/2.4.1 (x86_64-apple-darwin16.5.0) command/lock options/spec_run,plugins,trampoline_disable 7edfb7e0938d0c35
+> connection: keep-alive
+> keep-alive: 30
+> host: index.rubygems.org \ No newline at end of file
diff --git a/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/bcrypt/GET/response b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/bcrypt/GET/response
new file mode 100644
index 0000000000..22f10c15a9
--- /dev/null
+++ b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/bcrypt/GET/response
Binary files differ
diff --git a/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/bcrypt_pbkdf/GET/request b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/bcrypt_pbkdf/GET/request
new file mode 100644
index 0000000000..cba3167ca3
--- /dev/null
+++ b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/bcrypt_pbkdf/GET/request
@@ -0,0 +1,7 @@
+> GET /info/bcrypt_pbkdf
+> accept-encoding: gzip
+> accept: */*
+> user-agent: bundler/1.15.0.pre.2 rubygems/2.6.11 ruby/2.4.1 (x86_64-apple-darwin16.5.0) command/lock options/spec_run,plugins,trampoline_disable 7edfb7e0938d0c35
+> connection: keep-alive
+> keep-alive: 30
+> host: index.rubygems.org \ No newline at end of file
diff --git a/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/bcrypt_pbkdf/GET/response b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/bcrypt_pbkdf/GET/response
new file mode 100644
index 0000000000..52e3f662f6
--- /dev/null
+++ b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/bcrypt_pbkdf/GET/response
Binary files differ
diff --git a/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/bones-extras/GET/request b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/bones-extras/GET/request
new file mode 100644
index 0000000000..a42bb5fc39
--- /dev/null
+++ b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/bones-extras/GET/request
@@ -0,0 +1,7 @@
+> GET /info/bones-extras
+> accept-encoding: gzip
+> accept: */*
+> user-agent: bundler/1.15.0.pre.2 rubygems/2.6.11 ruby/2.4.1 (x86_64-apple-darwin16.5.0) command/lock options/spec_run,plugins,trampoline_disable 7edfb7e0938d0c35
+> connection: keep-alive
+> keep-alive: 30
+> host: index.rubygems.org \ No newline at end of file
diff --git a/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/bones-extras/GET/response b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/bones-extras/GET/response
new file mode 100644
index 0000000000..17c018a8ac
--- /dev/null
+++ b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/bones-extras/GET/response
Binary files differ
diff --git a/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/bones-git/GET/request b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/bones-git/GET/request
new file mode 100644
index 0000000000..f887a9d8b9
--- /dev/null
+++ b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/bones-git/GET/request
@@ -0,0 +1,7 @@
+> GET /info/bones-git
+> accept-encoding: gzip
+> accept: */*
+> user-agent: bundler/1.15.0.pre.2 rubygems/2.6.11 ruby/2.4.1 (x86_64-apple-darwin16.5.0) command/lock options/spec_run,plugins,trampoline_disable 7edfb7e0938d0c35
+> connection: keep-alive
+> keep-alive: 30
+> host: index.rubygems.org \ No newline at end of file
diff --git a/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/bones-git/GET/response b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/bones-git/GET/response
new file mode 100644
index 0000000000..08fe306b65
--- /dev/null
+++ b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/bones-git/GET/response
Binary files differ
diff --git a/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/bones-rcov/GET/request b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/bones-rcov/GET/request
new file mode 100644
index 0000000000..123d71230b
--- /dev/null
+++ b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/bones-rcov/GET/request
@@ -0,0 +1,7 @@
+> GET /info/bones-rcov
+> accept-encoding: gzip
+> accept: */*
+> user-agent: bundler/1.15.0.pre.2 rubygems/2.6.11 ruby/2.4.1 (x86_64-apple-darwin16.5.0) command/lock options/spec_run,plugins,trampoline_disable 7edfb7e0938d0c35
+> connection: keep-alive
+> keep-alive: 30
+> host: index.rubygems.org \ No newline at end of file
diff --git a/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/bones-rcov/GET/response b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/bones-rcov/GET/response
new file mode 100644
index 0000000000..76b01488ea
--- /dev/null
+++ b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/bones-rcov/GET/response
Binary files differ
diff --git a/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/bones-rspec/GET/request b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/bones-rspec/GET/request
new file mode 100644
index 0000000000..11d8de5fd1
--- /dev/null
+++ b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/bones-rspec/GET/request
@@ -0,0 +1,7 @@
+> GET /info/bones-rspec
+> accept-encoding: gzip
+> accept: */*
+> user-agent: bundler/1.15.0.pre.2 rubygems/2.6.11 ruby/2.4.1 (x86_64-apple-darwin16.5.0) command/lock options/spec_run,plugins,trampoline_disable 7edfb7e0938d0c35
+> connection: keep-alive
+> keep-alive: 30
+> host: index.rubygems.org \ No newline at end of file
diff --git a/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/bones-rspec/GET/response b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/bones-rspec/GET/response
new file mode 100644
index 0000000000..a82c0fc9ee
--- /dev/null
+++ b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/bones-rspec/GET/response
Binary files differ
diff --git a/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/bones-rubyforge/GET/request b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/bones-rubyforge/GET/request
new file mode 100644
index 0000000000..759c5dc5a7
--- /dev/null
+++ b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/bones-rubyforge/GET/request
@@ -0,0 +1,7 @@
+> GET /info/bones-rubyforge
+> accept-encoding: gzip
+> accept: */*
+> user-agent: bundler/1.15.0.pre.2 rubygems/2.6.11 ruby/2.4.1 (x86_64-apple-darwin16.5.0) command/lock options/spec_run,plugins,trampoline_disable 7edfb7e0938d0c35
+> connection: keep-alive
+> keep-alive: 30
+> host: index.rubygems.org \ No newline at end of file
diff --git a/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/bones-rubyforge/GET/response b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/bones-rubyforge/GET/response
new file mode 100644
index 0000000000..685f899378
--- /dev/null
+++ b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/bones-rubyforge/GET/response
Binary files differ
diff --git a/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/bones-zentest/GET/request b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/bones-zentest/GET/request
new file mode 100644
index 0000000000..ae5a9b068f
--- /dev/null
+++ b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/bones-zentest/GET/request
@@ -0,0 +1,7 @@
+> GET /info/bones-zentest
+> accept-encoding: gzip
+> accept: */*
+> user-agent: bundler/1.15.0.pre.2 rubygems/2.6.11 ruby/2.4.1 (x86_64-apple-darwin16.5.0) command/lock options/spec_run,plugins,trampoline_disable 7edfb7e0938d0c35
+> connection: keep-alive
+> keep-alive: 30
+> host: index.rubygems.org \ No newline at end of file
diff --git a/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/bones-zentest/GET/response b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/bones-zentest/GET/response
new file mode 100644
index 0000000000..2b69b3ed62
--- /dev/null
+++ b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/bones-zentest/GET/response
Binary files differ
diff --git a/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/bones/GET/request b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/bones/GET/request
new file mode 100644
index 0000000000..3e6d44e52f
--- /dev/null
+++ b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/bones/GET/request
@@ -0,0 +1,7 @@
+> GET /info/bones
+> accept-encoding: gzip
+> accept: */*
+> user-agent: bundler/1.15.0.pre.2 rubygems/2.6.11 ruby/2.4.1 (x86_64-apple-darwin16.5.0) command/lock options/spec_run,plugins,trampoline_disable 7edfb7e0938d0c35
+> connection: keep-alive
+> keep-alive: 30
+> host: index.rubygems.org \ No newline at end of file
diff --git a/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/bones/GET/response b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/bones/GET/response
new file mode 100644
index 0000000000..6dc4b11a25
--- /dev/null
+++ b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/bones/GET/response
Binary files differ
diff --git a/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/builder/GET/request b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/builder/GET/request
new file mode 100644
index 0000000000..5fe5431bfa
--- /dev/null
+++ b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/builder/GET/request
@@ -0,0 +1,7 @@
+> GET /info/builder
+> accept-encoding: gzip
+> accept: */*
+> user-agent: bundler/1.15.0.pre.2 rubygems/2.6.11 ruby/2.4.1 (x86_64-apple-darwin16.5.0) command/lock options/spec_run,plugins,trampoline_disable 7edfb7e0938d0c35
+> connection: keep-alive
+> keep-alive: 30
+> host: index.rubygems.org \ No newline at end of file
diff --git a/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/builder/GET/response b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/builder/GET/response
new file mode 100644
index 0000000000..bd2e97ab92
--- /dev/null
+++ b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/builder/GET/response
Binary files differ
diff --git a/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/bundler/GET/request b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/bundler/GET/request
new file mode 100644
index 0000000000..d0af347d8a
--- /dev/null
+++ b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/bundler/GET/request
@@ -0,0 +1,7 @@
+> GET /info/bundler
+> accept-encoding: gzip
+> accept: */*
+> user-agent: bundler/1.15.0.pre.2 rubygems/2.6.11 ruby/2.4.1 (x86_64-apple-darwin16.5.0) command/lock options/spec_run,plugins,trampoline_disable 7edfb7e0938d0c35
+> connection: keep-alive
+> keep-alive: 30
+> host: index.rubygems.org \ No newline at end of file
diff --git a/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/bundler/GET/response b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/bundler/GET/response
new file mode 100644
index 0000000000..41da082444
--- /dev/null
+++ b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/bundler/GET/response
Binary files differ
diff --git a/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/camping/GET/request b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/camping/GET/request
new file mode 100644
index 0000000000..d40975748c
--- /dev/null
+++ b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/camping/GET/request
@@ -0,0 +1,7 @@
+> GET /info/camping
+> accept-encoding: gzip
+> accept: */*
+> user-agent: bundler/1.15.0.pre.2 rubygems/2.6.11 ruby/2.4.1 (x86_64-apple-darwin16.5.0) command/lock options/spec_run,plugins,trampoline_disable 7edfb7e0938d0c35
+> connection: keep-alive
+> keep-alive: 30
+> host: index.rubygems.org \ No newline at end of file
diff --git a/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/camping/GET/response b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/camping/GET/response
new file mode 100644
index 0000000000..c9a4dbcbc1
--- /dev/null
+++ b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/camping/GET/response
Binary files differ
diff --git a/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/capybara/GET/request b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/capybara/GET/request
new file mode 100644
index 0000000000..4e852e84e4
--- /dev/null
+++ b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/capybara/GET/request
@@ -0,0 +1,7 @@
+> GET /info/capybara
+> accept-encoding: gzip
+> accept: */*
+> user-agent: bundler/1.15.0.pre.2 rubygems/2.6.11 ruby/2.4.1 (x86_64-apple-darwin16.5.0) command/lock options/spec_run,plugins,trampoline_disable 7edfb7e0938d0c35
+> connection: keep-alive
+> keep-alive: 30
+> host: index.rubygems.org \ No newline at end of file
diff --git a/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/capybara/GET/response b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/capybara/GET/response
new file mode 100644
index 0000000000..9afec9a3a6
--- /dev/null
+++ b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/capybara/GET/response
Binary files differ
diff --git a/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/celerity/GET/request b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/celerity/GET/request
new file mode 100644
index 0000000000..8ae268566f
--- /dev/null
+++ b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/celerity/GET/request
@@ -0,0 +1,7 @@
+> GET /info/celerity
+> accept-encoding: gzip
+> accept: */*
+> user-agent: bundler/1.15.0.pre.2 rubygems/2.6.11 ruby/2.4.1 (x86_64-apple-darwin16.5.0) command/lock options/spec_run,plugins,trampoline_disable 7edfb7e0938d0c35
+> connection: keep-alive
+> keep-alive: 30
+> host: index.rubygems.org \ No newline at end of file
diff --git a/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/celerity/GET/response b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/celerity/GET/response
new file mode 100644
index 0000000000..585c893662
--- /dev/null
+++ b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/celerity/GET/response
Binary files differ
diff --git a/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/celluloid-essentials/GET/request b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/celluloid-essentials/GET/request
new file mode 100644
index 0000000000..caa2b64772
--- /dev/null
+++ b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/celluloid-essentials/GET/request
@@ -0,0 +1,7 @@
+> GET /info/celluloid-essentials
+> accept-encoding: gzip
+> accept: */*
+> user-agent: bundler/1.15.0.pre.2 rubygems/2.6.11 ruby/2.4.1 (x86_64-apple-darwin16.5.0) command/lock options/spec_run,plugins,trampoline_disable 7edfb7e0938d0c35
+> connection: keep-alive
+> keep-alive: 30
+> host: index.rubygems.org \ No newline at end of file
diff --git a/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/celluloid-essentials/GET/response b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/celluloid-essentials/GET/response
new file mode 100644
index 0000000000..33973fc9d1
--- /dev/null
+++ b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/celluloid-essentials/GET/response
Binary files differ
diff --git a/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/celluloid-extras/GET/request b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/celluloid-extras/GET/request
new file mode 100644
index 0000000000..3680210c06
--- /dev/null
+++ b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/celluloid-extras/GET/request
@@ -0,0 +1,7 @@
+> GET /info/celluloid-extras
+> accept-encoding: gzip
+> accept: */*
+> user-agent: bundler/1.15.0.pre.2 rubygems/2.6.11 ruby/2.4.1 (x86_64-apple-darwin16.5.0) command/lock options/spec_run,plugins,trampoline_disable 7edfb7e0938d0c35
+> connection: keep-alive
+> keep-alive: 30
+> host: index.rubygems.org \ No newline at end of file
diff --git a/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/celluloid-extras/GET/response b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/celluloid-extras/GET/response
new file mode 100644
index 0000000000..f01977e2ea
--- /dev/null
+++ b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/celluloid-extras/GET/response
Binary files differ
diff --git a/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/celluloid-fsm/GET/request b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/celluloid-fsm/GET/request
new file mode 100644
index 0000000000..9ab4a9f9a5
--- /dev/null
+++ b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/celluloid-fsm/GET/request
@@ -0,0 +1,7 @@
+> GET /info/celluloid-fsm
+> accept-encoding: gzip
+> accept: */*
+> user-agent: bundler/1.15.0.pre.2 rubygems/2.6.11 ruby/2.4.1 (x86_64-apple-darwin16.5.0) command/lock options/spec_run,plugins,trampoline_disable 7edfb7e0938d0c35
+> connection: keep-alive
+> keep-alive: 30
+> host: index.rubygems.org \ No newline at end of file
diff --git a/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/celluloid-fsm/GET/response b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/celluloid-fsm/GET/response
new file mode 100644
index 0000000000..806ba68900
--- /dev/null
+++ b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/celluloid-fsm/GET/response
Binary files differ
diff --git a/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/celluloid-io/GET/request b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/celluloid-io/GET/request
new file mode 100644
index 0000000000..48deb49201
--- /dev/null
+++ b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/celluloid-io/GET/request
@@ -0,0 +1,7 @@
+> GET /info/celluloid-io
+> accept-encoding: gzip
+> accept: */*
+> user-agent: bundler/1.15.0.pre.2 rubygems/2.6.11 ruby/2.4.1 (x86_64-apple-darwin16.5.0) command/lock options/spec_run,plugins,trampoline_disable 53c83f3e5793993c
+> connection: keep-alive
+> keep-alive: 30
+> host: index.rubygems.org \ No newline at end of file
diff --git a/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/celluloid-io/GET/response b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/celluloid-io/GET/response
new file mode 100644
index 0000000000..d56b30c56c
--- /dev/null
+++ b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/celluloid-io/GET/response
Binary files differ
diff --git a/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/celluloid-pool/GET/request b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/celluloid-pool/GET/request
new file mode 100644
index 0000000000..375710b600
--- /dev/null
+++ b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/celluloid-pool/GET/request
@@ -0,0 +1,7 @@
+> GET /info/celluloid-pool
+> accept-encoding: gzip
+> accept: */*
+> user-agent: bundler/1.15.0.pre.2 rubygems/2.6.11 ruby/2.4.1 (x86_64-apple-darwin16.5.0) command/lock options/spec_run,plugins,trampoline_disable 7edfb7e0938d0c35
+> connection: keep-alive
+> keep-alive: 30
+> host: index.rubygems.org \ No newline at end of file
diff --git a/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/celluloid-pool/GET/response b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/celluloid-pool/GET/response
new file mode 100644
index 0000000000..9668a5eb7f
--- /dev/null
+++ b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/celluloid-pool/GET/response
Binary files differ
diff --git a/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/celluloid-supervision/GET/request b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/celluloid-supervision/GET/request
new file mode 100644
index 0000000000..62acec8401
--- /dev/null
+++ b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/celluloid-supervision/GET/request
@@ -0,0 +1,7 @@
+> GET /info/celluloid-supervision
+> accept-encoding: gzip
+> accept: */*
+> user-agent: bundler/1.15.0.pre.2 rubygems/2.6.11 ruby/2.4.1 (x86_64-apple-darwin16.5.0) command/lock options/spec_run,plugins,trampoline_disable 7edfb7e0938d0c35
+> connection: keep-alive
+> keep-alive: 30
+> host: index.rubygems.org \ No newline at end of file
diff --git a/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/celluloid-supervision/GET/response b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/celluloid-supervision/GET/response
new file mode 100644
index 0000000000..90faa1a6b9
--- /dev/null
+++ b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/celluloid-supervision/GET/response
Binary files differ
diff --git a/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/celluloid/GET/request b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/celluloid/GET/request
new file mode 100644
index 0000000000..ea4c6081c6
--- /dev/null
+++ b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/celluloid/GET/request
@@ -0,0 +1,7 @@
+> GET /info/celluloid
+> accept-encoding: gzip
+> accept: */*
+> user-agent: bundler/1.15.0.pre.2 rubygems/2.6.11 ruby/2.4.1 (x86_64-apple-darwin16.5.0) command/lock options/spec_run,plugins,trampoline_disable 7edfb7e0938d0c35
+> connection: keep-alive
+> keep-alive: 30
+> host: index.rubygems.org \ No newline at end of file
diff --git a/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/celluloid/GET/response b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/celluloid/GET/response
new file mode 100644
index 0000000000..d77594e62d
--- /dev/null
+++ b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/celluloid/GET/response
Binary files differ
diff --git a/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/cgi_multipart_eof_fix/GET/request b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/cgi_multipart_eof_fix/GET/request
new file mode 100644
index 0000000000..2087abff17
--- /dev/null
+++ b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/cgi_multipart_eof_fix/GET/request
@@ -0,0 +1,7 @@
+> GET /info/cgi_multipart_eof_fix
+> accept-encoding: gzip
+> accept: */*
+> user-agent: bundler/1.15.0.pre.2 rubygems/2.6.11 ruby/2.4.1 (x86_64-apple-darwin16.5.0) command/lock options/spec_run,plugins,trampoline_disable 7edfb7e0938d0c35
+> connection: keep-alive
+> keep-alive: 30
+> host: index.rubygems.org \ No newline at end of file
diff --git a/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/cgi_multipart_eof_fix/GET/response b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/cgi_multipart_eof_fix/GET/response
new file mode 100644
index 0000000000..a66ec83d22
--- /dev/null
+++ b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/cgi_multipart_eof_fix/GET/response
Binary files differ
diff --git a/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/childprocess/GET/request b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/childprocess/GET/request
new file mode 100644
index 0000000000..c9c4c8e1c3
--- /dev/null
+++ b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/childprocess/GET/request
@@ -0,0 +1,7 @@
+> GET /info/childprocess
+> accept-encoding: gzip
+> accept: */*
+> user-agent: bundler/1.15.0.pre.2 rubygems/2.6.11 ruby/2.4.1 (x86_64-apple-darwin16.5.0) command/lock options/spec_run,plugins,trampoline_disable 7edfb7e0938d0c35
+> connection: keep-alive
+> keep-alive: 30
+> host: index.rubygems.org \ No newline at end of file
diff --git a/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/childprocess/GET/response b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/childprocess/GET/response
new file mode 100644
index 0000000000..e92674716c
--- /dev/null
+++ b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/childprocess/GET/response
Binary files differ
diff --git a/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/climate_control/GET/request b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/climate_control/GET/request
new file mode 100644
index 0000000000..627dfc2236
--- /dev/null
+++ b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/climate_control/GET/request
@@ -0,0 +1,7 @@
+> GET /info/climate_control
+> accept-encoding: gzip
+> accept: */*
+> user-agent: bundler/1.15.0.pre.2 rubygems/2.6.11 ruby/2.4.1 (x86_64-apple-darwin16.5.0) command/lock options/spec_run,plugins,trampoline_disable 6d5397ce7f8b26e0
+> connection: keep-alive
+> keep-alive: 30
+> host: index.rubygems.org \ No newline at end of file
diff --git a/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/climate_control/GET/response b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/climate_control/GET/response
new file mode 100644
index 0000000000..2d5960987c
--- /dev/null
+++ b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/climate_control/GET/response
Binary files differ
diff --git a/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/cocaine/GET/request b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/cocaine/GET/request
new file mode 100644
index 0000000000..0b58b496a2
--- /dev/null
+++ b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/cocaine/GET/request
@@ -0,0 +1,7 @@
+> GET /info/cocaine
+> accept-encoding: gzip
+> accept: */*
+> user-agent: bundler/1.15.0.pre.2 rubygems/2.6.11 ruby/2.4.1 (x86_64-apple-darwin16.5.0) command/lock options/spec_run,plugins,trampoline_disable 6d5397ce7f8b26e0
+> connection: keep-alive
+> keep-alive: 30
+> host: index.rubygems.org \ No newline at end of file
diff --git a/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/cocaine/GET/response b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/cocaine/GET/response
new file mode 100644
index 0000000000..bfd985f32e
--- /dev/null
+++ b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/cocaine/GET/response
Binary files differ
diff --git a/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/coercible/GET/request b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/coercible/GET/request
new file mode 100644
index 0000000000..26fb80abd9
--- /dev/null
+++ b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/coercible/GET/request
@@ -0,0 +1,7 @@
+> GET /info/coercible
+> accept-encoding: gzip
+> accept: */*
+> user-agent: bundler/1.15.0.pre.2 rubygems/2.6.11 ruby/2.4.1 (x86_64-apple-darwin16.5.0) command/lock options/spec_run,plugins,trampoline_disable 53c83f3e5793993c
+> connection: keep-alive
+> keep-alive: 30
+> host: index.rubygems.org \ No newline at end of file
diff --git a/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/coercible/GET/response b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/coercible/GET/response
new file mode 100644
index 0000000000..54e169a319
--- /dev/null
+++ b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/coercible/GET/response
Binary files differ
diff --git a/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/coffee-rails/GET/request b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/coffee-rails/GET/request
new file mode 100644
index 0000000000..35f65b1c96
--- /dev/null
+++ b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/coffee-rails/GET/request
@@ -0,0 +1,7 @@
+> GET /info/coffee-rails
+> accept-encoding: gzip
+> accept: */*
+> user-agent: bundler/1.15.0.pre.2 rubygems/2.6.11 ruby/2.4.1 (x86_64-apple-darwin16.5.0) command/lock options/spec_run,plugins,trampoline_disable 7edfb7e0938d0c35
+> connection: keep-alive
+> keep-alive: 30
+> host: index.rubygems.org \ No newline at end of file
diff --git a/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/coffee-rails/GET/response b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/coffee-rails/GET/response
new file mode 100644
index 0000000000..d5e17e5ce9
--- /dev/null
+++ b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/coffee-rails/GET/response
Binary files differ
diff --git a/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/coffee-script-source/GET/request b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/coffee-script-source/GET/request
new file mode 100644
index 0000000000..c1e276d2f2
--- /dev/null
+++ b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/coffee-script-source/GET/request
@@ -0,0 +1,7 @@
+> GET /info/coffee-script-source
+> accept-encoding: gzip
+> accept: */*
+> user-agent: bundler/1.15.0.pre.2 rubygems/2.6.11 ruby/2.4.1 (x86_64-apple-darwin16.5.0) command/lock options/spec_run,plugins,trampoline_disable 7edfb7e0938d0c35
+> connection: keep-alive
+> keep-alive: 30
+> host: index.rubygems.org \ No newline at end of file
diff --git a/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/coffee-script-source/GET/response b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/coffee-script-source/GET/response
new file mode 100644
index 0000000000..95f31d23d8
--- /dev/null
+++ b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/coffee-script-source/GET/response
Binary files differ
diff --git a/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/coffee-script/GET/request b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/coffee-script/GET/request
new file mode 100644
index 0000000000..6fb40106a3
--- /dev/null
+++ b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/coffee-script/GET/request
@@ -0,0 +1,7 @@
+> GET /info/coffee-script
+> accept-encoding: gzip
+> accept: */*
+> user-agent: bundler/1.15.0.pre.2 rubygems/2.6.11 ruby/2.4.1 (x86_64-apple-darwin16.5.0) command/lock options/spec_run,plugins,trampoline_disable 7edfb7e0938d0c35
+> connection: keep-alive
+> keep-alive: 30
+> host: index.rubygems.org \ No newline at end of file
diff --git a/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/coffee-script/GET/response b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/coffee-script/GET/response
new file mode 100644
index 0000000000..f513d56091
--- /dev/null
+++ b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/coffee-script/GET/response
Binary files differ
diff --git a/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/colorize/GET/request b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/colorize/GET/request
new file mode 100644
index 0000000000..86a09b2b35
--- /dev/null
+++ b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/colorize/GET/request
@@ -0,0 +1,7 @@
+> GET /info/colorize
+> accept-encoding: gzip
+> accept: */*
+> user-agent: bundler/1.15.0.pre.2 rubygems/2.6.11 ruby/2.4.1 (x86_64-apple-darwin16.5.0) command/lock options/spec_run,plugins,trampoline_disable 7edfb7e0938d0c35
+> connection: keep-alive
+> keep-alive: 30
+> host: index.rubygems.org \ No newline at end of file
diff --git a/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/colorize/GET/response b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/colorize/GET/response
new file mode 100644
index 0000000000..25dd358184
--- /dev/null
+++ b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/colorize/GET/response
Binary files differ
diff --git a/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/concurrent-ruby/GET/request b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/concurrent-ruby/GET/request
new file mode 100644
index 0000000000..0069d6d724
--- /dev/null
+++ b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/concurrent-ruby/GET/request
@@ -0,0 +1,7 @@
+> GET /info/concurrent-ruby
+> accept-encoding: gzip
+> accept: */*
+> user-agent: bundler/1.15.0.pre.2 rubygems/2.6.11 ruby/2.4.1 (x86_64-apple-darwin16.5.0) command/lock options/spec_run,plugins,trampoline_disable 7edfb7e0938d0c35
+> connection: keep-alive
+> keep-alive: 30
+> host: index.rubygems.org \ No newline at end of file
diff --git a/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/concurrent-ruby/GET/response b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/concurrent-ruby/GET/response
new file mode 100644
index 0000000000..186892a49c
--- /dev/null
+++ b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/concurrent-ruby/GET/response
Binary files differ
diff --git a/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/configuration/GET/request b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/configuration/GET/request
new file mode 100644
index 0000000000..70e600db3d
--- /dev/null
+++ b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/configuration/GET/request
@@ -0,0 +1,7 @@
+> GET /info/configuration
+> accept-encoding: gzip
+> accept: */*
+> user-agent: bundler/1.15.0.pre.2 rubygems/2.6.11 ruby/2.4.1 (x86_64-apple-darwin16.5.0) command/lock options/spec_run,plugins,trampoline_disable 7edfb7e0938d0c35
+> connection: keep-alive
+> keep-alive: 30
+> host: index.rubygems.org \ No newline at end of file
diff --git a/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/configuration/GET/response b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/configuration/GET/response
new file mode 100644
index 0000000000..1e1fb6fa74
--- /dev/null
+++ b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/configuration/GET/response
Binary files differ
diff --git a/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/coveralls/GET/request b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/coveralls/GET/request
new file mode 100644
index 0000000000..5692539d94
--- /dev/null
+++ b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/coveralls/GET/request
@@ -0,0 +1,7 @@
+> GET /info/coveralls
+> accept-encoding: gzip
+> accept: */*
+> user-agent: bundler/1.15.0.pre.2 rubygems/2.6.11 ruby/2.4.1 (x86_64-apple-darwin16.5.0) command/lock options/spec_run,plugins,trampoline_disable 7edfb7e0938d0c35
+> connection: keep-alive
+> keep-alive: 30
+> host: index.rubygems.org \ No newline at end of file
diff --git a/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/coveralls/GET/response b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/coveralls/GET/response
new file mode 100644
index 0000000000..314e64865c
--- /dev/null
+++ b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/coveralls/GET/response
Binary files differ
diff --git a/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/crass/GET/request b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/crass/GET/request
new file mode 100644
index 0000000000..8b9407ffc0
--- /dev/null
+++ b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/crass/GET/request
@@ -0,0 +1,7 @@
+> GET /info/crass
+> accept-encoding: gzip
+> accept: */*
+> user-agent: bundler/1.15.0.pre.2 rubygems/2.6.11 ruby/2.4.1 (x86_64-apple-darwin16.5.0) command/lock options/spec_run,plugins,trampoline_disable 7edfb7e0938d0c35
+> connection: keep-alive
+> keep-alive: 30
+> host: index.rubygems.org \ No newline at end of file
diff --git a/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/crass/GET/response b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/crass/GET/response
new file mode 100644
index 0000000000..d73b4d2f17
--- /dev/null
+++ b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/crass/GET/response
Binary files differ
diff --git a/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/cucumber-core/GET/request b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/cucumber-core/GET/request
new file mode 100644
index 0000000000..2675af7847
--- /dev/null
+++ b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/cucumber-core/GET/request
@@ -0,0 +1,7 @@
+> GET /info/cucumber-core
+> accept-encoding: gzip
+> accept: */*
+> user-agent: bundler/1.15.0.pre.2 rubygems/2.6.11 ruby/2.4.1 (x86_64-apple-darwin16.5.0) command/lock options/spec_run,plugins,trampoline_disable 7edfb7e0938d0c35
+> connection: keep-alive
+> keep-alive: 30
+> host: index.rubygems.org \ No newline at end of file
diff --git a/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/cucumber-core/GET/response b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/cucumber-core/GET/response
new file mode 100644
index 0000000000..defc43e284
--- /dev/null
+++ b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/cucumber-core/GET/response
Binary files differ
diff --git a/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/cucumber-wire/GET/request b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/cucumber-wire/GET/request
new file mode 100644
index 0000000000..f37e871807
--- /dev/null
+++ b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/cucumber-wire/GET/request
@@ -0,0 +1,7 @@
+> GET /info/cucumber-wire
+> accept-encoding: gzip
+> accept: */*
+> user-agent: bundler/1.15.0.pre.2 rubygems/2.6.11 ruby/2.4.1 (x86_64-apple-darwin16.5.0) command/lock options/spec_run,plugins,trampoline_disable 7edfb7e0938d0c35
+> connection: keep-alive
+> keep-alive: 30
+> host: index.rubygems.org \ No newline at end of file
diff --git a/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/cucumber-wire/GET/response b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/cucumber-wire/GET/response
new file mode 100644
index 0000000000..dd6a2d7a1f
--- /dev/null
+++ b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/cucumber-wire/GET/response
Binary files differ
diff --git a/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/cucumber/GET/request b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/cucumber/GET/request
new file mode 100644
index 0000000000..db80e44ac1
--- /dev/null
+++ b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/cucumber/GET/request
@@ -0,0 +1,7 @@
+> GET /info/cucumber
+> accept-encoding: gzip
+> accept: */*
+> user-agent: bundler/1.15.0.pre.2 rubygems/2.6.11 ruby/2.4.1 (x86_64-apple-darwin16.5.0) command/lock options/spec_run,plugins,trampoline_disable 7edfb7e0938d0c35
+> connection: keep-alive
+> keep-alive: 30
+> host: index.rubygems.org \ No newline at end of file
diff --git a/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/cucumber/GET/response b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/cucumber/GET/response
new file mode 100644
index 0000000000..8ec223a388
--- /dev/null
+++ b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/cucumber/GET/response
Binary files differ
diff --git a/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/culerity/GET/request b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/culerity/GET/request
new file mode 100644
index 0000000000..f92a2f7bc9
--- /dev/null
+++ b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/culerity/GET/request
@@ -0,0 +1,7 @@
+> GET /info/culerity
+> accept-encoding: gzip
+> accept: */*
+> user-agent: bundler/1.15.0.pre.2 rubygems/2.6.11 ruby/2.4.1 (x86_64-apple-darwin16.5.0) command/lock options/spec_run,plugins,trampoline_disable 7edfb7e0938d0c35
+> connection: keep-alive
+> keep-alive: 30
+> host: index.rubygems.org \ No newline at end of file
diff --git a/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/culerity/GET/response b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/culerity/GET/response
new file mode 100644
index 0000000000..a26aae4ac6
--- /dev/null
+++ b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/culerity/GET/response
Binary files differ
diff --git a/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/curses/GET/request b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/curses/GET/request
new file mode 100644
index 0000000000..1119c8e4fa
--- /dev/null
+++ b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/curses/GET/request
@@ -0,0 +1,7 @@
+> GET /info/curses
+> accept-encoding: gzip
+> accept: */*
+> user-agent: bundler/1.15.0.pre.2 rubygems/2.6.11 ruby/2.4.1 (x86_64-apple-darwin16.5.0) command/lock options/spec_run,plugins,trampoline_disable 7edfb7e0938d0c35
+> connection: keep-alive
+> keep-alive: 30
+> host: index.rubygems.org \ No newline at end of file
diff --git a/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/curses/GET/response b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/curses/GET/response
new file mode 100644
index 0000000000..1450b0afdd
--- /dev/null
+++ b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/curses/GET/response
Binary files differ
diff --git a/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/daemons/GET/request b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/daemons/GET/request
new file mode 100644
index 0000000000..5080c98e6d
--- /dev/null
+++ b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/daemons/GET/request
@@ -0,0 +1,7 @@
+> GET /info/daemons
+> accept-encoding: gzip
+> accept: */*
+> user-agent: bundler/1.15.0.pre.2 rubygems/2.6.11 ruby/2.4.1 (x86_64-apple-darwin16.5.0) command/lock options/spec_run,plugins,trampoline_disable 7edfb7e0938d0c35
+> connection: keep-alive
+> keep-alive: 30
+> host: index.rubygems.org \ No newline at end of file
diff --git a/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/daemons/GET/response b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/daemons/GET/response
new file mode 100644
index 0000000000..f96024298f
--- /dev/null
+++ b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/daemons/GET/response
Binary files differ
diff --git a/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/database_cleaner/GET/request b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/database_cleaner/GET/request
new file mode 100644
index 0000000000..d80f93551a
--- /dev/null
+++ b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/database_cleaner/GET/request
@@ -0,0 +1,7 @@
+> GET /info/database_cleaner
+> accept-encoding: gzip
+> accept: */*
+> user-agent: bundler/1.15.0.pre.2 rubygems/2.6.11 ruby/2.4.1 (x86_64-apple-darwin16.5.0) command/lock options/spec_run,plugins,trampoline_disable 7edfb7e0938d0c35
+> connection: keep-alive
+> keep-alive: 30
+> host: index.rubygems.org \ No newline at end of file
diff --git a/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/database_cleaner/GET/response b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/database_cleaner/GET/response
new file mode 100644
index 0000000000..362be4a4da
--- /dev/null
+++ b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/database_cleaner/GET/response
Binary files differ
diff --git a/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/declarative-option/GET/request b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/declarative-option/GET/request
new file mode 100644
index 0000000000..f2463924fc
--- /dev/null
+++ b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/declarative-option/GET/request
@@ -0,0 +1,7 @@
+> GET /info/declarative-option
+> accept-encoding: gzip
+> accept: */*
+> user-agent: bundler/1.15.0.pre.2 rubygems/2.6.11 ruby/2.4.1 (x86_64-apple-darwin16.5.0) command/lock options/spec_run,plugins,trampoline_disable 53c83f3e5793993c
+> connection: keep-alive
+> keep-alive: 30
+> host: index.rubygems.org \ No newline at end of file
diff --git a/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/declarative-option/GET/response b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/declarative-option/GET/response
new file mode 100644
index 0000000000..02d0a6c4d8
--- /dev/null
+++ b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/declarative-option/GET/response
Binary files differ
diff --git a/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/declarative/GET/request b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/declarative/GET/request
new file mode 100644
index 0000000000..de13d40070
--- /dev/null
+++ b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/declarative/GET/request
@@ -0,0 +1,7 @@
+> GET /info/declarative
+> accept-encoding: gzip
+> accept: */*
+> user-agent: bundler/1.15.0.pre.2 rubygems/2.6.11 ruby/2.4.1 (x86_64-apple-darwin16.5.0) command/lock options/spec_run,plugins,trampoline_disable 53c83f3e5793993c
+> connection: keep-alive
+> keep-alive: 30
+> host: index.rubygems.org \ No newline at end of file
diff --git a/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/declarative/GET/response b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/declarative/GET/response
new file mode 100644
index 0000000000..0ac050c7dd
--- /dev/null
+++ b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/declarative/GET/response
Binary files differ
diff --git a/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/descendants_tracker/GET/request b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/descendants_tracker/GET/request
new file mode 100644
index 0000000000..563a4f60c2
--- /dev/null
+++ b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/descendants_tracker/GET/request
@@ -0,0 +1,7 @@
+> GET /info/descendants_tracker
+> accept-encoding: gzip
+> accept: */*
+> user-agent: bundler/1.15.0.pre.2 rubygems/2.6.11 ruby/2.4.1 (x86_64-apple-darwin16.5.0) command/lock options/spec_run,plugins,trampoline_disable 53c83f3e5793993c
+> connection: keep-alive
+> keep-alive: 30
+> host: index.rubygems.org \ No newline at end of file
diff --git a/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/descendants_tracker/GET/response b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/descendants_tracker/GET/response
new file mode 100644
index 0000000000..23fc0f5703
--- /dev/null
+++ b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/descendants_tracker/GET/response
Binary files differ
diff --git a/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/diff-lcs/GET/request b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/diff-lcs/GET/request
new file mode 100644
index 0000000000..3c60080b38
--- /dev/null
+++ b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/diff-lcs/GET/request
@@ -0,0 +1,7 @@
+> GET /info/diff-lcs
+> accept-encoding: gzip
+> accept: */*
+> user-agent: bundler/1.15.0.pre.2 rubygems/2.6.11 ruby/2.4.1 (x86_64-apple-darwin16.5.0) command/lock options/spec_run,plugins,trampoline_disable 7edfb7e0938d0c35
+> connection: keep-alive
+> keep-alive: 30
+> host: index.rubygems.org \ No newline at end of file
diff --git a/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/diff-lcs/GET/response b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/diff-lcs/GET/response
new file mode 100644
index 0000000000..a715afbadf
--- /dev/null
+++ b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/diff-lcs/GET/response
Binary files differ
diff --git a/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/docile/GET/request b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/docile/GET/request
new file mode 100644
index 0000000000..de1e687189
--- /dev/null
+++ b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/docile/GET/request
@@ -0,0 +1,7 @@
+> GET /info/docile
+> accept-encoding: gzip
+> accept: */*
+> user-agent: bundler/1.15.0.pre.2 rubygems/2.6.11 ruby/2.4.1 (x86_64-apple-darwin16.5.0) command/lock options/spec_run,plugins,trampoline_disable 7edfb7e0938d0c35
+> connection: keep-alive
+> keep-alive: 30
+> host: index.rubygems.org \ No newline at end of file
diff --git a/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/docile/GET/response b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/docile/GET/response
new file mode 100644
index 0000000000..56252f4598
--- /dev/null
+++ b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/docile/GET/response
Binary files differ
diff --git a/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/domain_name/GET/request b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/domain_name/GET/request
new file mode 100644
index 0000000000..6157da6082
--- /dev/null
+++ b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/domain_name/GET/request
@@ -0,0 +1,7 @@
+> GET /info/domain_name
+> accept-encoding: gzip
+> accept: */*
+> user-agent: bundler/1.15.0.pre.2 rubygems/2.6.11 ruby/2.4.1 (x86_64-apple-darwin16.5.0) command/lock options/spec_run,plugins,trampoline_disable 7edfb7e0938d0c35
+> connection: keep-alive
+> keep-alive: 30
+> host: index.rubygems.org \ No newline at end of file
diff --git a/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/domain_name/GET/response b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/domain_name/GET/response
new file mode 100644
index 0000000000..69e0e69025
--- /dev/null
+++ b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/domain_name/GET/response
Binary files differ
diff --git a/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/dotenv-deployment/GET/request b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/dotenv-deployment/GET/request
new file mode 100644
index 0000000000..fe63740e5b
--- /dev/null
+++ b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/dotenv-deployment/GET/request
@@ -0,0 +1,7 @@
+> GET /info/dotenv-deployment
+> accept-encoding: gzip
+> accept: */*
+> user-agent: bundler/1.15.0.pre.2 rubygems/2.6.11 ruby/2.4.1 (x86_64-apple-darwin16.5.0) command/lock options/spec_run,plugins,trampoline_disable 7edfb7e0938d0c35
+> connection: keep-alive
+> keep-alive: 30
+> host: index.rubygems.org \ No newline at end of file
diff --git a/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/dotenv-deployment/GET/response b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/dotenv-deployment/GET/response
new file mode 100644
index 0000000000..a640a58ddc
--- /dev/null
+++ b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/dotenv-deployment/GET/response
Binary files differ
diff --git a/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/dotenv/GET/request b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/dotenv/GET/request
new file mode 100644
index 0000000000..234c682a25
--- /dev/null
+++ b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/dotenv/GET/request
@@ -0,0 +1,7 @@
+> GET /info/dotenv
+> accept-encoding: gzip
+> accept: */*
+> user-agent: bundler/1.15.0.pre.2 rubygems/2.6.11 ruby/2.4.1 (x86_64-apple-darwin16.5.0) command/lock options/spec_run,plugins,trampoline_disable 7edfb7e0938d0c35
+> connection: keep-alive
+> keep-alive: 30
+> host: index.rubygems.org \ No newline at end of file
diff --git a/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/dotenv/GET/response b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/dotenv/GET/response
new file mode 100644
index 0000000000..7207be4b53
--- /dev/null
+++ b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/dotenv/GET/response
Binary files differ
diff --git a/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/echoe/GET/request b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/echoe/GET/request
new file mode 100644
index 0000000000..98ea72af26
--- /dev/null
+++ b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/echoe/GET/request
@@ -0,0 +1,7 @@
+> GET /info/echoe
+> accept-encoding: gzip
+> accept: */*
+> user-agent: bundler/1.15.0.pre.2 rubygems/2.6.11 ruby/2.4.1 (x86_64-apple-darwin16.5.0) command/lock options/spec_run,plugins,trampoline_disable 7edfb7e0938d0c35
+> connection: keep-alive
+> keep-alive: 30
+> host: index.rubygems.org \ No newline at end of file
diff --git a/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/echoe/GET/response b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/echoe/GET/response
new file mode 100644
index 0000000000..8c48623d2c
--- /dev/null
+++ b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/echoe/GET/response
Binary files differ
diff --git a/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/em-hiredis/GET/request b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/em-hiredis/GET/request
new file mode 100644
index 0000000000..12962c23bb
--- /dev/null
+++ b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/em-hiredis/GET/request
@@ -0,0 +1,7 @@
+> GET /info/em-hiredis
+> accept-encoding: gzip
+> accept: */*
+> user-agent: bundler/1.15.0.pre.2 rubygems/2.6.11 ruby/2.4.1 (x86_64-apple-darwin16.5.0) command/lock options/spec_run,plugins,trampoline_disable 7edfb7e0938d0c35
+> connection: keep-alive
+> keep-alive: 30
+> host: index.rubygems.org \ No newline at end of file
diff --git a/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/em-hiredis/GET/response b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/em-hiredis/GET/response
new file mode 100644
index 0000000000..36c32f4dc2
--- /dev/null
+++ b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/em-hiredis/GET/response
Binary files differ
diff --git a/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/english/GET/request b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/english/GET/request
new file mode 100644
index 0000000000..e558748718
--- /dev/null
+++ b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/english/GET/request
@@ -0,0 +1,7 @@
+> GET /info/english
+> accept-encoding: gzip
+> accept: */*
+> user-agent: bundler/1.15.0.pre.2 rubygems/2.6.11 ruby/2.4.1 (x86_64-apple-darwin16.5.0) command/lock options/spec_run,plugins,trampoline_disable 53c83f3e5793993c
+> connection: keep-alive
+> keep-alive: 30
+> host: index.rubygems.org \ No newline at end of file
diff --git a/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/english/GET/response b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/english/GET/response
new file mode 100644
index 0000000000..ff4ad5bfae
--- /dev/null
+++ b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/english/GET/response
Binary files differ
diff --git a/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/equalizer/GET/request b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/equalizer/GET/request
new file mode 100644
index 0000000000..830c2ba57f
--- /dev/null
+++ b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/equalizer/GET/request
@@ -0,0 +1,7 @@
+> GET /info/equalizer
+> accept-encoding: gzip
+> accept: */*
+> user-agent: bundler/1.15.0.pre.2 rubygems/2.6.11 ruby/2.4.1 (x86_64-apple-darwin16.5.0) command/lock options/spec_run,plugins,trampoline_disable 53c83f3e5793993c
+> connection: keep-alive
+> keep-alive: 30
+> host: index.rubygems.org \ No newline at end of file
diff --git a/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/equalizer/GET/response b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/equalizer/GET/response
new file mode 100644
index 0000000000..7947e79a87
--- /dev/null
+++ b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/equalizer/GET/response
Binary files differ
diff --git a/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/erubi/GET/request b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/erubi/GET/request
new file mode 100644
index 0000000000..60045f3490
--- /dev/null
+++ b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/erubi/GET/request
@@ -0,0 +1,7 @@
+> GET /info/erubi
+> accept-encoding: gzip
+> accept: */*
+> user-agent: bundler/1.15.0.pre.2 rubygems/2.6.11 ruby/2.4.1 (x86_64-apple-darwin16.5.0) command/lock options/spec_run,plugins,trampoline_disable 7edfb7e0938d0c35
+> connection: keep-alive
+> keep-alive: 30
+> host: index.rubygems.org \ No newline at end of file
diff --git a/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/erubi/GET/response b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/erubi/GET/response
new file mode 100644
index 0000000000..c9cf020d3c
--- /dev/null
+++ b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/erubi/GET/response
Binary files differ
diff --git a/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/erubis/GET/request b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/erubis/GET/request
new file mode 100644
index 0000000000..1f4a5d9599
--- /dev/null
+++ b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/erubis/GET/request
@@ -0,0 +1,7 @@
+> GET /info/erubis
+> accept-encoding: gzip
+> accept: */*
+> user-agent: bundler/1.15.0.pre.2 rubygems/2.6.11 ruby/2.4.1 (x86_64-apple-darwin16.5.0) command/lock options/spec_run,plugins,trampoline_disable 7edfb7e0938d0c35
+> connection: keep-alive
+> keep-alive: 30
+> host: index.rubygems.org \ No newline at end of file
diff --git a/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/erubis/GET/response b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/erubis/GET/response
new file mode 100644
index 0000000000..d8db903ef5
--- /dev/null
+++ b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/erubis/GET/response
Binary files differ
diff --git a/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/escape_utils/GET/request b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/escape_utils/GET/request
new file mode 100644
index 0000000000..27c56dc41b
--- /dev/null
+++ b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/escape_utils/GET/request
@@ -0,0 +1,7 @@
+> GET /info/escape_utils
+> accept-encoding: gzip
+> accept: */*
+> user-agent: bundler/1.15.0.pre.2 rubygems/2.6.11 ruby/2.4.1 (x86_64-apple-darwin16.5.0) command/lock options/spec_run,plugins,trampoline_disable 53c83f3e5793993c
+> connection: keep-alive
+> keep-alive: 30
+> host: index.rubygems.org \ No newline at end of file
diff --git a/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/escape_utils/GET/response b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/escape_utils/GET/response
new file mode 100644
index 0000000000..fba2eb7d3f
--- /dev/null
+++ b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/escape_utils/GET/response
Binary files differ
diff --git a/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/et-orbi/GET/request b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/et-orbi/GET/request
new file mode 100644
index 0000000000..83753cb9de
--- /dev/null
+++ b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/et-orbi/GET/request
@@ -0,0 +1,7 @@
+> GET /info/et-orbi
+> accept-encoding: gzip
+> accept: */*
+> user-agent: bundler/1.15.0.pre.2 rubygems/2.6.11 ruby/2.4.1 (x86_64-apple-darwin16.5.0) command/install options/retry,path,disable_shared_gems,spec_run,plugins,trampoline_disable d59b382d069fc94f
+> connection: keep-alive
+> keep-alive: 30
+> host: index.rubygems.org \ No newline at end of file
diff --git a/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/et-orbi/GET/response b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/et-orbi/GET/response
new file mode 100644
index 0000000000..7ff97e23f3
--- /dev/null
+++ b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/et-orbi/GET/response
Binary files differ
diff --git a/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/event-bus/GET/request b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/event-bus/GET/request
new file mode 100644
index 0000000000..aad129c8f2
--- /dev/null
+++ b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/event-bus/GET/request
@@ -0,0 +1,7 @@
+> GET /info/event-bus
+> accept-encoding: gzip
+> accept: */*
+> user-agent: bundler/1.15.0.pre.2 rubygems/2.6.11 ruby/2.4.1 (x86_64-apple-darwin16.5.0) command/lock options/spec_run,plugins,trampoline_disable 7edfb7e0938d0c35
+> connection: keep-alive
+> keep-alive: 30
+> host: index.rubygems.org \ No newline at end of file
diff --git a/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/event-bus/GET/response b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/event-bus/GET/response
new file mode 100644
index 0000000000..ae88842c6c
--- /dev/null
+++ b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/event-bus/GET/response
Binary files differ
diff --git a/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/eventmachine-le/GET/request b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/eventmachine-le/GET/request
new file mode 100644
index 0000000000..1d83bd53b7
--- /dev/null
+++ b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/eventmachine-le/GET/request
@@ -0,0 +1,7 @@
+> GET /info/eventmachine-le
+> accept-encoding: gzip
+> accept: */*
+> user-agent: bundler/1.15.0.pre.2 rubygems/2.6.11 ruby/2.4.1 (x86_64-apple-darwin16.5.0) command/lock options/spec_run,plugins,trampoline_disable 7edfb7e0938d0c35
+> connection: keep-alive
+> keep-alive: 30
+> host: index.rubygems.org \ No newline at end of file
diff --git a/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/eventmachine-le/GET/response b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/eventmachine-le/GET/response
new file mode 100644
index 0000000000..fe84542b87
--- /dev/null
+++ b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/eventmachine-le/GET/response
Binary files differ
diff --git a/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/eventmachine/GET/request b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/eventmachine/GET/request
new file mode 100644
index 0000000000..614a5bf2a8
--- /dev/null
+++ b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/eventmachine/GET/request
@@ -0,0 +1,7 @@
+> GET /info/eventmachine
+> accept-encoding: gzip
+> accept: */*
+> user-agent: bundler/1.15.0.pre.2 rubygems/2.6.11 ruby/2.4.1 (x86_64-apple-darwin16.5.0) command/lock options/spec_run,plugins,trampoline_disable 7edfb7e0938d0c35
+> connection: keep-alive
+> keep-alive: 30
+> host: index.rubygems.org \ No newline at end of file
diff --git a/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/eventmachine/GET/response b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/eventmachine/GET/response
new file mode 100644
index 0000000000..4f01cf2733
--- /dev/null
+++ b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/eventmachine/GET/response
Binary files differ
diff --git a/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/execjs/GET/request b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/execjs/GET/request
new file mode 100644
index 0000000000..531f5c9b31
--- /dev/null
+++ b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/execjs/GET/request
@@ -0,0 +1,7 @@
+> GET /info/execjs
+> accept-encoding: gzip
+> accept: */*
+> user-agent: bundler/1.15.0.pre.2 rubygems/2.6.11 ruby/2.4.1 (x86_64-apple-darwin16.5.0) command/lock options/spec_run,plugins,trampoline_disable 7edfb7e0938d0c35
+> connection: keep-alive
+> keep-alive: 30
+> host: index.rubygems.org \ No newline at end of file
diff --git a/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/execjs/GET/response b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/execjs/GET/response
new file mode 100644
index 0000000000..2349c04641
--- /dev/null
+++ b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/execjs/GET/response
Binary files differ
diff --git a/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/extlib/GET/request b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/extlib/GET/request
new file mode 100644
index 0000000000..3fa0dea3a5
--- /dev/null
+++ b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/extlib/GET/request
@@ -0,0 +1,7 @@
+> GET /info/extlib
+> accept-encoding: gzip
+> accept: */*
+> user-agent: bundler/1.15.0.pre.2 rubygems/2.6.11 ruby/2.4.1 (x86_64-apple-darwin16.5.0) command/lock options/spec_run,plugins,trampoline_disable 53c83f3e5793993c
+> connection: keep-alive
+> keep-alive: 30
+> host: index.rubygems.org \ No newline at end of file
diff --git a/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/extlib/GET/response b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/extlib/GET/response
new file mode 100644
index 0000000000..6c6c2ba613
--- /dev/null
+++ b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/extlib/GET/response
Binary files differ
diff --git a/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/facets/GET/request b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/facets/GET/request
new file mode 100644
index 0000000000..6aae67744b
--- /dev/null
+++ b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/facets/GET/request
@@ -0,0 +1,7 @@
+> GET /info/facets
+> accept-encoding: gzip
+> accept: */*
+> user-agent: bundler/1.15.0.pre.2 rubygems/2.6.11 ruby/2.4.1 (x86_64-apple-darwin16.5.0) command/lock options/spec_run,plugins,trampoline_disable 7edfb7e0938d0c35
+> connection: keep-alive
+> keep-alive: 30
+> host: index.rubygems.org \ No newline at end of file
diff --git a/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/facets/GET/response b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/facets/GET/response
new file mode 100644
index 0000000000..aa2db990de
--- /dev/null
+++ b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/facets/GET/response
Binary files differ
diff --git a/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/facter/GET/request b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/facter/GET/request
new file mode 100644
index 0000000000..18bdd6e328
--- /dev/null
+++ b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/facter/GET/request
@@ -0,0 +1,7 @@
+> GET /info/facter
+> accept-encoding: gzip
+> accept: */*
+> user-agent: bundler/1.15.0.pre.2 rubygems/2.6.11 ruby/2.4.1 (x86_64-apple-darwin16.5.0) command/lock options/spec_run,plugins,trampoline_disable 7edfb7e0938d0c35
+> connection: keep-alive
+> keep-alive: 30
+> host: index.rubygems.org \ No newline at end of file
diff --git a/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/facter/GET/response b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/facter/GET/response
new file mode 100644
index 0000000000..ec8e0dea90
--- /dev/null
+++ b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/facter/GET/response
Binary files differ
diff --git a/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/faker/GET/request b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/faker/GET/request
new file mode 100644
index 0000000000..7bf2fb9f5d
--- /dev/null
+++ b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/faker/GET/request
@@ -0,0 +1,7 @@
+> GET /info/faker
+> accept-encoding: gzip
+> accept: */*
+> user-agent: bundler/1.15.0.pre.2 rubygems/2.6.11 ruby/2.4.1 (x86_64-apple-darwin16.5.0) command/install options/jobs,spec_run,trampoline_disable,plugins ab677b2f2db78951
+> connection: keep-alive
+> keep-alive: 30
+> host: index.rubygems.org \ No newline at end of file
diff --git a/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/faker/GET/response b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/faker/GET/response
new file mode 100644
index 0000000000..0e92a79ec6
--- /dev/null
+++ b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/faker/GET/response
Binary files differ
diff --git a/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/faraday/GET/request b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/faraday/GET/request
new file mode 100644
index 0000000000..b7ee2f317a
--- /dev/null
+++ b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/faraday/GET/request
@@ -0,0 +1,7 @@
+> GET /info/faraday
+> accept-encoding: gzip
+> accept: */*
+> user-agent: bundler/1.15.0.pre.2 rubygems/2.6.11 ruby/2.4.1 (x86_64-apple-darwin16.5.0) command/lock options/spec_run,plugins,trampoline_disable 53c83f3e5793993c
+> connection: keep-alive
+> keep-alive: 30
+> host: index.rubygems.org \ No newline at end of file
diff --git a/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/faraday/GET/response b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/faraday/GET/response
new file mode 100644
index 0000000000..ff1f6f9285
--- /dev/null
+++ b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/faraday/GET/response
Binary files differ
diff --git a/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/fastthread/GET/request b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/fastthread/GET/request
new file mode 100644
index 0000000000..7ea5079231
--- /dev/null
+++ b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/fastthread/GET/request
@@ -0,0 +1,7 @@
+> GET /info/fastthread
+> accept-encoding: gzip
+> accept: */*
+> user-agent: bundler/1.15.0.pre.2 rubygems/2.6.11 ruby/2.4.1 (x86_64-apple-darwin16.5.0) command/lock options/spec_run,plugins,trampoline_disable 7edfb7e0938d0c35
+> connection: keep-alive
+> keep-alive: 30
+> host: index.rubygems.org \ No newline at end of file
diff --git a/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/fastthread/GET/response b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/fastthread/GET/response
new file mode 100644
index 0000000000..a8f2fe281c
--- /dev/null
+++ b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/fastthread/GET/response
Binary files differ
diff --git a/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/faye-websocket/GET/request b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/faye-websocket/GET/request
new file mode 100644
index 0000000000..e865b6d68f
--- /dev/null
+++ b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/faye-websocket/GET/request
@@ -0,0 +1,7 @@
+> GET /info/faye-websocket
+> accept-encoding: gzip
+> accept: */*
+> user-agent: bundler/1.15.0.pre.2 rubygems/2.6.11 ruby/2.4.1 (x86_64-apple-darwin16.5.0) command/lock options/spec_run,plugins,trampoline_disable 7edfb7e0938d0c35
+> connection: keep-alive
+> keep-alive: 30
+> host: index.rubygems.org \ No newline at end of file
diff --git a/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/faye-websocket/GET/response b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/faye-websocket/GET/response
new file mode 100644
index 0000000000..9556c3541a
--- /dev/null
+++ b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/faye-websocket/GET/response
Binary files differ
diff --git a/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/fcgi/GET/request b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/fcgi/GET/request
new file mode 100644
index 0000000000..4389c71b0c
--- /dev/null
+++ b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/fcgi/GET/request
@@ -0,0 +1,7 @@
+> GET /info/fcgi
+> accept-encoding: gzip
+> accept: */*
+> user-agent: bundler/1.15.0.pre.2 rubygems/2.6.11 ruby/2.4.1 (x86_64-apple-darwin16.5.0) command/lock options/spec_run,plugins,trampoline_disable 7edfb7e0938d0c35
+> connection: keep-alive
+> keep-alive: 30
+> host: index.rubygems.org \ No newline at end of file
diff --git a/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/fcgi/GET/response b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/fcgi/GET/response
new file mode 100644
index 0000000000..daf43cba8f
--- /dev/null
+++ b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/fcgi/GET/response
Binary files differ
diff --git a/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/ffi-win32-extensions/GET/request b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/ffi-win32-extensions/GET/request
new file mode 100644
index 0000000000..c2ea7ed71b
--- /dev/null
+++ b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/ffi-win32-extensions/GET/request
@@ -0,0 +1,7 @@
+> GET /info/ffi-win32-extensions
+> accept-encoding: gzip
+> accept: */*
+> user-agent: bundler/1.15.0.pre.2 rubygems/2.6.11 ruby/2.4.1 (x86_64-apple-darwin16.5.0) command/lock options/spec_run,plugins,trampoline_disable 7edfb7e0938d0c35
+> connection: keep-alive
+> keep-alive: 30
+> host: index.rubygems.org \ No newline at end of file
diff --git a/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/ffi-win32-extensions/GET/response b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/ffi-win32-extensions/GET/response
new file mode 100644
index 0000000000..b9a3383c07
--- /dev/null
+++ b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/ffi-win32-extensions/GET/response
Binary files differ
diff --git a/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/ffi/GET/request b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/ffi/GET/request
new file mode 100644
index 0000000000..337ccf260d
--- /dev/null
+++ b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/ffi/GET/request
@@ -0,0 +1,7 @@
+> GET /info/ffi
+> accept-encoding: gzip
+> accept: */*
+> user-agent: bundler/1.15.0.pre.2 rubygems/2.6.11 ruby/2.4.1 (x86_64-apple-darwin16.5.0) command/lock options/spec_run,plugins,trampoline_disable 7edfb7e0938d0c35
+> connection: keep-alive
+> keep-alive: 30
+> host: index.rubygems.org \ No newline at end of file
diff --git a/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/ffi/GET/response b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/ffi/GET/response
new file mode 100644
index 0000000000..d000af0070
--- /dev/null
+++ b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/ffi/GET/response
Binary files differ
diff --git a/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/flexmock/GET/request b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/flexmock/GET/request
new file mode 100644
index 0000000000..85e3d59016
--- /dev/null
+++ b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/flexmock/GET/request
@@ -0,0 +1,7 @@
+> GET /info/flexmock
+> accept-encoding: gzip
+> accept: */*
+> user-agent: bundler/1.15.0.pre.2 rubygems/2.6.11 ruby/2.4.1 (x86_64-apple-darwin16.5.0) command/lock options/spec_run,plugins,trampoline_disable 7edfb7e0938d0c35
+> connection: keep-alive
+> keep-alive: 30
+> host: index.rubygems.org \ No newline at end of file
diff --git a/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/flexmock/GET/response b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/flexmock/GET/response
new file mode 100644
index 0000000000..fb369fd425
--- /dev/null
+++ b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/flexmock/GET/response
Binary files differ
diff --git a/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/functional-ruby/GET/request b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/functional-ruby/GET/request
new file mode 100644
index 0000000000..2946076a0c
--- /dev/null
+++ b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/functional-ruby/GET/request
@@ -0,0 +1,7 @@
+> GET /info/functional-ruby
+> accept-encoding: gzip
+> accept: */*
+> user-agent: bundler/1.15.0.pre.2 rubygems/2.6.11 ruby/2.4.1 (x86_64-apple-darwin16.5.0) command/lock options/spec_run,plugins,trampoline_disable 7edfb7e0938d0c35
+> connection: keep-alive
+> keep-alive: 30
+> host: index.rubygems.org \ No newline at end of file
diff --git a/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/functional-ruby/GET/response b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/functional-ruby/GET/response
new file mode 100644
index 0000000000..20c2d272bb
--- /dev/null
+++ b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/functional-ruby/GET/response
Binary files differ
diff --git a/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/gem_plugin/GET/request b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/gem_plugin/GET/request
new file mode 100644
index 0000000000..037082143d
--- /dev/null
+++ b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/gem_plugin/GET/request
@@ -0,0 +1,7 @@
+> GET /info/gem_plugin
+> accept-encoding: gzip
+> accept: */*
+> user-agent: bundler/1.15.0.pre.2 rubygems/2.6.11 ruby/2.4.1 (x86_64-apple-darwin16.5.0) command/lock options/spec_run,plugins,trampoline_disable 7edfb7e0938d0c35
+> connection: keep-alive
+> keep-alive: 30
+> host: index.rubygems.org \ No newline at end of file
diff --git a/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/gem_plugin/GET/response b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/gem_plugin/GET/response
new file mode 100644
index 0000000000..7fae98bbb3
--- /dev/null
+++ b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/gem_plugin/GET/response
Binary files differ
diff --git a/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/gemcutter/GET/request b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/gemcutter/GET/request
new file mode 100644
index 0000000000..48a190b596
--- /dev/null
+++ b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/gemcutter/GET/request
@@ -0,0 +1,7 @@
+> GET /info/gemcutter
+> accept-encoding: gzip
+> accept: */*
+> user-agent: bundler/1.15.0.pre.2 rubygems/2.6.11 ruby/2.4.1 (x86_64-apple-darwin16.5.0) command/lock options/spec_run,plugins,trampoline_disable 7edfb7e0938d0c35
+> connection: keep-alive
+> keep-alive: 30
+> host: index.rubygems.org \ No newline at end of file
diff --git a/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/gemcutter/GET/response b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/gemcutter/GET/response
new file mode 100644
index 0000000000..a0dbe8851d
--- /dev/null
+++ b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/gemcutter/GET/response
Binary files differ
diff --git a/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/gherkin/GET/request b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/gherkin/GET/request
new file mode 100644
index 0000000000..e16c323f9f
--- /dev/null
+++ b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/gherkin/GET/request
@@ -0,0 +1,7 @@
+> GET /info/gherkin
+> accept-encoding: gzip
+> accept: */*
+> user-agent: bundler/1.15.0.pre.2 rubygems/2.6.11 ruby/2.4.1 (x86_64-apple-darwin16.5.0) command/lock options/spec_run,plugins,trampoline_disable 7edfb7e0938d0c35
+> connection: keep-alive
+> keep-alive: 30
+> host: index.rubygems.org \ No newline at end of file
diff --git a/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/gherkin/GET/response b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/gherkin/GET/response
new file mode 100644
index 0000000000..829f722690
--- /dev/null
+++ b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/gherkin/GET/response
Binary files differ
diff --git a/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/gherkin3/GET/request b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/gherkin3/GET/request
new file mode 100644
index 0000000000..51c1b8dbd1
--- /dev/null
+++ b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/gherkin3/GET/request
@@ -0,0 +1,7 @@
+> GET /info/gherkin3
+> accept-encoding: gzip
+> accept: */*
+> user-agent: bundler/1.15.0.pre.2 rubygems/2.6.11 ruby/2.4.1 (x86_64-apple-darwin16.5.0) command/lock options/spec_run,plugins,trampoline_disable 7edfb7e0938d0c35
+> connection: keep-alive
+> keep-alive: 30
+> host: index.rubygems.org \ No newline at end of file
diff --git a/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/gherkin3/GET/response b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/gherkin3/GET/response
new file mode 100644
index 0000000000..a84fde4ecc
--- /dev/null
+++ b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/gherkin3/GET/response
Binary files differ
diff --git a/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/git/GET/request b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/git/GET/request
new file mode 100644
index 0000000000..a17b1c9fd9
--- /dev/null
+++ b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/git/GET/request
@@ -0,0 +1,7 @@
+> GET /info/git
+> accept-encoding: gzip
+> accept: */*
+> user-agent: bundler/1.15.0.pre.2 rubygems/2.6.11 ruby/2.4.1 (x86_64-apple-darwin16.5.0) command/lock options/spec_run,plugins,trampoline_disable 7edfb7e0938d0c35
+> connection: keep-alive
+> keep-alive: 30
+> host: index.rubygems.org \ No newline at end of file
diff --git a/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/git/GET/response b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/git/GET/response
new file mode 100644
index 0000000000..48b2f3e525
--- /dev/null
+++ b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/git/GET/response
Binary files differ
diff --git a/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/globalid/GET/request b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/globalid/GET/request
new file mode 100644
index 0000000000..0b5cc95383
--- /dev/null
+++ b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/globalid/GET/request
@@ -0,0 +1,7 @@
+> GET /info/globalid
+> accept-encoding: gzip
+> accept: */*
+> user-agent: bundler/1.15.0.pre.2 rubygems/2.6.11 ruby/2.4.1 (x86_64-apple-darwin16.5.0) command/lock options/spec_run,plugins,trampoline_disable 7edfb7e0938d0c35
+> connection: keep-alive
+> keep-alive: 30
+> host: index.rubygems.org \ No newline at end of file
diff --git a/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/globalid/GET/response b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/globalid/GET/response
new file mode 100644
index 0000000000..3682bcef6e
--- /dev/null
+++ b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/globalid/GET/response
Binary files differ
diff --git a/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/google-api-client/GET/request b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/google-api-client/GET/request
new file mode 100644
index 0000000000..6997e2f1b1
--- /dev/null
+++ b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/google-api-client/GET/request
@@ -0,0 +1,7 @@
+> GET /info/google-api-client
+> accept-encoding: gzip
+> accept: */*
+> user-agent: bundler/1.15.0.pre.2 rubygems/2.6.11 ruby/2.4.1 (x86_64-apple-darwin16.5.0) command/lock options/spec_run,plugins,trampoline_disable 53c83f3e5793993c
+> connection: keep-alive
+> keep-alive: 30
+> host: index.rubygems.org \ No newline at end of file
diff --git a/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/google-api-client/GET/response b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/google-api-client/GET/response
new file mode 100644
index 0000000000..c976f20fe6
--- /dev/null
+++ b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/google-api-client/GET/response
Binary files differ
diff --git a/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/googleauth/GET/request b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/googleauth/GET/request
new file mode 100644
index 0000000000..a5af0919c9
--- /dev/null
+++ b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/googleauth/GET/request
@@ -0,0 +1,7 @@
+> GET /info/googleauth
+> accept-encoding: gzip
+> accept: */*
+> user-agent: bundler/1.15.0.pre.2 rubygems/2.6.11 ruby/2.4.1 (x86_64-apple-darwin16.5.0) command/lock options/spec_run,plugins,trampoline_disable 53c83f3e5793993c
+> connection: keep-alive
+> keep-alive: 30
+> host: index.rubygems.org \ No newline at end of file
diff --git a/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/googleauth/GET/response b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/googleauth/GET/response
new file mode 100644
index 0000000000..a8feae6890
--- /dev/null
+++ b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/googleauth/GET/response
Binary files differ
diff --git a/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/gxapi_rails/GET/request b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/gxapi_rails/GET/request
new file mode 100644
index 0000000000..35f5608ebe
--- /dev/null
+++ b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/gxapi_rails/GET/request
@@ -0,0 +1,7 @@
+> GET /info/gxapi_rails
+> accept-encoding: gzip
+> accept: */*
+> user-agent: bundler/1.15.0.pre.2 rubygems/2.6.11 ruby/2.4.1 (x86_64-apple-darwin16.5.0) command/lock options/spec_run,plugins,trampoline_disable 53c83f3e5793993c
+> connection: keep-alive
+> keep-alive: 30
+> host: index.rubygems.org \ No newline at end of file
diff --git a/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/gxapi_rails/GET/response b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/gxapi_rails/GET/response
new file mode 100644
index 0000000000..fbdf6f55bf
--- /dev/null
+++ b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/gxapi_rails/GET/response
Binary files differ
diff --git a/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/hashie/GET/request b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/hashie/GET/request
new file mode 100644
index 0000000000..385ec2b595
--- /dev/null
+++ b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/hashie/GET/request
@@ -0,0 +1,7 @@
+> GET /info/hashie
+> accept-encoding: gzip
+> accept: */*
+> user-agent: bundler/1.15.0.pre.2 rubygems/2.6.11 ruby/2.4.1 (x86_64-apple-darwin16.5.0) command/lock options/spec_run,plugins,trampoline_disable 7edfb7e0938d0c35
+> connection: keep-alive
+> keep-alive: 30
+> host: index.rubygems.org \ No newline at end of file
diff --git a/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/hashie/GET/response b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/hashie/GET/response
new file mode 100644
index 0000000000..3d47fc2375
--- /dev/null
+++ b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/hashie/GET/response
Binary files differ
diff --git a/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/highline/GET/request b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/highline/GET/request
new file mode 100644
index 0000000000..4b571d66c1
--- /dev/null
+++ b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/highline/GET/request
@@ -0,0 +1,7 @@
+> GET /info/highline
+> accept-encoding: gzip
+> accept: */*
+> user-agent: bundler/1.15.0.pre.2 rubygems/2.6.11 ruby/2.4.1 (x86_64-apple-darwin16.5.0) command/lock options/spec_run,plugins,trampoline_disable 7edfb7e0938d0c35
+> connection: keep-alive
+> keep-alive: 30
+> host: index.rubygems.org \ No newline at end of file
diff --git a/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/highline/GET/response b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/highline/GET/response
new file mode 100644
index 0000000000..338daddcc1
--- /dev/null
+++ b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/highline/GET/response
Binary files differ
diff --git a/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/hike/GET/request b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/hike/GET/request
new file mode 100644
index 0000000000..f6c38deaaa
--- /dev/null
+++ b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/hike/GET/request
@@ -0,0 +1,7 @@
+> GET /info/hike
+> accept-encoding: gzip
+> accept: */*
+> user-agent: bundler/1.15.0.pre.2 rubygems/2.6.11 ruby/2.4.1 (x86_64-apple-darwin16.5.0) command/lock options/spec_run,plugins,trampoline_disable 7edfb7e0938d0c35
+> connection: keep-alive
+> keep-alive: 30
+> host: index.rubygems.org \ No newline at end of file
diff --git a/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/hike/GET/response b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/hike/GET/response
new file mode 100644
index 0000000000..2b957a4ff6
--- /dev/null
+++ b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/hike/GET/response
Binary files differ
diff --git a/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/hiredis/GET/request b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/hiredis/GET/request
new file mode 100644
index 0000000000..6113e85b8d
--- /dev/null
+++ b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/hiredis/GET/request
@@ -0,0 +1,7 @@
+> GET /info/hiredis
+> accept-encoding: gzip
+> accept: */*
+> user-agent: bundler/1.15.0.pre.2 rubygems/2.6.11 ruby/2.4.1 (x86_64-apple-darwin16.5.0) command/lock options/spec_run,plugins,trampoline_disable 7edfb7e0938d0c35
+> connection: keep-alive
+> keep-alive: 30
+> host: index.rubygems.org \ No newline at end of file
diff --git a/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/hiredis/GET/response b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/hiredis/GET/response
new file mode 100644
index 0000000000..d173e1925a
--- /dev/null
+++ b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/hiredis/GET/response
Binary files differ
diff --git a/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/hitimes/GET/request b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/hitimes/GET/request
new file mode 100644
index 0000000000..4a3c1bbdab
--- /dev/null
+++ b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/hitimes/GET/request
@@ -0,0 +1,7 @@
+> GET /info/hitimes
+> accept-encoding: gzip
+> accept: */*
+> user-agent: bundler/1.15.0.pre.2 rubygems/2.6.11 ruby/2.4.1 (x86_64-apple-darwin16.5.0) command/lock options/spec_run,plugins,trampoline_disable 7edfb7e0938d0c35
+> connection: keep-alive
+> keep-alive: 30
+> host: index.rubygems.org \ No newline at end of file
diff --git a/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/hitimes/GET/response b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/hitimes/GET/response
new file mode 100644
index 0000000000..24355f1810
--- /dev/null
+++ b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/hitimes/GET/response
Binary files differ
diff --git a/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/hoe/GET/request b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/hoe/GET/request
new file mode 100644
index 0000000000..e86bcea319
--- /dev/null
+++ b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/hoe/GET/request
@@ -0,0 +1,7 @@
+> GET /info/hoe
+> accept-encoding: gzip
+> accept: */*
+> user-agent: bundler/1.15.0.pre.2 rubygems/2.6.11 ruby/2.4.1 (x86_64-apple-darwin16.5.0) command/lock options/spec_run,plugins,trampoline_disable 7edfb7e0938d0c35
+> connection: keep-alive
+> keep-alive: 30
+> host: index.rubygems.org \ No newline at end of file
diff --git a/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/hoe/GET/response b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/hoe/GET/response
new file mode 100644
index 0000000000..82c2887f97
--- /dev/null
+++ b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/hoe/GET/response
Binary files differ
diff --git a/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/hooks/GET/request b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/hooks/GET/request
new file mode 100644
index 0000000000..40972439c4
--- /dev/null
+++ b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/hooks/GET/request
@@ -0,0 +1,7 @@
+> GET /info/hooks
+> accept-encoding: gzip
+> accept: */*
+> user-agent: bundler/1.15.0.pre.2 rubygems/2.6.11 ruby/2.4.1 (x86_64-apple-darwin16.5.0) command/lock options/spec_run,plugins,trampoline_disable 53c83f3e5793993c
+> connection: keep-alive
+> keep-alive: 30
+> host: index.rubygems.org \ No newline at end of file
diff --git a/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/hooks/GET/response b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/hooks/GET/response
new file mode 100644
index 0000000000..b74b3e7313
--- /dev/null
+++ b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/hooks/GET/response
Binary files differ
diff --git a/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/http-cookie/GET/request b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/http-cookie/GET/request
new file mode 100644
index 0000000000..dc272ed3b8
--- /dev/null
+++ b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/http-cookie/GET/request
@@ -0,0 +1,7 @@
+> GET /info/http-cookie
+> accept-encoding: gzip
+> accept: */*
+> user-agent: bundler/1.15.0.pre.2 rubygems/2.6.11 ruby/2.4.1 (x86_64-apple-darwin16.5.0) command/lock options/spec_run,plugins,trampoline_disable 7edfb7e0938d0c35
+> connection: keep-alive
+> keep-alive: 30
+> host: index.rubygems.org \ No newline at end of file
diff --git a/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/http-cookie/GET/response b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/http-cookie/GET/response
new file mode 100644
index 0000000000..d8db0ab577
--- /dev/null
+++ b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/http-cookie/GET/response
Binary files differ
diff --git a/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/http_parser.rb/GET/request b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/http_parser.rb/GET/request
new file mode 100644
index 0000000000..e67979aa78
--- /dev/null
+++ b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/http_parser.rb/GET/request
@@ -0,0 +1,7 @@
+> GET /info/http_parser.rb
+> accept-encoding: gzip
+> accept: */*
+> user-agent: bundler/1.15.0.pre.2 rubygems/2.6.11 ruby/2.4.1 (x86_64-apple-darwin16.5.0) command/lock options/spec_run,plugins,trampoline_disable 7edfb7e0938d0c35
+> connection: keep-alive
+> keep-alive: 30
+> host: index.rubygems.org \ No newline at end of file
diff --git a/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/http_parser.rb/GET/response b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/http_parser.rb/GET/response
new file mode 100644
index 0000000000..ed892d2641
--- /dev/null
+++ b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/http_parser.rb/GET/response
Binary files differ
diff --git a/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/httpadapter/GET/request b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/httpadapter/GET/request
new file mode 100644
index 0000000000..c9d3ce3546
--- /dev/null
+++ b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/httpadapter/GET/request
@@ -0,0 +1,7 @@
+> GET /info/httpadapter
+> accept-encoding: gzip
+> accept: */*
+> user-agent: bundler/1.15.0.pre.2 rubygems/2.6.11 ruby/2.4.1 (x86_64-apple-darwin16.5.0) command/lock options/spec_run,plugins,trampoline_disable 53c83f3e5793993c
+> connection: keep-alive
+> keep-alive: 30
+> host: index.rubygems.org \ No newline at end of file
diff --git a/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/httpadapter/GET/response b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/httpadapter/GET/response
new file mode 100644
index 0000000000..2085d78734
--- /dev/null
+++ b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/httpadapter/GET/response
Binary files differ
diff --git a/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/httpclient/GET/request b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/httpclient/GET/request
new file mode 100644
index 0000000000..499c716b32
--- /dev/null
+++ b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/httpclient/GET/request
@@ -0,0 +1,7 @@
+> GET /info/httpclient
+> accept-encoding: gzip
+> accept: */*
+> user-agent: bundler/1.15.0.pre.2 rubygems/2.6.11 ruby/2.4.1 (x86_64-apple-darwin16.5.0) command/lock options/spec_run,plugins,trampoline_disable 53c83f3e5793993c
+> connection: keep-alive
+> keep-alive: 30
+> host: index.rubygems.org \ No newline at end of file
diff --git a/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/httpclient/GET/response b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/httpclient/GET/response
new file mode 100644
index 0000000000..2085e02351
--- /dev/null
+++ b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/httpclient/GET/response
Binary files differ
diff --git a/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/hurley/GET/request b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/hurley/GET/request
new file mode 100644
index 0000000000..218736d428
--- /dev/null
+++ b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/hurley/GET/request
@@ -0,0 +1,7 @@
+> GET /info/hurley
+> accept-encoding: gzip
+> accept: */*
+> user-agent: bundler/1.15.0.pre.2 rubygems/2.6.11 ruby/2.4.1 (x86_64-apple-darwin16.5.0) command/lock options/spec_run,plugins,trampoline_disable 53c83f3e5793993c
+> connection: keep-alive
+> keep-alive: 30
+> host: index.rubygems.org \ No newline at end of file
diff --git a/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/hurley/GET/response b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/hurley/GET/response
new file mode 100644
index 0000000000..5268938361
--- /dev/null
+++ b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/hurley/GET/response
Binary files differ
diff --git a/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/i18n/GET/request b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/i18n/GET/request
new file mode 100644
index 0000000000..ad35d73f0b
--- /dev/null
+++ b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/i18n/GET/request
@@ -0,0 +1,7 @@
+> GET /info/i18n
+> accept-encoding: gzip
+> accept: */*
+> user-agent: bundler/1.15.0.pre.2 rubygems/2.6.11 ruby/2.4.1 (x86_64-apple-darwin16.5.0) command/lock options/spec_run,plugins,trampoline_disable 7edfb7e0938d0c35
+> connection: keep-alive
+> keep-alive: 30
+> host: index.rubygems.org \ No newline at end of file
diff --git a/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/i18n/GET/response b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/i18n/GET/response
new file mode 100644
index 0000000000..a5d8e4a8d8
--- /dev/null
+++ b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/i18n/GET/response
Binary files differ
diff --git a/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/ice_nine/GET/request b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/ice_nine/GET/request
new file mode 100644
index 0000000000..0c7e990bf7
--- /dev/null
+++ b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/ice_nine/GET/request
@@ -0,0 +1,7 @@
+> GET /info/ice_nine
+> accept-encoding: gzip
+> accept: */*
+> user-agent: bundler/1.15.0.pre.2 rubygems/2.6.11 ruby/2.4.1 (x86_64-apple-darwin16.5.0) command/lock options/spec_run,plugins,trampoline_disable 53c83f3e5793993c
+> connection: keep-alive
+> keep-alive: 30
+> host: index.rubygems.org \ No newline at end of file
diff --git a/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/ice_nine/GET/response b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/ice_nine/GET/response
new file mode 100644
index 0000000000..9640b04f66
--- /dev/null
+++ b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/ice_nine/GET/response
Binary files differ
diff --git a/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/journey/GET/request b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/journey/GET/request
new file mode 100644
index 0000000000..8f9b0132c2
--- /dev/null
+++ b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/journey/GET/request
@@ -0,0 +1,7 @@
+> GET /info/journey
+> accept-encoding: gzip
+> accept: */*
+> user-agent: bundler/1.15.0.pre.2 rubygems/2.6.11 ruby/2.4.1 (x86_64-apple-darwin16.5.0) command/lock options/spec_run,plugins,trampoline_disable 7edfb7e0938d0c35
+> connection: keep-alive
+> keep-alive: 30
+> host: index.rubygems.org \ No newline at end of file
diff --git a/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/journey/GET/response b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/journey/GET/response
new file mode 100644
index 0000000000..18f04980b2
--- /dev/null
+++ b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/journey/GET/response
Binary files differ
diff --git a/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/jruby-pageant/GET/request b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/jruby-pageant/GET/request
new file mode 100644
index 0000000000..6dd6f3f43b
--- /dev/null
+++ b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/jruby-pageant/GET/request
@@ -0,0 +1,7 @@
+> GET /info/jruby-pageant
+> accept-encoding: gzip
+> accept: */*
+> user-agent: bundler/1.15.0.pre.2 rubygems/2.6.11 ruby/2.4.1 (x86_64-apple-darwin16.5.0) command/lock options/spec_run,plugins,trampoline_disable 7edfb7e0938d0c35
+> connection: keep-alive
+> keep-alive: 30
+> host: index.rubygems.org \ No newline at end of file
diff --git a/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/jruby-pageant/GET/response b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/jruby-pageant/GET/response
new file mode 100644
index 0000000000..c1d4f95e29
--- /dev/null
+++ b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/jruby-pageant/GET/response
Binary files differ
diff --git a/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/json/GET/request b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/json/GET/request
new file mode 100644
index 0000000000..7ca746d23e
--- /dev/null
+++ b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/json/GET/request
@@ -0,0 +1,7 @@
+> GET /info/json
+> accept-encoding: gzip
+> accept: */*
+> user-agent: bundler/1.15.0.pre.2 rubygems/2.6.11 ruby/2.4.1 (x86_64-apple-darwin16.5.0) command/lock options/spec_run,plugins,trampoline_disable 7edfb7e0938d0c35
+> connection: keep-alive
+> keep-alive: 30
+> host: index.rubygems.org \ No newline at end of file
diff --git a/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/json/GET/response b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/json/GET/response
new file mode 100644
index 0000000000..dbaffc17f1
--- /dev/null
+++ b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/json/GET/response
Binary files differ
diff --git a/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/json_pure/GET/request b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/json_pure/GET/request
new file mode 100644
index 0000000000..aa2b18bd1d
--- /dev/null
+++ b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/json_pure/GET/request
@@ -0,0 +1,7 @@
+> GET /info/json_pure
+> accept-encoding: gzip
+> accept: */*
+> user-agent: bundler/1.15.0.pre.2 rubygems/2.6.11 ruby/2.4.1 (x86_64-apple-darwin16.5.0) command/lock options/spec_run,plugins,trampoline_disable 7edfb7e0938d0c35
+> connection: keep-alive
+> keep-alive: 30
+> host: index.rubygems.org \ No newline at end of file
diff --git a/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/json_pure/GET/response b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/json_pure/GET/response
new file mode 100644
index 0000000000..66abe94a62
--- /dev/null
+++ b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/json_pure/GET/response
Binary files differ
diff --git a/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/jwt/GET/request b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/jwt/GET/request
new file mode 100644
index 0000000000..c8669eac08
--- /dev/null
+++ b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/jwt/GET/request
@@ -0,0 +1,7 @@
+> GET /info/jwt
+> accept-encoding: gzip
+> accept: */*
+> user-agent: bundler/1.15.0.pre.2 rubygems/2.6.11 ruby/2.4.1 (x86_64-apple-darwin16.5.0) command/lock options/spec_run,plugins,trampoline_disable 53c83f3e5793993c
+> connection: keep-alive
+> keep-alive: 30
+> host: index.rubygems.org \ No newline at end of file
diff --git a/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/jwt/GET/response b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/jwt/GET/response
new file mode 100644
index 0000000000..e262e41c07
--- /dev/null
+++ b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/jwt/GET/response
Binary files differ
diff --git a/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/language/GET/request b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/language/GET/request
new file mode 100644
index 0000000000..4aeefbc7aa
--- /dev/null
+++ b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/language/GET/request
@@ -0,0 +1,7 @@
+> GET /info/language
+> accept-encoding: gzip
+> accept: */*
+> user-agent: bundler/1.15.0.pre.2 rubygems/2.6.11 ruby/2.4.1 (x86_64-apple-darwin16.5.0) command/lock options/spec_run,plugins,trampoline_disable 53c83f3e5793993c
+> connection: keep-alive
+> keep-alive: 30
+> host: index.rubygems.org \ No newline at end of file
diff --git a/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/language/GET/response b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/language/GET/response
new file mode 100644
index 0000000000..6b63972d50
--- /dev/null
+++ b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/language/GET/response
Binary files differ
diff --git a/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/launchy/GET/request b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/launchy/GET/request
new file mode 100644
index 0000000000..60da8f9a26
--- /dev/null
+++ b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/launchy/GET/request
@@ -0,0 +1,7 @@
+> GET /info/launchy
+> accept-encoding: gzip
+> accept: */*
+> user-agent: bundler/1.15.0.pre.2 rubygems/2.6.11 ruby/2.4.1 (x86_64-apple-darwin16.5.0) command/lock options/spec_run,plugins,trampoline_disable 7edfb7e0938d0c35
+> connection: keep-alive
+> keep-alive: 30
+> host: index.rubygems.org \ No newline at end of file
diff --git a/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/launchy/GET/response b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/launchy/GET/response
new file mode 100644
index 0000000000..db76626340
--- /dev/null
+++ b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/launchy/GET/response
Binary files differ
diff --git a/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/libwebsocket/GET/request b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/libwebsocket/GET/request
new file mode 100644
index 0000000000..3764e1e3b1
--- /dev/null
+++ b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/libwebsocket/GET/request
@@ -0,0 +1,7 @@
+> GET /info/libwebsocket
+> accept-encoding: gzip
+> accept: */*
+> user-agent: bundler/1.15.0.pre.2 rubygems/2.6.11 ruby/2.4.1 (x86_64-apple-darwin16.5.0) command/lock options/spec_run,plugins,trampoline_disable 7edfb7e0938d0c35
+> connection: keep-alive
+> keep-alive: 30
+> host: index.rubygems.org \ No newline at end of file
diff --git a/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/libwebsocket/GET/response b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/libwebsocket/GET/response
new file mode 100644
index 0000000000..244ba5277a
--- /dev/null
+++ b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/libwebsocket/GET/response
Binary files differ
diff --git a/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/libxml-ruby/GET/request b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/libxml-ruby/GET/request
new file mode 100644
index 0000000000..fad58483fe
--- /dev/null
+++ b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/libxml-ruby/GET/request
@@ -0,0 +1,7 @@
+> GET /info/libxml-ruby
+> accept-encoding: gzip
+> accept: */*
+> user-agent: bundler/1.15.0.pre.2 rubygems/2.6.11 ruby/2.4.1 (x86_64-apple-darwin16.5.0) command/lock options/spec_run,plugins,trampoline_disable 7edfb7e0938d0c35
+> connection: keep-alive
+> keep-alive: 30
+> host: index.rubygems.org \ No newline at end of file
diff --git a/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/libxml-ruby/GET/response b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/libxml-ruby/GET/response
new file mode 100644
index 0000000000..2742abd449
--- /dev/null
+++ b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/libxml-ruby/GET/response
Binary files differ
diff --git a/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/liquid/GET/request b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/liquid/GET/request
new file mode 100644
index 0000000000..9ac0105694
--- /dev/null
+++ b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/liquid/GET/request
@@ -0,0 +1,7 @@
+> GET /info/liquid
+> accept-encoding: gzip
+> accept: */*
+> user-agent: bundler/1.15.0.pre.2 rubygems/2.6.11 ruby/2.4.1 (x86_64-apple-darwin16.5.0) command/lock options/spec_run,plugins,trampoline_disable 53c83f3e5793993c
+> connection: keep-alive
+> keep-alive: 30
+> host: index.rubygems.org \ No newline at end of file
diff --git a/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/liquid/GET/response b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/liquid/GET/response
new file mode 100644
index 0000000000..fa37cb788f
--- /dev/null
+++ b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/liquid/GET/response
Binary files differ
diff --git a/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/listen/GET/request b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/listen/GET/request
new file mode 100644
index 0000000000..d8ac06f4ea
--- /dev/null
+++ b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/listen/GET/request
@@ -0,0 +1,7 @@
+> GET /info/listen
+> accept-encoding: gzip
+> accept: */*
+> user-agent: bundler/1.15.0.pre.2 rubygems/2.6.11 ruby/2.4.1 (x86_64-apple-darwin16.5.0) command/lock options/spec_run,plugins,trampoline_disable 53c83f3e5793993c
+> connection: keep-alive
+> keep-alive: 30
+> host: index.rubygems.org \ No newline at end of file
diff --git a/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/listen/GET/response b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/listen/GET/response
new file mode 100644
index 0000000000..74dd5df6ce
--- /dev/null
+++ b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/listen/GET/response
Binary files differ
diff --git a/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/little-plugger/GET/request b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/little-plugger/GET/request
new file mode 100644
index 0000000000..34f643d772
--- /dev/null
+++ b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/little-plugger/GET/request
@@ -0,0 +1,7 @@
+> GET /info/little-plugger
+> accept-encoding: gzip
+> accept: */*
+> user-agent: bundler/1.15.0.pre.2 rubygems/2.6.11 ruby/2.4.1 (x86_64-apple-darwin16.5.0) command/lock options/spec_run,plugins,trampoline_disable 7edfb7e0938d0c35
+> connection: keep-alive
+> keep-alive: 30
+> host: index.rubygems.org \ No newline at end of file
diff --git a/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/little-plugger/GET/response b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/little-plugger/GET/response
new file mode 100644
index 0000000000..2b8b21982f
--- /dev/null
+++ b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/little-plugger/GET/response
Binary files differ
diff --git a/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/lockfile/GET/request b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/lockfile/GET/request
new file mode 100644
index 0000000000..21ccaf6be5
--- /dev/null
+++ b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/lockfile/GET/request
@@ -0,0 +1,7 @@
+> GET /info/lockfile
+> accept-encoding: gzip
+> accept: */*
+> user-agent: bundler/1.15.0.pre.2 rubygems/2.6.11 ruby/2.4.1 (x86_64-apple-darwin16.5.0) command/lock options/spec_run,plugins,trampoline_disable 7edfb7e0938d0c35
+> connection: keep-alive
+> keep-alive: 30
+> host: index.rubygems.org \ No newline at end of file
diff --git a/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/lockfile/GET/response b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/lockfile/GET/response
new file mode 100644
index 0000000000..fde932b183
--- /dev/null
+++ b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/lockfile/GET/response
Binary files differ
diff --git a/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/logging/GET/request b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/logging/GET/request
new file mode 100644
index 0000000000..8a7bd45f35
--- /dev/null
+++ b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/logging/GET/request
@@ -0,0 +1,7 @@
+> GET /info/logging
+> accept-encoding: gzip
+> accept: */*
+> user-agent: bundler/1.15.0.pre.2 rubygems/2.6.11 ruby/2.4.1 (x86_64-apple-darwin16.5.0) command/lock options/spec_run,plugins,trampoline_disable 53c83f3e5793993c
+> connection: keep-alive
+> keep-alive: 30
+> host: index.rubygems.org \ No newline at end of file
diff --git a/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/logging/GET/response b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/logging/GET/response
new file mode 100644
index 0000000000..cbe9bfdebf
--- /dev/null
+++ b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/logging/GET/response
Binary files differ
diff --git a/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/loofah/GET/request b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/loofah/GET/request
new file mode 100644
index 0000000000..2cb6d57679
--- /dev/null
+++ b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/loofah/GET/request
@@ -0,0 +1,7 @@
+> GET /info/loofah
+> accept-encoding: gzip
+> accept: */*
+> user-agent: bundler/1.15.0.pre.2 rubygems/2.6.11 ruby/2.4.1 (x86_64-apple-darwin16.5.0) command/lock options/spec_run,plugins,trampoline_disable 7edfb7e0938d0c35
+> connection: keep-alive
+> keep-alive: 30
+> host: index.rubygems.org \ No newline at end of file
diff --git a/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/loofah/GET/response b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/loofah/GET/response
new file mode 100644
index 0000000000..848cc7b05b
--- /dev/null
+++ b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/loofah/GET/response
Binary files differ
diff --git a/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/loquacious/GET/request b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/loquacious/GET/request
new file mode 100644
index 0000000000..bda60b4dc3
--- /dev/null
+++ b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/loquacious/GET/request
@@ -0,0 +1,7 @@
+> GET /info/loquacious
+> accept-encoding: gzip
+> accept: */*
+> user-agent: bundler/1.15.0.pre.2 rubygems/2.6.11 ruby/2.4.1 (x86_64-apple-darwin16.5.0) command/lock options/spec_run,plugins,trampoline_disable 7edfb7e0938d0c35
+> connection: keep-alive
+> keep-alive: 30
+> host: index.rubygems.org \ No newline at end of file
diff --git a/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/loquacious/GET/response b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/loquacious/GET/response
new file mode 100644
index 0000000000..bbda4bc450
--- /dev/null
+++ b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/loquacious/GET/response
Binary files differ
diff --git a/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/mab/GET/request b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/mab/GET/request
new file mode 100644
index 0000000000..115c6e6448
--- /dev/null
+++ b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/mab/GET/request
@@ -0,0 +1,7 @@
+> GET /info/mab
+> accept-encoding: gzip
+> accept: */*
+> user-agent: bundler/1.15.0.pre.2 rubygems/2.6.11 ruby/2.4.1 (x86_64-apple-darwin16.5.0) command/lock options/spec_run,plugins,trampoline_disable 7edfb7e0938d0c35
+> connection: keep-alive
+> keep-alive: 30
+> host: index.rubygems.org \ No newline at end of file
diff --git a/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/mab/GET/response b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/mab/GET/response
new file mode 100644
index 0000000000..067827ad9c
--- /dev/null
+++ b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/mab/GET/response
Binary files differ
diff --git a/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/mail/GET/request b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/mail/GET/request
new file mode 100644
index 0000000000..ea11e0bd0c
--- /dev/null
+++ b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/mail/GET/request
@@ -0,0 +1,7 @@
+> GET /info/mail
+> accept-encoding: gzip
+> accept: */*
+> user-agent: bundler/1.15.0.pre.2 rubygems/2.6.11 ruby/2.4.1 (x86_64-apple-darwin16.5.0) command/lock options/spec_run,plugins,trampoline_disable 7edfb7e0938d0c35
+> connection: keep-alive
+> keep-alive: 30
+> host: index.rubygems.org \ No newline at end of file
diff --git a/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/mail/GET/response b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/mail/GET/response
new file mode 100644
index 0000000000..5dd7ab169c
--- /dev/null
+++ b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/mail/GET/response
Binary files differ
diff --git a/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/markaby/GET/request b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/markaby/GET/request
new file mode 100644
index 0000000000..27db5d09cf
--- /dev/null
+++ b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/markaby/GET/request
@@ -0,0 +1,7 @@
+> GET /info/markaby
+> accept-encoding: gzip
+> accept: */*
+> user-agent: bundler/1.15.0.pre.2 rubygems/2.6.11 ruby/2.4.1 (x86_64-apple-darwin16.5.0) command/lock options/spec_run,plugins,trampoline_disable 7edfb7e0938d0c35
+> connection: keep-alive
+> keep-alive: 30
+> host: index.rubygems.org \ No newline at end of file
diff --git a/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/markaby/GET/response b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/markaby/GET/response
new file mode 100644
index 0000000000..917d9f7777
--- /dev/null
+++ b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/markaby/GET/response
Binary files differ
diff --git a/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/memcache-client/GET/request b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/memcache-client/GET/request
new file mode 100644
index 0000000000..4b0c275c6e
--- /dev/null
+++ b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/memcache-client/GET/request
@@ -0,0 +1,7 @@
+> GET /info/memcache-client
+> accept-encoding: gzip
+> accept: */*
+> user-agent: bundler/1.15.0.pre.2 rubygems/2.6.11 ruby/2.4.1 (x86_64-apple-darwin16.5.0) command/lock options/spec_run,plugins,trampoline_disable 7edfb7e0938d0c35
+> connection: keep-alive
+> keep-alive: 30
+> host: index.rubygems.org \ No newline at end of file
diff --git a/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/memcache-client/GET/response b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/memcache-client/GET/response
new file mode 100644
index 0000000000..a1fb37c9f7
--- /dev/null
+++ b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/memcache-client/GET/response
Binary files differ
diff --git a/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/memoist/GET/request b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/memoist/GET/request
new file mode 100644
index 0000000000..fcda1676de
--- /dev/null
+++ b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/memoist/GET/request
@@ -0,0 +1,7 @@
+> GET /info/memoist
+> accept-encoding: gzip
+> accept: */*
+> user-agent: bundler/1.15.0.pre.2 rubygems/2.6.11 ruby/2.4.1 (x86_64-apple-darwin16.5.0) command/lock options/spec_run,plugins,trampoline_disable 53c83f3e5793993c
+> connection: keep-alive
+> keep-alive: 30
+> host: index.rubygems.org \ No newline at end of file
diff --git a/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/memoist/GET/response b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/memoist/GET/response
new file mode 100644
index 0000000000..b3b4112024
--- /dev/null
+++ b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/memoist/GET/response
Binary files differ
diff --git a/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/memoizable/GET/request b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/memoizable/GET/request
new file mode 100644
index 0000000000..ae7e5e0371
--- /dev/null
+++ b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/memoizable/GET/request
@@ -0,0 +1,7 @@
+> GET /info/memoizable
+> accept-encoding: gzip
+> accept: */*
+> user-agent: bundler/1.15.0.pre.2 rubygems/2.6.11 ruby/2.4.1 (x86_64-apple-darwin16.5.0) command/lock options/spec_run,plugins,trampoline_disable 53c83f3e5793993c
+> connection: keep-alive
+> keep-alive: 30
+> host: index.rubygems.org \ No newline at end of file
diff --git a/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/memoizable/GET/response b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/memoizable/GET/response
new file mode 100644
index 0000000000..730066f3b8
--- /dev/null
+++ b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/memoizable/GET/response
Binary files differ
diff --git a/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/metaclass/GET/request b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/metaclass/GET/request
new file mode 100644
index 0000000000..9f502c21cc
--- /dev/null
+++ b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/metaclass/GET/request
@@ -0,0 +1,7 @@
+> GET /info/metaclass
+> accept-encoding: gzip
+> accept: */*
+> user-agent: bundler/1.15.0.pre.2 rubygems/2.6.11 ruby/2.4.1 (x86_64-apple-darwin16.5.0) command/lock options/spec_run,plugins,trampoline_disable 7edfb7e0938d0c35
+> connection: keep-alive
+> keep-alive: 30
+> host: index.rubygems.org \ No newline at end of file
diff --git a/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/metaclass/GET/response b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/metaclass/GET/response
new file mode 100644
index 0000000000..838e17e78b
--- /dev/null
+++ b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/metaclass/GET/response
Binary files differ
diff --git a/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/metaid/GET/request b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/metaid/GET/request
new file mode 100644
index 0000000000..872aea81e0
--- /dev/null
+++ b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/metaid/GET/request
@@ -0,0 +1,7 @@
+> GET /info/metaid
+> accept-encoding: gzip
+> accept: */*
+> user-agent: bundler/1.15.0.pre.2 rubygems/2.6.11 ruby/2.4.1 (x86_64-apple-darwin16.5.0) command/lock options/spec_run,plugins,trampoline_disable 7edfb7e0938d0c35
+> connection: keep-alive
+> keep-alive: 30
+> host: index.rubygems.org \ No newline at end of file
diff --git a/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/metaid/GET/response b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/metaid/GET/response
new file mode 100644
index 0000000000..3b745e234b
--- /dev/null
+++ b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/metaid/GET/response
Binary files differ
diff --git a/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/method_source/GET/request b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/method_source/GET/request
new file mode 100644
index 0000000000..4d02bc1e42
--- /dev/null
+++ b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/method_source/GET/request
@@ -0,0 +1,7 @@
+> GET /info/method_source
+> accept-encoding: gzip
+> accept: */*
+> user-agent: bundler/1.15.0.pre.2 rubygems/2.6.11 ruby/2.4.1 (x86_64-apple-darwin16.5.0) command/lock options/spec_run,plugins,trampoline_disable 7edfb7e0938d0c35
+> connection: keep-alive
+> keep-alive: 30
+> host: index.rubygems.org \ No newline at end of file
diff --git a/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/method_source/GET/response b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/method_source/GET/response
new file mode 100644
index 0000000000..18c79330c5
--- /dev/null
+++ b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/method_source/GET/response
Binary files differ
diff --git a/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/mime-types-data/GET/request b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/mime-types-data/GET/request
new file mode 100644
index 0000000000..8081aaa002
--- /dev/null
+++ b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/mime-types-data/GET/request
@@ -0,0 +1,7 @@
+> GET /info/mime-types-data
+> accept-encoding: gzip
+> accept: */*
+> user-agent: bundler/1.15.0.pre.2 rubygems/2.6.11 ruby/2.4.1 (x86_64-apple-darwin16.5.0) command/lock options/spec_run,plugins,trampoline_disable 7edfb7e0938d0c35
+> connection: keep-alive
+> keep-alive: 30
+> host: index.rubygems.org \ No newline at end of file
diff --git a/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/mime-types-data/GET/response b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/mime-types-data/GET/response
new file mode 100644
index 0000000000..c428319a48
--- /dev/null
+++ b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/mime-types-data/GET/response
Binary files differ
diff --git a/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/mime-types/GET/request b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/mime-types/GET/request
new file mode 100644
index 0000000000..eb07326eda
--- /dev/null
+++ b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/mime-types/GET/request
@@ -0,0 +1,7 @@
+> GET /info/mime-types
+> accept-encoding: gzip
+> accept: */*
+> user-agent: bundler/1.15.0.pre.2 rubygems/2.6.11 ruby/2.4.1 (x86_64-apple-darwin16.5.0) command/lock options/spec_run,plugins,trampoline_disable 7edfb7e0938d0c35
+> connection: keep-alive
+> keep-alive: 30
+> host: index.rubygems.org \ No newline at end of file
diff --git a/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/mime-types/GET/response b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/mime-types/GET/response
new file mode 100644
index 0000000000..c811fa5136
--- /dev/null
+++ b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/mime-types/GET/response
Binary files differ
diff --git a/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/mimemagic/GET/request b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/mimemagic/GET/request
new file mode 100644
index 0000000000..cbb2e4f493
--- /dev/null
+++ b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/mimemagic/GET/request
@@ -0,0 +1,7 @@
+> GET /info/mimemagic
+> accept-encoding: gzip
+> accept: */*
+> user-agent: bundler/1.15.0.pre.2 rubygems/2.6.11 ruby/2.4.1 (x86_64-apple-darwin16.5.0) command/lock options/spec_run,plugins,trampoline_disable 6d5397ce7f8b26e0
+> connection: keep-alive
+> keep-alive: 30
+> host: index.rubygems.org \ No newline at end of file
diff --git a/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/mimemagic/GET/response b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/mimemagic/GET/response
new file mode 100644
index 0000000000..bf480bbe5f
--- /dev/null
+++ b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/mimemagic/GET/response
Binary files differ
diff --git a/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/mini_portile/GET/request b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/mini_portile/GET/request
new file mode 100644
index 0000000000..f536dc4d3e
--- /dev/null
+++ b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/mini_portile/GET/request
@@ -0,0 +1,7 @@
+> GET /info/mini_portile
+> accept-encoding: gzip
+> accept: */*
+> user-agent: bundler/1.15.0.pre.2 rubygems/2.6.11 ruby/2.4.1 (x86_64-apple-darwin16.5.0) command/lock options/spec_run,plugins,trampoline_disable 7edfb7e0938d0c35
+> connection: keep-alive
+> keep-alive: 30
+> host: index.rubygems.org \ No newline at end of file
diff --git a/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/mini_portile/GET/response b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/mini_portile/GET/response
new file mode 100644
index 0000000000..0e53b5b3d0
--- /dev/null
+++ b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/mini_portile/GET/response
Binary files differ
diff --git a/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/mini_portile2/GET/request b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/mini_portile2/GET/request
new file mode 100644
index 0000000000..ab28a8089a
--- /dev/null
+++ b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/mini_portile2/GET/request
@@ -0,0 +1,7 @@
+> GET /info/mini_portile2
+> accept-encoding: gzip
+> accept: */*
+> user-agent: bundler/1.15.0.pre.2 rubygems/2.6.11 ruby/2.4.1 (x86_64-apple-darwin16.5.0) command/lock options/spec_run,plugins,trampoline_disable 7edfb7e0938d0c35
+> connection: keep-alive
+> keep-alive: 30
+> host: index.rubygems.org \ No newline at end of file
diff --git a/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/mini_portile2/GET/response b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/mini_portile2/GET/response
new file mode 100644
index 0000000000..e664192bbe
--- /dev/null
+++ b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/mini_portile2/GET/response
Binary files differ
diff --git a/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/minitar-cli/GET/request b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/minitar-cli/GET/request
new file mode 100644
index 0000000000..d9d5968a5b
--- /dev/null
+++ b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/minitar-cli/GET/request
@@ -0,0 +1,7 @@
+> GET /info/minitar-cli
+> accept-encoding: gzip
+> accept: */*
+> user-agent: bundler/1.15.0.pre.2 rubygems/2.6.11 ruby/2.4.1 (x86_64-apple-darwin16.5.0) command/lock options/spec_run,plugins,trampoline_disable 7edfb7e0938d0c35
+> connection: keep-alive
+> keep-alive: 30
+> host: index.rubygems.org \ No newline at end of file
diff --git a/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/minitar-cli/GET/response b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/minitar-cli/GET/response
new file mode 100644
index 0000000000..fb853dc6c2
--- /dev/null
+++ b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/minitar-cli/GET/response
Binary files differ
diff --git a/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/minitar/GET/request b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/minitar/GET/request
new file mode 100644
index 0000000000..c8b5697b43
--- /dev/null
+++ b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/minitar/GET/request
@@ -0,0 +1,7 @@
+> GET /info/minitar
+> accept-encoding: gzip
+> accept: */*
+> user-agent: bundler/1.15.0.pre.2 rubygems/2.6.11 ruby/2.4.1 (x86_64-apple-darwin16.5.0) command/lock options/spec_run,plugins,trampoline_disable 7edfb7e0938d0c35
+> connection: keep-alive
+> keep-alive: 30
+> host: index.rubygems.org \ No newline at end of file
diff --git a/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/minitar/GET/response b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/minitar/GET/response
new file mode 100644
index 0000000000..17342c80e5
--- /dev/null
+++ b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/minitar/GET/response
Binary files differ
diff --git a/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/minitest/GET/request b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/minitest/GET/request
new file mode 100644
index 0000000000..4d88e89a59
--- /dev/null
+++ b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/minitest/GET/request
@@ -0,0 +1,7 @@
+> GET /info/minitest
+> accept-encoding: gzip
+> accept: */*
+> user-agent: bundler/1.15.0.pre.2 rubygems/2.6.11 ruby/2.4.1 (x86_64-apple-darwin16.5.0) command/lock options/spec_run,plugins,trampoline_disable 7edfb7e0938d0c35
+> connection: keep-alive
+> keep-alive: 30
+> host: index.rubygems.org \ No newline at end of file
diff --git a/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/minitest/GET/response b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/minitest/GET/response
new file mode 100644
index 0000000000..514aae033a
--- /dev/null
+++ b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/minitest/GET/response
Binary files differ
diff --git a/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/mkrf/GET/request b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/mkrf/GET/request
new file mode 100644
index 0000000000..3333257711
--- /dev/null
+++ b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/mkrf/GET/request
@@ -0,0 +1,7 @@
+> GET /info/mkrf
+> accept-encoding: gzip
+> accept: */*
+> user-agent: bundler/1.15.0.pre.2 rubygems/2.6.11 ruby/2.4.1 (x86_64-apple-darwin16.5.0) command/lock options/spec_run,plugins,trampoline_disable 7edfb7e0938d0c35
+> connection: keep-alive
+> keep-alive: 30
+> host: index.rubygems.org \ No newline at end of file
diff --git a/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/mkrf/GET/response b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/mkrf/GET/response
new file mode 100644
index 0000000000..5e0d4ee277
--- /dev/null
+++ b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/mkrf/GET/response
Binary files differ
diff --git a/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/mocha/GET/request b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/mocha/GET/request
new file mode 100644
index 0000000000..f215f1f8d6
--- /dev/null
+++ b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/mocha/GET/request
@@ -0,0 +1,7 @@
+> GET /info/mocha
+> accept-encoding: gzip
+> accept: */*
+> user-agent: bundler/1.15.0.pre.2 rubygems/2.6.11 ruby/2.4.1 (x86_64-apple-darwin16.5.0) command/lock options/spec_run,plugins,trampoline_disable 7edfb7e0938d0c35
+> connection: keep-alive
+> keep-alive: 30
+> host: index.rubygems.org \ No newline at end of file
diff --git a/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/mocha/GET/response b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/mocha/GET/response
new file mode 100644
index 0000000000..da32ecfb8d
--- /dev/null
+++ b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/mocha/GET/response
Binary files differ
diff --git a/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/mongrel/GET/request b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/mongrel/GET/request
new file mode 100644
index 0000000000..0181a370bc
--- /dev/null
+++ b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/mongrel/GET/request
@@ -0,0 +1,7 @@
+> GET /info/mongrel
+> accept-encoding: gzip
+> accept: */*
+> user-agent: bundler/1.15.0.pre.2 rubygems/2.6.11 ruby/2.4.1 (x86_64-apple-darwin16.5.0) command/lock options/spec_run,plugins,trampoline_disable 7edfb7e0938d0c35
+> connection: keep-alive
+> keep-alive: 30
+> host: index.rubygems.org \ No newline at end of file
diff --git a/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/mongrel/GET/response b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/mongrel/GET/response
new file mode 100644
index 0000000000..0184bd09dc
--- /dev/null
+++ b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/mongrel/GET/response
Binary files differ
diff --git a/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/mono_logger/GET/request b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/mono_logger/GET/request
new file mode 100644
index 0000000000..088d7a648d
--- /dev/null
+++ b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/mono_logger/GET/request
@@ -0,0 +1,7 @@
+> GET /info/mono_logger
+> accept-encoding: gzip
+> accept: */*
+> user-agent: bundler/1.15.0.pre.2 rubygems/2.6.11 ruby/2.4.1 (x86_64-apple-darwin16.5.0) command/install options/retry,path,disable_shared_gems,spec_run,plugins,trampoline_disable d59b382d069fc94f
+> connection: keep-alive
+> keep-alive: 30
+> host: index.rubygems.org \ No newline at end of file
diff --git a/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/mono_logger/GET/response b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/mono_logger/GET/response
new file mode 100644
index 0000000000..5163ec92af
--- /dev/null
+++ b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/mono_logger/GET/response
Binary files differ
diff --git a/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/multi_json/GET/request b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/multi_json/GET/request
new file mode 100644
index 0000000000..56942172dc
--- /dev/null
+++ b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/multi_json/GET/request
@@ -0,0 +1,7 @@
+> GET /info/multi_json
+> accept-encoding: gzip
+> accept: */*
+> user-agent: bundler/1.15.0.pre.2 rubygems/2.6.11 ruby/2.4.1 (x86_64-apple-darwin16.5.0) command/lock options/spec_run,plugins,trampoline_disable 7edfb7e0938d0c35
+> connection: keep-alive
+> keep-alive: 30
+> host: index.rubygems.org \ No newline at end of file
diff --git a/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/multi_json/GET/response b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/multi_json/GET/response
new file mode 100644
index 0000000000..001f44bb08
--- /dev/null
+++ b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/multi_json/GET/response
Binary files differ
diff --git a/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/multi_test/GET/request b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/multi_test/GET/request
new file mode 100644
index 0000000000..8f4d50696c
--- /dev/null
+++ b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/multi_test/GET/request
@@ -0,0 +1,7 @@
+> GET /info/multi_test
+> accept-encoding: gzip
+> accept: */*
+> user-agent: bundler/1.15.0.pre.2 rubygems/2.6.11 ruby/2.4.1 (x86_64-apple-darwin16.5.0) command/lock options/spec_run,plugins,trampoline_disable 7edfb7e0938d0c35
+> connection: keep-alive
+> keep-alive: 30
+> host: index.rubygems.org \ No newline at end of file
diff --git a/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/multi_test/GET/response b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/multi_test/GET/response
new file mode 100644
index 0000000000..955de5d64d
--- /dev/null
+++ b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/multi_test/GET/response
Binary files differ
diff --git a/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/multimap/GET/request b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/multimap/GET/request
new file mode 100644
index 0000000000..1a64e6f47e
--- /dev/null
+++ b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/multimap/GET/request
@@ -0,0 +1,7 @@
+> GET /info/multimap
+> accept-encoding: gzip
+> accept: */*
+> user-agent: bundler/1.15.0.pre.2 rubygems/2.6.11 ruby/2.4.1 (x86_64-apple-darwin16.5.0) command/lock options/spec_run,plugins,trampoline_disable 7edfb7e0938d0c35
+> connection: keep-alive
+> keep-alive: 30
+> host: index.rubygems.org \ No newline at end of file
diff --git a/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/multimap/GET/response b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/multimap/GET/response
new file mode 100644
index 0000000000..da10914932
--- /dev/null
+++ b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/multimap/GET/response
Binary files differ
diff --git a/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/multipart-post/GET/request b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/multipart-post/GET/request
new file mode 100644
index 0000000000..63eec25ffd
--- /dev/null
+++ b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/multipart-post/GET/request
@@ -0,0 +1,7 @@
+> GET /info/multipart-post
+> accept-encoding: gzip
+> accept: */*
+> user-agent: bundler/1.15.0.pre.2 rubygems/2.6.11 ruby/2.4.1 (x86_64-apple-darwin16.5.0) command/lock options/spec_run,plugins,trampoline_disable 53c83f3e5793993c
+> connection: keep-alive
+> keep-alive: 30
+> host: index.rubygems.org \ No newline at end of file
diff --git a/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/multipart-post/GET/response b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/multipart-post/GET/response
new file mode 100644
index 0000000000..ec7b13cfc5
--- /dev/null
+++ b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/multipart-post/GET/response
Binary files differ
diff --git a/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/mustermann/GET/request b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/mustermann/GET/request
new file mode 100644
index 0000000000..710afe0829
--- /dev/null
+++ b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/mustermann/GET/request
@@ -0,0 +1,7 @@
+> GET /info/mustermann
+> accept-encoding: gzip
+> accept: */*
+> user-agent: bundler/1.15.0.pre.2 rubygems/2.6.11 ruby/2.4.1 (x86_64-apple-darwin16.5.0) command/lock options/spec_run,plugins,trampoline_disable 53c83f3e5793993c
+> connection: keep-alive
+> keep-alive: 30
+> host: index.rubygems.org \ No newline at end of file
diff --git a/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/mustermann/GET/response b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/mustermann/GET/response
new file mode 100644
index 0000000000..21ba1104a6
--- /dev/null
+++ b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/mustermann/GET/response
Binary files differ
diff --git a/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/needle/GET/request b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/needle/GET/request
new file mode 100644
index 0000000000..45d8ea2c39
--- /dev/null
+++ b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/needle/GET/request
@@ -0,0 +1,7 @@
+> GET /info/needle
+> accept-encoding: gzip
+> accept: */*
+> user-agent: bundler/1.15.0.pre.2 rubygems/2.6.11 ruby/2.4.1 (x86_64-apple-darwin16.5.0) command/lock options/spec_run,plugins,trampoline_disable 7edfb7e0938d0c35
+> connection: keep-alive
+> keep-alive: 30
+> host: index.rubygems.org \ No newline at end of file
diff --git a/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/needle/GET/response b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/needle/GET/response
new file mode 100644
index 0000000000..600fcfb700
--- /dev/null
+++ b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/needle/GET/response
Binary files differ
diff --git a/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/nenv/GET/request b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/nenv/GET/request
new file mode 100644
index 0000000000..4ab184fc81
--- /dev/null
+++ b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/nenv/GET/request
@@ -0,0 +1,7 @@
+> GET /info/nenv
+> accept-encoding: gzip
+> accept: */*
+> user-agent: bundler/1.15.0.pre.2 rubygems/2.6.11 ruby/2.4.1 (x86_64-apple-darwin16.5.0) command/lock options/spec_run,plugins,trampoline_disable 7edfb7e0938d0c35
+> connection: keep-alive
+> keep-alive: 30
+> host: index.rubygems.org \ No newline at end of file
diff --git a/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/nenv/GET/response b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/nenv/GET/response
new file mode 100644
index 0000000000..8bb1ae92e6
--- /dev/null
+++ b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/nenv/GET/response
Binary files differ
diff --git a/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/net-scp/GET/request b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/net-scp/GET/request
new file mode 100644
index 0000000000..8910edf8e6
--- /dev/null
+++ b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/net-scp/GET/request
@@ -0,0 +1,7 @@
+> GET /info/net-scp
+> accept-encoding: gzip
+> accept: */*
+> user-agent: bundler/1.15.0.pre.2 rubygems/2.6.11 ruby/2.4.1 (x86_64-apple-darwin16.5.0) command/lock options/spec_run,plugins,trampoline_disable 7edfb7e0938d0c35
+> connection: keep-alive
+> keep-alive: 30
+> host: index.rubygems.org \ No newline at end of file
diff --git a/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/net-scp/GET/response b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/net-scp/GET/response
new file mode 100644
index 0000000000..1041db3aa7
--- /dev/null
+++ b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/net-scp/GET/response
Binary files differ
diff --git a/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/net-ssh/GET/request b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/net-ssh/GET/request
new file mode 100644
index 0000000000..043751da3b
--- /dev/null
+++ b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/net-ssh/GET/request
@@ -0,0 +1,7 @@
+> GET /info/net-ssh
+> accept-encoding: gzip
+> accept: */*
+> user-agent: bundler/1.15.0.pre.2 rubygems/2.6.11 ruby/2.4.1 (x86_64-apple-darwin16.5.0) command/lock options/spec_run,plugins,trampoline_disable 7edfb7e0938d0c35
+> connection: keep-alive
+> keep-alive: 30
+> host: index.rubygems.org \ No newline at end of file
diff --git a/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/net-ssh/GET/response b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/net-ssh/GET/response
new file mode 100644
index 0000000000..33632b22b5
--- /dev/null
+++ b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/net-ssh/GET/response
Binary files differ
diff --git a/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/netrc/GET/request b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/netrc/GET/request
new file mode 100644
index 0000000000..912c799120
--- /dev/null
+++ b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/netrc/GET/request
@@ -0,0 +1,7 @@
+> GET /info/netrc
+> accept-encoding: gzip
+> accept: */*
+> user-agent: bundler/1.15.0.pre.2 rubygems/2.6.11 ruby/2.4.1 (x86_64-apple-darwin16.5.0) command/lock options/spec_run,plugins,trampoline_disable 7edfb7e0938d0c35
+> connection: keep-alive
+> keep-alive: 30
+> host: index.rubygems.org \ No newline at end of file
diff --git a/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/netrc/GET/response b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/netrc/GET/response
new file mode 100644
index 0000000000..53a65c4824
--- /dev/null
+++ b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/netrc/GET/response
Binary files differ
diff --git a/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/newgem/GET/request b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/newgem/GET/request
new file mode 100644
index 0000000000..ef62899a0c
--- /dev/null
+++ b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/newgem/GET/request
@@ -0,0 +1,7 @@
+> GET /info/newgem
+> accept-encoding: gzip
+> accept: */*
+> user-agent: bundler/1.15.0.pre.2 rubygems/2.6.11 ruby/2.4.1 (x86_64-apple-darwin16.5.0) command/install options/retry,path,disable_shared_gems,spec_run,plugins,trampoline_disable d59b382d069fc94f
+> connection: keep-alive
+> keep-alive: 30
+> host: index.rubygems.org \ No newline at end of file
diff --git a/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/newgem/GET/response b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/newgem/GET/response
new file mode 100644
index 0000000000..9a5e53ac8c
--- /dev/null
+++ b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/newgem/GET/response
Binary files differ
diff --git a/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/nio4r/GET/request b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/nio4r/GET/request
new file mode 100644
index 0000000000..44337df0b7
--- /dev/null
+++ b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/nio4r/GET/request
@@ -0,0 +1,7 @@
+> GET /info/nio4r
+> accept-encoding: gzip
+> accept: */*
+> user-agent: bundler/1.15.0.pre.2 rubygems/2.6.11 ruby/2.4.1 (x86_64-apple-darwin16.5.0) command/lock options/spec_run,plugins,trampoline_disable 7edfb7e0938d0c35
+> connection: keep-alive
+> keep-alive: 30
+> host: index.rubygems.org \ No newline at end of file
diff --git a/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/nio4r/GET/response b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/nio4r/GET/response
new file mode 100644
index 0000000000..56e0f5a7e1
--- /dev/null
+++ b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/nio4r/GET/response
Binary files differ
diff --git a/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/nokogiri/GET/request b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/nokogiri/GET/request
new file mode 100644
index 0000000000..09c5dd725f
--- /dev/null
+++ b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/nokogiri/GET/request
@@ -0,0 +1,7 @@
+> GET /info/nokogiri
+> accept-encoding: gzip
+> accept: */*
+> user-agent: bundler/1.15.0.pre.2 rubygems/2.6.11 ruby/2.4.1 (x86_64-apple-darwin16.5.0) command/lock options/spec_run,plugins,trampoline_disable 7edfb7e0938d0c35
+> connection: keep-alive
+> keep-alive: 30
+> host: index.rubygems.org \ No newline at end of file
diff --git a/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/nokogiri/GET/response b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/nokogiri/GET/response
new file mode 100644
index 0000000000..369a205b2e
--- /dev/null
+++ b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/nokogiri/GET/response
Binary files differ
diff --git a/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/os/GET/request b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/os/GET/request
new file mode 100644
index 0000000000..1d82322d8b
--- /dev/null
+++ b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/os/GET/request
@@ -0,0 +1,7 @@
+> GET /info/os
+> accept-encoding: gzip
+> accept: */*
+> user-agent: bundler/1.15.0.pre.2 rubygems/2.6.11 ruby/2.4.1 (x86_64-apple-darwin16.5.0) command/lock options/spec_run,plugins,trampoline_disable 53c83f3e5793993c
+> connection: keep-alive
+> keep-alive: 30
+> host: index.rubygems.org \ No newline at end of file
diff --git a/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/os/GET/response b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/os/GET/response
new file mode 100644
index 0000000000..cd38a4e1ef
--- /dev/null
+++ b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/os/GET/response
Binary files differ
diff --git a/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/paperclip/GET/request b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/paperclip/GET/request
new file mode 100644
index 0000000000..c977514627
--- /dev/null
+++ b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/paperclip/GET/request
@@ -0,0 +1,7 @@
+> GET /info/paperclip
+> accept-encoding: gzip
+> accept: */*
+> user-agent: bundler/1.15.0.pre.2 rubygems/2.6.11 ruby/2.4.1 (x86_64-apple-darwin16.5.0) command/lock options/spec_run,plugins,trampoline_disable 6d5397ce7f8b26e0
+> connection: keep-alive
+> keep-alive: 30
+> host: index.rubygems.org \ No newline at end of file
diff --git a/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/paperclip/GET/response b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/paperclip/GET/response
new file mode 100644
index 0000000000..31b3fdd4d7
--- /dev/null
+++ b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/paperclip/GET/response
Binary files differ
diff --git a/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/parser/GET/request b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/parser/GET/request
new file mode 100644
index 0000000000..5fc1b9ff8b
--- /dev/null
+++ b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/parser/GET/request
@@ -0,0 +1,7 @@
+> GET /info/parser
+> accept-encoding: gzip
+> accept: */*
+> user-agent: bundler/1.15.0.pre.2 rubygems/2.6.11 ruby/2.4.1 (x86_64-apple-darwin16.5.0) command/lock options/spec_run,plugins,trampoline_disable 7edfb7e0938d0c35
+> connection: keep-alive
+> keep-alive: 30
+> host: index.rubygems.org \ No newline at end of file
diff --git a/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/parser/GET/response b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/parser/GET/response
new file mode 100644
index 0000000000..8de3ebdeeb
--- /dev/null
+++ b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/parser/GET/response
Binary files differ
diff --git a/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/pattern-match/GET/request b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/pattern-match/GET/request
new file mode 100644
index 0000000000..1636fe07b4
--- /dev/null
+++ b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/pattern-match/GET/request
@@ -0,0 +1,7 @@
+> GET /info/pattern-match
+> accept-encoding: gzip
+> accept: */*
+> user-agent: bundler/1.15.0.pre.2 rubygems/2.6.11 ruby/2.4.1 (x86_64-apple-darwin16.5.0) command/lock options/spec_run,plugins,trampoline_disable 7edfb7e0938d0c35
+> connection: keep-alive
+> keep-alive: 30
+> host: index.rubygems.org \ No newline at end of file
diff --git a/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/pattern-match/GET/response b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/pattern-match/GET/response
new file mode 100644
index 0000000000..407bd97444
--- /dev/null
+++ b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/pattern-match/GET/response
Binary files differ
diff --git a/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/pkg-config/GET/request b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/pkg-config/GET/request
new file mode 100644
index 0000000000..8f2f5ae398
--- /dev/null
+++ b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/pkg-config/GET/request
@@ -0,0 +1,7 @@
+> GET /info/pkg-config
+> accept-encoding: gzip
+> accept: */*
+> user-agent: bundler/1.15.0.pre.2 rubygems/2.6.11 ruby/2.4.1 (x86_64-apple-darwin16.5.0) command/lock options/spec_run,plugins,trampoline_disable 7edfb7e0938d0c35
+> connection: keep-alive
+> keep-alive: 30
+> host: index.rubygems.org \ No newline at end of file
diff --git a/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/pkg-config/GET/response b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/pkg-config/GET/response
new file mode 100644
index 0000000000..892050438f
--- /dev/null
+++ b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/pkg-config/GET/response
Binary files differ
diff --git a/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/polyglot/GET/request b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/polyglot/GET/request
new file mode 100644
index 0000000000..8841563b63
--- /dev/null
+++ b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/polyglot/GET/request
@@ -0,0 +1,7 @@
+> GET /info/polyglot
+> accept-encoding: gzip
+> accept: */*
+> user-agent: bundler/1.15.0.pre.2 rubygems/2.6.11 ruby/2.4.1 (x86_64-apple-darwin16.5.0) command/lock options/spec_run,plugins,trampoline_disable 7edfb7e0938d0c35
+> connection: keep-alive
+> keep-alive: 30
+> host: index.rubygems.org \ No newline at end of file
diff --git a/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/polyglot/GET/response b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/polyglot/GET/response
new file mode 100644
index 0000000000..2e5dba2b76
--- /dev/null
+++ b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/polyglot/GET/response
Binary files differ
diff --git a/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/power_assert/GET/request b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/power_assert/GET/request
new file mode 100644
index 0000000000..73ef4c0d07
--- /dev/null
+++ b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/power_assert/GET/request
@@ -0,0 +1,7 @@
+> GET /info/power_assert
+> accept-encoding: gzip
+> accept: */*
+> user-agent: bundler/1.15.0.pre.2 rubygems/2.6.11 ruby/2.4.1 (x86_64-apple-darwin16.5.0) command/lock options/spec_run,plugins,trampoline_disable 7edfb7e0938d0c35
+> connection: keep-alive
+> keep-alive: 30
+> host: index.rubygems.org \ No newline at end of file
diff --git a/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/power_assert/GET/response b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/power_assert/GET/response
new file mode 100644
index 0000000000..d9cdfe043b
--- /dev/null
+++ b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/power_assert/GET/response
Binary files differ
diff --git a/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/powerbar/GET/request b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/powerbar/GET/request
new file mode 100644
index 0000000000..0a69936bc6
--- /dev/null
+++ b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/powerbar/GET/request
@@ -0,0 +1,7 @@
+> GET /info/powerbar
+> accept-encoding: gzip
+> accept: */*
+> user-agent: bundler/1.15.0.pre.2 rubygems/2.6.11 ruby/2.4.1 (x86_64-apple-darwin16.5.0) command/lock options/spec_run,plugins,trampoline_disable 7edfb7e0938d0c35
+> connection: keep-alive
+> keep-alive: 30
+> host: index.rubygems.org \ No newline at end of file
diff --git a/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/powerbar/GET/response b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/powerbar/GET/response
new file mode 100644
index 0000000000..a71d6494db
--- /dev/null
+++ b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/powerbar/GET/response
Binary files differ
diff --git a/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/powerpack/GET/request b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/powerpack/GET/request
new file mode 100644
index 0000000000..20bf19b1af
--- /dev/null
+++ b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/powerpack/GET/request
@@ -0,0 +1,7 @@
+> GET /info/powerpack
+> accept-encoding: gzip
+> accept: */*
+> user-agent: bundler/1.15.0.pre.2 rubygems/2.6.11 ruby/2.4.1 (x86_64-apple-darwin16.5.0) command/lock options/spec_run,plugins,trampoline_disable 7edfb7e0938d0c35
+> connection: keep-alive
+> keep-alive: 30
+> host: index.rubygems.org \ No newline at end of file
diff --git a/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/powerpack/GET/response b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/powerpack/GET/response
new file mode 100644
index 0000000000..18240e5335
--- /dev/null
+++ b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/powerpack/GET/response
Binary files differ
diff --git a/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/preforker/GET/request b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/preforker/GET/request
new file mode 100644
index 0000000000..2ba448e12d
--- /dev/null
+++ b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/preforker/GET/request
@@ -0,0 +1,7 @@
+> GET /info/preforker
+> accept-encoding: gzip
+> accept: */*
+> user-agent: bundler/1.15.0.pre.2 rubygems/2.6.11 ruby/2.4.1 (x86_64-apple-darwin16.5.0) command/lock options/spec_run,plugins,trampoline_disable 7edfb7e0938d0c35
+> connection: keep-alive
+> keep-alive: 30
+> host: index.rubygems.org \ No newline at end of file
diff --git a/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/preforker/GET/response b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/preforker/GET/response
new file mode 100644
index 0000000000..c9cf52559e
--- /dev/null
+++ b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/preforker/GET/response
Binary files differ
diff --git a/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/public_suffix/GET/request b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/public_suffix/GET/request
new file mode 100644
index 0000000000..9f13c8a79e
--- /dev/null
+++ b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/public_suffix/GET/request
@@ -0,0 +1,7 @@
+> GET /info/public_suffix
+> accept-encoding: gzip
+> accept: */*
+> user-agent: bundler/1.15.0.pre.2 rubygems/2.6.11 ruby/2.4.1 (x86_64-apple-darwin16.5.0) command/lock options/spec_run,plugins,trampoline_disable 7edfb7e0938d0c35
+> connection: keep-alive
+> keep-alive: 30
+> host: index.rubygems.org \ No newline at end of file
diff --git a/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/public_suffix/GET/response b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/public_suffix/GET/response
new file mode 100644
index 0000000000..75a81259f8
--- /dev/null
+++ b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/public_suffix/GET/response
Binary files differ
diff --git a/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/racc/GET/request b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/racc/GET/request
new file mode 100644
index 0000000000..dfc9adfa9d
--- /dev/null
+++ b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/racc/GET/request
@@ -0,0 +1,7 @@
+> GET /info/racc
+> accept-encoding: gzip
+> accept: */*
+> user-agent: bundler/1.15.0.pre.2 rubygems/2.6.11 ruby/2.4.1 (x86_64-apple-darwin16.5.0) command/lock options/spec_run,plugins,trampoline_disable 7edfb7e0938d0c35
+> connection: keep-alive
+> keep-alive: 30
+> host: index.rubygems.org \ No newline at end of file
diff --git a/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/racc/GET/response b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/racc/GET/response
new file mode 100644
index 0000000000..3b19786ead
--- /dev/null
+++ b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/racc/GET/response
Binary files differ
diff --git a/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/rack-cache/GET/request b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/rack-cache/GET/request
new file mode 100644
index 0000000000..27a90522f4
--- /dev/null
+++ b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/rack-cache/GET/request
@@ -0,0 +1,7 @@
+> GET /info/rack-cache
+> accept-encoding: gzip
+> accept: */*
+> user-agent: bundler/1.15.0.pre.2 rubygems/2.6.11 ruby/2.4.1 (x86_64-apple-darwin16.5.0) command/lock options/spec_run,plugins,trampoline_disable 7edfb7e0938d0c35
+> connection: keep-alive
+> keep-alive: 30
+> host: index.rubygems.org \ No newline at end of file
diff --git a/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/rack-cache/GET/response b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/rack-cache/GET/response
new file mode 100644
index 0000000000..94e686dc49
--- /dev/null
+++ b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/rack-cache/GET/response
Binary files differ
diff --git a/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/rack-mount/GET/request b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/rack-mount/GET/request
new file mode 100644
index 0000000000..59a7bd8b8d
--- /dev/null
+++ b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/rack-mount/GET/request
@@ -0,0 +1,7 @@
+> GET /info/rack-mount
+> accept-encoding: gzip
+> accept: */*
+> user-agent: bundler/1.15.0.pre.2 rubygems/2.6.11 ruby/2.4.1 (x86_64-apple-darwin16.5.0) command/lock options/spec_run,plugins,trampoline_disable 7edfb7e0938d0c35
+> connection: keep-alive
+> keep-alive: 30
+> host: index.rubygems.org \ No newline at end of file
diff --git a/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/rack-mount/GET/response b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/rack-mount/GET/response
new file mode 100644
index 0000000000..42dde6a265
--- /dev/null
+++ b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/rack-mount/GET/response
Binary files differ
diff --git a/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/rack-protection/GET/request b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/rack-protection/GET/request
new file mode 100644
index 0000000000..4eb6557436
--- /dev/null
+++ b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/rack-protection/GET/request
@@ -0,0 +1,7 @@
+> GET /info/rack-protection
+> accept-encoding: gzip
+> accept: */*
+> user-agent: bundler/1.15.0.pre.2 rubygems/2.6.11 ruby/2.4.1 (x86_64-apple-darwin16.5.0) command/lock options/spec_run,plugins,trampoline_disable 53c83f3e5793993c
+> connection: keep-alive
+> keep-alive: 30
+> host: index.rubygems.org \ No newline at end of file
diff --git a/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/rack-protection/GET/response b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/rack-protection/GET/response
new file mode 100644
index 0000000000..8ac5f63f69
--- /dev/null
+++ b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/rack-protection/GET/response
Binary files differ
diff --git a/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/rack-ssl/GET/request b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/rack-ssl/GET/request
new file mode 100644
index 0000000000..6871bc0308
--- /dev/null
+++ b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/rack-ssl/GET/request
@@ -0,0 +1,7 @@
+> GET /info/rack-ssl
+> accept-encoding: gzip
+> accept: */*
+> user-agent: bundler/1.15.0.pre.2 rubygems/2.6.11 ruby/2.4.1 (x86_64-apple-darwin16.5.0) command/lock options/spec_run,plugins,trampoline_disable 7edfb7e0938d0c35
+> connection: keep-alive
+> keep-alive: 30
+> host: index.rubygems.org \ No newline at end of file
diff --git a/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/rack-ssl/GET/response b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/rack-ssl/GET/response
new file mode 100644
index 0000000000..47375b7ed8
--- /dev/null
+++ b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/rack-ssl/GET/response
Binary files differ
diff --git a/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/rack-test/GET/request b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/rack-test/GET/request
new file mode 100644
index 0000000000..624dd07678
--- /dev/null
+++ b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/rack-test/GET/request
@@ -0,0 +1,7 @@
+> GET /info/rack-test
+> accept-encoding: gzip
+> accept: */*
+> user-agent: bundler/1.15.0.pre.2 rubygems/2.6.11 ruby/2.4.1 (x86_64-apple-darwin16.5.0) command/lock options/spec_run,plugins,trampoline_disable 7edfb7e0938d0c35
+> connection: keep-alive
+> keep-alive: 30
+> host: index.rubygems.org \ No newline at end of file
diff --git a/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/rack-test/GET/response b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/rack-test/GET/response
new file mode 100644
index 0000000000..ee93493b49
--- /dev/null
+++ b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/rack-test/GET/response
Binary files differ
diff --git a/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/rack/GET/request b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/rack/GET/request
new file mode 100644
index 0000000000..16a0feac8c
--- /dev/null
+++ b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/rack/GET/request
@@ -0,0 +1,7 @@
+> GET /info/rack
+> accept-encoding: gzip
+> accept: */*
+> user-agent: bundler/1.15.0.pre.2 rubygems/2.6.11 ruby/2.4.1 (x86_64-apple-darwin16.5.0) command/lock options/spec_run,plugins,trampoline_disable 7edfb7e0938d0c35
+> connection: keep-alive
+> keep-alive: 30
+> host: index.rubygems.org \ No newline at end of file
diff --git a/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/rack/GET/response b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/rack/GET/response
new file mode 100644
index 0000000000..867035cd63
--- /dev/null
+++ b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/rack/GET/response
Binary files differ
diff --git a/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/rails-deprecated_sanitizer/GET/request b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/rails-deprecated_sanitizer/GET/request
new file mode 100644
index 0000000000..67514b94c8
--- /dev/null
+++ b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/rails-deprecated_sanitizer/GET/request
@@ -0,0 +1,7 @@
+> GET /info/rails-deprecated_sanitizer
+> accept-encoding: gzip
+> accept: */*
+> user-agent: bundler/1.15.0.pre.2 rubygems/2.6.11 ruby/2.4.1 (x86_64-apple-darwin16.5.0) command/lock options/spec_run,plugins,trampoline_disable 7edfb7e0938d0c35
+> connection: keep-alive
+> keep-alive: 30
+> host: index.rubygems.org \ No newline at end of file
diff --git a/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/rails-deprecated_sanitizer/GET/response b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/rails-deprecated_sanitizer/GET/response
new file mode 100644
index 0000000000..1344345709
--- /dev/null
+++ b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/rails-deprecated_sanitizer/GET/response
Binary files differ
diff --git a/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/rails-dom-testing/GET/request b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/rails-dom-testing/GET/request
new file mode 100644
index 0000000000..2caa6d814e
--- /dev/null
+++ b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/rails-dom-testing/GET/request
@@ -0,0 +1,7 @@
+> GET /info/rails-dom-testing
+> accept-encoding: gzip
+> accept: */*
+> user-agent: bundler/1.15.0.pre.2 rubygems/2.6.11 ruby/2.4.1 (x86_64-apple-darwin16.5.0) command/lock options/spec_run,plugins,trampoline_disable 7edfb7e0938d0c35
+> connection: keep-alive
+> keep-alive: 30
+> host: index.rubygems.org \ No newline at end of file
diff --git a/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/rails-dom-testing/GET/response b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/rails-dom-testing/GET/response
new file mode 100644
index 0000000000..cc215cf4f0
--- /dev/null
+++ b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/rails-dom-testing/GET/response
Binary files differ
diff --git a/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/rails-html-sanitizer/GET/request b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/rails-html-sanitizer/GET/request
new file mode 100644
index 0000000000..54db344173
--- /dev/null
+++ b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/rails-html-sanitizer/GET/request
@@ -0,0 +1,7 @@
+> GET /info/rails-html-sanitizer
+> accept-encoding: gzip
+> accept: */*
+> user-agent: bundler/1.15.0.pre.2 rubygems/2.6.11 ruby/2.4.1 (x86_64-apple-darwin16.5.0) command/lock options/spec_run,plugins,trampoline_disable 7edfb7e0938d0c35
+> connection: keep-alive
+> keep-alive: 30
+> host: index.rubygems.org \ No newline at end of file
diff --git a/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/rails-html-sanitizer/GET/response b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/rails-html-sanitizer/GET/response
new file mode 100644
index 0000000000..6dbdd7d5c3
--- /dev/null
+++ b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/rails-html-sanitizer/GET/response
Binary files differ
diff --git a/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/rails-observers/GET/request b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/rails-observers/GET/request
new file mode 100644
index 0000000000..3fb8b11adf
--- /dev/null
+++ b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/rails-observers/GET/request
@@ -0,0 +1,7 @@
+> GET /info/rails-observers
+> accept-encoding: gzip
+> accept: */*
+> user-agent: bundler/1.15.0.pre.2 rubygems/2.6.11 ruby/2.4.1 (x86_64-apple-darwin16.5.0) command/lock options/spec_run,plugins,trampoline_disable 7edfb7e0938d0c35
+> connection: keep-alive
+> keep-alive: 30
+> host: index.rubygems.org \ No newline at end of file
diff --git a/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/rails-observers/GET/response b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/rails-observers/GET/response
new file mode 100644
index 0000000000..ba7e9367fa
--- /dev/null
+++ b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/rails-observers/GET/response
Binary files differ
diff --git a/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/rails/GET/request b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/rails/GET/request
new file mode 100644
index 0000000000..b156e7be25
--- /dev/null
+++ b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/rails/GET/request
@@ -0,0 +1,7 @@
+> GET /info/rails
+> accept-encoding: gzip
+> accept: */*
+> user-agent: bundler/1.15.0.pre.2 rubygems/2.6.11 ruby/2.4.1 (x86_64-apple-darwin16.5.0) command/lock options/spec_run,plugins,trampoline_disable 7edfb7e0938d0c35
+> connection: keep-alive
+> keep-alive: 30
+> host: index.rubygems.org \ No newline at end of file
diff --git a/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/rails/GET/response b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/rails/GET/response
new file mode 100644
index 0000000000..9ff62db657
--- /dev/null
+++ b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/rails/GET/response
Binary files differ
diff --git a/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/railties/GET/request b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/railties/GET/request
new file mode 100644
index 0000000000..40f66c8a6f
--- /dev/null
+++ b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/railties/GET/request
@@ -0,0 +1,7 @@
+> GET /info/railties
+> accept-encoding: gzip
+> accept: */*
+> user-agent: bundler/1.15.0.pre.2 rubygems/2.6.11 ruby/2.4.1 (x86_64-apple-darwin16.5.0) command/lock options/spec_run,plugins,trampoline_disable 7edfb7e0938d0c35
+> connection: keep-alive
+> keep-alive: 30
+> host: index.rubygems.org \ No newline at end of file
diff --git a/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/railties/GET/response b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/railties/GET/response
new file mode 100644
index 0000000000..c95e7e7edd
--- /dev/null
+++ b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/railties/GET/response
Binary files differ
diff --git a/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/rainbow/GET/request b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/rainbow/GET/request
new file mode 100644
index 0000000000..ae1ee0cee9
--- /dev/null
+++ b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/rainbow/GET/request
@@ -0,0 +1,7 @@
+> GET /info/rainbow
+> accept-encoding: gzip
+> accept: */*
+> user-agent: bundler/1.15.0.pre.2 rubygems/2.6.11 ruby/2.4.1 (x86_64-apple-darwin16.5.0) command/lock options/spec_run,plugins,trampoline_disable 7edfb7e0938d0c35
+> connection: keep-alive
+> keep-alive: 30
+> host: index.rubygems.org \ No newline at end of file
diff --git a/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/rainbow/GET/response b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/rainbow/GET/response
new file mode 100644
index 0000000000..f09bf393c2
--- /dev/null
+++ b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/rainbow/GET/response
Binary files differ
diff --git a/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/rake-compiler/GET/request b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/rake-compiler/GET/request
new file mode 100644
index 0000000000..2f777a05bf
--- /dev/null
+++ b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/rake-compiler/GET/request
@@ -0,0 +1,7 @@
+> GET /info/rake-compiler
+> accept-encoding: gzip
+> accept: */*
+> user-agent: bundler/1.15.0.pre.2 rubygems/2.6.11 ruby/2.4.1 (x86_64-apple-darwin16.5.0) command/lock options/spec_run,plugins,trampoline_disable 7edfb7e0938d0c35
+> connection: keep-alive
+> keep-alive: 30
+> host: index.rubygems.org \ No newline at end of file
diff --git a/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/rake-compiler/GET/response b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/rake-compiler/GET/response
new file mode 100644
index 0000000000..23e76df066
--- /dev/null
+++ b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/rake-compiler/GET/response
Binary files differ
diff --git a/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/rake/GET/request b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/rake/GET/request
new file mode 100644
index 0000000000..c161c917e1
--- /dev/null
+++ b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/rake/GET/request
@@ -0,0 +1,7 @@
+> GET /info/rake
+> accept-encoding: gzip
+> accept: */*
+> user-agent: bundler/1.15.0.pre.2 rubygems/2.6.11 ruby/2.4.1 (x86_64-apple-darwin16.5.0) command/lock options/spec_run,plugins,trampoline_disable 7edfb7e0938d0c35
+> connection: keep-alive
+> keep-alive: 30
+> host: index.rubygems.org \ No newline at end of file
diff --git a/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/rake/GET/response b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/rake/GET/response
new file mode 100644
index 0000000000..da73b27d17
--- /dev/null
+++ b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/rake/GET/response
Binary files differ
diff --git a/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/rb-fchange/GET/request b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/rb-fchange/GET/request
new file mode 100644
index 0000000000..101066914a
--- /dev/null
+++ b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/rb-fchange/GET/request
@@ -0,0 +1,7 @@
+> GET /info/rb-fchange
+> accept-encoding: gzip
+> accept: */*
+> user-agent: bundler/1.15.0.pre.2 rubygems/2.6.11 ruby/2.4.1 (x86_64-apple-darwin16.5.0) command/lock options/spec_run,plugins,trampoline_disable 53c83f3e5793993c
+> connection: keep-alive
+> keep-alive: 30
+> host: index.rubygems.org \ No newline at end of file
diff --git a/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/rb-fchange/GET/response b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/rb-fchange/GET/response
new file mode 100644
index 0000000000..99ed1a9fdf
--- /dev/null
+++ b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/rb-fchange/GET/response
Binary files differ
diff --git a/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/rb-fsevent/GET/request b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/rb-fsevent/GET/request
new file mode 100644
index 0000000000..192253cb0c
--- /dev/null
+++ b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/rb-fsevent/GET/request
@@ -0,0 +1,7 @@
+> GET /info/rb-fsevent
+> accept-encoding: gzip
+> accept: */*
+> user-agent: bundler/1.15.0.pre.2 rubygems/2.6.11 ruby/2.4.1 (x86_64-apple-darwin16.5.0) command/lock options/spec_run,plugins,trampoline_disable 53c83f3e5793993c
+> connection: keep-alive
+> keep-alive: 30
+> host: index.rubygems.org \ No newline at end of file
diff --git a/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/rb-fsevent/GET/response b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/rb-fsevent/GET/response
new file mode 100644
index 0000000000..536d498501
--- /dev/null
+++ b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/rb-fsevent/GET/response
Binary files differ
diff --git a/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/rb-inotify/GET/request b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/rb-inotify/GET/request
new file mode 100644
index 0000000000..cf7287e37b
--- /dev/null
+++ b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/rb-inotify/GET/request
@@ -0,0 +1,7 @@
+> GET /info/rb-inotify
+> accept-encoding: gzip
+> accept: */*
+> user-agent: bundler/1.15.0.pre.2 rubygems/2.6.11 ruby/2.4.1 (x86_64-apple-darwin16.5.0) command/lock options/spec_run,plugins,trampoline_disable 53c83f3e5793993c
+> connection: keep-alive
+> keep-alive: 30
+> host: index.rubygems.org \ No newline at end of file
diff --git a/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/rb-inotify/GET/response b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/rb-inotify/GET/response
new file mode 100644
index 0000000000..6e34ecb855
--- /dev/null
+++ b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/rb-inotify/GET/response
Binary files differ
diff --git a/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/rb-kqueue/GET/request b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/rb-kqueue/GET/request
new file mode 100644
index 0000000000..6d256b9e11
--- /dev/null
+++ b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/rb-kqueue/GET/request
@@ -0,0 +1,7 @@
+> GET /info/rb-kqueue
+> accept-encoding: gzip
+> accept: */*
+> user-agent: bundler/1.15.0.pre.2 rubygems/2.6.11 ruby/2.4.1 (x86_64-apple-darwin16.5.0) command/lock options/spec_run,plugins,trampoline_disable 53c83f3e5793993c
+> connection: keep-alive
+> keep-alive: 30
+> host: index.rubygems.org \ No newline at end of file
diff --git a/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/rb-kqueue/GET/response b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/rb-kqueue/GET/response
new file mode 100644
index 0000000000..63953471b7
--- /dev/null
+++ b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/rb-kqueue/GET/response
Binary files differ
diff --git a/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/rbnacl-libsodium/GET/request b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/rbnacl-libsodium/GET/request
new file mode 100644
index 0000000000..0a269f784f
--- /dev/null
+++ b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/rbnacl-libsodium/GET/request
@@ -0,0 +1,7 @@
+> GET /info/rbnacl-libsodium
+> accept-encoding: gzip
+> accept: */*
+> user-agent: bundler/1.15.0.pre.2 rubygems/2.6.11 ruby/2.4.1 (x86_64-apple-darwin16.5.0) command/lock options/spec_run,plugins,trampoline_disable 7edfb7e0938d0c35
+> connection: keep-alive
+> keep-alive: 30
+> host: index.rubygems.org \ No newline at end of file
diff --git a/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/rbnacl-libsodium/GET/response b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/rbnacl-libsodium/GET/response
new file mode 100644
index 0000000000..158fec8538
--- /dev/null
+++ b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/rbnacl-libsodium/GET/response
Binary files differ
diff --git a/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/rbnacl/GET/request b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/rbnacl/GET/request
new file mode 100644
index 0000000000..d28de6c266
--- /dev/null
+++ b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/rbnacl/GET/request
@@ -0,0 +1,7 @@
+> GET /info/rbnacl
+> accept-encoding: gzip
+> accept: */*
+> user-agent: bundler/1.15.0.pre.2 rubygems/2.6.11 ruby/2.4.1 (x86_64-apple-darwin16.5.0) command/lock options/spec_run,plugins,trampoline_disable 7edfb7e0938d0c35
+> connection: keep-alive
+> keep-alive: 30
+> host: index.rubygems.org \ No newline at end of file
diff --git a/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/rbnacl/GET/response b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/rbnacl/GET/response
new file mode 100644
index 0000000000..6a5555bc2b
--- /dev/null
+++ b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/rbnacl/GET/response
Binary files differ
diff --git a/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/rcov/GET/request b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/rcov/GET/request
new file mode 100644
index 0000000000..611a286a4c
--- /dev/null
+++ b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/rcov/GET/request
@@ -0,0 +1,7 @@
+> GET /info/rcov
+> accept-encoding: gzip
+> accept: */*
+> user-agent: bundler/1.15.0.pre.2 rubygems/2.6.11 ruby/2.4.1 (x86_64-apple-darwin16.5.0) command/lock options/spec_run,plugins,trampoline_disable 7edfb7e0938d0c35
+> connection: keep-alive
+> keep-alive: 30
+> host: index.rubygems.org \ No newline at end of file
diff --git a/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/rcov/GET/response b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/rcov/GET/response
new file mode 100644
index 0000000000..7ef58c5aab
--- /dev/null
+++ b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/rcov/GET/response
Binary files differ
diff --git a/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/rdoc/GET/request b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/rdoc/GET/request
new file mode 100644
index 0000000000..8402303257
--- /dev/null
+++ b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/rdoc/GET/request
@@ -0,0 +1,7 @@
+> GET /info/rdoc
+> accept-encoding: gzip
+> accept: */*
+> user-agent: bundler/1.15.0.pre.2 rubygems/2.6.11 ruby/2.4.1 (x86_64-apple-darwin16.5.0) command/lock options/spec_run,plugins,trampoline_disable 7edfb7e0938d0c35
+> connection: keep-alive
+> keep-alive: 30
+> host: index.rubygems.org \ No newline at end of file
diff --git a/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/rdoc/GET/response b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/rdoc/GET/response
new file mode 100644
index 0000000000..3d86e4f442
--- /dev/null
+++ b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/rdoc/GET/response
Binary files differ
diff --git a/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/redis-namespace/GET/request b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/redis-namespace/GET/request
new file mode 100644
index 0000000000..9b78830065
--- /dev/null
+++ b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/redis-namespace/GET/request
@@ -0,0 +1,7 @@
+> GET /info/redis-namespace
+> accept-encoding: gzip
+> accept: */*
+> user-agent: bundler/1.15.0.pre.2 rubygems/2.6.11 ruby/2.4.1 (x86_64-apple-darwin16.5.0) command/install options/retry,path,disable_shared_gems,spec_run,plugins,trampoline_disable d59b382d069fc94f
+> connection: keep-alive
+> keep-alive: 30
+> host: index.rubygems.org \ No newline at end of file
diff --git a/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/redis-namespace/GET/response b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/redis-namespace/GET/response
new file mode 100644
index 0000000000..03d9194045
--- /dev/null
+++ b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/redis-namespace/GET/response
Binary files differ
diff --git a/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/redis/GET/request b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/redis/GET/request
new file mode 100644
index 0000000000..9bfcfc80fd
--- /dev/null
+++ b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/redis/GET/request
@@ -0,0 +1,7 @@
+> GET /info/redis
+> accept-encoding: gzip
+> accept: */*
+> user-agent: bundler/1.15.0.pre.2 rubygems/2.6.11 ruby/2.4.1 (x86_64-apple-darwin16.5.0) command/lock options/spec_run,plugins,trampoline_disable 7edfb7e0938d0c35
+> connection: keep-alive
+> keep-alive: 30
+> host: index.rubygems.org \ No newline at end of file
diff --git a/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/redis/GET/response b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/redis/GET/response
new file mode 100644
index 0000000000..9f5d4406e5
--- /dev/null
+++ b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/redis/GET/response
Binary files differ
diff --git a/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/ref/GET/request b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/ref/GET/request
new file mode 100644
index 0000000000..42ee151f68
--- /dev/null
+++ b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/ref/GET/request
@@ -0,0 +1,7 @@
+> GET /info/ref
+> accept-encoding: gzip
+> accept: */*
+> user-agent: bundler/1.15.0.pre.2 rubygems/2.6.11 ruby/2.4.1 (x86_64-apple-darwin16.5.0) command/lock options/spec_run,plugins,trampoline_disable 7edfb7e0938d0c35
+> connection: keep-alive
+> keep-alive: 30
+> host: index.rubygems.org \ No newline at end of file
diff --git a/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/ref/GET/response b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/ref/GET/response
new file mode 100644
index 0000000000..528ef107b5
--- /dev/null
+++ b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/ref/GET/response
Binary files differ
diff --git a/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/representable/GET/request b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/representable/GET/request
new file mode 100644
index 0000000000..73a5ca084e
--- /dev/null
+++ b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/representable/GET/request
@@ -0,0 +1,7 @@
+> GET /info/representable
+> accept-encoding: gzip
+> accept: */*
+> user-agent: bundler/1.15.0.pre.2 rubygems/2.6.11 ruby/2.4.1 (x86_64-apple-darwin16.5.0) command/lock options/spec_run,plugins,trampoline_disable 53c83f3e5793993c
+> connection: keep-alive
+> keep-alive: 30
+> host: index.rubygems.org \ No newline at end of file
diff --git a/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/representable/GET/response b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/representable/GET/response
new file mode 100644
index 0000000000..5a28b34afb
--- /dev/null
+++ b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/representable/GET/response
Binary files differ
diff --git a/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/resque-scheduler/GET/request b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/resque-scheduler/GET/request
new file mode 100644
index 0000000000..aa9132aedb
--- /dev/null
+++ b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/resque-scheduler/GET/request
@@ -0,0 +1,7 @@
+> GET /info/resque-scheduler
+> accept-encoding: gzip
+> accept: */*
+> user-agent: bundler/1.15.0.pre.2 rubygems/2.6.11 ruby/2.4.1 (x86_64-apple-darwin16.5.0) command/install options/retry,path,disable_shared_gems,spec_run,plugins,trampoline_disable d59b382d069fc94f
+> connection: keep-alive
+> keep-alive: 30
+> host: index.rubygems.org \ No newline at end of file
diff --git a/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/resque-scheduler/GET/response b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/resque-scheduler/GET/response
new file mode 100644
index 0000000000..8e0c95e2cb
--- /dev/null
+++ b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/resque-scheduler/GET/response
Binary files differ
diff --git a/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/resque/GET/request b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/resque/GET/request
new file mode 100644
index 0000000000..616a9e5b9f
--- /dev/null
+++ b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/resque/GET/request
@@ -0,0 +1,7 @@
+> GET /info/resque
+> accept-encoding: gzip
+> accept: */*
+> user-agent: bundler/1.15.0.pre.2 rubygems/2.6.11 ruby/2.4.1 (x86_64-apple-darwin16.5.0) command/install options/retry,path,disable_shared_gems,spec_run,plugins,trampoline_disable d59b382d069fc94f
+> connection: keep-alive
+> keep-alive: 30
+> host: index.rubygems.org \ No newline at end of file
diff --git a/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/resque/GET/response b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/resque/GET/response
new file mode 100644
index 0000000000..32c3e51e9b
--- /dev/null
+++ b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/resque/GET/response
Binary files differ
diff --git a/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/rest-client/GET/request b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/rest-client/GET/request
new file mode 100644
index 0000000000..5935658273
--- /dev/null
+++ b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/rest-client/GET/request
@@ -0,0 +1,7 @@
+> GET /info/rest-client
+> accept-encoding: gzip
+> accept: */*
+> user-agent: bundler/1.15.0.pre.2 rubygems/2.6.11 ruby/2.4.1 (x86_64-apple-darwin16.5.0) command/lock options/spec_run,plugins,trampoline_disable 7edfb7e0938d0c35
+> connection: keep-alive
+> keep-alive: 30
+> host: index.rubygems.org \ No newline at end of file
diff --git a/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/rest-client/GET/response b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/rest-client/GET/response
new file mode 100644
index 0000000000..5363438b08
--- /dev/null
+++ b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/rest-client/GET/response
Binary files differ
diff --git a/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/retriable/GET/request b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/retriable/GET/request
new file mode 100644
index 0000000000..a76f439668
--- /dev/null
+++ b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/retriable/GET/request
@@ -0,0 +1,7 @@
+> GET /info/retriable
+> accept-encoding: gzip
+> accept: */*
+> user-agent: bundler/1.15.0.pre.2 rubygems/2.6.11 ruby/2.4.1 (x86_64-apple-darwin16.5.0) command/lock options/spec_run,plugins,trampoline_disable 53c83f3e5793993c
+> connection: keep-alive
+> keep-alive: 30
+> host: index.rubygems.org \ No newline at end of file
diff --git a/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/retriable/GET/response b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/retriable/GET/response
new file mode 100644
index 0000000000..1ee15eeb98
--- /dev/null
+++ b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/retriable/GET/response
Binary files differ
diff --git a/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/rexical/GET/request b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/rexical/GET/request
new file mode 100644
index 0000000000..0390a17867
--- /dev/null
+++ b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/rexical/GET/request
@@ -0,0 +1,7 @@
+> GET /info/rexical
+> accept-encoding: gzip
+> accept: */*
+> user-agent: bundler/1.15.0.pre.2 rubygems/2.6.11 ruby/2.4.1 (x86_64-apple-darwin16.5.0) command/lock options/spec_run,plugins,trampoline_disable 7edfb7e0938d0c35
+> connection: keep-alive
+> keep-alive: 30
+> host: index.rubygems.org \ No newline at end of file
diff --git a/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/rexical/GET/response b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/rexical/GET/response
new file mode 100644
index 0000000000..9e6fb35c6c
--- /dev/null
+++ b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/rexical/GET/response
Binary files differ
diff --git a/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/right_aws/GET/request b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/right_aws/GET/request
new file mode 100644
index 0000000000..46fa433f4a
--- /dev/null
+++ b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/right_aws/GET/request
@@ -0,0 +1,7 @@
+> GET /info/right_aws
+> accept-encoding: gzip
+> accept: */*
+> user-agent: bundler/1.15.0.pre.2 rubygems/2.6.11 ruby/2.4.1 (x86_64-apple-darwin16.5.0) command/lock options/spec_run,plugins,trampoline_disable 6d5397ce7f8b26e0
+> connection: keep-alive
+> keep-alive: 30
+> host: index.rubygems.org \ No newline at end of file
diff --git a/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/right_aws/GET/response b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/right_aws/GET/response
new file mode 100644
index 0000000000..eb62d2516c
--- /dev/null
+++ b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/right_aws/GET/response
Binary files differ
diff --git a/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/right_http_connection/GET/request b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/right_http_connection/GET/request
new file mode 100644
index 0000000000..9afacd1726
--- /dev/null
+++ b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/right_http_connection/GET/request
@@ -0,0 +1,7 @@
+> GET /info/right_http_connection
+> accept-encoding: gzip
+> accept: */*
+> user-agent: bundler/1.15.0.pre.2 rubygems/2.6.11 ruby/2.4.1 (x86_64-apple-darwin16.5.0) command/lock options/spec_run,plugins,trampoline_disable 6d5397ce7f8b26e0
+> connection: keep-alive
+> keep-alive: 30
+> host: index.rubygems.org \ No newline at end of file
diff --git a/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/right_http_connection/GET/response b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/right_http_connection/GET/response
new file mode 100644
index 0000000000..05212f5e5e
--- /dev/null
+++ b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/right_http_connection/GET/response
Binary files differ
diff --git a/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/rspec-core/GET/request b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/rspec-core/GET/request
new file mode 100644
index 0000000000..c9398deae9
--- /dev/null
+++ b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/rspec-core/GET/request
@@ -0,0 +1,7 @@
+> GET /info/rspec-core
+> accept-encoding: gzip
+> accept: */*
+> user-agent: bundler/1.15.0.pre.2 rubygems/2.6.11 ruby/2.4.1 (x86_64-apple-darwin16.5.0) command/lock options/spec_run,plugins,trampoline_disable 7edfb7e0938d0c35
+> connection: keep-alive
+> keep-alive: 30
+> host: index.rubygems.org \ No newline at end of file
diff --git a/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/rspec-core/GET/response b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/rspec-core/GET/response
new file mode 100644
index 0000000000..e34e0f1740
--- /dev/null
+++ b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/rspec-core/GET/response
Binary files differ
diff --git a/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/rspec-expectations/GET/request b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/rspec-expectations/GET/request
new file mode 100644
index 0000000000..660b24d100
--- /dev/null
+++ b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/rspec-expectations/GET/request
@@ -0,0 +1,7 @@
+> GET /info/rspec-expectations
+> accept-encoding: gzip
+> accept: */*
+> user-agent: bundler/1.15.0.pre.2 rubygems/2.6.11 ruby/2.4.1 (x86_64-apple-darwin16.5.0) command/lock options/spec_run,plugins,trampoline_disable 7edfb7e0938d0c35
+> connection: keep-alive
+> keep-alive: 30
+> host: index.rubygems.org \ No newline at end of file
diff --git a/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/rspec-expectations/GET/response b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/rspec-expectations/GET/response
new file mode 100644
index 0000000000..a51f67f84a
--- /dev/null
+++ b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/rspec-expectations/GET/response
Binary files differ
diff --git a/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/rspec-logsplit/GET/request b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/rspec-logsplit/GET/request
new file mode 100644
index 0000000000..5ff447f187
--- /dev/null
+++ b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/rspec-logsplit/GET/request
@@ -0,0 +1,7 @@
+> GET /info/rspec-logsplit
+> accept-encoding: gzip
+> accept: */*
+> user-agent: bundler/1.15.0.pre.2 rubygems/2.6.11 ruby/2.4.1 (x86_64-apple-darwin16.5.0) command/lock options/spec_run,plugins,trampoline_disable 7edfb7e0938d0c35
+> connection: keep-alive
+> keep-alive: 30
+> host: index.rubygems.org \ No newline at end of file
diff --git a/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/rspec-logsplit/GET/response b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/rspec-logsplit/GET/response
new file mode 100644
index 0000000000..b0780175c6
--- /dev/null
+++ b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/rspec-logsplit/GET/response
Binary files differ
diff --git a/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/rspec-mocks/GET/request b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/rspec-mocks/GET/request
new file mode 100644
index 0000000000..0a961c6ffd
--- /dev/null
+++ b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/rspec-mocks/GET/request
@@ -0,0 +1,7 @@
+> GET /info/rspec-mocks
+> accept-encoding: gzip
+> accept: */*
+> user-agent: bundler/1.15.0.pre.2 rubygems/2.6.11 ruby/2.4.1 (x86_64-apple-darwin16.5.0) command/lock options/spec_run,plugins,trampoline_disable 7edfb7e0938d0c35
+> connection: keep-alive
+> keep-alive: 30
+> host: index.rubygems.org \ No newline at end of file
diff --git a/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/rspec-mocks/GET/response b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/rspec-mocks/GET/response
new file mode 100644
index 0000000000..b80ac128fe
--- /dev/null
+++ b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/rspec-mocks/GET/response
Binary files differ
diff --git a/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/rspec-support/GET/request b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/rspec-support/GET/request
new file mode 100644
index 0000000000..ab2d3175ec
--- /dev/null
+++ b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/rspec-support/GET/request
@@ -0,0 +1,7 @@
+> GET /info/rspec-support
+> accept-encoding: gzip
+> accept: */*
+> user-agent: bundler/1.15.0.pre.2 rubygems/2.6.11 ruby/2.4.1 (x86_64-apple-darwin16.5.0) command/lock options/spec_run,plugins,trampoline_disable 7edfb7e0938d0c35
+> connection: keep-alive
+> keep-alive: 30
+> host: index.rubygems.org \ No newline at end of file
diff --git a/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/rspec-support/GET/response b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/rspec-support/GET/response
new file mode 100644
index 0000000000..b5ac515f64
--- /dev/null
+++ b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/rspec-support/GET/response
Binary files differ
diff --git a/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/rspec/GET/request b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/rspec/GET/request
new file mode 100644
index 0000000000..3f327837cc
--- /dev/null
+++ b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/rspec/GET/request
@@ -0,0 +1,7 @@
+> GET /info/rspec
+> accept-encoding: gzip
+> accept: */*
+> user-agent: bundler/1.15.0.pre.2 rubygems/2.6.11 ruby/2.4.1 (x86_64-apple-darwin16.5.0) command/lock options/spec_run,plugins,trampoline_disable 7edfb7e0938d0c35
+> connection: keep-alive
+> keep-alive: 30
+> host: index.rubygems.org \ No newline at end of file
diff --git a/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/rspec/GET/response b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/rspec/GET/response
new file mode 100644
index 0000000000..15739a2536
--- /dev/null
+++ b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/rspec/GET/response
Binary files differ
diff --git a/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/rubigen/GET/request b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/rubigen/GET/request
new file mode 100644
index 0000000000..19c742edd3
--- /dev/null
+++ b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/rubigen/GET/request
@@ -0,0 +1,7 @@
+> GET /info/rubigen
+> accept-encoding: gzip
+> accept: */*
+> user-agent: bundler/1.15.0.pre.2 rubygems/2.6.11 ruby/2.4.1 (x86_64-apple-darwin16.5.0) command/install options/retry,path,disable_shared_gems,spec_run,plugins,trampoline_disable d59b382d069fc94f
+> connection: keep-alive
+> keep-alive: 30
+> host: index.rubygems.org \ No newline at end of file
diff --git a/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/rubigen/GET/response b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/rubigen/GET/response
new file mode 100644
index 0000000000..d891923d0f
--- /dev/null
+++ b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/rubigen/GET/response
Binary files differ
diff --git a/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/rubocop/GET/request b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/rubocop/GET/request
new file mode 100644
index 0000000000..49899f0274
--- /dev/null
+++ b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/rubocop/GET/request
@@ -0,0 +1,7 @@
+> GET /info/rubocop
+> accept-encoding: gzip
+> accept: */*
+> user-agent: bundler/1.15.0.pre.2 rubygems/2.6.11 ruby/2.4.1 (x86_64-apple-darwin16.5.0) command/lock options/spec_run,plugins,trampoline_disable 7edfb7e0938d0c35
+> connection: keep-alive
+> keep-alive: 30
+> host: index.rubygems.org \ No newline at end of file
diff --git a/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/rubocop/GET/response b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/rubocop/GET/response
new file mode 100644
index 0000000000..b04daa0835
--- /dev/null
+++ b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/rubocop/GET/response
Binary files differ
diff --git a/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/ruby-openid/GET/request b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/ruby-openid/GET/request
new file mode 100644
index 0000000000..83ae0d71e7
--- /dev/null
+++ b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/ruby-openid/GET/request
@@ -0,0 +1,7 @@
+> GET /info/ruby-openid
+> accept-encoding: gzip
+> accept: */*
+> user-agent: bundler/1.15.0.pre.2 rubygems/2.6.11 ruby/2.4.1 (x86_64-apple-darwin16.5.0) command/lock options/spec_run,plugins,trampoline_disable 7edfb7e0938d0c35
+> connection: keep-alive
+> keep-alive: 30
+> host: index.rubygems.org \ No newline at end of file
diff --git a/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/ruby-openid/GET/response b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/ruby-openid/GET/response
new file mode 100644
index 0000000000..52ed57c65f
--- /dev/null
+++ b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/ruby-openid/GET/response
Binary files differ
diff --git a/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/ruby-progressbar/GET/request b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/ruby-progressbar/GET/request
new file mode 100644
index 0000000000..85bcdde042
--- /dev/null
+++ b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/ruby-progressbar/GET/request
@@ -0,0 +1,7 @@
+> GET /info/ruby-progressbar
+> accept-encoding: gzip
+> accept: */*
+> user-agent: bundler/1.15.0.pre.2 rubygems/2.6.11 ruby/2.4.1 (x86_64-apple-darwin16.5.0) command/lock options/spec_run,plugins,trampoline_disable 7edfb7e0938d0c35
+> connection: keep-alive
+> keep-alive: 30
+> host: index.rubygems.org \ No newline at end of file
diff --git a/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/ruby-progressbar/GET/response b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/ruby-progressbar/GET/response
new file mode 100644
index 0000000000..17ac9088ac
--- /dev/null
+++ b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/ruby-progressbar/GET/response
Binary files differ
diff --git a/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/ruby-yadis/GET/request b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/ruby-yadis/GET/request
new file mode 100644
index 0000000000..e12117e5dc
--- /dev/null
+++ b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/ruby-yadis/GET/request
@@ -0,0 +1,7 @@
+> GET /info/ruby-yadis
+> accept-encoding: gzip
+> accept: */*
+> user-agent: bundler/1.15.0.pre.2 rubygems/2.6.11 ruby/2.4.1 (x86_64-apple-darwin16.5.0) command/lock options/spec_run,plugins,trampoline_disable 7edfb7e0938d0c35
+> connection: keep-alive
+> keep-alive: 30
+> host: index.rubygems.org \ No newline at end of file
diff --git a/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/ruby-yadis/GET/response b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/ruby-yadis/GET/response
new file mode 100644
index 0000000000..13432135e4
--- /dev/null
+++ b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/ruby-yadis/GET/response
Binary files differ
diff --git a/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/ruby_dep/GET/request b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/ruby_dep/GET/request
new file mode 100644
index 0000000000..43d58ead74
--- /dev/null
+++ b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/ruby_dep/GET/request
@@ -0,0 +1,7 @@
+> GET /info/ruby_dep
+> accept-encoding: gzip
+> accept: */*
+> user-agent: bundler/1.15.0.pre.2 rubygems/2.6.11 ruby/2.4.1 (x86_64-apple-darwin16.5.0) command/lock options/spec_run,plugins,trampoline_disable 53c83f3e5793993c
+> connection: keep-alive
+> keep-alive: 30
+> host: index.rubygems.org \ No newline at end of file
diff --git a/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/ruby_dep/GET/response b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/ruby_dep/GET/response
new file mode 100644
index 0000000000..cc0788c900
--- /dev/null
+++ b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/ruby_dep/GET/response
Binary files differ
diff --git a/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/ruby_parser/GET/request b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/ruby_parser/GET/request
new file mode 100644
index 0000000000..460ff43276
--- /dev/null
+++ b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/ruby_parser/GET/request
@@ -0,0 +1,7 @@
+> GET /info/ruby_parser
+> accept-encoding: gzip
+> accept: */*
+> user-agent: bundler/1.15.0.pre.2 rubygems/2.6.11 ruby/2.4.1 (x86_64-apple-darwin16.5.0) command/lock options/spec_run,plugins,trampoline_disable 7edfb7e0938d0c35
+> connection: keep-alive
+> keep-alive: 30
+> host: index.rubygems.org \ No newline at end of file
diff --git a/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/ruby_parser/GET/response b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/ruby_parser/GET/response
new file mode 100644
index 0000000000..63c6ef0386
--- /dev/null
+++ b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/ruby_parser/GET/response
Binary files differ
diff --git a/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/rubyforge/GET/request b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/rubyforge/GET/request
new file mode 100644
index 0000000000..92e612095d
--- /dev/null
+++ b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/rubyforge/GET/request
@@ -0,0 +1,7 @@
+> GET /info/rubyforge
+> accept-encoding: gzip
+> accept: */*
+> user-agent: bundler/1.15.0.pre.2 rubygems/2.6.11 ruby/2.4.1 (x86_64-apple-darwin16.5.0) command/lock options/spec_run,plugins,trampoline_disable 7edfb7e0938d0c35
+> connection: keep-alive
+> keep-alive: 30
+> host: index.rubygems.org \ No newline at end of file
diff --git a/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/rubyforge/GET/response b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/rubyforge/GET/response
new file mode 100644
index 0000000000..16d3d25a0e
--- /dev/null
+++ b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/rubyforge/GET/response
Binary files differ
diff --git a/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/rubyzip/GET/request b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/rubyzip/GET/request
new file mode 100644
index 0000000000..56ff5252ce
--- /dev/null
+++ b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/rubyzip/GET/request
@@ -0,0 +1,7 @@
+> GET /info/rubyzip
+> accept-encoding: gzip
+> accept: */*
+> user-agent: bundler/1.15.0.pre.2 rubygems/2.6.11 ruby/2.4.1 (x86_64-apple-darwin16.5.0) command/lock options/spec_run,plugins,trampoline_disable 7edfb7e0938d0c35
+> connection: keep-alive
+> keep-alive: 30
+> host: index.rubygems.org \ No newline at end of file
diff --git a/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/rubyzip/GET/response b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/rubyzip/GET/response
new file mode 100644
index 0000000000..073c6fc055
--- /dev/null
+++ b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/rubyzip/GET/response
Binary files differ
diff --git a/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/rufus-scheduler/GET/request b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/rufus-scheduler/GET/request
new file mode 100644
index 0000000000..9c499d7320
--- /dev/null
+++ b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/rufus-scheduler/GET/request
@@ -0,0 +1,7 @@
+> GET /info/rufus-scheduler
+> accept-encoding: gzip
+> accept: */*
+> user-agent: bundler/1.15.0.pre.2 rubygems/2.6.11 ruby/2.4.1 (x86_64-apple-darwin16.5.0) command/install options/retry,path,disable_shared_gems,spec_run,plugins,trampoline_disable d59b382d069fc94f
+> connection: keep-alive
+> keep-alive: 30
+> host: index.rubygems.org \ No newline at end of file
diff --git a/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/rufus-scheduler/GET/response b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/rufus-scheduler/GET/response
new file mode 100644
index 0000000000..812fe87e81
--- /dev/null
+++ b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/rufus-scheduler/GET/response
Binary files differ
diff --git a/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/sass-listen/GET/request b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/sass-listen/GET/request
new file mode 100644
index 0000000000..98051f0722
--- /dev/null
+++ b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/sass-listen/GET/request
@@ -0,0 +1,7 @@
+> GET /info/sass-listen
+> accept-encoding: gzip
+> accept: */*
+> user-agent: bundler/1.15.0.pre.2 rubygems/2.6.11 ruby/2.4.1 (x86_64-apple-darwin16.5.0) command/lock options/spec_run,plugins,trampoline_disable 53c83f3e5793993c
+> connection: keep-alive
+> keep-alive: 30
+> host: index.rubygems.org \ No newline at end of file
diff --git a/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/sass-listen/GET/response b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/sass-listen/GET/response
new file mode 100644
index 0000000000..8c9edc10b3
--- /dev/null
+++ b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/sass-listen/GET/response
Binary files differ
diff --git a/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/sass-rails/GET/request b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/sass-rails/GET/request
new file mode 100644
index 0000000000..ab996f5ead
--- /dev/null
+++ b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/sass-rails/GET/request
@@ -0,0 +1,7 @@
+> GET /info/sass-rails
+> accept-encoding: gzip
+> accept: */*
+> user-agent: bundler/1.15.0.pre.2 rubygems/2.6.11 ruby/2.4.1 (x86_64-apple-darwin16.5.0) command/lock options/spec_run,plugins,trampoline_disable 53c83f3e5793993c
+> connection: keep-alive
+> keep-alive: 30
+> host: index.rubygems.org \ No newline at end of file
diff --git a/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/sass-rails/GET/response b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/sass-rails/GET/response
new file mode 100644
index 0000000000..c4a9239718
--- /dev/null
+++ b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/sass-rails/GET/response
Binary files differ
diff --git a/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/sass/GET/request b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/sass/GET/request
new file mode 100644
index 0000000000..16f4a2d834
--- /dev/null
+++ b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/sass/GET/request
@@ -0,0 +1,7 @@
+> GET /info/sass
+> accept-encoding: gzip
+> accept: */*
+> user-agent: bundler/1.15.0.pre.2 rubygems/2.6.11 ruby/2.4.1 (x86_64-apple-darwin16.5.0) command/lock options/spec_run,plugins,trampoline_disable 53c83f3e5793993c
+> connection: keep-alive
+> keep-alive: 30
+> host: index.rubygems.org \ No newline at end of file
diff --git a/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/sass/GET/response b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/sass/GET/response
new file mode 100644
index 0000000000..313c6759ab
--- /dev/null
+++ b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/sass/GET/response
Binary files differ
diff --git a/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/selenium-webdriver/GET/request b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/selenium-webdriver/GET/request
new file mode 100644
index 0000000000..3128daa2f7
--- /dev/null
+++ b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/selenium-webdriver/GET/request
@@ -0,0 +1,7 @@
+> GET /info/selenium-webdriver
+> accept-encoding: gzip
+> accept: */*
+> user-agent: bundler/1.15.0.pre.2 rubygems/2.6.11 ruby/2.4.1 (x86_64-apple-darwin16.5.0) command/lock options/spec_run,plugins,trampoline_disable 7edfb7e0938d0c35
+> connection: keep-alive
+> keep-alive: 30
+> host: index.rubygems.org \ No newline at end of file
diff --git a/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/selenium-webdriver/GET/response b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/selenium-webdriver/GET/response
new file mode 100644
index 0000000000..5776c2ea14
--- /dev/null
+++ b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/selenium-webdriver/GET/response
Binary files differ
diff --git a/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/sexp_processor/GET/request b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/sexp_processor/GET/request
new file mode 100644
index 0000000000..e92bfe4e50
--- /dev/null
+++ b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/sexp_processor/GET/request
@@ -0,0 +1,7 @@
+> GET /info/sexp_processor
+> accept-encoding: gzip
+> accept: */*
+> user-agent: bundler/1.15.0.pre.2 rubygems/2.6.11 ruby/2.4.1 (x86_64-apple-darwin16.5.0) command/lock options/spec_run,plugins,trampoline_disable 7edfb7e0938d0c35
+> connection: keep-alive
+> keep-alive: 30
+> host: index.rubygems.org \ No newline at end of file
diff --git a/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/sexp_processor/GET/response b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/sexp_processor/GET/response
new file mode 100644
index 0000000000..d7ebe60e4b
--- /dev/null
+++ b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/sexp_processor/GET/response
Binary files differ
diff --git a/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/shotgun/GET/request b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/shotgun/GET/request
new file mode 100644
index 0000000000..9d6b958cc5
--- /dev/null
+++ b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/shotgun/GET/request
@@ -0,0 +1,7 @@
+> GET /info/shotgun
+> accept-encoding: gzip
+> accept: */*
+> user-agent: bundler/1.15.0.pre.2 rubygems/2.6.11 ruby/2.4.1 (x86_64-apple-darwin16.5.0) command/lock options/spec_run,plugins,trampoline_disable 53c83f3e5793993c
+> connection: keep-alive
+> keep-alive: 30
+> host: index.rubygems.org \ No newline at end of file
diff --git a/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/shotgun/GET/response b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/shotgun/GET/response
new file mode 100644
index 0000000000..5818a8035a
--- /dev/null
+++ b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/shotgun/GET/response
Binary files differ
diff --git a/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/signet/GET/request b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/signet/GET/request
new file mode 100644
index 0000000000..bd4257ed35
--- /dev/null
+++ b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/signet/GET/request
@@ -0,0 +1,7 @@
+> GET /info/signet
+> accept-encoding: gzip
+> accept: */*
+> user-agent: bundler/1.15.0.pre.2 rubygems/2.6.11 ruby/2.4.1 (x86_64-apple-darwin16.5.0) command/lock options/spec_run,plugins,trampoline_disable 53c83f3e5793993c
+> connection: keep-alive
+> keep-alive: 30
+> host: index.rubygems.org \ No newline at end of file
diff --git a/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/signet/GET/response b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/signet/GET/response
new file mode 100644
index 0000000000..8fc0070487
--- /dev/null
+++ b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/signet/GET/response
Binary files differ
diff --git a/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/simplecov-html/GET/request b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/simplecov-html/GET/request
new file mode 100644
index 0000000000..daf148a4f8
--- /dev/null
+++ b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/simplecov-html/GET/request
@@ -0,0 +1,7 @@
+> GET /info/simplecov-html
+> accept-encoding: gzip
+> accept: */*
+> user-agent: bundler/1.15.0.pre.2 rubygems/2.6.11 ruby/2.4.1 (x86_64-apple-darwin16.5.0) command/lock options/spec_run,plugins,trampoline_disable 7edfb7e0938d0c35
+> connection: keep-alive
+> keep-alive: 30
+> host: index.rubygems.org \ No newline at end of file
diff --git a/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/simplecov-html/GET/response b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/simplecov-html/GET/response
new file mode 100644
index 0000000000..6f69f67f0f
--- /dev/null
+++ b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/simplecov-html/GET/response
Binary files differ
diff --git a/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/simplecov/GET/request b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/simplecov/GET/request
new file mode 100644
index 0000000000..be9dec39be
--- /dev/null
+++ b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/simplecov/GET/request
@@ -0,0 +1,7 @@
+> GET /info/simplecov
+> accept-encoding: gzip
+> accept: */*
+> user-agent: bundler/1.15.0.pre.2 rubygems/2.6.11 ruby/2.4.1 (x86_64-apple-darwin16.5.0) command/lock options/spec_run,plugins,trampoline_disable 7edfb7e0938d0c35
+> connection: keep-alive
+> keep-alive: 30
+> host: index.rubygems.org \ No newline at end of file
diff --git a/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/simplecov/GET/response b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/simplecov/GET/response
new file mode 100644
index 0000000000..a3e776cc99
--- /dev/null
+++ b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/simplecov/GET/response
Binary files differ
diff --git a/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/sinatra/GET/request b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/sinatra/GET/request
new file mode 100644
index 0000000000..f442fa89f6
--- /dev/null
+++ b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/sinatra/GET/request
@@ -0,0 +1,7 @@
+> GET /info/sinatra
+> accept-encoding: gzip
+> accept: */*
+> user-agent: bundler/1.15.0.pre.2 rubygems/2.6.11 ruby/2.4.1 (x86_64-apple-darwin16.5.0) command/lock options/spec_run,plugins,trampoline_disable 53c83f3e5793993c
+> connection: keep-alive
+> keep-alive: 30
+> host: index.rubygems.org \ No newline at end of file
diff --git a/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/sinatra/GET/response b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/sinatra/GET/response
new file mode 100644
index 0000000000..75911724b2
--- /dev/null
+++ b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/sinatra/GET/response
Binary files differ
diff --git a/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/slop/GET/request b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/slop/GET/request
new file mode 100644
index 0000000000..f4a1685ba2
--- /dev/null
+++ b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/slop/GET/request
@@ -0,0 +1,7 @@
+> GET /info/slop
+> accept-encoding: gzip
+> accept: */*
+> user-agent: bundler/1.15.0.pre.2 rubygems/2.6.11 ruby/2.4.1 (x86_64-apple-darwin16.5.0) command/lock options/spec_run,plugins,trampoline_disable 7edfb7e0938d0c35
+> connection: keep-alive
+> keep-alive: 30
+> host: index.rubygems.org \ No newline at end of file
diff --git a/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/slop/GET/response b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/slop/GET/response
new file mode 100644
index 0000000000..4596867818
--- /dev/null
+++ b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/slop/GET/response
Binary files differ
diff --git a/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/spicycode-rcov/GET/request b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/spicycode-rcov/GET/request
new file mode 100644
index 0000000000..c9686cae49
--- /dev/null
+++ b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/spicycode-rcov/GET/request
@@ -0,0 +1,7 @@
+> GET /info/spicycode-rcov
+> accept-encoding: gzip
+> accept: */*
+> user-agent: bundler/1.15.0.pre.2 rubygems/2.6.11 ruby/2.4.1 (x86_64-apple-darwin16.5.0) command/lock options/spec_run,plugins,trampoline_disable 7edfb7e0938d0c35
+> connection: keep-alive
+> keep-alive: 30
+> host: index.rubygems.org \ No newline at end of file
diff --git a/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/spicycode-rcov/GET/response b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/spicycode-rcov/GET/response
new file mode 100644
index 0000000000..02f19182ab
--- /dev/null
+++ b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/spicycode-rcov/GET/response
Binary files differ
diff --git a/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/spoon/GET/request b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/spoon/GET/request
new file mode 100644
index 0000000000..d1f41c369a
--- /dev/null
+++ b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/spoon/GET/request
@@ -0,0 +1,7 @@
+> GET /info/spoon
+> accept-encoding: gzip
+> accept: */*
+> user-agent: bundler/1.15.0.pre.2 rubygems/2.6.11 ruby/2.4.1 (x86_64-apple-darwin16.5.0) command/lock options/spec_run,plugins,trampoline_disable 7edfb7e0938d0c35
+> connection: keep-alive
+> keep-alive: 30
+> host: index.rubygems.org \ No newline at end of file
diff --git a/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/spoon/GET/response b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/spoon/GET/response
new file mode 100644
index 0000000000..1f3ef61f03
--- /dev/null
+++ b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/spoon/GET/response
Binary files differ
diff --git a/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/sprockets-rails/GET/request b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/sprockets-rails/GET/request
new file mode 100644
index 0000000000..7b7ba15490
--- /dev/null
+++ b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/sprockets-rails/GET/request
@@ -0,0 +1,7 @@
+> GET /info/sprockets-rails
+> accept-encoding: gzip
+> accept: */*
+> user-agent: bundler/1.15.0.pre.2 rubygems/2.6.11 ruby/2.4.1 (x86_64-apple-darwin16.5.0) command/lock options/spec_run,plugins,trampoline_disable 7edfb7e0938d0c35
+> connection: keep-alive
+> keep-alive: 30
+> host: index.rubygems.org \ No newline at end of file
diff --git a/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/sprockets-rails/GET/response b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/sprockets-rails/GET/response
new file mode 100644
index 0000000000..7e3e31b886
--- /dev/null
+++ b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/sprockets-rails/GET/response
Binary files differ
diff --git a/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/sprockets/GET/request b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/sprockets/GET/request
new file mode 100644
index 0000000000..06767f04a6
--- /dev/null
+++ b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/sprockets/GET/request
@@ -0,0 +1,7 @@
+> GET /info/sprockets
+> accept-encoding: gzip
+> accept: */*
+> user-agent: bundler/1.15.0.pre.2 rubygems/2.6.11 ruby/2.4.1 (x86_64-apple-darwin16.5.0) command/lock options/spec_run,plugins,trampoline_disable 7edfb7e0938d0c35
+> connection: keep-alive
+> keep-alive: 30
+> host: index.rubygems.org \ No newline at end of file
diff --git a/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/sprockets/GET/response b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/sprockets/GET/response
new file mode 100644
index 0000000000..e4bc7d20e3
--- /dev/null
+++ b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/sprockets/GET/response
Binary files differ
diff --git a/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/spruz/GET/request b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/spruz/GET/request
new file mode 100644
index 0000000000..a9995940f5
--- /dev/null
+++ b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/spruz/GET/request
@@ -0,0 +1,7 @@
+> GET /info/spruz
+> accept-encoding: gzip
+> accept: */*
+> user-agent: bundler/1.15.0.pre.2 rubygems/2.6.11 ruby/2.4.1 (x86_64-apple-darwin16.5.0) command/lock options/spec_run,plugins,trampoline_disable 7edfb7e0938d0c35
+> connection: keep-alive
+> keep-alive: 30
+> host: index.rubygems.org \ No newline at end of file
diff --git a/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/spruz/GET/response b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/spruz/GET/response
new file mode 100644
index 0000000000..3bf25600b0
--- /dev/null
+++ b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/spruz/GET/response
Binary files differ
diff --git a/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/sqlite3/GET/request b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/sqlite3/GET/request
new file mode 100644
index 0000000000..39542c09e8
--- /dev/null
+++ b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/sqlite3/GET/request
@@ -0,0 +1,7 @@
+> GET /info/sqlite3
+> accept-encoding: gzip
+> accept: */*
+> user-agent: bundler/1.15.0.pre.2 rubygems/2.6.11 ruby/2.4.1 (x86_64-apple-darwin16.5.0) command/lock options/spec_run,plugins,trampoline_disable 7edfb7e0938d0c35
+> connection: keep-alive
+> keep-alive: 30
+> host: index.rubygems.org \ No newline at end of file
diff --git a/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/sqlite3/GET/response b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/sqlite3/GET/response
new file mode 100644
index 0000000000..efc03a2679
--- /dev/null
+++ b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/sqlite3/GET/response
Binary files differ
diff --git a/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/syntax/GET/request b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/syntax/GET/request
new file mode 100644
index 0000000000..462e2bd29b
--- /dev/null
+++ b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/syntax/GET/request
@@ -0,0 +1,7 @@
+> GET /info/syntax
+> accept-encoding: gzip
+> accept: */*
+> user-agent: bundler/1.15.0.pre.2 rubygems/2.6.11 ruby/2.4.1 (x86_64-apple-darwin16.5.0) command/lock options/spec_run,plugins,trampoline_disable 7edfb7e0938d0c35
+> connection: keep-alive
+> keep-alive: 30
+> host: index.rubygems.org \ No newline at end of file
diff --git a/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/syntax/GET/response b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/syntax/GET/response
new file mode 100644
index 0000000000..afa8ce7387
--- /dev/null
+++ b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/syntax/GET/response
Binary files differ
diff --git a/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/sys-admin/GET/request b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/sys-admin/GET/request
new file mode 100644
index 0000000000..4ce082dcaa
--- /dev/null
+++ b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/sys-admin/GET/request
@@ -0,0 +1,7 @@
+> GET /info/sys-admin
+> accept-encoding: gzip
+> accept: */*
+> user-agent: bundler/1.15.0.pre.2 rubygems/2.6.11 ruby/2.4.1 (x86_64-apple-darwin16.5.0) command/lock options/spec_run,plugins,trampoline_disable 7edfb7e0938d0c35
+> connection: keep-alive
+> keep-alive: 30
+> host: index.rubygems.org \ No newline at end of file
diff --git a/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/sys-admin/GET/response b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/sys-admin/GET/response
new file mode 100644
index 0000000000..249397108b
--- /dev/null
+++ b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/sys-admin/GET/response
Binary files differ
diff --git a/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/tenderlove-frex/GET/request b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/tenderlove-frex/GET/request
new file mode 100644
index 0000000000..39f37ebdf3
--- /dev/null
+++ b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/tenderlove-frex/GET/request
@@ -0,0 +1,7 @@
+> GET /info/tenderlove-frex
+> accept-encoding: gzip
+> accept: */*
+> user-agent: bundler/1.15.0.pre.2 rubygems/2.6.11 ruby/2.4.1 (x86_64-apple-darwin16.5.0) command/lock options/spec_run,plugins,trampoline_disable 7edfb7e0938d0c35
+> connection: keep-alive
+> keep-alive: 30
+> host: index.rubygems.org \ No newline at end of file
diff --git a/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/tenderlove-frex/GET/response b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/tenderlove-frex/GET/response
new file mode 100644
index 0000000000..53e2fb263e
--- /dev/null
+++ b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/tenderlove-frex/GET/response
Binary files differ
diff --git a/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/term-ansicolor/GET/request b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/term-ansicolor/GET/request
new file mode 100644
index 0000000000..23c9c82fcf
--- /dev/null
+++ b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/term-ansicolor/GET/request
@@ -0,0 +1,7 @@
+> GET /info/term-ansicolor
+> accept-encoding: gzip
+> accept: */*
+> user-agent: bundler/1.15.0.pre.2 rubygems/2.6.11 ruby/2.4.1 (x86_64-apple-darwin16.5.0) command/lock options/spec_run,plugins,trampoline_disable 7edfb7e0938d0c35
+> connection: keep-alive
+> keep-alive: 30
+> host: index.rubygems.org \ No newline at end of file
diff --git a/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/term-ansicolor/GET/response b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/term-ansicolor/GET/response
new file mode 100644
index 0000000000..9baf5c0838
--- /dev/null
+++ b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/term-ansicolor/GET/response
Binary files differ
diff --git a/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/termios/GET/request b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/termios/GET/request
new file mode 100644
index 0000000000..17087a36e1
--- /dev/null
+++ b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/termios/GET/request
@@ -0,0 +1,7 @@
+> GET /info/termios
+> accept-encoding: gzip
+> accept: */*
+> user-agent: bundler/1.15.0.pre.2 rubygems/2.6.11 ruby/2.4.1 (x86_64-apple-darwin16.5.0) command/lock options/spec_run,plugins,trampoline_disable 7edfb7e0938d0c35
+> connection: keep-alive
+> keep-alive: 30
+> host: index.rubygems.org \ No newline at end of file
diff --git a/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/termios/GET/response b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/termios/GET/response
new file mode 100644
index 0000000000..ed5ff907da
--- /dev/null
+++ b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/termios/GET/response
Binary files differ
diff --git a/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/test-spec/GET/request b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/test-spec/GET/request
new file mode 100644
index 0000000000..1d2d581583
--- /dev/null
+++ b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/test-spec/GET/request
@@ -0,0 +1,7 @@
+> GET /info/test-spec
+> accept-encoding: gzip
+> accept: */*
+> user-agent: bundler/1.15.0.pre.2 rubygems/2.6.11 ruby/2.4.1 (x86_64-apple-darwin16.5.0) command/lock options/spec_run,plugins,trampoline_disable 7edfb7e0938d0c35
+> connection: keep-alive
+> keep-alive: 30
+> host: index.rubygems.org \ No newline at end of file
diff --git a/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/test-spec/GET/response b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/test-spec/GET/response
new file mode 100644
index 0000000000..4c95e0f607
--- /dev/null
+++ b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/test-spec/GET/response
Binary files differ
diff --git a/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/test-unit/GET/request b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/test-unit/GET/request
new file mode 100644
index 0000000000..92b85c1751
--- /dev/null
+++ b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/test-unit/GET/request
@@ -0,0 +1,7 @@
+> GET /info/test-unit
+> accept-encoding: gzip
+> accept: */*
+> user-agent: bundler/1.15.0.pre.2 rubygems/2.6.11 ruby/2.4.1 (x86_64-apple-darwin16.5.0) command/lock options/spec_run,plugins,trampoline_disable 7edfb7e0938d0c35
+> connection: keep-alive
+> keep-alive: 30
+> host: index.rubygems.org \ No newline at end of file
diff --git a/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/test-unit/GET/response b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/test-unit/GET/response
new file mode 100644
index 0000000000..bb27d58d78
--- /dev/null
+++ b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/test-unit/GET/response
Binary files differ
diff --git a/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/text-format/GET/request b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/text-format/GET/request
new file mode 100644
index 0000000000..3a8cbe23e1
--- /dev/null
+++ b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/text-format/GET/request
@@ -0,0 +1,7 @@
+> GET /info/text-format
+> accept-encoding: gzip
+> accept: */*
+> user-agent: bundler/1.15.0.pre.2 rubygems/2.6.11 ruby/2.4.1 (x86_64-apple-darwin16.5.0) command/lock options/spec_run,plugins,trampoline_disable 7edfb7e0938d0c35
+> connection: keep-alive
+> keep-alive: 30
+> host: index.rubygems.org \ No newline at end of file
diff --git a/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/text-format/GET/response b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/text-format/GET/response
new file mode 100644
index 0000000000..f1c0e296e5
--- /dev/null
+++ b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/text-format/GET/response
Binary files differ
diff --git a/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/text-hyphen/GET/request b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/text-hyphen/GET/request
new file mode 100644
index 0000000000..5aa85a177c
--- /dev/null
+++ b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/text-hyphen/GET/request
@@ -0,0 +1,7 @@
+> GET /info/text-hyphen
+> accept-encoding: gzip
+> accept: */*
+> user-agent: bundler/1.15.0.pre.2 rubygems/2.6.11 ruby/2.4.1 (x86_64-apple-darwin16.5.0) command/lock options/spec_run,plugins,trampoline_disable 7edfb7e0938d0c35
+> connection: keep-alive
+> keep-alive: 30
+> host: index.rubygems.org \ No newline at end of file
diff --git a/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/text-hyphen/GET/response b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/text-hyphen/GET/response
new file mode 100644
index 0000000000..415db7ffb8
--- /dev/null
+++ b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/text-hyphen/GET/response
Binary files differ
diff --git a/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/thin/GET/request b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/thin/GET/request
new file mode 100644
index 0000000000..ce6a7c8e8e
--- /dev/null
+++ b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/thin/GET/request
@@ -0,0 +1,7 @@
+> GET /info/thin
+> accept-encoding: gzip
+> accept: */*
+> user-agent: bundler/1.15.0.pre.2 rubygems/2.6.11 ruby/2.4.1 (x86_64-apple-darwin16.5.0) command/lock options/spec_run,plugins,trampoline_disable 7edfb7e0938d0c35
+> connection: keep-alive
+> keep-alive: 30
+> host: index.rubygems.org \ No newline at end of file
diff --git a/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/thin/GET/response b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/thin/GET/response
new file mode 100644
index 0000000000..2816f819c1
--- /dev/null
+++ b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/thin/GET/response
Binary files differ
diff --git a/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/thor/GET/request b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/thor/GET/request
new file mode 100644
index 0000000000..413597fd9d
--- /dev/null
+++ b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/thor/GET/request
@@ -0,0 +1,7 @@
+> GET /info/thor
+> accept-encoding: gzip
+> accept: */*
+> user-agent: bundler/1.15.0.pre.2 rubygems/2.6.11 ruby/2.4.1 (x86_64-apple-darwin16.5.0) command/lock options/spec_run,plugins,trampoline_disable 7edfb7e0938d0c35
+> connection: keep-alive
+> keep-alive: 30
+> host: index.rubygems.org \ No newline at end of file
diff --git a/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/thor/GET/response b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/thor/GET/response
new file mode 100644
index 0000000000..e7ffff2c35
--- /dev/null
+++ b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/thor/GET/response
Binary files differ
diff --git a/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/thoughtbot-shoulda/GET/request b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/thoughtbot-shoulda/GET/request
new file mode 100644
index 0000000000..b420081022
--- /dev/null
+++ b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/thoughtbot-shoulda/GET/request
@@ -0,0 +1,7 @@
+> GET /info/thoughtbot-shoulda
+> accept-encoding: gzip
+> accept: */*
+> user-agent: bundler/1.15.0.pre.2 rubygems/2.6.11 ruby/2.4.1 (x86_64-apple-darwin16.5.0) command/lock options/spec_run,plugins,trampoline_disable 6d5397ce7f8b26e0
+> connection: keep-alive
+> keep-alive: 30
+> host: index.rubygems.org \ No newline at end of file
diff --git a/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/thoughtbot-shoulda/GET/response b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/thoughtbot-shoulda/GET/response
new file mode 100644
index 0000000000..f9e7a1a93d
--- /dev/null
+++ b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/thoughtbot-shoulda/GET/response
Binary files differ
diff --git a/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/thread_safe/GET/request b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/thread_safe/GET/request
new file mode 100644
index 0000000000..f5f0fffab3
--- /dev/null
+++ b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/thread_safe/GET/request
@@ -0,0 +1,7 @@
+> GET /info/thread_safe
+> accept-encoding: gzip
+> accept: */*
+> user-agent: bundler/1.15.0.pre.2 rubygems/2.6.11 ruby/2.4.1 (x86_64-apple-darwin16.5.0) command/lock options/spec_run,plugins,trampoline_disable 7edfb7e0938d0c35
+> connection: keep-alive
+> keep-alive: 30
+> host: index.rubygems.org \ No newline at end of file
diff --git a/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/thread_safe/GET/response b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/thread_safe/GET/response
new file mode 100644
index 0000000000..aea7453992
--- /dev/null
+++ b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/thread_safe/GET/response
Binary files differ
diff --git a/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/tilt/GET/request b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/tilt/GET/request
new file mode 100644
index 0000000000..039aa0341f
--- /dev/null
+++ b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/tilt/GET/request
@@ -0,0 +1,7 @@
+> GET /info/tilt
+> accept-encoding: gzip
+> accept: */*
+> user-agent: bundler/1.15.0.pre.2 rubygems/2.6.11 ruby/2.4.1 (x86_64-apple-darwin16.5.0) command/lock options/spec_run,plugins,trampoline_disable 7edfb7e0938d0c35
+> connection: keep-alive
+> keep-alive: 30
+> host: index.rubygems.org \ No newline at end of file
diff --git a/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/tilt/GET/response b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/tilt/GET/response
new file mode 100644
index 0000000000..2345ec0b21
--- /dev/null
+++ b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/tilt/GET/response
Binary files differ
diff --git a/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/timers/GET/request b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/timers/GET/request
new file mode 100644
index 0000000000..2fc37f3a88
--- /dev/null
+++ b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/timers/GET/request
@@ -0,0 +1,7 @@
+> GET /info/timers
+> accept-encoding: gzip
+> accept: */*
+> user-agent: bundler/1.15.0.pre.2 rubygems/2.6.11 ruby/2.4.1 (x86_64-apple-darwin16.5.0) command/lock options/spec_run,plugins,trampoline_disable 7edfb7e0938d0c35
+> connection: keep-alive
+> keep-alive: 30
+> host: index.rubygems.org \ No newline at end of file
diff --git a/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/timers/GET/response b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/timers/GET/response
new file mode 100644
index 0000000000..e86a9276f5
--- /dev/null
+++ b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/timers/GET/response
Binary files differ
diff --git a/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/tins/GET/request b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/tins/GET/request
new file mode 100644
index 0000000000..be1d206beb
--- /dev/null
+++ b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/tins/GET/request
@@ -0,0 +1,7 @@
+> GET /info/tins
+> accept-encoding: gzip
+> accept: */*
+> user-agent: bundler/1.15.0.pre.2 rubygems/2.6.11 ruby/2.4.1 (x86_64-apple-darwin16.5.0) command/lock options/spec_run,plugins,trampoline_disable 7edfb7e0938d0c35
+> connection: keep-alive
+> keep-alive: 30
+> host: index.rubygems.org \ No newline at end of file
diff --git a/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/tins/GET/response b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/tins/GET/response
new file mode 100644
index 0000000000..b115ddbd57
--- /dev/null
+++ b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/tins/GET/response
Binary files differ
diff --git a/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/tlsmail/GET/request b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/tlsmail/GET/request
new file mode 100644
index 0000000000..56ebce0f3f
--- /dev/null
+++ b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/tlsmail/GET/request
@@ -0,0 +1,7 @@
+> GET /info/tlsmail
+> accept-encoding: gzip
+> accept: */*
+> user-agent: bundler/1.15.0.pre.2 rubygems/2.6.11 ruby/2.4.1 (x86_64-apple-darwin16.5.0) command/lock options/spec_run,plugins,trampoline_disable 7edfb7e0938d0c35
+> connection: keep-alive
+> keep-alive: 30
+> host: index.rubygems.org \ No newline at end of file
diff --git a/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/tlsmail/GET/response b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/tlsmail/GET/response
new file mode 100644
index 0000000000..ecd321ccbc
--- /dev/null
+++ b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/tlsmail/GET/response
Binary files differ
diff --git a/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/tool/GET/request b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/tool/GET/request
new file mode 100644
index 0000000000..a8492ade82
--- /dev/null
+++ b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/tool/GET/request
@@ -0,0 +1,7 @@
+> GET /info/tool
+> accept-encoding: gzip
+> accept: */*
+> user-agent: bundler/1.15.0.pre.2 rubygems/2.6.11 ruby/2.4.1 (x86_64-apple-darwin16.5.0) command/lock options/spec_run,plugins,trampoline_disable 53c83f3e5793993c
+> connection: keep-alive
+> keep-alive: 30
+> host: index.rubygems.org \ No newline at end of file
diff --git a/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/tool/GET/response b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/tool/GET/response
new file mode 100644
index 0000000000..634d8a43da
--- /dev/null
+++ b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/tool/GET/response
Binary files differ
diff --git a/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/treetop/GET/request b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/treetop/GET/request
new file mode 100644
index 0000000000..52f2db382f
--- /dev/null
+++ b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/treetop/GET/request
@@ -0,0 +1,7 @@
+> GET /info/treetop
+> accept-encoding: gzip
+> accept: */*
+> user-agent: bundler/1.15.0.pre.2 rubygems/2.6.11 ruby/2.4.1 (x86_64-apple-darwin16.5.0) command/lock options/spec_run,plugins,trampoline_disable 7edfb7e0938d0c35
+> connection: keep-alive
+> keep-alive: 30
+> host: index.rubygems.org \ No newline at end of file
diff --git a/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/treetop/GET/response b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/treetop/GET/response
new file mode 100644
index 0000000000..7c41530d1c
--- /dev/null
+++ b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/treetop/GET/response
Binary files differ
diff --git a/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/trollop/GET/request b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/trollop/GET/request
new file mode 100644
index 0000000000..224cab6988
--- /dev/null
+++ b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/trollop/GET/request
@@ -0,0 +1,7 @@
+> GET /info/trollop
+> accept-encoding: gzip
+> accept: */*
+> user-agent: bundler/1.15.0.pre.2 rubygems/2.6.11 ruby/2.4.1 (x86_64-apple-darwin16.5.0) command/lock options/spec_run,plugins,trampoline_disable 7edfb7e0938d0c35
+> connection: keep-alive
+> keep-alive: 30
+> host: index.rubygems.org \ No newline at end of file
diff --git a/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/trollop/GET/response b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/trollop/GET/response
new file mode 100644
index 0000000000..0b27048b76
--- /dev/null
+++ b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/trollop/GET/response
Binary files differ
diff --git a/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/tzinfo/GET/request b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/tzinfo/GET/request
new file mode 100644
index 0000000000..0175216dd1
--- /dev/null
+++ b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/tzinfo/GET/request
@@ -0,0 +1,7 @@
+> GET /info/tzinfo
+> accept-encoding: gzip
+> accept: */*
+> user-agent: bundler/1.15.0.pre.2 rubygems/2.6.11 ruby/2.4.1 (x86_64-apple-darwin16.5.0) command/lock options/spec_run,plugins,trampoline_disable 7edfb7e0938d0c35
+> connection: keep-alive
+> keep-alive: 30
+> host: index.rubygems.org \ No newline at end of file
diff --git a/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/tzinfo/GET/response b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/tzinfo/GET/response
new file mode 100644
index 0000000000..53f6c4697b
--- /dev/null
+++ b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/tzinfo/GET/response
Binary files differ
diff --git a/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/uber/GET/request b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/uber/GET/request
new file mode 100644
index 0000000000..9fe5b0c30a
--- /dev/null
+++ b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/uber/GET/request
@@ -0,0 +1,7 @@
+> GET /info/uber
+> accept-encoding: gzip
+> accept: */*
+> user-agent: bundler/1.15.0.pre.2 rubygems/2.6.11 ruby/2.4.1 (x86_64-apple-darwin16.5.0) command/lock options/spec_run,plugins,trampoline_disable 53c83f3e5793993c
+> connection: keep-alive
+> keep-alive: 30
+> host: index.rubygems.org \ No newline at end of file
diff --git a/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/uber/GET/response b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/uber/GET/response
new file mode 100644
index 0000000000..eba3bd402e
--- /dev/null
+++ b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/uber/GET/response
Binary files differ
diff --git a/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/unf/GET/request b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/unf/GET/request
new file mode 100644
index 0000000000..f67c99558f
--- /dev/null
+++ b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/unf/GET/request
@@ -0,0 +1,7 @@
+> GET /info/unf
+> accept-encoding: gzip
+> accept: */*
+> user-agent: bundler/1.15.0.pre.2 rubygems/2.6.11 ruby/2.4.1 (x86_64-apple-darwin16.5.0) command/lock options/spec_run,plugins,trampoline_disable 7edfb7e0938d0c35
+> connection: keep-alive
+> keep-alive: 30
+> host: index.rubygems.org \ No newline at end of file
diff --git a/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/unf/GET/response b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/unf/GET/response
new file mode 100644
index 0000000000..ffc37964aa
--- /dev/null
+++ b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/unf/GET/response
Binary files differ
diff --git a/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/unf_ext/GET/request b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/unf_ext/GET/request
new file mode 100644
index 0000000000..77598fe741
--- /dev/null
+++ b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/unf_ext/GET/request
@@ -0,0 +1,7 @@
+> GET /info/unf_ext
+> accept-encoding: gzip
+> accept: */*
+> user-agent: bundler/1.15.0.pre.2 rubygems/2.6.11 ruby/2.4.1 (x86_64-apple-darwin16.5.0) command/lock options/spec_run,plugins,trampoline_disable 7edfb7e0938d0c35
+> connection: keep-alive
+> keep-alive: 30
+> host: index.rubygems.org \ No newline at end of file
diff --git a/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/unf_ext/GET/response b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/unf_ext/GET/response
new file mode 100644
index 0000000000..df21493ce7
--- /dev/null
+++ b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/unf_ext/GET/response
Binary files differ
diff --git a/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/unicode-display_width/GET/request b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/unicode-display_width/GET/request
new file mode 100644
index 0000000000..9d4f27056b
--- /dev/null
+++ b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/unicode-display_width/GET/request
@@ -0,0 +1,7 @@
+> GET /info/unicode-display_width
+> accept-encoding: gzip
+> accept: */*
+> user-agent: bundler/1.15.0.pre.2 rubygems/2.6.11 ruby/2.4.1 (x86_64-apple-darwin16.5.0) command/lock options/spec_run,plugins,trampoline_disable 7edfb7e0938d0c35
+> connection: keep-alive
+> keep-alive: 30
+> host: index.rubygems.org \ No newline at end of file
diff --git a/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/unicode-display_width/GET/response b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/unicode-display_width/GET/response
new file mode 100644
index 0000000000..4c6e844651
--- /dev/null
+++ b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/unicode-display_width/GET/response
Binary files differ
diff --git a/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/uuidtools/GET/request b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/uuidtools/GET/request
new file mode 100644
index 0000000000..5daed37793
--- /dev/null
+++ b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/uuidtools/GET/request
@@ -0,0 +1,7 @@
+> GET /info/uuidtools
+> accept-encoding: gzip
+> accept: */*
+> user-agent: bundler/1.15.0.pre.2 rubygems/2.6.11 ruby/2.4.1 (x86_64-apple-darwin16.5.0) command/lock options/spec_run,plugins,trampoline_disable 53c83f3e5793993c
+> connection: keep-alive
+> keep-alive: 30
+> host: index.rubygems.org \ No newline at end of file
diff --git a/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/uuidtools/GET/response b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/uuidtools/GET/response
new file mode 100644
index 0000000000..dce91487b9
--- /dev/null
+++ b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/uuidtools/GET/response
Binary files differ
diff --git a/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/vegas/GET/request b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/vegas/GET/request
new file mode 100644
index 0000000000..f22bf57945
--- /dev/null
+++ b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/vegas/GET/request
@@ -0,0 +1,7 @@
+> GET /info/vegas
+> accept-encoding: gzip
+> accept: */*
+> user-agent: bundler/1.15.0.pre.2 rubygems/2.6.11 ruby/2.4.1 (x86_64-apple-darwin16.5.0) command/install options/retry,path,disable_shared_gems,spec_run,plugins,trampoline_disable d59b382d069fc94f
+> connection: keep-alive
+> keep-alive: 30
+> host: index.rubygems.org \ No newline at end of file
diff --git a/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/vegas/GET/response b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/vegas/GET/response
new file mode 100644
index 0000000000..c927a24960
--- /dev/null
+++ b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/vegas/GET/response
Binary files differ
diff --git a/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/virtus/GET/request b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/virtus/GET/request
new file mode 100644
index 0000000000..858ceea38d
--- /dev/null
+++ b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/virtus/GET/request
@@ -0,0 +1,7 @@
+> GET /info/virtus
+> accept-encoding: gzip
+> accept: */*
+> user-agent: bundler/1.15.0.pre.2 rubygems/2.6.11 ruby/2.4.1 (x86_64-apple-darwin16.5.0) command/lock options/spec_run,plugins,trampoline_disable 53c83f3e5793993c
+> connection: keep-alive
+> keep-alive: 30
+> host: index.rubygems.org \ No newline at end of file
diff --git a/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/virtus/GET/response b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/virtus/GET/response
new file mode 100644
index 0000000000..5f4a979efb
--- /dev/null
+++ b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/virtus/GET/response
Binary files differ
diff --git a/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/weakling/GET/request b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/weakling/GET/request
new file mode 100644
index 0000000000..f6a7eb9098
--- /dev/null
+++ b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/weakling/GET/request
@@ -0,0 +1,7 @@
+> GET /info/weakling
+> accept-encoding: gzip
+> accept: */*
+> user-agent: bundler/1.15.0.pre.2 rubygems/2.6.11 ruby/2.4.1 (x86_64-apple-darwin16.5.0) command/lock options/spec_run,plugins,trampoline_disable 7edfb7e0938d0c35
+> connection: keep-alive
+> keep-alive: 30
+> host: index.rubygems.org \ No newline at end of file
diff --git a/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/weakling/GET/response b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/weakling/GET/response
new file mode 100644
index 0000000000..6bb2bd7f81
--- /dev/null
+++ b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/weakling/GET/response
Binary files differ
diff --git a/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/websocket-driver/GET/request b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/websocket-driver/GET/request
new file mode 100644
index 0000000000..06463439e0
--- /dev/null
+++ b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/websocket-driver/GET/request
@@ -0,0 +1,7 @@
+> GET /info/websocket-driver
+> accept-encoding: gzip
+> accept: */*
+> user-agent: bundler/1.15.0.pre.2 rubygems/2.6.11 ruby/2.4.1 (x86_64-apple-darwin16.5.0) command/lock options/spec_run,plugins,trampoline_disable 7edfb7e0938d0c35
+> connection: keep-alive
+> keep-alive: 30
+> host: index.rubygems.org \ No newline at end of file
diff --git a/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/websocket-driver/GET/response b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/websocket-driver/GET/response
new file mode 100644
index 0000000000..3e008063cf
--- /dev/null
+++ b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/websocket-driver/GET/response
Binary files differ
diff --git a/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/websocket-extensions/GET/request b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/websocket-extensions/GET/request
new file mode 100644
index 0000000000..4757f24824
--- /dev/null
+++ b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/websocket-extensions/GET/request
@@ -0,0 +1,7 @@
+> GET /info/websocket-extensions
+> accept-encoding: gzip
+> accept: */*
+> user-agent: bundler/1.15.0.pre.2 rubygems/2.6.11 ruby/2.4.1 (x86_64-apple-darwin16.5.0) command/lock options/spec_run,plugins,trampoline_disable 7edfb7e0938d0c35
+> connection: keep-alive
+> keep-alive: 30
+> host: index.rubygems.org \ No newline at end of file
diff --git a/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/websocket-extensions/GET/response b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/websocket-extensions/GET/response
new file mode 100644
index 0000000000..82d7d627ef
--- /dev/null
+++ b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/websocket-extensions/GET/response
Binary files differ
diff --git a/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/websocket/GET/request b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/websocket/GET/request
new file mode 100644
index 0000000000..45eaa04e55
--- /dev/null
+++ b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/websocket/GET/request
@@ -0,0 +1,7 @@
+> GET /info/websocket
+> accept-encoding: gzip
+> accept: */*
+> user-agent: bundler/1.15.0.pre.2 rubygems/2.6.11 ruby/2.4.1 (x86_64-apple-darwin16.5.0) command/lock options/spec_run,plugins,trampoline_disable 7edfb7e0938d0c35
+> connection: keep-alive
+> keep-alive: 30
+> host: index.rubygems.org \ No newline at end of file
diff --git a/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/websocket/GET/response b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/websocket/GET/response
new file mode 100644
index 0000000000..12f2851eb4
--- /dev/null
+++ b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/websocket/GET/response
Binary files differ
diff --git a/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/win32-api/GET/request b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/win32-api/GET/request
new file mode 100644
index 0000000000..9d47c2709b
--- /dev/null
+++ b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/win32-api/GET/request
@@ -0,0 +1,7 @@
+> GET /info/win32-api
+> accept-encoding: gzip
+> accept: */*
+> user-agent: bundler/1.15.0.pre.2 rubygems/2.6.11 ruby/2.4.1 (x86_64-apple-darwin16.5.0) command/lock options/spec_run,plugins,trampoline_disable 7edfb7e0938d0c35
+> connection: keep-alive
+> keep-alive: 30
+> host: index.rubygems.org \ No newline at end of file
diff --git a/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/win32-api/GET/response b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/win32-api/GET/response
new file mode 100644
index 0000000000..0949fa6bd6
--- /dev/null
+++ b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/win32-api/GET/response
Binary files differ
diff --git a/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/win32-dir/GET/request b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/win32-dir/GET/request
new file mode 100644
index 0000000000..6a11013349
--- /dev/null
+++ b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/win32-dir/GET/request
@@ -0,0 +1,7 @@
+> GET /info/win32-dir
+> accept-encoding: gzip
+> accept: */*
+> user-agent: bundler/1.15.0.pre.2 rubygems/2.6.11 ruby/2.4.1 (x86_64-apple-darwin16.5.0) command/lock options/spec_run,plugins,trampoline_disable 7edfb7e0938d0c35
+> connection: keep-alive
+> keep-alive: 30
+> host: index.rubygems.org \ No newline at end of file
diff --git a/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/win32-dir/GET/response b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/win32-dir/GET/response
new file mode 100644
index 0000000000..e3ef8912a4
--- /dev/null
+++ b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/win32-dir/GET/response
Binary files differ
diff --git a/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/win32-security/GET/request b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/win32-security/GET/request
new file mode 100644
index 0000000000..d89f956691
--- /dev/null
+++ b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/win32-security/GET/request
@@ -0,0 +1,7 @@
+> GET /info/win32-security
+> accept-encoding: gzip
+> accept: */*
+> user-agent: bundler/1.15.0.pre.2 rubygems/2.6.11 ruby/2.4.1 (x86_64-apple-darwin16.5.0) command/lock options/spec_run,plugins,trampoline_disable 7edfb7e0938d0c35
+> connection: keep-alive
+> keep-alive: 30
+> host: index.rubygems.org \ No newline at end of file
diff --git a/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/win32-security/GET/response b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/win32-security/GET/response
new file mode 100644
index 0000000000..bb0c9a7e36
--- /dev/null
+++ b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/win32-security/GET/response
Binary files differ
diff --git a/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/win32console/GET/request b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/win32console/GET/request
new file mode 100644
index 0000000000..37acaa6088
--- /dev/null
+++ b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/win32console/GET/request
@@ -0,0 +1,7 @@
+> GET /info/win32console
+> accept-encoding: gzip
+> accept: */*
+> user-agent: bundler/1.15.0.pre.2 rubygems/2.6.11 ruby/2.4.1 (x86_64-apple-darwin16.5.0) command/lock options/spec_run,plugins,trampoline_disable 7edfb7e0938d0c35
+> connection: keep-alive
+> keep-alive: 30
+> host: index.rubygems.org \ No newline at end of file
diff --git a/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/win32console/GET/response b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/win32console/GET/response
new file mode 100644
index 0000000000..521817fcfc
--- /dev/null
+++ b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/win32console/GET/response
Binary files differ
diff --git a/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/windows-api/GET/request b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/windows-api/GET/request
new file mode 100644
index 0000000000..30402b17e0
--- /dev/null
+++ b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/windows-api/GET/request
@@ -0,0 +1,7 @@
+> GET /info/windows-api
+> accept-encoding: gzip
+> accept: */*
+> user-agent: bundler/1.15.0.pre.2 rubygems/2.6.11 ruby/2.4.1 (x86_64-apple-darwin16.5.0) command/lock options/spec_run,plugins,trampoline_disable 7edfb7e0938d0c35
+> connection: keep-alive
+> keep-alive: 30
+> host: index.rubygems.org \ No newline at end of file
diff --git a/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/windows-api/GET/response b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/windows-api/GET/response
new file mode 100644
index 0000000000..a5f9ab5106
--- /dev/null
+++ b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/windows-api/GET/response
Binary files differ
diff --git a/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/windows-pr/GET/request b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/windows-pr/GET/request
new file mode 100644
index 0000000000..31c1180ac7
--- /dev/null
+++ b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/windows-pr/GET/request
@@ -0,0 +1,7 @@
+> GET /info/windows-pr
+> accept-encoding: gzip
+> accept: */*
+> user-agent: bundler/1.15.0.pre.2 rubygems/2.6.11 ruby/2.4.1 (x86_64-apple-darwin16.5.0) command/lock options/spec_run,plugins,trampoline_disable 7edfb7e0938d0c35
+> connection: keep-alive
+> keep-alive: 30
+> host: index.rubygems.org \ No newline at end of file
diff --git a/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/windows-pr/GET/response b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/windows-pr/GET/response
new file mode 100644
index 0000000000..da32f51343
--- /dev/null
+++ b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/windows-pr/GET/response
Binary files differ
diff --git a/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/xpath/GET/request b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/xpath/GET/request
new file mode 100644
index 0000000000..5cc409d8db
--- /dev/null
+++ b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/xpath/GET/request
@@ -0,0 +1,7 @@
+> GET /info/xpath
+> accept-encoding: gzip
+> accept: */*
+> user-agent: bundler/1.15.0.pre.2 rubygems/2.6.11 ruby/2.4.1 (x86_64-apple-darwin16.5.0) command/lock options/spec_run,plugins,trampoline_disable 7edfb7e0938d0c35
+> connection: keep-alive
+> keep-alive: 30
+> host: index.rubygems.org \ No newline at end of file
diff --git a/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/xpath/GET/response b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/xpath/GET/response
new file mode 100644
index 0000000000..07edc592e7
--- /dev/null
+++ b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/info/xpath/GET/response
Binary files differ
diff --git a/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/versions/GET/request b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/versions/GET/request
new file mode 100644
index 0000000000..ec73805dff
--- /dev/null
+++ b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/versions/GET/request
@@ -0,0 +1,7 @@
+> GET /versions
+> accept-encoding: gzip
+> accept: */*
+> user-agent: bundler/1.15.0.pre.2 rubygems/2.6.11 ruby/2.4.1 (x86_64-apple-darwin16.5.0) command/lock options/spec_run,plugins,trampoline_disable 7edfb7e0938d0c35
+> connection: keep-alive
+> keep-alive: 30
+> host: index.rubygems.org \ No newline at end of file
diff --git a/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/versions/GET/response b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/versions/GET/response
new file mode 100644
index 0000000000..0a46b96850
--- /dev/null
+++ b/spec/bundler/support/artifice/vcr_cassettes/realworld/index.rubygems.org/versions/GET/response
Binary files differ
diff --git a/spec/bundler/support/artifice/vcr_cassettes/realworld/rubygems.org/gems/activesupport-3.2.12.gem/GET/request b/spec/bundler/support/artifice/vcr_cassettes/realworld/rubygems.org/gems/activesupport-3.2.12.gem/GET/request
new file mode 100644
index 0000000000..c078ac79e1
--- /dev/null
+++ b/spec/bundler/support/artifice/vcr_cassettes/realworld/rubygems.org/gems/activesupport-3.2.12.gem/GET/request
@@ -0,0 +1,7 @@
+> GET /gems/activesupport-3.2.12.gem
+> accept-encoding: gzip;q=1.0,deflate;q=0.6,identity;q=0.3
+> accept: */*
+> user-agent: Ruby
+> connection: keep-alive
+> keep-alive: 30
+> host: rubygems.org \ No newline at end of file
diff --git a/spec/bundler/support/artifice/vcr_cassettes/realworld/rubygems.org/gems/activesupport-3.2.12.gem/GET/response b/spec/bundler/support/artifice/vcr_cassettes/realworld/rubygems.org/gems/activesupport-3.2.12.gem/GET/response
new file mode 100644
index 0000000000..7690c1c76d
--- /dev/null
+++ b/spec/bundler/support/artifice/vcr_cassettes/realworld/rubygems.org/gems/activesupport-3.2.12.gem/GET/response
Binary files differ
diff --git a/spec/bundler/support/artifice/vcr_cassettes/realworld/rubygems.org/gems/activesupport-3.2.22.5.gem/GET/request b/spec/bundler/support/artifice/vcr_cassettes/realworld/rubygems.org/gems/activesupport-3.2.22.5.gem/GET/request
new file mode 100644
index 0000000000..b87c281d96
--- /dev/null
+++ b/spec/bundler/support/artifice/vcr_cassettes/realworld/rubygems.org/gems/activesupport-3.2.22.5.gem/GET/request
@@ -0,0 +1,7 @@
+> GET /gems/activesupport-3.2.22.5.gem
+> accept-encoding: gzip;q=1.0,deflate;q=0.6,identity;q=0.3
+> accept: */*
+> user-agent: Ruby
+> connection: keep-alive
+> keep-alive: 30
+> host: rubygems.org \ No newline at end of file
diff --git a/spec/bundler/support/artifice/vcr_cassettes/realworld/rubygems.org/gems/activesupport-3.2.22.5.gem/GET/response b/spec/bundler/support/artifice/vcr_cassettes/realworld/rubygems.org/gems/activesupport-3.2.22.5.gem/GET/response
new file mode 100644
index 0000000000..3659fabd5f
--- /dev/null
+++ b/spec/bundler/support/artifice/vcr_cassettes/realworld/rubygems.org/gems/activesupport-3.2.22.5.gem/GET/response
Binary files differ
diff --git a/spec/bundler/support/artifice/vcr_cassettes/realworld/rubygems.org/gems/bundler-1.12.3.gem/GET/request b/spec/bundler/support/artifice/vcr_cassettes/realworld/rubygems.org/gems/bundler-1.12.3.gem/GET/request
new file mode 100644
index 0000000000..af03dfd189
--- /dev/null
+++ b/spec/bundler/support/artifice/vcr_cassettes/realworld/rubygems.org/gems/bundler-1.12.3.gem/GET/request
@@ -0,0 +1,7 @@
+> GET /gems/bundler-1.12.3.gem
+> accept-encoding: gzip;q=1.0,deflate;q=0.6,identity;q=0.3
+> accept: */*
+> user-agent: Ruby
+> connection: keep-alive
+> keep-alive: 30
+> host: rubygems.org \ No newline at end of file
diff --git a/spec/bundler/support/artifice/vcr_cassettes/realworld/rubygems.org/gems/bundler-1.12.3.gem/GET/response b/spec/bundler/support/artifice/vcr_cassettes/realworld/rubygems.org/gems/bundler-1.12.3.gem/GET/response
new file mode 100644
index 0000000000..8a5dc75d9e
--- /dev/null
+++ b/spec/bundler/support/artifice/vcr_cassettes/realworld/rubygems.org/gems/bundler-1.12.3.gem/GET/response
Binary files differ
diff --git a/spec/bundler/support/artifice/vcr_cassettes/realworld/rubygems.org/gems/diff-lcs-1.3.gem/GET/request b/spec/bundler/support/artifice/vcr_cassettes/realworld/rubygems.org/gems/diff-lcs-1.3.gem/GET/request
new file mode 100644
index 0000000000..6b0ccfc8c1
--- /dev/null
+++ b/spec/bundler/support/artifice/vcr_cassettes/realworld/rubygems.org/gems/diff-lcs-1.3.gem/GET/request
@@ -0,0 +1,7 @@
+> GET /gems/diff-lcs-1.3.gem
+> accept-encoding: gzip;q=1.0,deflate;q=0.6,identity;q=0.3
+> accept: */*
+> user-agent: Ruby
+> connection: keep-alive
+> keep-alive: 30
+> host: rubygems.org \ No newline at end of file
diff --git a/spec/bundler/support/artifice/vcr_cassettes/realworld/rubygems.org/gems/diff-lcs-1.3.gem/GET/response b/spec/bundler/support/artifice/vcr_cassettes/realworld/rubygems.org/gems/diff-lcs-1.3.gem/GET/response
new file mode 100644
index 0000000000..908888f595
--- /dev/null
+++ b/spec/bundler/support/artifice/vcr_cassettes/realworld/rubygems.org/gems/diff-lcs-1.3.gem/GET/response
Binary files differ
diff --git a/spec/bundler/support/artifice/vcr_cassettes/realworld/rubygems.org/gems/faker-1.1.2.gem/GET/request b/spec/bundler/support/artifice/vcr_cassettes/realworld/rubygems.org/gems/faker-1.1.2.gem/GET/request
new file mode 100644
index 0000000000..5226c62cd2
--- /dev/null
+++ b/spec/bundler/support/artifice/vcr_cassettes/realworld/rubygems.org/gems/faker-1.1.2.gem/GET/request
@@ -0,0 +1,7 @@
+> GET /gems/faker-1.1.2.gem
+> accept-encoding: gzip;q=1.0,deflate;q=0.6,identity;q=0.3
+> accept: */*
+> user-agent: Ruby
+> connection: keep-alive
+> keep-alive: 30
+> host: rubygems.org \ No newline at end of file
diff --git a/spec/bundler/support/artifice/vcr_cassettes/realworld/rubygems.org/gems/faker-1.1.2.gem/GET/response b/spec/bundler/support/artifice/vcr_cassettes/realworld/rubygems.org/gems/faker-1.1.2.gem/GET/response
new file mode 100644
index 0000000000..19bf053db5
--- /dev/null
+++ b/spec/bundler/support/artifice/vcr_cassettes/realworld/rubygems.org/gems/faker-1.1.2.gem/GET/response
Binary files differ
diff --git a/spec/bundler/support/artifice/vcr_cassettes/realworld/rubygems.org/gems/i18n-0.6.11.gem/GET/request b/spec/bundler/support/artifice/vcr_cassettes/realworld/rubygems.org/gems/i18n-0.6.11.gem/GET/request
new file mode 100644
index 0000000000..6e27eac32c
--- /dev/null
+++ b/spec/bundler/support/artifice/vcr_cassettes/realworld/rubygems.org/gems/i18n-0.6.11.gem/GET/request
@@ -0,0 +1,7 @@
+> GET /gems/i18n-0.6.11.gem
+> accept-encoding: gzip;q=1.0,deflate;q=0.6,identity;q=0.3
+> accept: */*
+> user-agent: Ruby
+> connection: keep-alive
+> keep-alive: 30
+> host: rubygems.org \ No newline at end of file
diff --git a/spec/bundler/support/artifice/vcr_cassettes/realworld/rubygems.org/gems/i18n-0.6.11.gem/GET/response b/spec/bundler/support/artifice/vcr_cassettes/realworld/rubygems.org/gems/i18n-0.6.11.gem/GET/response
new file mode 100644
index 0000000000..0253208389
--- /dev/null
+++ b/spec/bundler/support/artifice/vcr_cassettes/realworld/rubygems.org/gems/i18n-0.6.11.gem/GET/response
Binary files differ
diff --git a/spec/bundler/support/artifice/vcr_cassettes/realworld/rubygems.org/gems/i18n-0.8.1.gem/GET/request b/spec/bundler/support/artifice/vcr_cassettes/realworld/rubygems.org/gems/i18n-0.8.1.gem/GET/request
new file mode 100644
index 0000000000..04e800510b
--- /dev/null
+++ b/spec/bundler/support/artifice/vcr_cassettes/realworld/rubygems.org/gems/i18n-0.8.1.gem/GET/request
@@ -0,0 +1,7 @@
+> GET /gems/i18n-0.8.1.gem
+> accept-encoding: gzip;q=1.0,deflate;q=0.6,identity;q=0.3
+> accept: */*
+> user-agent: Ruby
+> connection: keep-alive
+> keep-alive: 30
+> host: rubygems.org \ No newline at end of file
diff --git a/spec/bundler/support/artifice/vcr_cassettes/realworld/rubygems.org/gems/i18n-0.8.1.gem/GET/response b/spec/bundler/support/artifice/vcr_cassettes/realworld/rubygems.org/gems/i18n-0.8.1.gem/GET/response
new file mode 100644
index 0000000000..e746a6b73d
--- /dev/null
+++ b/spec/bundler/support/artifice/vcr_cassettes/realworld/rubygems.org/gems/i18n-0.8.1.gem/GET/response
Binary files differ
diff --git a/spec/bundler/support/artifice/vcr_cassettes/realworld/rubygems.org/gems/mono_logger-1.1.0.gem/GET/request b/spec/bundler/support/artifice/vcr_cassettes/realworld/rubygems.org/gems/mono_logger-1.1.0.gem/GET/request
new file mode 100644
index 0000000000..8e82694d05
--- /dev/null
+++ b/spec/bundler/support/artifice/vcr_cassettes/realworld/rubygems.org/gems/mono_logger-1.1.0.gem/GET/request
@@ -0,0 +1,7 @@
+> GET /gems/mono_logger-1.1.0.gem
+> accept-encoding: gzip;q=1.0,deflate;q=0.6,identity;q=0.3
+> accept: */*
+> user-agent: Ruby
+> connection: keep-alive
+> keep-alive: 30
+> host: rubygems.org \ No newline at end of file
diff --git a/spec/bundler/support/artifice/vcr_cassettes/realworld/rubygems.org/gems/mono_logger-1.1.0.gem/GET/response b/spec/bundler/support/artifice/vcr_cassettes/realworld/rubygems.org/gems/mono_logger-1.1.0.gem/GET/response
new file mode 100644
index 0000000000..3e1edd9559
--- /dev/null
+++ b/spec/bundler/support/artifice/vcr_cassettes/realworld/rubygems.org/gems/mono_logger-1.1.0.gem/GET/response
Binary files differ
diff --git a/spec/bundler/support/artifice/vcr_cassettes/realworld/rubygems.org/gems/multi_json-1.12.1.gem/GET/request b/spec/bundler/support/artifice/vcr_cassettes/realworld/rubygems.org/gems/multi_json-1.12.1.gem/GET/request
new file mode 100644
index 0000000000..fa8e059e91
--- /dev/null
+++ b/spec/bundler/support/artifice/vcr_cassettes/realworld/rubygems.org/gems/multi_json-1.12.1.gem/GET/request
@@ -0,0 +1,7 @@
+> GET /gems/multi_json-1.12.1.gem
+> accept-encoding: gzip;q=1.0,deflate;q=0.6,identity;q=0.3
+> accept: */*
+> user-agent: Ruby
+> connection: keep-alive
+> keep-alive: 30
+> host: rubygems.org \ No newline at end of file
diff --git a/spec/bundler/support/artifice/vcr_cassettes/realworld/rubygems.org/gems/multi_json-1.12.1.gem/GET/response b/spec/bundler/support/artifice/vcr_cassettes/realworld/rubygems.org/gems/multi_json-1.12.1.gem/GET/response
new file mode 100644
index 0000000000..3a5565f9e0
--- /dev/null
+++ b/spec/bundler/support/artifice/vcr_cassettes/realworld/rubygems.org/gems/multi_json-1.12.1.gem/GET/response
Binary files differ
diff --git a/spec/bundler/support/artifice/vcr_cassettes/realworld/rubygems.org/gems/rack-1.0.1.gem/GET/request b/spec/bundler/support/artifice/vcr_cassettes/realworld/rubygems.org/gems/rack-1.0.1.gem/GET/request
new file mode 100644
index 0000000000..9d96c013bc
--- /dev/null
+++ b/spec/bundler/support/artifice/vcr_cassettes/realworld/rubygems.org/gems/rack-1.0.1.gem/GET/request
@@ -0,0 +1,7 @@
+> GET /gems/rack-1.0.1.gem
+> accept-encoding: gzip;q=1.0,deflate;q=0.6,identity;q=0.3
+> accept: */*
+> user-agent: Ruby
+> connection: keep-alive
+> keep-alive: 30
+> host: rubygems.org \ No newline at end of file
diff --git a/spec/bundler/support/artifice/vcr_cassettes/realworld/rubygems.org/gems/rack-1.0.1.gem/GET/response b/spec/bundler/support/artifice/vcr_cassettes/realworld/rubygems.org/gems/rack-1.0.1.gem/GET/response
new file mode 100644
index 0000000000..3c461eee58
--- /dev/null
+++ b/spec/bundler/support/artifice/vcr_cassettes/realworld/rubygems.org/gems/rack-1.0.1.gem/GET/response
Binary files differ
diff --git a/spec/bundler/support/artifice/vcr_cassettes/realworld/rubygems.org/gems/rack-1.6.5.gem/GET/request b/spec/bundler/support/artifice/vcr_cassettes/realworld/rubygems.org/gems/rack-1.6.5.gem/GET/request
new file mode 100644
index 0000000000..4ae9745db3
--- /dev/null
+++ b/spec/bundler/support/artifice/vcr_cassettes/realworld/rubygems.org/gems/rack-1.6.5.gem/GET/request
@@ -0,0 +1,7 @@
+> GET /gems/rack-1.6.5.gem
+> accept-encoding: gzip;q=1.0,deflate;q=0.6,identity;q=0.3
+> accept: */*
+> user-agent: Ruby
+> connection: keep-alive
+> keep-alive: 30
+> host: rubygems.org \ No newline at end of file
diff --git a/spec/bundler/support/artifice/vcr_cassettes/realworld/rubygems.org/gems/rack-1.6.5.gem/GET/response b/spec/bundler/support/artifice/vcr_cassettes/realworld/rubygems.org/gems/rack-1.6.5.gem/GET/response
new file mode 100644
index 0000000000..81fbf129bb
--- /dev/null
+++ b/spec/bundler/support/artifice/vcr_cassettes/realworld/rubygems.org/gems/rack-1.6.5.gem/GET/response
Binary files differ
diff --git a/spec/bundler/support/artifice/vcr_cassettes/realworld/rubygems.org/gems/rack-protection-1.5.3.gem/GET/request b/spec/bundler/support/artifice/vcr_cassettes/realworld/rubygems.org/gems/rack-protection-1.5.3.gem/GET/request
new file mode 100644
index 0000000000..03a85b2308
--- /dev/null
+++ b/spec/bundler/support/artifice/vcr_cassettes/realworld/rubygems.org/gems/rack-protection-1.5.3.gem/GET/request
@@ -0,0 +1,7 @@
+> GET /gems/rack-protection-1.5.3.gem
+> accept-encoding: gzip;q=1.0,deflate;q=0.6,identity;q=0.3
+> accept: */*
+> user-agent: Ruby
+> connection: keep-alive
+> keep-alive: 30
+> host: rubygems.org \ No newline at end of file
diff --git a/spec/bundler/support/artifice/vcr_cassettes/realworld/rubygems.org/gems/rack-protection-1.5.3.gem/GET/response b/spec/bundler/support/artifice/vcr_cassettes/realworld/rubygems.org/gems/rack-protection-1.5.3.gem/GET/response
new file mode 100644
index 0000000000..5753f9f8c6
--- /dev/null
+++ b/spec/bundler/support/artifice/vcr_cassettes/realworld/rubygems.org/gems/rack-protection-1.5.3.gem/GET/response
Binary files differ
diff --git a/spec/bundler/support/artifice/vcr_cassettes/realworld/rubygems.org/gems/redis-3.3.3.gem/GET/request b/spec/bundler/support/artifice/vcr_cassettes/realworld/rubygems.org/gems/redis-3.3.3.gem/GET/request
new file mode 100644
index 0000000000..7d5ad5ad23
--- /dev/null
+++ b/spec/bundler/support/artifice/vcr_cassettes/realworld/rubygems.org/gems/redis-3.3.3.gem/GET/request
@@ -0,0 +1,7 @@
+> GET /gems/redis-3.3.3.gem
+> accept-encoding: gzip;q=1.0,deflate;q=0.6,identity;q=0.3
+> accept: */*
+> user-agent: Ruby
+> connection: keep-alive
+> keep-alive: 30
+> host: rubygems.org \ No newline at end of file
diff --git a/spec/bundler/support/artifice/vcr_cassettes/realworld/rubygems.org/gems/redis-3.3.3.gem/GET/response b/spec/bundler/support/artifice/vcr_cassettes/realworld/rubygems.org/gems/redis-3.3.3.gem/GET/response
new file mode 100644
index 0000000000..375d86d9d7
--- /dev/null
+++ b/spec/bundler/support/artifice/vcr_cassettes/realworld/rubygems.org/gems/redis-3.3.3.gem/GET/response
Binary files differ
diff --git a/spec/bundler/support/artifice/vcr_cassettes/realworld/rubygems.org/gems/redis-namespace-1.5.3.gem/GET/request b/spec/bundler/support/artifice/vcr_cassettes/realworld/rubygems.org/gems/redis-namespace-1.5.3.gem/GET/request
new file mode 100644
index 0000000000..f928e29dd3
--- /dev/null
+++ b/spec/bundler/support/artifice/vcr_cassettes/realworld/rubygems.org/gems/redis-namespace-1.5.3.gem/GET/request
@@ -0,0 +1,7 @@
+> GET /gems/redis-namespace-1.5.3.gem
+> accept-encoding: gzip;q=1.0,deflate;q=0.6,identity;q=0.3
+> accept: */*
+> user-agent: Ruby
+> connection: keep-alive
+> keep-alive: 30
+> host: rubygems.org \ No newline at end of file
diff --git a/spec/bundler/support/artifice/vcr_cassettes/realworld/rubygems.org/gems/redis-namespace-1.5.3.gem/GET/response b/spec/bundler/support/artifice/vcr_cassettes/realworld/rubygems.org/gems/redis-namespace-1.5.3.gem/GET/response
new file mode 100644
index 0000000000..eab27de2e2
--- /dev/null
+++ b/spec/bundler/support/artifice/vcr_cassettes/realworld/rubygems.org/gems/redis-namespace-1.5.3.gem/GET/response
Binary files differ
diff --git a/spec/bundler/support/artifice/vcr_cassettes/realworld/rubygems.org/gems/resque-1.24.1.gem/GET/request b/spec/bundler/support/artifice/vcr_cassettes/realworld/rubygems.org/gems/resque-1.24.1.gem/GET/request
new file mode 100644
index 0000000000..91c5562047
--- /dev/null
+++ b/spec/bundler/support/artifice/vcr_cassettes/realworld/rubygems.org/gems/resque-1.24.1.gem/GET/request
@@ -0,0 +1,7 @@
+> GET /gems/resque-1.24.1.gem
+> accept-encoding: gzip;q=1.0,deflate;q=0.6,identity;q=0.3
+> accept: */*
+> user-agent: Ruby
+> connection: keep-alive
+> keep-alive: 30
+> host: rubygems.org \ No newline at end of file
diff --git a/spec/bundler/support/artifice/vcr_cassettes/realworld/rubygems.org/gems/resque-1.24.1.gem/GET/response b/spec/bundler/support/artifice/vcr_cassettes/realworld/rubygems.org/gems/resque-1.24.1.gem/GET/response
new file mode 100644
index 0000000000..33d38e4c6c
--- /dev/null
+++ b/spec/bundler/support/artifice/vcr_cassettes/realworld/rubygems.org/gems/resque-1.24.1.gem/GET/response
Binary files differ
diff --git a/spec/bundler/support/artifice/vcr_cassettes/realworld/rubygems.org/gems/resque-scheduler-2.2.0.gem/GET/request b/spec/bundler/support/artifice/vcr_cassettes/realworld/rubygems.org/gems/resque-scheduler-2.2.0.gem/GET/request
new file mode 100644
index 0000000000..0237de2859
--- /dev/null
+++ b/spec/bundler/support/artifice/vcr_cassettes/realworld/rubygems.org/gems/resque-scheduler-2.2.0.gem/GET/request
@@ -0,0 +1,7 @@
+> GET /gems/resque-scheduler-2.2.0.gem
+> accept-encoding: gzip;q=1.0,deflate;q=0.6,identity;q=0.3
+> accept: */*
+> user-agent: Ruby
+> connection: keep-alive
+> keep-alive: 30
+> host: rubygems.org \ No newline at end of file
diff --git a/spec/bundler/support/artifice/vcr_cassettes/realworld/rubygems.org/gems/resque-scheduler-2.2.0.gem/GET/response b/spec/bundler/support/artifice/vcr_cassettes/realworld/rubygems.org/gems/resque-scheduler-2.2.0.gem/GET/response
new file mode 100644
index 0000000000..455dc8bb01
--- /dev/null
+++ b/spec/bundler/support/artifice/vcr_cassettes/realworld/rubygems.org/gems/resque-scheduler-2.2.0.gem/GET/response
Binary files differ
diff --git a/spec/bundler/support/artifice/vcr_cassettes/realworld/rubygems.org/gems/rufus-scheduler-2.0.24.gem/GET/request b/spec/bundler/support/artifice/vcr_cassettes/realworld/rubygems.org/gems/rufus-scheduler-2.0.24.gem/GET/request
new file mode 100644
index 0000000000..a8428bc9f6
--- /dev/null
+++ b/spec/bundler/support/artifice/vcr_cassettes/realworld/rubygems.org/gems/rufus-scheduler-2.0.24.gem/GET/request
@@ -0,0 +1,7 @@
+> GET /gems/rufus-scheduler-2.0.24.gem
+> accept-encoding: gzip;q=1.0,deflate;q=0.6,identity;q=0.3
+> accept: */*
+> user-agent: Ruby
+> connection: keep-alive
+> keep-alive: 30
+> host: rubygems.org \ No newline at end of file
diff --git a/spec/bundler/support/artifice/vcr_cassettes/realworld/rubygems.org/gems/rufus-scheduler-2.0.24.gem/GET/response b/spec/bundler/support/artifice/vcr_cassettes/realworld/rubygems.org/gems/rufus-scheduler-2.0.24.gem/GET/response
new file mode 100644
index 0000000000..72b58e69dd
--- /dev/null
+++ b/spec/bundler/support/artifice/vcr_cassettes/realworld/rubygems.org/gems/rufus-scheduler-2.0.24.gem/GET/response
Binary files differ
diff --git a/spec/bundler/support/artifice/vcr_cassettes/realworld/rubygems.org/gems/sinatra-1.4.8.gem/GET/request b/spec/bundler/support/artifice/vcr_cassettes/realworld/rubygems.org/gems/sinatra-1.4.8.gem/GET/request
new file mode 100644
index 0000000000..ee93e5d100
--- /dev/null
+++ b/spec/bundler/support/artifice/vcr_cassettes/realworld/rubygems.org/gems/sinatra-1.4.8.gem/GET/request
@@ -0,0 +1,7 @@
+> GET /gems/sinatra-1.4.8.gem
+> accept-encoding: gzip;q=1.0,deflate;q=0.6,identity;q=0.3
+> accept: */*
+> user-agent: Ruby
+> connection: keep-alive
+> keep-alive: 30
+> host: rubygems.org \ No newline at end of file
diff --git a/spec/bundler/support/artifice/vcr_cassettes/realworld/rubygems.org/gems/sinatra-1.4.8.gem/GET/response b/spec/bundler/support/artifice/vcr_cassettes/realworld/rubygems.org/gems/sinatra-1.4.8.gem/GET/response
new file mode 100644
index 0000000000..c3aa1333c6
--- /dev/null
+++ b/spec/bundler/support/artifice/vcr_cassettes/realworld/rubygems.org/gems/sinatra-1.4.8.gem/GET/response
Binary files differ
diff --git a/spec/bundler/support/artifice/vcr_cassettes/realworld/rubygems.org/gems/thread_safe-0.3.6.gem/GET/request b/spec/bundler/support/artifice/vcr_cassettes/realworld/rubygems.org/gems/thread_safe-0.3.6.gem/GET/request
new file mode 100644
index 0000000000..51ddc098ae
--- /dev/null
+++ b/spec/bundler/support/artifice/vcr_cassettes/realworld/rubygems.org/gems/thread_safe-0.3.6.gem/GET/request
@@ -0,0 +1,7 @@
+> GET /gems/thread_safe-0.3.6.gem
+> accept-encoding: gzip;q=1.0,deflate;q=0.6,identity;q=0.3
+> accept: */*
+> user-agent: Ruby
+> connection: keep-alive
+> keep-alive: 30
+> host: rubygems.org \ No newline at end of file
diff --git a/spec/bundler/support/artifice/vcr_cassettes/realworld/rubygems.org/gems/thread_safe-0.3.6.gem/GET/response b/spec/bundler/support/artifice/vcr_cassettes/realworld/rubygems.org/gems/thread_safe-0.3.6.gem/GET/response
new file mode 100644
index 0000000000..9007f04014
--- /dev/null
+++ b/spec/bundler/support/artifice/vcr_cassettes/realworld/rubygems.org/gems/thread_safe-0.3.6.gem/GET/response
Binary files differ
diff --git a/spec/bundler/support/artifice/vcr_cassettes/realworld/rubygems.org/gems/tilt-2.0.7.gem/GET/request b/spec/bundler/support/artifice/vcr_cassettes/realworld/rubygems.org/gems/tilt-2.0.7.gem/GET/request
new file mode 100644
index 0000000000..c329c7b4c2
--- /dev/null
+++ b/spec/bundler/support/artifice/vcr_cassettes/realworld/rubygems.org/gems/tilt-2.0.7.gem/GET/request
@@ -0,0 +1,7 @@
+> GET /gems/tilt-2.0.7.gem
+> accept-encoding: gzip;q=1.0,deflate;q=0.6,identity;q=0.3
+> accept: */*
+> user-agent: Ruby
+> connection: keep-alive
+> keep-alive: 30
+> host: rubygems.org \ No newline at end of file
diff --git a/spec/bundler/support/artifice/vcr_cassettes/realworld/rubygems.org/gems/tilt-2.0.7.gem/GET/response b/spec/bundler/support/artifice/vcr_cassettes/realworld/rubygems.org/gems/tilt-2.0.7.gem/GET/response
new file mode 100644
index 0000000000..46add52ee8
--- /dev/null
+++ b/spec/bundler/support/artifice/vcr_cassettes/realworld/rubygems.org/gems/tilt-2.0.7.gem/GET/response
Binary files differ
diff --git a/spec/bundler/support/artifice/vcr_cassettes/realworld/rubygems.org/gems/tzinfo-1.2.3.gem/GET/request b/spec/bundler/support/artifice/vcr_cassettes/realworld/rubygems.org/gems/tzinfo-1.2.3.gem/GET/request
new file mode 100644
index 0000000000..df7b05b346
--- /dev/null
+++ b/spec/bundler/support/artifice/vcr_cassettes/realworld/rubygems.org/gems/tzinfo-1.2.3.gem/GET/request
@@ -0,0 +1,7 @@
+> GET /gems/tzinfo-1.2.3.gem
+> accept-encoding: gzip;q=1.0,deflate;q=0.6,identity;q=0.3
+> accept: */*
+> user-agent: Ruby
+> connection: keep-alive
+> keep-alive: 30
+> host: rubygems.org \ No newline at end of file
diff --git a/spec/bundler/support/artifice/vcr_cassettes/realworld/rubygems.org/gems/tzinfo-1.2.3.gem/GET/response b/spec/bundler/support/artifice/vcr_cassettes/realworld/rubygems.org/gems/tzinfo-1.2.3.gem/GET/response
new file mode 100644
index 0000000000..a64e2fda89
--- /dev/null
+++ b/spec/bundler/support/artifice/vcr_cassettes/realworld/rubygems.org/gems/tzinfo-1.2.3.gem/GET/response
Binary files differ
diff --git a/spec/bundler/support/artifice/vcr_cassettes/realworld/rubygems.org/gems/vegas-0.1.11.gem/GET/request b/spec/bundler/support/artifice/vcr_cassettes/realworld/rubygems.org/gems/vegas-0.1.11.gem/GET/request
new file mode 100644
index 0000000000..562c01e339
--- /dev/null
+++ b/spec/bundler/support/artifice/vcr_cassettes/realworld/rubygems.org/gems/vegas-0.1.11.gem/GET/request
@@ -0,0 +1,7 @@
+> GET /gems/vegas-0.1.11.gem
+> accept-encoding: gzip;q=1.0,deflate;q=0.6,identity;q=0.3
+> accept: */*
+> user-agent: Ruby
+> connection: keep-alive
+> keep-alive: 30
+> host: rubygems.org \ No newline at end of file
diff --git a/spec/bundler/support/artifice/vcr_cassettes/realworld/rubygems.org/gems/vegas-0.1.11.gem/GET/response b/spec/bundler/support/artifice/vcr_cassettes/realworld/rubygems.org/gems/vegas-0.1.11.gem/GET/response
new file mode 100644
index 0000000000..b84b62a38c
--- /dev/null
+++ b/spec/bundler/support/artifice/vcr_cassettes/realworld/rubygems.org/gems/vegas-0.1.11.gem/GET/response
Binary files differ
diff --git a/spec/bundler/support/artifice/vcr_cassettes/realworld/rubygems.org/quick/Marshal.4.8/bundler-1.12.3.gemspec.rz/GET/request b/spec/bundler/support/artifice/vcr_cassettes/realworld/rubygems.org/quick/Marshal.4.8/bundler-1.12.3.gemspec.rz/GET/request
new file mode 100644
index 0000000000..ef6eab21ce
--- /dev/null
+++ b/spec/bundler/support/artifice/vcr_cassettes/realworld/rubygems.org/quick/Marshal.4.8/bundler-1.12.3.gemspec.rz/GET/request
@@ -0,0 +1,7 @@
+> GET /quick/Marshal.4.8/bundler-1.12.3.gemspec.rz
+> accept-encoding: gzip;q=1.0,deflate;q=0.6,identity;q=0.3
+> accept: */*
+> user-agent: Ruby
+> connection: keep-alive
+> keep-alive: 30
+> host: rubygems.org \ No newline at end of file
diff --git a/spec/bundler/support/artifice/vcr_cassettes/realworld/rubygems.org/quick/Marshal.4.8/bundler-1.12.3.gemspec.rz/GET/response b/spec/bundler/support/artifice/vcr_cassettes/realworld/rubygems.org/quick/Marshal.4.8/bundler-1.12.3.gemspec.rz/GET/response
new file mode 100644
index 0000000000..c2e8cb4bce
--- /dev/null
+++ b/spec/bundler/support/artifice/vcr_cassettes/realworld/rubygems.org/quick/Marshal.4.8/bundler-1.12.3.gemspec.rz/GET/response
Binary files differ
diff --git a/spec/bundler/support/artifice/vcr_cassettes/realworld/rubygems.org/specs.4.8.gz/GET/request b/spec/bundler/support/artifice/vcr_cassettes/realworld/rubygems.org/specs.4.8.gz/GET/request
new file mode 100644
index 0000000000..ca0f179471
--- /dev/null
+++ b/spec/bundler/support/artifice/vcr_cassettes/realworld/rubygems.org/specs.4.8.gz/GET/request
@@ -0,0 +1,7 @@
+> GET /specs.4.8.gz
+> accept-encoding: gzip;q=1.0,deflate;q=0.6,identity;q=0.3
+> accept: */*
+> user-agent: Ruby
+> connection: keep-alive
+> keep-alive: 30
+> host: rubygems.org \ No newline at end of file
diff --git a/spec/bundler/support/artifice/vcr_cassettes/realworld/rubygems.org/specs.4.8.gz/GET/response b/spec/bundler/support/artifice/vcr_cassettes/realworld/rubygems.org/specs.4.8.gz/GET/response
new file mode 100644
index 0000000000..95277c9b51
--- /dev/null
+++ b/spec/bundler/support/artifice/vcr_cassettes/realworld/rubygems.org/specs.4.8.gz/GET/response
Binary files differ
diff --git a/spec/bundler/support/artifice/windows.rb b/spec/bundler/support/artifice/windows.rb
index c18ca454ec..f39b2c6d53 100644
--- a/spec/bundler/support/artifice/windows.rb
+++ b/spec/bundler/support/artifice/windows.rb
@@ -1,4 +1,5 @@
# frozen_string_literal: true
+
require File.expand_path("../../path.rb", __FILE__)
include Spec::Path
diff --git a/spec/bundler/support/builders.rb b/spec/bundler/support/builders.rb
index db128d497b..e8208eacd9 100644
--- a/spec/bundler/support/builders.rb
+++ b/spec/bundler/support/builders.rb
@@ -1,4 +1,5 @@
# frozen_string_literal: true
+
require "bundler/shared_helpers"
require "shellwords"
@@ -18,7 +19,7 @@ module Spec
def build_repo1
build_repo gem_repo1 do
- build_gem "rack", %w(0.9.1 1.0.0) do |s|
+ build_gem "rack", %w[0.9.1 1.0.0] do |s|
s.executables = "rackup"
s.post_install_message = "Rack's post install message"
end
@@ -57,7 +58,7 @@ module Spec
build_gem "activeresource", "2.3.2" do |s|
s.add_dependency "activesupport", "2.3.2"
end
- build_gem "activesupport", %w(1.2.3 2.3.2 2.3.5)
+ build_gem "activesupport", %w[1.2.3 2.3.2 2.3.5]
build_gem "activemerchant" do |s|
s.add_dependency "activesupport", ">= 2.0.0"
@@ -256,7 +257,7 @@ module Spec
end
# Capistrano did this (at least until version 2.5.10)
- # Rubygems 2.2 doesn't allow the specifying of a dependency twice
+ # RubyGems 2.2 doesn't allow the specifying of a dependency twice
# See https://github.com/rubygems/rubygems/commit/03dbac93a3396a80db258d9bc63500333c25bd2f
build_gem "double_deps", "1.0", :skip_validation => true do |s|
s.add_dependency "net-ssh", ">= 1.0.0"
@@ -565,7 +566,7 @@ module Spec
# exit 1 unless with_config("simple")
- extension_name = "very_simple_binary_c"
+ extension_name = "#{name}_c"
if extra_lib_dir = with_config("ext-lib")
# add extra libpath if --with-ext-lib is
# passed in as a build_arg
@@ -575,11 +576,11 @@ module Spec
end
create_makefile extension_name
RUBY
- write "ext/very_simple_binary.c", <<-C
+ write "ext/#{name}.c", <<-C
#include "ruby.h"
- void Init_very_simple_binary_c() {
- rb_define_module("VerySimpleBinaryInC");
+ void Init_#{name}_c() {
+ rb_define_module("#{Builders.constantize(name)}_IN_C");
}
C
end
@@ -724,18 +725,21 @@ module Spec
class GemBuilder < LibBuilder
def _build(opts)
lib_path = super(opts.merge(:path => @context.tmp(".tmp/#{@spec.full_name}"), :no_default => opts[:no_default]))
+ destination = opts[:path] || _default_path
Dir.chdir(lib_path) do
- destination = opts[:path] || _default_path
FileUtils.mkdir_p(destination)
@spec.authors = ["that guy"] if !@spec.authors || @spec.authors.empty?
Bundler.rubygems.build(@spec, opts[:skip_validation])
- if opts[:to_system]
- `gem install --ignore-dependencies --no-ri --no-rdoc #{@spec.full_name}.gem`
- else
- FileUtils.mv("#{@spec.full_name}.gem", opts[:path] || _default_path)
- end
+ end
+ gem_path = File.expand_path("#{@spec.full_name}.gem", lib_path)
+ if opts[:to_system]
+ @context.system_gems gem_path, :keep_path => true
+ elsif opts[:to_bundle]
+ @context.system_gems gem_path, :path => :bundle_path, :keep_path => true
+ else
+ FileUtils.mv(gem_path, destination)
end
end
diff --git a/spec/bundler/support/code_climate.rb b/spec/bundler/support/code_climate.rb
index 8f1fb35bcd..a15442cabe 100644
--- a/spec/bundler/support/code_climate.rb
+++ b/spec/bundler/support/code_climate.rb
@@ -1,4 +1,5 @@
# frozen_string_literal: true
+
module Spec
module CodeClimate
def self.setup
diff --git a/spec/bundler/support/command_execution.rb b/spec/bundler/support/command_execution.rb
new file mode 100644
index 0000000000..556285ac52
--- /dev/null
+++ b/spec/bundler/support/command_execution.rb
@@ -0,0 +1,57 @@
+# frozen_string_literal: true
+
+require "support/helpers"
+require "support/path"
+
+module Spec
+ CommandExecution = Struct.new(:command, :working_directory, :exitstatus, :stdout, :stderr) do
+ include RSpec::Matchers::Composable
+
+ def to_s
+ c = Shellwords.shellsplit(command.strip).map {|s| s.include?("\n") ? " \\\n <<EOS\n#{s.gsub(/^/, " ").chomp}\nEOS" : Shellwords.shellescape(s) }
+ c = c.reduce("") do |acc, elem|
+ concat = acc + " " + elem
+
+ last_line = concat.match(/.*\z/)[0]
+ if last_line.size >= 100
+ acc + " \\\n " + elem
+ else
+ concat
+ end
+ end
+ "$ #{c.strip}"
+ end
+ alias_method :inspect, :to_s
+
+ def stdboth
+ @stdboth ||= [stderr, stdout].join("\n").strip
+ end
+
+ def bundler_err
+ if Bundler::VERSION.start_with?("1.")
+ stdout
+ else
+ stderr
+ end
+ end
+
+ def to_s_verbose
+ [
+ to_s,
+ stdout,
+ stderr,
+ exitstatus ? "# $? => #{exitstatus}" : "",
+ ].reject(&:empty?).join("\n")
+ end
+
+ def success?
+ return true unless exitstatus
+ exitstatus == 0
+ end
+
+ def failure?
+ return true unless exitstatus
+ exitstatus > 0
+ end
+ end
+end
diff --git a/spec/bundler/support/hax.rb b/spec/bundler/support/hax.rb
index 663d3527c5..aee55a0ac9 100644
--- a/spec/bundler/support/hax.rb
+++ b/spec/bundler/support/hax.rb
@@ -1,7 +1,13 @@
# frozen_string_literal: true
+
require "rubygems"
module Gem
+ if version = ENV["BUNDLER_SPEC_RUBYGEMS_VERSION"]
+ remove_const(:VERSION) if const_defined?(:VERSION)
+ VERSION = version
+ end
+
class Platform
@local = new(ENV["BUNDLER_SPEC_PLATFORM"]) if ENV["BUNDLER_SPEC_PLATFORM"]
end
@@ -45,3 +51,11 @@ class Object
end
end
end
+
+if ENV["BUNDLER_SPEC_IGNORE_COMPATIBILITY_GUARD"]
+ $LOADED_FEATURES << File.expand_path("../../../bundler/compatibility_guard.rb", __FILE__)
+ $LOADED_FEATURES << File.expand_path("../../../bundler/compatibility_guard", __FILE__)
+ $LOADED_FEATURES << "bundler/compatibility_guard.rb"
+ $LOADED_FEATURES << "bundler/compatibility_guard"
+ require "bundler/compatibility_guard"
+end
diff --git a/spec/bundler/support/helpers.rb b/spec/bundler/support/helpers.rb
index 192747da05..01ddb49977 100644
--- a/spec/bundler/support/helpers.rb
+++ b/spec/bundler/support/helpers.rb
@@ -4,7 +4,7 @@ module Spec
module Helpers
def reset!
Dir.glob("#{tmp}/{gems/*,*}", File::FNM_DOTMATCH).each do |dir|
- next if %w(base remote1 gems rubygems . ..).include?(File.basename(dir))
+ next if %w[base remote1 gems rubygems . ..].include?(File.basename(dir))
if ENV["BUNDLER_SUDO_TESTS"]
`sudo rm -rf "#{dir}"`
else
@@ -21,23 +21,39 @@ module Spec
def self.bang(method)
define_method("#{method}!") do |*args, &blk|
send(method, *args, &blk).tap do
- if exitstatus && exitstatus != 0
- error = out + "\n" + err
- error.strip!
+ unless last_command.success?
raise RuntimeError,
- "Invoking #{method}!(#{args.map(&:inspect).join(", ")}) failed:\n#{error}",
+ "Invoking #{method}!(#{args.map(&:inspect).join(", ")}) failed:\n#{last_command.stdboth}",
caller.drop_while {|bt| bt.start_with?(__FILE__) }
end
end
end
end
- attr_reader :out, :err, :exitstatus
-
def the_bundle(*args)
TheBundle.new(*args)
end
+ def last_command
+ @command_executions.last || raise("There is no last command")
+ end
+
+ def out
+ last_command.stdboth
+ end
+
+ def err
+ last_command.stderr
+ end
+
+ def exitstatus
+ last_command.exitstatus
+ end
+
+ def bundle_update_requires_all?
+ Bundler::VERSION.start_with?("1.") ? nil : true
+ end
+
def in_app_root(&blk)
Dir.chdir(bundled_app, &blk)
end
@@ -54,7 +70,7 @@ module Spec
opts = args.last.is_a?(Hash) ? args.pop : {}
groups = args.map(&:inspect).join(", ")
setup = "require 'rubygems' ; require 'bundler' ; Bundler.setup(#{groups})\n"
- @out = ruby(setup + cmd, opts)
+ ruby(setup + cmd, opts)
end
bang :run
@@ -83,7 +99,8 @@ module Spec
with_sudo = options.delete(:sudo)
sudo = with_sudo == :preserve_env ? "sudo -E" : "sudo" if with_sudo
- options["no-color"] = true unless options.key?("no-color") || cmd.to_s =~ /\A(e|ex|exe|exec|conf|confi|config)(\s|\z)/
+ no_color = options.delete("no-color") { cmd.to_s !~ /\A(e|ex|exe|exec|conf|confi|config)(\s|\z)/ }
+ options["no-color"] = true if no_color
bundle_bin = options.delete("bundle_bin") || bindir.join("bundle")
@@ -91,11 +108,23 @@ module Spec
bundle_bin = "-S bundle"
end
+ env = options.delete(:env) || {}
+ env["PATH"].gsub!("#{Path.root}/exe", "") if env["PATH"] && system_bundler
+
requires = options.delete(:requires) || []
- if artifice = options.delete(:artifice) { "fail" unless RSpec.current_example.metadata[:realworld] }
- requires << File.expand_path("../artifice/#{artifice}.rb", __FILE__)
- end
requires << "support/hax"
+
+ artifice = options.delete(:artifice) do
+ if RSpec.current_example.metadata[:realworld]
+ "vcr"
+ else
+ "fail"
+ end
+ end
+ if artifice
+ requires << File.expand_path("../artifice/#{artifice}", __FILE__)
+ end
+
requires_str = requires.map {|r| "-r#{r}" }.join(" ")
load_path = []
@@ -103,10 +132,19 @@ module Spec
load_path << spec
load_path_str = "-I#{load_path.join(File::PATH_SEPARATOR)}"
- env = (options.delete(:env) || {}).map {|k, v| "#{k}='#{v}'" }.join(" ")
- env["PATH"].gsub!(Path.bindir, "") if env["PATH"] && system_bundler
+ env = env.map {|k, v| "#{k}='#{v}'" }.join(" ")
+
args = options.map do |k, v|
- v == true ? " --#{k}" : " --#{k} #{v}" if v
+ case v
+ when nil
+ next
+ when true
+ " --#{k}"
+ when false
+ " --no-#{k}"
+ else
+ " --#{k} #{v}"
+ end
end.join
cmd = "#{env} #{sudo} #{Gem.ruby} #{load_path_str} #{requires_str} #{bundle_bin} #{cmd}#{args}"
@@ -114,6 +152,24 @@ module Spec
end
bang :bundle
+ def forgotten_command_line_options(options)
+ remembered = Bundler::VERSION.split(".", 2).first == "1"
+ options = options.map do |k, v|
+ k = Array(k)[remembered ? 0 : -1]
+ v = '""' if v && v.to_s.empty?
+ [k, v]
+ end
+ return Hash[options] if remembered
+ options.each do |k, v|
+ if v.nil?
+ bundle! "config --delete #{k}"
+ else
+ bundle! "config --local #{k} #{v}"
+ end
+ end
+ {}
+ end
+
def bundler(cmd, options = {})
options["bundle_bin"] = bindir.join("bundler")
bundle(cmd, options)
@@ -171,24 +227,20 @@ module Spec
end
def sys_exec(cmd)
+ command_execution = CommandExecution.new(cmd.to_s, Dir.pwd)
+
Open3.popen3(cmd.to_s) do |stdin, stdout, stderr, wait_thr|
yield stdin, stdout, wait_thr if block_given?
stdin.close
- @exitstatus = wait_thr && wait_thr.value.exitstatus
- @out = Thread.new { stdout.read }.value.strip
- @err = Thread.new { stderr.read }.value.strip
+ command_execution.exitstatus = wait_thr && wait_thr.value.exitstatus
+ command_execution.stdout = Thread.new { stdout.read }.value.strip
+ command_execution.stderr = Thread.new { stderr.read }.value.strip
end
- (@all_output ||= String.new) << [
- "$ #{cmd.to_s.strip}",
- out,
- err,
- @exitstatus ? "# $? => #{@exitstatus}" : "",
- "\n",
- ].reject(&:empty?).join("\n")
+ (@command_executions ||= []) << command_execution
- @out
+ command_execution.stdout
end
bang :sys_exec
@@ -317,16 +369,32 @@ module Spec
end
def system_gems(*gems)
+ opts = gems.last.is_a?(Hash) ? gems.last : {}
+ path = opts.fetch(:path, system_gem_path)
+ if path == :bundle_path
+ path = ruby!(<<-RUBY)
+ require "bundler"
+ begin
+ puts Bundler.bundle_path
+ rescue Bundler::GemfileNotFound
+ ENV["BUNDLE_GEMFILE"] = "Gemfile"
+ retry
+ end
+
+ RUBY
+ end
gems = gems.flatten
- FileUtils.rm_rf(system_gem_path)
- FileUtils.mkdir_p(system_gem_path)
+ unless opts[:keep_path]
+ FileUtils.rm_rf(path)
+ FileUtils.mkdir_p(path)
+ end
Gem.clear_paths
env_backup = ENV.to_hash
- ENV["GEM_HOME"] = system_gem_path.to_s
- ENV["GEM_PATH"] = system_gem_path.to_s
+ ENV["GEM_HOME"] = path.to_s
+ ENV["GEM_PATH"] = path.to_s
ENV["BUNDLER_ORIG_GEM_PATH"] = nil
install_gems(*gems)
@@ -380,7 +448,7 @@ module Spec
def simulate_new_machine
system_gems []
- FileUtils.rm_rf default_bundle_path
+ FileUtils.rm_rf system_gem_path
FileUtils.rm_rf bundled_app(".bundle")
end
@@ -422,6 +490,14 @@ module Spec
ENV["BUNDLER_SPEC_VERSION"] = old if block_given?
end
+ def simulate_rubygems_version(version)
+ old = ENV["BUNDLER_SPEC_RUBYGEMS_VERSION"]
+ ENV["BUNDLER_SPEC_RUBYGEMS_VERSION"] = version.to_s
+ yield if block_given?
+ ensure
+ ENV["BUNDLER_SPEC_RUBYGEMS_VERSION"] = old if block_given?
+ end
+
def simulate_windows
old = ENV["BUNDLER_SPEC_WINDOWS"]
ENV["BUNDLER_SPEC_WINDOWS"] = "true"
@@ -500,5 +576,13 @@ module Spec
end
port
end
+
+ def bundler_fileutils
+ if RUBY_VERSION >= "2.4"
+ ::Bundler::FileUtils
+ else
+ ::FileUtils
+ end
+ end
end
end
diff --git a/spec/bundler/support/indexes.rb b/spec/bundler/support/indexes.rb
index 29780014fc..05605195b1 100644
--- a/spec/bundler/support/indexes.rb
+++ b/spec/bundler/support/indexes.rb
@@ -1,4 +1,5 @@
# frozen_string_literal: true
+
module Spec
module Indexes
def dep(name, reqs = nil)
@@ -16,12 +17,16 @@ module Spec
def resolve(args = [])
@platforms ||= ["ruby"]
deps = []
+ default_source = instance_double("Bundler::Source::Rubygems", :specs => @index)
+ source_requirements = { :default => default_source }
@deps.each do |d|
@platforms.each do |p|
+ source_requirements[d.name] = d.source = default_source
deps << Bundler::DepProxy.new(d, p)
end
end
- Bundler::Resolver.resolve(deps, @index, *args)
+ source_requirements ||= {}
+ Bundler::Resolver.resolve(deps, @index, source_requirements, *args)
end
def should_resolve_as(specs)
@@ -62,13 +67,16 @@ module Spec
s.level = opts.first
s.strict = opts.include?(:strict)
end
- should_resolve_and_include specs, [{}, @base, search]
+ should_resolve_and_include specs, [@base, search]
end
def an_awesome_index
build_index do
- gem "rack", %w(0.8 0.9 0.9.1 0.9.2 1.0 1.1)
- gem "rack-mount", %w(0.4 0.5 0.5.1 0.5.2 0.6)
+ gem "rack", %w[0.8 0.9 0.9.1 0.9.2 1.0 1.1]
+ gem "rack-mount", %w[0.4 0.5 0.5.1 0.5.2 0.6]
+
+ # --- Pre-release support
+ gem "rubygems\0", ["1.3.2"]
# --- Rails
versions "1.2.3 2.2.3 2.3.5 3.0.0.beta 3.0.0.beta1" do |version|
@@ -129,6 +137,14 @@ module Spec
dep "activesupport", ">= #{version}"
end
end
+
+ gem "reform", ["1.0.0"] do
+ dep "activesupport", ">= 1.0.0.beta1"
+ end
+
+ gem "need-pre", ["1.0.0"] do
+ dep "activesupport", "~> 3.0.0.beta1"
+ end
end
end
@@ -136,7 +152,7 @@ module Spec
# goes well, it should resolve to 3.0.4
def a_conflict_index
build_index do
- gem "builder", %w(3.0.4 3.1.4)
+ gem "builder", %w[3.0.4 3.1.4]
gem("grape", "0.2.6") do
dep "builder", ">= 0"
end
@@ -156,11 +172,11 @@ module Spec
def a_complex_conflict_index
build_index do
- gem("a", %w(1.0.2 1.1.4 1.2.0 1.4.0)) do
+ gem("a", %w[1.0.2 1.1.4 1.2.0 1.4.0]) do
dep "d", ">= 0"
end
- gem("d", %w(1.3.0 1.4.1)) do
+ gem("d", %w[1.3.0 1.4.1]) do
dep "x", ">= 0"
end
@@ -203,7 +219,7 @@ module Spec
def index_with_conflict_on_child
build_index do
- gem "json", %w(1.6.5 1.7.7 1.8.0)
+ gem "json", %w[1.6.5 1.7.7 1.8.0]
gem("chef", "10.26") do
dep "json", [">= 1.4.4", "<= 1.7.7"]
@@ -223,7 +239,7 @@ module Spec
# Issue #3459
def a_complicated_index
build_index do
- gem "foo", %w(3.0.0 3.0.5) do
+ gem "foo", %w[3.0.0 3.0.5] do
dep "qux", ["~> 3.1"]
dep "baz", ["< 9.0", ">= 5.0"]
dep "bar", ["~> 1.0"]
@@ -262,7 +278,7 @@ module Spec
dep "garply", [">= 0.3.1"]
end
- gem "grault", %w(2.6.3 3.1.1)
+ gem "grault", %w[2.6.3 3.1.1]
gem "garply", "0.5.1" do
dep "waldo", ["~> 0.1.3"]
@@ -272,7 +288,7 @@ module Spec
dep "plugh", ["~> 0.6.0"]
end
- gem "plugh", %w(0.6.3 0.6.11 0.7.0)
+ gem "plugh", %w[0.6.3 0.6.11 0.7.0]
gem "qux", "3.2.21" do
dep "plugh", [">= 0.6.4", "~> 0.6"]
@@ -285,7 +301,7 @@ module Spec
def a_unresovable_child_index
build_index do
- gem "json", %w(1.8.0)
+ gem "json", %w[1.8.0]
gem("chef", "10.26") do
dep "json", [">= 1.4.4", "<= 1.7.7"]
@@ -304,10 +320,10 @@ module Spec
def a_index_with_root_conflict_on_child
build_index do
- gem "builder", %w(2.1.2 3.0.1 3.1.3)
- gem "i18n", %w(0.4.1 0.4.2)
+ gem "builder", %w[2.1.2 3.0.1 3.1.3]
+ gem "i18n", %w[0.4.1 0.4.2]
- gem "activesupport", %w(3.0.0 3.0.1 3.0.5 3.1.7)
+ gem "activesupport", %w[3.0.0 3.0.1 3.0.5 3.1.7]
gem("activemodel", "3.0.5") do
dep "activesupport", "= 3.0.5"
@@ -361,5 +377,29 @@ module Spec
end
end
end
+
+ def an_ambiguous_index
+ build_index do
+ gem("a", "1.0.0") do
+ dep "c", ">= 0"
+ end
+
+ gem("b", %w[0.5.0 1.0.0])
+
+ gem("b", "2.0.0") do
+ dep "c", "< 2.0.0"
+ end
+
+ gem("c", "1.0.0") do
+ dep "d", "1.0.0"
+ end
+
+ gem("c", "2.0.0") do
+ dep "d", "2.0.0"
+ end
+
+ gem("d", %w[1.0.0 2.0.0])
+ end
+ end
end
end
diff --git a/spec/bundler/support/less_than_proc.rb b/spec/bundler/support/less_than_proc.rb
index 27966aa6ed..ddac5458b7 100644
--- a/spec/bundler/support/less_than_proc.rb
+++ b/spec/bundler/support/less_than_proc.rb
@@ -1,4 +1,5 @@
# frozen_string_literal: true
+
class LessThanProc < Proc
attr_accessor :present
diff --git a/spec/bundler/support/manpages.rb b/spec/bundler/support/manpages.rb
new file mode 100644
index 0000000000..ce1f72cc49
--- /dev/null
+++ b/spec/bundler/support/manpages.rb
@@ -0,0 +1,14 @@
+# frozen_string_literal: true
+
+module Spec
+ module Manpages
+ def self.setup
+ man_path = Spec::Path.root.join("man")
+ return if man_path.children(false).select {|file| file.extname == ".ronn" }.all? do |man|
+ Dir[man_path.join("#{man.to_s[0..-6]}*.txt").to_s].any?
+ end
+
+ system(Spec::Path.root.join("bin", "rake").to_s, "man:build") || raise("Failed building man pages")
+ end
+ end
+end
diff --git a/spec/bundler/support/matchers.rb b/spec/bundler/support/matchers.rb
index 9248360639..782257a222 100644
--- a/spec/bundler/support/matchers.rb
+++ b/spec/bundler/support/matchers.rb
@@ -1,4 +1,5 @@
# frozen_string_literal: true
+
require "forwardable"
require "support/the_bundle"
module Spec
@@ -78,7 +79,12 @@ module Spec
RSpec::Matchers.define :have_major_deprecation do |expected|
diffable
match do |actual|
- actual.split(MAJOR_DEPRECATION).any? do |d|
+ deprecations = actual.split(MAJOR_DEPRECATION)
+
+ return !expected.nil? if deprecations.size <= 1
+ return true if expected.nil?
+
+ deprecations.any? do |d|
!d.empty? && values_match?(expected, d.strip)
end
end
@@ -108,6 +114,20 @@ module Spec
end
end
+ RSpec::Matchers.define :be_sorted do
+ diffable
+ attr_reader :expected
+ match do |actual|
+ expected = block_arg ? actual.sort_by(&block_arg) : actual.sort
+ actual.==(expected).tap do
+ # HACK: since rspec won't show a diff when everything is a string
+ differ = RSpec::Support::Differ.new
+ @actual = differ.send(:object_to_string, actual)
+ @expected = differ.send(:object_to_string, expected)
+ end
+ end
+ end
+
define_compound_matcher :read_as, [exist] do |file_contents|
diffable
@@ -135,8 +155,8 @@ module Spec
rescue => e
next "#{name} is not installed:\n#{indent(e)}"
end
- out.gsub!(/#{MAJOR_DEPRECATION}.*$/, "")
- actual_version, actual_platform = out.strip.split(/\s+/, 2)
+ last_command.stdout.gsub!(/#{MAJOR_DEPRECATION}.*$/, "")
+ actual_version, actual_platform = last_command.stdout.strip.split(/\s+/, 2)
unless Gem::Version.new(actual_version) == Gem::Version.new(version)
next "#{name} was expected to be at version #{version} but was #{actual_version}"
end
@@ -150,8 +170,8 @@ module Spec
rescue
next "#{name} does not have a source defined:\n#{indent(e)}"
end
- out.gsub!(/#{MAJOR_DEPRECATION}.*$/, "")
- unless out.strip == source
+ last_command.stdout.gsub!(/#{MAJOR_DEPRECATION}.*$/, "")
+ unless last_command.stdout.strip == source
next "Expected #{name} (#{version}) to be installed from `#{source}`, was actually from `#{out}`"
end
end.compact
@@ -176,9 +196,9 @@ module Spec
rescue => e
next "checking for #{name} failed:\n#{e}"
end
- next if out == "WIN"
+ next if last_command.stdout == "WIN"
next "expected #{name} to not be installed, but it was" if version.nil?
- if Gem::Version.new(out) == Gem::Version.new(version)
+ if Gem::Version.new(last_command.stdout) == Gem::Version.new(version)
next "expected #{name} (#{version}) not to be installed, but it was"
end
end.compact
diff --git a/spec/bundler/support/path.rb b/spec/bundler/support/path.rb
index b58658e71a..17868b17d1 100644
--- a/spec/bundler/support/path.rb
+++ b/spec/bundler/support/path.rb
@@ -1,4 +1,5 @@
# frozen_string_literal: true
+
require "pathname"
module Spec
@@ -29,7 +30,11 @@ module Spec
end
def default_bundle_path(*path)
- system_gem_path(*path)
+ if Bundler::VERSION.split(".").first.to_i < 2
+ system_gem_path(*path)
+ else
+ bundled_app(*[".bundle", ENV.fetch("BUNDLER_SPEC_RUBY_ENGINE", Gem.ruby_engine), Gem::ConfigMap[:ruby_version], *path].compact)
+ end
end
def bundled_app(*path)
@@ -110,6 +115,9 @@ module Spec
private
def for_ruby_core?
+ # avoid to wornings
+ @for_ruby_core ||= nil
+
if @for_ruby_core.nil?
@for_ruby_core = true & (ENV["BUNDLE_RUBY"] && ENV["BUNDLE_GEM"])
else
diff --git a/spec/bundler/support/permissions.rb b/spec/bundler/support/permissions.rb
index f5636dd70a..b21ce3848d 100644
--- a/spec/bundler/support/permissions.rb
+++ b/spec/bundler/support/permissions.rb
@@ -1,4 +1,5 @@
# frozen_string_literal: true
+
module Spec
module Permissions
def with_umask(new_umask)
diff --git a/spec/bundler/support/platforms.rb b/spec/bundler/support/platforms.rb
index a2a3afba00..002350114b 100644
--- a/spec/bundler/support/platforms.rb
+++ b/spec/bundler/support/platforms.rb
@@ -1,4 +1,5 @@
# frozen_string_literal: true
+
module Spec
module Platforms
include Bundler::GemHelpers
@@ -43,6 +44,10 @@ module Spec
generic_local_platform
end
+ def specific_local_platform
+ Bundler.local_platform
+ end
+
def not_local
all_platforms.find {|p| p != generic_local_platform }
end
@@ -94,5 +99,18 @@ module Spec
def not_local_patchlevel
9999
end
+
+ def lockfile_platforms(*platforms)
+ platforms = local_platforms if platforms.empty?
+ platforms.map(&:to_s).sort.join("\n ")
+ end
+
+ def local_platforms
+ if Bundler::VERSION.split(".").first.to_i > 1
+ [local, specific_local_platform]
+ else
+ [local]
+ end
+ end
end
end
diff --git a/spec/bundler/support/rubygems_ext.rb b/spec/bundler/support/rubygems_ext.rb
index 596e1530d2..73e90f6883 100644
--- a/spec/bundler/support/rubygems_ext.rb
+++ b/spec/bundler/support/rubygems_ext.rb
@@ -1,4 +1,5 @@
# frozen_string_literal: true
+
require "rubygems/user_interaction"
require "support/path" unless defined?(Spec::Path)
@@ -8,7 +9,9 @@ module Spec
deps = {
# rack 2.x requires Ruby version >= 2.2.2.
# artifice doesn't support rack 2.x now.
- "rack" => "< 2",
+ # TODO: revert to `< 2` once https://github.com/rack/rack/issues/1168 is
+ # addressed
+ "rack" => "1.6.6",
# rack-test 0.7.0 dropped 1.8.7 support
# https://github.com/rack-test/rack-test/issues/193#issuecomment-314230318
"rack-test" => "< 0.7.0",
@@ -19,7 +22,6 @@ module Spec
"rake" => "10.0.2",
# 3.0.0 breaks 1.9.2 specs
"builder" => "2.1.2",
- "bundler" => "1.12.0",
}
# ruby-graphviz is used by the viz tests
deps["ruby-graphviz"] = nil if RUBY_VERSION >= "1.9.3"
diff --git a/spec/bundler/support/silent_logger.rb b/spec/bundler/support/silent_logger.rb
index 1a8f91b3ba..8665beb2c9 100644
--- a/spec/bundler/support/silent_logger.rb
+++ b/spec/bundler/support/silent_logger.rb
@@ -1,4 +1,5 @@
# frozen_string_literal: true
+
require "logger"
module Spec
class SilentLogger
diff --git a/spec/bundler/support/sometimes.rb b/spec/bundler/support/sometimes.rb
index 6a50f5ff4c..65a95ed59c 100644
--- a/spec/bundler/support/sometimes.rb
+++ b/spec/bundler/support/sometimes.rb
@@ -1,4 +1,5 @@
# frozen_string_literal: true
+
module Sometimes
def run_with_retries(example_to_run, retries)
example = RSpec.current_example
diff --git a/spec/bundler/support/streams.rb b/spec/bundler/support/streams.rb
index 561b29092b..b9e1d292dc 100644
--- a/spec/bundler/support/streams.rb
+++ b/spec/bundler/support/streams.rb
@@ -1,4 +1,5 @@
# frozen_string_literal: true
+
require "stringio"
def capture(*streams)
diff --git a/spec/bundler/support/sudo.rb b/spec/bundler/support/sudo.rb
index 8c82bb8c0f..04e9443945 100644
--- a/spec/bundler/support/sudo.rb
+++ b/spec/bundler/support/sudo.rb
@@ -1,4 +1,5 @@
# frozen_string_literal: true
+
module Spec
module Sudo
def self.present?
diff --git a/spec/bundler/support/the_bundle.rb b/spec/bundler/support/the_bundle.rb
index 742d393425..c994eaae78 100644
--- a/spec/bundler/support/the_bundle.rb
+++ b/spec/bundler/support/the_bundle.rb
@@ -1,4 +1,5 @@
# frozen_string_literal: true
+
require "support/helpers"
require "support/path"
diff --git a/spec/bundler/update/gems/post_install_spec.rb b/spec/bundler/update/gems/post_install_spec.rb
index 5a4fe7f321..2fb3547806 100644
--- a/spec/bundler/update/gems/post_install_spec.rb
+++ b/spec/bundler/update/gems/post_install_spec.rb
@@ -1,5 +1,4 @@
# frozen_string_literal: true
-require "spec_helper"
RSpec.describe "bundle update" do
let(:config) {}
@@ -53,7 +52,7 @@ RSpec.describe "bundle update" do
gem 'thin'
G
- bundle! :update
+ bundle! :update, :all => bundle_update_requires_all?
end
it_behaves_like "a post-install message outputter"
@@ -68,7 +67,7 @@ RSpec.describe "bundle update" do
gem 'thin'
G
- bundle! :update
+ bundle! :update, :all => bundle_update_requires_all?
end
it_behaves_like "a post-install message outputter"
diff --git a/spec/bundler/update/git_spec.rb b/spec/bundler/update/git_spec.rb
index 021c8c942b..52c4fc0957 100644
--- a/spec/bundler/update/git_spec.rb
+++ b/spec/bundler/update/git_spec.rb
@@ -1,5 +1,4 @@
# frozen_string_literal: true
-require "spec_helper"
RSpec.describe "bundle update" do
describe "git sources" do
@@ -17,7 +16,7 @@ RSpec.describe "bundle update" do
s.write "lib/foo.rb", "FOO = '1.1'"
end
- bundle "update"
+ bundle "update", :all => bundle_update_requires_all?
expect(the_bundle).to include_gems "foo 1.1"
end
@@ -28,12 +27,11 @@ RSpec.describe "bundle update" do
s.add_dependency "activesupport", "= 3.0"
end
- install_gemfile <<-G
+ install_gemfile! <<-G
gem "rails", :git => "#{lib_path("rails")}"
G
- bundle "update rails"
- expect(out).to include("Using activesupport 3.0 from #{lib_path("rails")} (at master@#{revision_for(lib_path("rails"))[0..6]})")
+ bundle! "update rails"
expect(the_bundle).to include_gems "rails 3.0", "activesupport 3.0"
end
@@ -58,7 +56,7 @@ RSpec.describe "bundle update" do
it "floats on master when updating all gems that are pinned to the source even if you have child dependencies" do
build_git "foo", :path => lib_path("foo")
- build_gem "bar", :to_system => true do |s|
+ build_gem "bar", :to_bundle => true do |s|
s.add_dependency "foo"
end
@@ -113,14 +111,16 @@ RSpec.describe "bundle update" do
gem 'foo', :git => "#{@remote.path}", :tag => "fubar"
G
- bundle "update"
+ bundle "update", :all => bundle_update_requires_all?
expect(exitstatus).to eq(0) if exitstatus
end
describe "with submodules" do
before :each do
- build_gem "submodule", :to_system => true do |s|
- s.write "lib/submodule.rb", "puts 'GEM'"
+ build_repo4 do
+ build_gem "submodule" do |s|
+ s.write "lib/submodule.rb", "puts 'GEM'"
+ end
end
build_git "submodule", "1.0" do |s|
@@ -139,6 +139,7 @@ RSpec.describe "bundle update" do
it "it unlocks the source when submodules are added to a git source" do
install_gemfile <<-G
+ source "file:#{gem_repo4}"
git "#{lib_path("has_submodule-1.0")}" do
gem "has_submodule"
end
@@ -148,6 +149,7 @@ RSpec.describe "bundle update" do
expect(out).to eq("GEM")
install_gemfile <<-G
+ source "file:#{gem_repo4}"
git "#{lib_path("has_submodule-1.0")}", :submodules => true do
gem "has_submodule"
end
@@ -158,22 +160,24 @@ RSpec.describe "bundle update" do
end
it "unlocks the source when submodules are removed from git source", :git => ">= 2.9.0" do
- install_gemfile <<-G
+ install_gemfile! <<-G
+ source "file:#{gem_repo4}"
git "#{lib_path("has_submodule-1.0")}", :submodules => true do
gem "has_submodule"
end
G
- run "require 'submodule'"
+ run! "require 'submodule'"
expect(out).to eq("GIT")
- install_gemfile <<-G
+ install_gemfile! <<-G
+ source "file:#{gem_repo4}"
git "#{lib_path("has_submodule-1.0")}" do
gem "has_submodule"
end
G
- run "require 'submodule'"
+ run! "require 'submodule'"
expect(out).to eq("GEM")
end
end
@@ -187,8 +191,9 @@ RSpec.describe "bundle update" do
lib_path("foo-1.0").join(".git").rmtree
- bundle :update
- expect(out).to include(lib_path("foo-1.0").to_s)
+ bundle :update, :all => bundle_update_requires_all?
+ expect(last_command.bundler_err).to include(lib_path("foo-1.0").to_s).
+ and match(/Git error: command `git fetch.+has failed/)
end
it "should not explode on invalid revision on update of gem by name" do
@@ -228,7 +233,7 @@ RSpec.describe "bundle update" do
rails!
G
- bundle "update"
+ bundle "update", :all => bundle_update_requires_all?
expect(out).to include("Using rails 3.0 (was 2.3.2) from #{lib_path("rails")} (at master@#{revision_for(lib_path("rails"))[0..6]})")
end
end
@@ -294,7 +299,7 @@ RSpec.describe "bundle update" do
G
end
- it "the --source flag updates version of gems that were originally pulled in by the source" do
+ it "the --source flag updates version of gems that were originally pulled in by the source", :bundler => "< 2" do
spec_lines = lib_path("bar/foo.gemspec").read.split("\n")
spec_lines[5] = "s.version = '2.0'"
@@ -329,5 +334,41 @@ RSpec.describe "bundle update" do
#{Bundler::VERSION}
G
end
+
+ it "the --source flag updates version of gems that were originally pulled in by the source", :bundler => "2" do
+ spec_lines = lib_path("bar/foo.gemspec").read.split("\n")
+ spec_lines[5] = "s.version = '2.0'"
+
+ update_git "foo", "2.0", :path => @git.path do |s|
+ s.write "foo.gemspec", spec_lines.join("\n")
+ end
+
+ ref = @git.ref_for "master"
+
+ bundle "update --source bar"
+
+ lockfile_should_be <<-G
+ GEM
+ remote: file:#{gem_repo2}/
+ specs:
+ rack (1.0.0)
+
+ GIT
+ remote: #{@git.path}
+ revision: #{ref}
+ specs:
+ foo (2.0)
+
+ PLATFORMS
+ #{lockfile_platforms}
+
+ DEPENDENCIES
+ foo!
+ rack
+
+ BUNDLED WITH
+ #{Bundler::VERSION}
+ G
+ end
end
end
diff --git a/spec/bundler/update/path_spec.rb b/spec/bundler/update/path_spec.rb
index 5ac4f7b1fe..38c125e04b 100644
--- a/spec/bundler/update/path_spec.rb
+++ b/spec/bundler/update/path_spec.rb
@@ -1,5 +1,4 @@
# frozen_string_literal: true
-require "spec_helper"
RSpec.describe "path sources" do
describe "bundle update --source" do