cloudsmith-api 0.51.34 → 0.52.5
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/Gemfile.lock +3 -3
- data/README.md +14 -5
- data/build.json +1 -1
- data/docs/AlpinePackageUpload.md +63 -0
- data/docs/ConanPackageUpload.md +1 -0
- data/docs/EntitlementsCreate.md +1 -1
- data/docs/EntitlementsPartialUpdate.md +1 -1
- data/docs/EntitlementsRefresh.md +1 -1
- data/docs/MavenPackageUpload.md +1 -0
- data/docs/Package.md +2 -0
- data/docs/PackageCopy.md +2 -0
- data/docs/PackageMove.md +2 -0
- data/docs/PackagesApi.md +238 -39
- data/docs/PackagesCopy.md +1 -1
- data/docs/PackagesMove.md +0 -1
- data/docs/PackagesTag.md +10 -0
- data/docs/PackagesUploadAlpine.md +1 -0
- data/docs/PackagesUploadCargo.md +1 -0
- data/docs/PackagesUploadCocoapods.md +1 -0
- data/docs/PackagesUploadComposer.md +1 -0
- data/docs/PackagesUploadConan.md +3 -0
- data/docs/PackagesUploadCran.md +1 -0
- data/docs/PackagesUploadDart.md +1 -0
- data/docs/PackagesUploadDeb.md +3 -0
- data/docs/PackagesUploadDocker.md +1 -0
- data/docs/PackagesUploadGo.md +1 -0
- data/docs/PackagesUploadHelm.md +1 -0
- data/docs/PackagesUploadLuarocks.md +1 -0
- data/docs/PackagesUploadMaven.md +1 -0
- data/docs/PackagesUploadNpm.md +1 -0
- data/docs/PackagesUploadNuget.md +1 -0
- data/docs/PackagesUploadPython.md +1 -0
- data/docs/PackagesUploadRaw.md +1 -0
- data/docs/PackagesUploadRpm.md +1 -0
- data/docs/PackagesUploadRuby.md +1 -0
- data/docs/{PackagesResync.md → PackagesUploadTerraform.md} +3 -1
- data/docs/PackagesUploadVagrant.md +1 -0
- data/docs/PackagesValidateuploadAlpine.md +1 -0
- data/docs/PackagesValidateuploadCargo.md +1 -0
- data/docs/PackagesValidateuploadCocoapods.md +1 -0
- data/docs/PackagesValidateuploadComposer.md +1 -0
- data/docs/PackagesValidateuploadConan.md +3 -0
- data/docs/PackagesValidateuploadCran.md +1 -0
- data/docs/PackagesValidateuploadDart.md +1 -0
- data/docs/PackagesValidateuploadDeb.md +3 -0
- data/docs/PackagesValidateuploadDocker.md +1 -0
- data/docs/PackagesValidateuploadGo.md +1 -0
- data/docs/PackagesValidateuploadHelm.md +1 -0
- data/docs/PackagesValidateuploadLuarocks.md +1 -0
- data/docs/PackagesValidateuploadMaven.md +1 -0
- data/docs/PackagesValidateuploadNpm.md +1 -0
- data/docs/PackagesValidateuploadNuget.md +1 -0
- data/docs/PackagesValidateuploadPython.md +1 -0
- data/docs/PackagesValidateuploadRaw.md +1 -0
- data/docs/PackagesValidateuploadRpm.md +1 -0
- data/docs/PackagesValidateuploadRuby.md +1 -0
- data/docs/PackagesValidateuploadTerraform.md +10 -0
- data/docs/PackagesValidateuploadVagrant.md +1 -0
- data/docs/RawPackageUpload.md +1 -0
- data/docs/ReposCreate.md +4 -7
- data/docs/ReposPartialUpdate.md +3 -7
- data/docs/Repository.md +11 -10
- data/docs/RepositoryToken.md +3 -3
- data/docs/RepositoryTokenRefresh.md +3 -3
- data/docs/RepositoryTokenSyncTokens.md +3 -3
- data/docs/RepositoryWebhook.md +1 -0
- data/docs/StorageRegion.md +9 -0
- data/docs/StorageregionsApi.md +122 -0
- data/docs/VagrantPackageUpload.md +1 -0
- data/docs/WebhooksCreate.md +1 -0
- data/docs/WebhooksPartialUpdate.md +1 -0
- data/lib/cloudsmith-api.rb +6 -1
- data/lib/cloudsmith-api/api/packages_api.rb +237 -53
- data/lib/cloudsmith-api/api/storageregions_api.rb +119 -0
- data/lib/cloudsmith-api/models/alpine_package_upload.rb +743 -0
- data/lib/cloudsmith-api/models/conan_package_upload.rb +11 -1
- data/lib/cloudsmith-api/models/entitlements_create.rb +1 -1
- data/lib/cloudsmith-api/models/entitlements_partial_update.rb +1 -1
- data/lib/cloudsmith-api/models/entitlements_refresh.rb +1 -1
- data/lib/cloudsmith-api/models/maven_package_upload.rb +11 -1
- data/lib/cloudsmith-api/models/package.rb +21 -1
- data/lib/cloudsmith-api/models/package_copy.rb +21 -1
- data/lib/cloudsmith-api/models/package_move.rb +21 -1
- data/lib/cloudsmith-api/models/packages_copy.rb +1 -1
- data/lib/cloudsmith-api/models/packages_move.rb +4 -14
- data/lib/cloudsmith-api/models/packages_tag.rb +211 -0
- data/lib/cloudsmith-api/models/packages_upload_alpine.rb +14 -4
- data/lib/cloudsmith-api/models/packages_upload_cargo.rb +14 -4
- data/lib/cloudsmith-api/models/packages_upload_cocoapods.rb +14 -4
- data/lib/cloudsmith-api/models/packages_upload_composer.rb +14 -4
- data/lib/cloudsmith-api/models/packages_upload_conan.rb +34 -4
- data/lib/cloudsmith-api/models/packages_upload_cran.rb +14 -4
- data/lib/cloudsmith-api/models/packages_upload_dart.rb +14 -4
- data/lib/cloudsmith-api/models/packages_upload_deb.rb +34 -4
- data/lib/cloudsmith-api/models/packages_upload_docker.rb +14 -4
- data/lib/cloudsmith-api/models/packages_upload_go.rb +14 -4
- data/lib/cloudsmith-api/models/packages_upload_helm.rb +14 -4
- data/lib/cloudsmith-api/models/packages_upload_luarocks.rb +14 -4
- data/lib/cloudsmith-api/models/packages_upload_maven.rb +11 -1
- data/lib/cloudsmith-api/models/packages_upload_npm.rb +14 -4
- data/lib/cloudsmith-api/models/packages_upload_nuget.rb +14 -4
- data/lib/cloudsmith-api/models/packages_upload_python.rb +14 -4
- data/lib/cloudsmith-api/models/packages_upload_raw.rb +11 -1
- data/lib/cloudsmith-api/models/packages_upload_rpm.rb +14 -4
- data/lib/cloudsmith-api/models/packages_upload_ruby.rb +14 -4
- data/lib/cloudsmith-api/models/packages_upload_terraform.rb +214 -0
- data/lib/cloudsmith-api/models/packages_upload_vagrant.rb +11 -1
- data/lib/cloudsmith-api/models/packages_validateupload_alpine.rb +14 -4
- data/lib/cloudsmith-api/models/packages_validateupload_cargo.rb +14 -4
- data/lib/cloudsmith-api/models/packages_validateupload_cocoapods.rb +14 -4
- data/lib/cloudsmith-api/models/packages_validateupload_composer.rb +14 -4
- data/lib/cloudsmith-api/models/packages_validateupload_conan.rb +34 -4
- data/lib/cloudsmith-api/models/packages_validateupload_cran.rb +14 -4
- data/lib/cloudsmith-api/models/packages_validateupload_dart.rb +14 -4
- data/lib/cloudsmith-api/models/packages_validateupload_deb.rb +34 -4
- data/lib/cloudsmith-api/models/packages_validateupload_docker.rb +14 -4
- data/lib/cloudsmith-api/models/packages_validateupload_go.rb +14 -4
- data/lib/cloudsmith-api/models/packages_validateupload_helm.rb +14 -4
- data/lib/cloudsmith-api/models/packages_validateupload_luarocks.rb +14 -4
- data/lib/cloudsmith-api/models/packages_validateupload_maven.rb +11 -1
- data/lib/cloudsmith-api/models/packages_validateupload_npm.rb +14 -4
- data/lib/cloudsmith-api/models/packages_validateupload_nuget.rb +14 -4
- data/lib/cloudsmith-api/models/packages_validateupload_python.rb +14 -4
- data/lib/cloudsmith-api/models/packages_validateupload_raw.rb +11 -1
- data/lib/cloudsmith-api/models/packages_validateupload_rpm.rb +14 -4
- data/lib/cloudsmith-api/models/packages_validateupload_ruby.rb +14 -4
- data/lib/cloudsmith-api/models/packages_validateupload_terraform.rb +214 -0
- data/lib/cloudsmith-api/models/packages_validateupload_vagrant.rb +11 -1
- data/lib/cloudsmith-api/models/raw_package_upload.rb +11 -1
- data/lib/cloudsmith-api/models/repos_create.rb +17 -57
- data/lib/cloudsmith-api/models/repos_partial_update.rb +4 -44
- data/lib/cloudsmith-api/models/repository.rb +24 -24
- data/lib/cloudsmith-api/models/repository_token.rb +3 -3
- data/lib/cloudsmith-api/models/repository_token_refresh.rb +3 -3
- data/lib/cloudsmith-api/models/repository_token_sync_tokens.rb +3 -3
- data/lib/cloudsmith-api/models/repository_webhook.rb +11 -1
- data/lib/cloudsmith-api/models/{packages_resync.rb → storage_region.rb} +29 -9
- data/lib/cloudsmith-api/models/vagrant_package_upload.rb +11 -1
- data/lib/cloudsmith-api/models/webhooks_create.rb +11 -1
- data/lib/cloudsmith-api/models/webhooks_partial_update.rb +11 -1
- data/lib/cloudsmith-api/version.rb +1 -1
- data/spec/api/packages_api_spec.rb +59 -17
- data/spec/api/storageregions_api_spec.rb +58 -0
- data/spec/models/alpine_package_upload_spec.rb +372 -0
- data/spec/models/conan_package_upload_spec.rb +6 -0
- data/spec/models/maven_package_upload_spec.rb +6 -0
- data/spec/models/package_copy_spec.rb +12 -0
- data/spec/models/package_move_spec.rb +12 -0
- data/spec/models/package_spec.rb +12 -0
- data/spec/models/packages_move_spec.rb +0 -6
- data/spec/models/packages_tag_spec.rb +54 -0
- data/spec/models/packages_upload_alpine_spec.rb +6 -0
- data/spec/models/packages_upload_cargo_spec.rb +6 -0
- data/spec/models/packages_upload_cocoapods_spec.rb +6 -0
- data/spec/models/packages_upload_composer_spec.rb +6 -0
- data/spec/models/packages_upload_conan_spec.rb +18 -0
- data/spec/models/packages_upload_cran_spec.rb +6 -0
- data/spec/models/packages_upload_dart_spec.rb +6 -0
- data/spec/models/packages_upload_deb_spec.rb +18 -0
- data/spec/models/packages_upload_docker_spec.rb +6 -0
- data/spec/models/packages_upload_go_spec.rb +6 -0
- data/spec/models/packages_upload_helm_spec.rb +6 -0
- data/spec/models/packages_upload_luarocks_spec.rb +6 -0
- data/spec/models/packages_upload_maven_spec.rb +6 -0
- data/spec/models/packages_upload_npm_spec.rb +6 -0
- data/spec/models/packages_upload_nuget_spec.rb +6 -0
- data/spec/models/packages_upload_python_spec.rb +6 -0
- data/spec/models/packages_upload_raw_spec.rb +6 -0
- data/spec/models/packages_upload_rpm_spec.rb +6 -0
- data/spec/models/packages_upload_ruby_spec.rb +6 -0
- data/spec/models/packages_upload_terraform_spec.rb +54 -0
- data/spec/models/packages_upload_vagrant_spec.rb +6 -0
- data/spec/models/packages_validateupload_alpine_spec.rb +6 -0
- data/spec/models/packages_validateupload_cargo_spec.rb +6 -0
- data/spec/models/packages_validateupload_cocoapods_spec.rb +6 -0
- data/spec/models/packages_validateupload_composer_spec.rb +6 -0
- data/spec/models/packages_validateupload_conan_spec.rb +18 -0
- data/spec/models/packages_validateupload_cran_spec.rb +6 -0
- data/spec/models/packages_validateupload_dart_spec.rb +6 -0
- data/spec/models/packages_validateupload_deb_spec.rb +18 -0
- data/spec/models/packages_validateupload_docker_spec.rb +6 -0
- data/spec/models/packages_validateupload_go_spec.rb +6 -0
- data/spec/models/packages_validateupload_helm_spec.rb +6 -0
- data/spec/models/packages_validateupload_luarocks_spec.rb +6 -0
- data/spec/models/packages_validateupload_maven_spec.rb +6 -0
- data/spec/models/packages_validateupload_npm_spec.rb +6 -0
- data/spec/models/packages_validateupload_nuget_spec.rb +6 -0
- data/spec/models/packages_validateupload_python_spec.rb +6 -0
- data/spec/models/packages_validateupload_raw_spec.rb +6 -0
- data/spec/models/packages_validateupload_rpm_spec.rb +6 -0
- data/spec/models/packages_validateupload_ruby_spec.rb +6 -0
- data/spec/models/packages_validateupload_terraform_spec.rb +54 -0
- data/spec/models/packages_validateupload_vagrant_spec.rb +6 -0
- data/spec/models/raw_package_upload_spec.rb +6 -0
- data/spec/models/repos_create_spec.rb +3 -21
- data/spec/models/repos_partial_update_spec.rb +0 -24
- data/spec/models/repository_spec.rb +6 -0
- data/spec/models/repository_webhook_spec.rb +6 -0
- data/spec/models/{packages_resync_spec.rb → storage_region_spec.rb} +13 -7
- data/spec/models/vagrant_package_upload_spec.rb +6 -0
- data/spec/models/webhooks_create_spec.rb +6 -0
- data/spec/models/webhooks_partial_update_spec.rb +6 -0
- data/vendor/bundle/ruby/2.6.0/cache/diff-lcs-1.4.4.gem +0 -0
- data/vendor/bundle/ruby/2.6.0/cache/json-2.3.1.gem +0 -0
- data/vendor/bundle/ruby/2.6.0/extensions/x86_64-linux/2.6.0/autotest-fsevent-0.2.17/gem_make.out +1 -1
- data/vendor/bundle/ruby/2.6.0/extensions/x86_64-linux/2.6.0/ffi-1.13.1/gem_make.out +2 -2
- data/vendor/bundle/ruby/2.6.0/extensions/x86_64-linux/2.6.0/{json-2.3.0 → json-2.3.1}/gem.build_complete +0 -0
- data/vendor/bundle/ruby/2.6.0/extensions/x86_64-linux/2.6.0/{json-2.3.0 → json-2.3.1}/gem_make.out +5 -5
- data/vendor/bundle/ruby/2.6.0/extensions/x86_64-linux/2.6.0/json-2.3.1/json/ext/generator.so +0 -0
- data/vendor/bundle/ruby/2.6.0/extensions/x86_64-linux/2.6.0/json-2.3.1/json/ext/parser.so +0 -0
- data/vendor/bundle/ruby/2.6.0/extensions/x86_64-linux/2.6.0/{json-2.3.0 → json-2.3.1}/mkmf.log +0 -0
- data/vendor/bundle/ruby/2.6.0/gems/{diff-lcs-1.3 → diff-lcs-1.4.4}/.rspec +0 -0
- data/vendor/bundle/ruby/2.6.0/gems/{diff-lcs-1.3 → diff-lcs-1.4.4}/Code-of-Conduct.md +0 -0
- data/vendor/bundle/ruby/2.6.0/gems/diff-lcs-1.4.4/Contributing.md +118 -0
- data/vendor/bundle/ruby/2.6.0/gems/diff-lcs-1.4.4/History.md +319 -0
- data/vendor/bundle/ruby/2.6.0/gems/{diff-lcs-1.3 → diff-lcs-1.4.4}/License.md +0 -0
- data/vendor/bundle/ruby/2.6.0/gems/{diff-lcs-1.3 → diff-lcs-1.4.4}/Manifest.txt +8 -0
- data/vendor/bundle/ruby/2.6.0/gems/{diff-lcs-1.3 → diff-lcs-1.4.4}/README.rdoc +10 -10
- data/vendor/bundle/ruby/2.6.0/gems/{diff-lcs-1.3 → diff-lcs-1.4.4}/Rakefile +39 -22
- data/vendor/bundle/ruby/2.6.0/gems/diff-lcs-1.4.4/autotest/discover.rb +3 -0
- data/vendor/bundle/ruby/2.6.0/gems/{diff-lcs-1.3 → diff-lcs-1.4.4}/bin/htmldiff +7 -4
- data/vendor/bundle/ruby/2.6.0/gems/{diff-lcs-1.3 → diff-lcs-1.4.4}/bin/ldiff +4 -1
- data/vendor/bundle/ruby/2.6.0/gems/{diff-lcs-1.3 → diff-lcs-1.4.4}/docs/COPYING.txt +0 -0
- data/vendor/bundle/ruby/2.6.0/gems/{diff-lcs-1.3 → diff-lcs-1.4.4}/docs/artistic.txt +0 -0
- data/vendor/bundle/ruby/2.6.0/gems/diff-lcs-1.4.4/lib/diff-lcs.rb +3 -0
- data/vendor/bundle/ruby/2.6.0/gems/{diff-lcs-1.3 → diff-lcs-1.4.4}/lib/diff/lcs.rb +184 -170
- data/vendor/bundle/ruby/2.6.0/gems/{diff-lcs-1.3 → diff-lcs-1.4.4}/lib/diff/lcs/array.rb +1 -1
- data/vendor/bundle/ruby/2.6.0/gems/diff-lcs-1.4.4/lib/diff/lcs/backports.rb +9 -0
- data/vendor/bundle/ruby/2.6.0/gems/{diff-lcs-1.3 → diff-lcs-1.4.4}/lib/diff/lcs/block.rb +1 -1
- data/vendor/bundle/ruby/2.6.0/gems/{diff-lcs-1.3 → diff-lcs-1.4.4}/lib/diff/lcs/callbacks.rb +15 -12
- data/vendor/bundle/ruby/2.6.0/gems/{diff-lcs-1.3 → diff-lcs-1.4.4}/lib/diff/lcs/change.rb +30 -37
- data/vendor/bundle/ruby/2.6.0/gems/{diff-lcs-1.3 → diff-lcs-1.4.4}/lib/diff/lcs/htmldiff.rb +17 -16
- data/vendor/bundle/ruby/2.6.0/gems/{diff-lcs-1.3 → diff-lcs-1.4.4}/lib/diff/lcs/hunk.rb +156 -74
- data/vendor/bundle/ruby/2.6.0/gems/{diff-lcs-1.3 → diff-lcs-1.4.4}/lib/diff/lcs/internals.rb +36 -39
- data/vendor/bundle/ruby/2.6.0/gems/{diff-lcs-1.3 → diff-lcs-1.4.4}/lib/diff/lcs/ldiff.rb +46 -42
- data/vendor/bundle/ruby/2.6.0/gems/{diff-lcs-1.3 → diff-lcs-1.4.4}/lib/diff/lcs/string.rb +1 -1
- data/vendor/bundle/ruby/2.6.0/gems/{diff-lcs-1.3 → diff-lcs-1.4.4}/spec/change_spec.rb +31 -7
- data/vendor/bundle/ruby/2.6.0/gems/{diff-lcs-1.3/spec/ldiff_spec.rb → diff-lcs-1.4.4/spec/diff_spec.rb} +15 -11
- data/vendor/bundle/ruby/2.6.0/gems/diff-lcs-1.4.4/spec/fixtures/aX +1 -0
- data/vendor/bundle/ruby/2.6.0/gems/diff-lcs-1.4.4/spec/fixtures/bXaX +1 -0
- data/vendor/bundle/ruby/2.6.0/gems/{diff-lcs-1.3 → diff-lcs-1.4.4}/spec/fixtures/ds1.csv +0 -0
- data/vendor/bundle/ruby/2.6.0/gems/{diff-lcs-1.3 → diff-lcs-1.4.4}/spec/fixtures/ds2.csv +0 -0
- data/vendor/bundle/ruby/2.6.0/gems/diff-lcs-1.4.4/spec/fixtures/ldiff/output.diff +4 -0
- data/vendor/bundle/ruby/2.6.0/gems/diff-lcs-1.4.4/spec/fixtures/ldiff/output.diff-c +7 -0
- data/vendor/bundle/ruby/2.6.0/gems/diff-lcs-1.4.4/spec/fixtures/ldiff/output.diff-e +3 -0
- data/vendor/bundle/ruby/2.6.0/gems/diff-lcs-1.4.4/spec/fixtures/ldiff/output.diff-f +3 -0
- data/vendor/bundle/ruby/2.6.0/gems/diff-lcs-1.4.4/spec/fixtures/ldiff/output.diff-u +5 -0
- data/vendor/bundle/ruby/2.6.0/gems/diff-lcs-1.4.4/spec/hunk_spec.rb +83 -0
- data/vendor/bundle/ruby/2.6.0/gems/diff-lcs-1.4.4/spec/issues_spec.rb +154 -0
- data/vendor/bundle/ruby/2.6.0/gems/{diff-lcs-1.3 → diff-lcs-1.4.4}/spec/lcs_spec.rb +10 -10
- data/vendor/bundle/ruby/2.6.0/gems/diff-lcs-1.4.4/spec/ldiff_spec.rb +87 -0
- data/vendor/bundle/ruby/2.6.0/gems/{diff-lcs-1.3 → diff-lcs-1.4.4}/spec/patch_spec.rb +93 -99
- data/vendor/bundle/ruby/2.6.0/gems/diff-lcs-1.4.4/spec/sdiff_spec.rb +214 -0
- data/vendor/bundle/ruby/2.6.0/gems/{diff-lcs-1.3 → diff-lcs-1.4.4}/spec/spec_helper.rb +118 -64
- data/vendor/bundle/ruby/2.6.0/gems/diff-lcs-1.4.4/spec/traverse_balanced_spec.rb +310 -0
- data/vendor/bundle/ruby/2.6.0/gems/{diff-lcs-1.3 → diff-lcs-1.4.4}/spec/traverse_sequences_spec.rb +28 -28
- data/vendor/bundle/ruby/2.6.0/gems/ffi-1.13.1/ext/ffi_c/Makefile +3 -3
- data/vendor/bundle/ruby/2.6.0/gems/{json-2.3.0 → json-2.3.1}/.gitignore +0 -0
- data/vendor/bundle/ruby/2.6.0/gems/{json-2.3.0 → json-2.3.1}/.travis.yml +2 -0
- data/vendor/bundle/ruby/2.6.0/gems/{json-2.3.0 → json-2.3.1}/CHANGES.md +33 -0
- data/vendor/bundle/ruby/2.6.0/gems/{json-2.3.0 → json-2.3.1}/Gemfile +0 -0
- data/vendor/bundle/ruby/2.6.0/gems/{json-2.3.0 → json-2.3.1}/README-json-jruby.md +0 -0
- data/vendor/bundle/ruby/2.6.0/gems/{json-2.3.0 → json-2.3.1}/README.md +16 -0
- data/vendor/bundle/ruby/2.6.0/gems/{json-2.3.0 → json-2.3.1}/Rakefile +8 -87
- data/vendor/bundle/ruby/2.6.0/gems/json-2.3.1/VERSION +1 -0
- data/vendor/bundle/ruby/2.6.0/gems/{json-2.3.0 → json-2.3.1}/diagrams/.keep +0 -0
- data/vendor/bundle/ruby/2.6.0/gems/{json-2.3.0 → json-2.3.1}/ext/json/ext/fbuffer/fbuffer.h +0 -0
- data/vendor/bundle/ruby/2.6.0/gems/{json-2.3.0 → json-2.3.1}/ext/json/ext/generator/.sitearchdir.-.json.-.ext.time +0 -0
- data/vendor/bundle/ruby/2.6.0/gems/{json-2.3.0 → json-2.3.1}/ext/json/ext/generator/depend +0 -0
- data/vendor/bundle/ruby/2.6.0/gems/{json-2.3.0 → json-2.3.1}/ext/json/ext/generator/extconf.rb +0 -0
- data/vendor/bundle/ruby/2.6.0/gems/{json-2.3.0 → json-2.3.1}/ext/json/ext/generator/generator.c +71 -1
- data/vendor/bundle/ruby/2.6.0/gems/{json-2.3.0 → json-2.3.1}/ext/json/ext/generator/generator.h +0 -0
- data/vendor/bundle/ruby/2.6.0/gems/json-2.3.1/ext/json/ext/generator/generator.so +0 -0
- data/vendor/bundle/ruby/2.6.0/gems/{json-2.3.0 → json-2.3.1}/ext/json/ext/parser/.sitearchdir.-.json.-.ext.time +0 -0
- data/vendor/bundle/ruby/2.6.0/gems/{json-2.3.0 → json-2.3.1}/ext/json/ext/parser/depend +0 -0
- data/vendor/bundle/ruby/2.6.0/gems/{json-2.3.0 → json-2.3.1}/ext/json/ext/parser/extconf.rb +0 -0
- data/vendor/bundle/ruby/2.6.0/gems/{json-2.3.0 → json-2.3.1}/ext/json/ext/parser/parser.c +71 -70
- data/vendor/bundle/ruby/2.6.0/gems/{json-2.3.0 → json-2.3.1}/ext/json/ext/parser/parser.h +0 -0
- data/vendor/bundle/ruby/2.6.0/gems/{json-2.3.0 → json-2.3.1}/ext/json/ext/parser/parser.rl +1 -0
- data/vendor/bundle/ruby/2.6.0/gems/json-2.3.1/ext/json/ext/parser/parser.so +0 -0
- data/vendor/bundle/ruby/2.6.0/gems/{json-2.3.0 → json-2.3.1}/ext/json/extconf.rb +0 -0
- data/vendor/bundle/ruby/2.6.0/gems/{json-2.3.0 → json-2.3.1}/install.rb +0 -0
- data/vendor/bundle/ruby/2.6.0/gems/{json-2.3.0 → json-2.3.1}/java/src/json/ext/ByteListTranscoder.java +0 -0
- data/vendor/bundle/ruby/2.6.0/gems/{json-2.3.0 → json-2.3.1}/java/src/json/ext/Generator.java +0 -0
- data/vendor/bundle/ruby/2.6.0/gems/{json-2.3.0 → json-2.3.1}/java/src/json/ext/GeneratorMethods.java +0 -0
- data/vendor/bundle/ruby/2.6.0/gems/{json-2.3.0 → json-2.3.1}/java/src/json/ext/GeneratorService.java +0 -0
- data/vendor/bundle/ruby/2.6.0/gems/{json-2.3.0 → json-2.3.1}/java/src/json/ext/GeneratorState.java +0 -0
- data/vendor/bundle/ruby/2.6.0/gems/{json-2.3.0 → json-2.3.1}/java/src/json/ext/OptionsReader.java +0 -0
- data/vendor/bundle/ruby/2.6.0/gems/{json-2.3.0 → json-2.3.1}/java/src/json/ext/Parser.java +0 -0
- data/vendor/bundle/ruby/2.6.0/gems/{json-2.3.0 → json-2.3.1}/java/src/json/ext/Parser.rl +0 -0
- data/vendor/bundle/ruby/2.6.0/gems/{json-2.3.0 → json-2.3.1}/java/src/json/ext/ParserService.java +0 -0
- data/vendor/bundle/ruby/2.6.0/gems/{json-2.3.0 → json-2.3.1}/java/src/json/ext/RuntimeInfo.java +0 -0
- data/vendor/bundle/ruby/2.6.0/gems/{json-2.3.0 → json-2.3.1}/java/src/json/ext/StringDecoder.java +0 -0
- data/vendor/bundle/ruby/2.6.0/gems/{json-2.3.0 → json-2.3.1}/java/src/json/ext/StringEncoder.java +0 -0
- data/vendor/bundle/ruby/2.6.0/gems/{json-2.3.0 → json-2.3.1}/java/src/json/ext/Utils.java +0 -0
- data/vendor/bundle/ruby/2.6.0/gems/{json-2.3.0 → json-2.3.1}/json-java.gemspec +3 -3
- data/vendor/bundle/ruby/2.6.0/gems/json-2.3.1/json.gemspec +139 -0
- data/vendor/bundle/ruby/2.6.0/gems/{json-2.3.0 → json-2.3.1}/json_pure.gemspec +8 -13
- data/vendor/bundle/ruby/2.6.0/gems/json-2.3.1/lib/json.rb +412 -0
- data/vendor/bundle/ruby/2.6.0/gems/{json-2.3.0 → json-2.3.1}/lib/json/add/bigdecimal.rb +0 -0
- data/vendor/bundle/ruby/2.6.0/gems/{json-2.3.0 → json-2.3.1}/lib/json/add/complex.rb +0 -0
- data/vendor/bundle/ruby/2.6.0/gems/{json-2.3.0 → json-2.3.1}/lib/json/add/core.rb +0 -0
- data/vendor/bundle/ruby/2.6.0/gems/{json-2.3.0 → json-2.3.1}/lib/json/add/date.rb +0 -0
- data/vendor/bundle/ruby/2.6.0/gems/{json-2.3.0 → json-2.3.1}/lib/json/add/date_time.rb +0 -0
- data/vendor/bundle/ruby/2.6.0/gems/{json-2.3.0 → json-2.3.1}/lib/json/add/exception.rb +0 -0
- data/vendor/bundle/ruby/2.6.0/gems/{json-2.3.0 → json-2.3.1}/lib/json/add/ostruct.rb +0 -0
- data/vendor/bundle/ruby/2.6.0/gems/{json-2.3.0 → json-2.3.1}/lib/json/add/range.rb +0 -0
- data/vendor/bundle/ruby/2.6.0/gems/{json-2.3.0 → json-2.3.1}/lib/json/add/rational.rb +0 -0
- data/vendor/bundle/ruby/2.6.0/gems/{json-2.3.0 → json-2.3.1}/lib/json/add/regexp.rb +0 -0
- data/vendor/bundle/ruby/2.6.0/gems/{json-2.3.0 → json-2.3.1}/lib/json/add/set.rb +0 -0
- data/vendor/bundle/ruby/2.6.0/gems/{json-2.3.0 → json-2.3.1}/lib/json/add/struct.rb +0 -0
- data/vendor/bundle/ruby/2.6.0/gems/{json-2.3.0 → json-2.3.1}/lib/json/add/symbol.rb +0 -0
- data/vendor/bundle/ruby/2.6.0/gems/{json-2.3.0 → json-2.3.1}/lib/json/add/time.rb +0 -0
- data/vendor/bundle/ruby/2.6.0/gems/json-2.3.1/lib/json/common.rb +691 -0
- data/vendor/bundle/ruby/2.6.0/gems/{json-2.3.0 → json-2.3.1}/lib/json/ext.rb +0 -0
- data/vendor/bundle/ruby/2.6.0/gems/{json-2.3.0 → json-2.3.1}/lib/json/ext/.keep +0 -0
- data/vendor/bundle/ruby/2.6.0/gems/json-2.3.1/lib/json/ext/generator.so +0 -0
- data/vendor/bundle/ruby/2.6.0/gems/json-2.3.1/lib/json/ext/parser.so +0 -0
- data/vendor/bundle/ruby/2.6.0/gems/{json-2.3.0 → json-2.3.1}/lib/json/generic_object.rb +0 -0
- data/vendor/bundle/ruby/2.6.0/gems/{json-2.3.0 → json-2.3.1}/lib/json/pure.rb +0 -0
- data/vendor/bundle/ruby/2.6.0/gems/{json-2.3.0 → json-2.3.1}/lib/json/pure/generator.rb +1 -1
- data/vendor/bundle/ruby/2.6.0/gems/{json-2.3.0 → json-2.3.1}/lib/json/pure/parser.rb +2 -2
- data/vendor/bundle/ruby/2.6.0/gems/{json-2.3.0 → json-2.3.1}/lib/json/version.rb +1 -1
- data/vendor/bundle/ruby/2.6.0/gems/{json-2.3.0 → json-2.3.1}/references/rfc7159.txt +0 -0
- data/vendor/bundle/ruby/2.6.0/gems/{json-2.3.0 → json-2.3.1}/tests/fixtures/fail10.json +0 -0
- data/vendor/bundle/ruby/2.6.0/gems/{json-2.3.0 → json-2.3.1}/tests/fixtures/fail11.json +0 -0
- data/vendor/bundle/ruby/2.6.0/gems/{json-2.3.0 → json-2.3.1}/tests/fixtures/fail12.json +0 -0
- data/vendor/bundle/ruby/2.6.0/gems/{json-2.3.0 → json-2.3.1}/tests/fixtures/fail13.json +0 -0
- data/vendor/bundle/ruby/2.6.0/gems/{json-2.3.0 → json-2.3.1}/tests/fixtures/fail14.json +0 -0
- data/vendor/bundle/ruby/2.6.0/gems/{json-2.3.0 → json-2.3.1}/tests/fixtures/fail18.json +0 -0
- data/vendor/bundle/ruby/2.6.0/gems/{json-2.3.0 → json-2.3.1}/tests/fixtures/fail19.json +0 -0
- data/vendor/bundle/ruby/2.6.0/gems/{json-2.3.0 → json-2.3.1}/tests/fixtures/fail2.json +0 -0
- data/vendor/bundle/ruby/2.6.0/gems/{json-2.3.0 → json-2.3.1}/tests/fixtures/fail20.json +0 -0
- data/vendor/bundle/ruby/2.6.0/gems/{json-2.3.0 → json-2.3.1}/tests/fixtures/fail21.json +0 -0
- data/vendor/bundle/ruby/2.6.0/gems/{json-2.3.0 → json-2.3.1}/tests/fixtures/fail22.json +0 -0
- data/vendor/bundle/ruby/2.6.0/gems/{json-2.3.0 → json-2.3.1}/tests/fixtures/fail23.json +0 -0
- data/vendor/bundle/ruby/2.6.0/gems/{json-2.3.0 → json-2.3.1}/tests/fixtures/fail24.json +0 -0
- data/vendor/bundle/ruby/2.6.0/gems/{json-2.3.0 → json-2.3.1}/tests/fixtures/fail25.json +0 -0
- data/vendor/bundle/ruby/2.6.0/gems/{json-2.3.0 → json-2.3.1}/tests/fixtures/fail27.json +0 -0
- data/vendor/bundle/ruby/2.6.0/gems/{json-2.3.0 → json-2.3.1}/tests/fixtures/fail28.json +0 -0
- data/vendor/bundle/ruby/2.6.0/gems/{json-2.3.0 → json-2.3.1}/tests/fixtures/fail3.json +0 -0
- data/vendor/bundle/ruby/2.6.0/gems/{json-2.3.0 → json-2.3.1}/tests/fixtures/fail4.json +0 -0
- data/vendor/bundle/ruby/2.6.0/gems/{json-2.3.0 → json-2.3.1}/tests/fixtures/fail5.json +0 -0
- data/vendor/bundle/ruby/2.6.0/gems/{json-2.3.0 → json-2.3.1}/tests/fixtures/fail6.json +0 -0
- data/vendor/bundle/ruby/2.6.0/gems/{json-2.3.0 → json-2.3.1}/tests/fixtures/fail7.json +0 -0
- data/vendor/bundle/ruby/2.6.0/gems/{json-2.3.0 → json-2.3.1}/tests/fixtures/fail8.json +0 -0
- data/vendor/bundle/ruby/2.6.0/gems/{json-2.3.0 → json-2.3.1}/tests/fixtures/fail9.json +0 -0
- data/vendor/bundle/ruby/2.6.0/gems/{json-2.3.0 → json-2.3.1}/tests/fixtures/obsolete_fail1.json +0 -0
- data/vendor/bundle/ruby/2.6.0/gems/{json-2.3.0 → json-2.3.1}/tests/fixtures/pass1.json +0 -0
- data/vendor/bundle/ruby/2.6.0/gems/{json-2.3.0 → json-2.3.1}/tests/fixtures/pass15.json +0 -0
- data/vendor/bundle/ruby/2.6.0/gems/{json-2.3.0 → json-2.3.1}/tests/fixtures/pass16.json +0 -0
- data/vendor/bundle/ruby/2.6.0/gems/{json-2.3.0 → json-2.3.1}/tests/fixtures/pass17.json +0 -0
- data/vendor/bundle/ruby/2.6.0/gems/{json-2.3.0 → json-2.3.1}/tests/fixtures/pass2.json +0 -0
- data/vendor/bundle/ruby/2.6.0/gems/{json-2.3.0 → json-2.3.1}/tests/fixtures/pass26.json +0 -0
- data/vendor/bundle/ruby/2.6.0/gems/{json-2.3.0 → json-2.3.1}/tests/fixtures/pass3.json +0 -0
- data/vendor/bundle/ruby/2.6.0/gems/{json-2.3.0 → json-2.3.1}/tests/json_addition_test.rb +0 -0
- data/vendor/bundle/ruby/2.6.0/gems/{json-2.3.0 → json-2.3.1}/tests/json_common_interface_test.rb +0 -0
- data/vendor/bundle/ruby/2.6.0/gems/{json-2.3.0 → json-2.3.1}/tests/json_encoding_test.rb +0 -0
- data/vendor/bundle/ruby/2.6.0/gems/{json-2.3.0 → json-2.3.1}/tests/json_ext_parser_test.rb +0 -0
- data/vendor/bundle/ruby/2.6.0/gems/{json-2.3.0 → json-2.3.1}/tests/json_fixtures_test.rb +6 -1
- data/vendor/bundle/ruby/2.6.0/gems/{json-2.3.0 → json-2.3.1}/tests/json_generator_test.rb +0 -0
- data/vendor/bundle/ruby/2.6.0/gems/{json-2.3.0 → json-2.3.1}/tests/json_generic_object_test.rb +0 -0
- data/vendor/bundle/ruby/2.6.0/gems/{json-2.3.0 → json-2.3.1}/tests/json_parser_test.rb +0 -0
- data/vendor/bundle/ruby/2.6.0/gems/{json-2.3.0 → json-2.3.1}/tests/json_string_matching_test.rb +0 -0
- data/vendor/bundle/ruby/2.6.0/gems/{json-2.3.0 → json-2.3.1}/tests/test_helper.rb +0 -0
- data/vendor/bundle/ruby/2.6.0/gems/{json-2.3.0 → json-2.3.1}/tools/diff.sh +0 -0
- data/vendor/bundle/ruby/2.6.0/gems/{json-2.3.0 → json-2.3.1}/tools/fuzz.rb +0 -0
- data/vendor/bundle/ruby/2.6.0/gems/{json-2.3.0 → json-2.3.1}/tools/server.rb +0 -0
- data/vendor/bundle/ruby/2.6.0/specifications/{diff-lcs-1.3.gemspec → diff-lcs-1.4.4.gemspec} +11 -13
- data/vendor/bundle/ruby/2.6.0/specifications/{json-2.3.0.gemspec → json-2.3.1.gemspec} +0 -0
- data/vendor/bundle/ruby/2.6.0/specifications/sys-uname-1.2.1.gemspec +1 -1
- metadata +276 -249
- data/vendor/bundle/ruby/2.6.0/cache/diff-lcs-1.3.gem +0 -0
- data/vendor/bundle/ruby/2.6.0/cache/json-2.3.0.gem +0 -0
- data/vendor/bundle/ruby/2.6.0/extensions/x86_64-linux/2.6.0/json-2.3.0/json/ext/generator.so +0 -0
- data/vendor/bundle/ruby/2.6.0/extensions/x86_64-linux/2.6.0/json-2.3.0/json/ext/parser.so +0 -0
- data/vendor/bundle/ruby/2.6.0/gems/diff-lcs-1.3/Contributing.md +0 -83
- data/vendor/bundle/ruby/2.6.0/gems/diff-lcs-1.3/History.md +0 -220
- data/vendor/bundle/ruby/2.6.0/gems/diff-lcs-1.3/autotest/discover.rb +0 -1
- data/vendor/bundle/ruby/2.6.0/gems/diff-lcs-1.3/lib/diff-lcs.rb +0 -3
- data/vendor/bundle/ruby/2.6.0/gems/diff-lcs-1.3/spec/diff_spec.rb +0 -47
- data/vendor/bundle/ruby/2.6.0/gems/diff-lcs-1.3/spec/hunk_spec.rb +0 -72
- data/vendor/bundle/ruby/2.6.0/gems/diff-lcs-1.3/spec/issues_spec.rb +0 -49
- data/vendor/bundle/ruby/2.6.0/gems/diff-lcs-1.3/spec/sdiff_spec.rb +0 -214
- data/vendor/bundle/ruby/2.6.0/gems/diff-lcs-1.3/spec/traverse_balanced_spec.rb +0 -310
- data/vendor/bundle/ruby/2.6.0/gems/json-2.3.0/LICENSE +0 -56
- data/vendor/bundle/ruby/2.6.0/gems/json-2.3.0/VERSION +0 -1
- data/vendor/bundle/ruby/2.6.0/gems/json-2.3.0/ext/json/ext/generator/generator.so +0 -0
- data/vendor/bundle/ruby/2.6.0/gems/json-2.3.0/ext/json/ext/parser/parser.so +0 -0
- data/vendor/bundle/ruby/2.6.0/gems/json-2.3.0/json.gemspec +0 -0
- data/vendor/bundle/ruby/2.6.0/gems/json-2.3.0/lib/json.rb +0 -63
- data/vendor/bundle/ruby/2.6.0/gems/json-2.3.0/lib/json/common.rb +0 -456
- data/vendor/bundle/ruby/2.6.0/gems/json-2.3.0/lib/json/ext/generator.so +0 -0
- data/vendor/bundle/ruby/2.6.0/gems/json-2.3.0/lib/json/ext/parser.so +0 -0
@@ -0,0 +1,310 @@
|
|
1
|
+
# frozen_string_literal: true
|
2
|
+
|
3
|
+
require 'spec_helper'
|
4
|
+
|
5
|
+
describe 'Diff::LCS.traverse_balanced' do
|
6
|
+
include Diff::LCS::SpecHelper::Matchers
|
7
|
+
|
8
|
+
shared_examples 'with a #change callback' do |s1, s2, result|
|
9
|
+
it 'traverses s1 -> s2 correctly' do
|
10
|
+
traversal = balanced_traversal(s1, s2, :balanced_callback)
|
11
|
+
expect(traversal.result).to eq(result)
|
12
|
+
end
|
13
|
+
|
14
|
+
it 'traverses s2 -> s1 correctly' do
|
15
|
+
traversal = balanced_traversal(s2, s1, :balanced_callback)
|
16
|
+
expect(traversal.result).to eq(balanced_reverse(result))
|
17
|
+
end
|
18
|
+
end
|
19
|
+
|
20
|
+
shared_examples 'without a #change callback' do |s1, s2, result|
|
21
|
+
it 'traverses s1 -> s2 correctly' do
|
22
|
+
traversal = balanced_traversal(s1, s2, :balanced_callback_no_change)
|
23
|
+
expect(traversal.result).to eq(map_to_no_change(result))
|
24
|
+
end
|
25
|
+
|
26
|
+
it 'traverses s2 -> s1 correctly' do
|
27
|
+
traversal = balanced_traversal(s2, s1, :balanced_callback_no_change)
|
28
|
+
expect(traversal.result).to eq(map_to_no_change(balanced_reverse(result)))
|
29
|
+
end
|
30
|
+
end
|
31
|
+
|
32
|
+
describe "identical string sequences ('abc')" do
|
33
|
+
s1 = s2 = 'abc'
|
34
|
+
|
35
|
+
result = [
|
36
|
+
['=', 0, 0],
|
37
|
+
['=', 1, 1],
|
38
|
+
['=', 2, 2]
|
39
|
+
]
|
40
|
+
|
41
|
+
it_has_behavior 'with a #change callback', s1, s2, result
|
42
|
+
it_has_behavior 'without a #change callback', s1, s2, result
|
43
|
+
end
|
44
|
+
|
45
|
+
describe 'identical array sequences %w(a b c)' do
|
46
|
+
s1 = s2 = %w(a b c)
|
47
|
+
|
48
|
+
result = [
|
49
|
+
['=', 0, 0],
|
50
|
+
['=', 1, 1],
|
51
|
+
['=', 2, 2]
|
52
|
+
]
|
53
|
+
|
54
|
+
it_has_behavior 'with a #change callback', s1, s2, result
|
55
|
+
it_has_behavior 'without a #change callback', s1, s2, result
|
56
|
+
end
|
57
|
+
|
58
|
+
describe 'sequences %w(a b c) & %w(a x c)' do
|
59
|
+
s1 = %w(a b c)
|
60
|
+
s2 = %w(a x c)
|
61
|
+
|
62
|
+
result = [
|
63
|
+
['=', 0, 0],
|
64
|
+
['!', 1, 1],
|
65
|
+
['=', 2, 2]
|
66
|
+
]
|
67
|
+
|
68
|
+
it_has_behavior 'with a #change callback', s1, s2, result
|
69
|
+
it_has_behavior 'without a #change callback', s1, s2, result
|
70
|
+
end
|
71
|
+
|
72
|
+
describe 'sequences %w(a x y c) & %w(a v w c)' do
|
73
|
+
s1 = %w(a x y c)
|
74
|
+
s2 = %w(a v w c)
|
75
|
+
|
76
|
+
result = [
|
77
|
+
['=', 0, 0],
|
78
|
+
['!', 1, 1],
|
79
|
+
['!', 2, 2],
|
80
|
+
['=', 3, 3]
|
81
|
+
]
|
82
|
+
|
83
|
+
it_has_behavior 'with a #change callback', s1, s2, result
|
84
|
+
it_has_behavior 'without a #change callback', s1, s2, result
|
85
|
+
end
|
86
|
+
|
87
|
+
describe 'sequences %w(x y c) & %w(v w c)' do
|
88
|
+
s1 = %w(x y c)
|
89
|
+
s2 = %w(v w c)
|
90
|
+
result = [
|
91
|
+
['!', 0, 0],
|
92
|
+
['!', 1, 1],
|
93
|
+
['=', 2, 2]
|
94
|
+
]
|
95
|
+
|
96
|
+
it_has_behavior 'with a #change callback', s1, s2, result
|
97
|
+
it_has_behavior 'without a #change callback', s1, s2, result
|
98
|
+
end
|
99
|
+
|
100
|
+
describe 'sequences %w(a x y z) & %w(b v w)' do
|
101
|
+
s1 = %w(a x y z)
|
102
|
+
s2 = %w(b v w)
|
103
|
+
result = [
|
104
|
+
['!', 0, 0],
|
105
|
+
['!', 1, 1],
|
106
|
+
['!', 2, 2],
|
107
|
+
['<', 3, 3]
|
108
|
+
]
|
109
|
+
|
110
|
+
it_has_behavior 'with a #change callback', s1, s2, result
|
111
|
+
it_has_behavior 'without a #change callback', s1, s2, result
|
112
|
+
end
|
113
|
+
|
114
|
+
describe 'sequences %w(a z) & %w(a)' do
|
115
|
+
s1 = %w(a z)
|
116
|
+
s2 = %w(a)
|
117
|
+
result = [
|
118
|
+
['=', 0, 0],
|
119
|
+
['<', 1, 1]
|
120
|
+
]
|
121
|
+
|
122
|
+
it_has_behavior 'with a #change callback', s1, s2, result
|
123
|
+
it_has_behavior 'without a #change callback', s1, s2, result
|
124
|
+
end
|
125
|
+
|
126
|
+
describe 'sequences %w(z a) & %w(a)' do
|
127
|
+
s1 = %w(z a)
|
128
|
+
s2 = %w(a)
|
129
|
+
result = [
|
130
|
+
['<', 0, 0],
|
131
|
+
['=', 1, 0]
|
132
|
+
]
|
133
|
+
|
134
|
+
it_has_behavior 'with a #change callback', s1, s2, result
|
135
|
+
it_has_behavior 'without a #change callback', s1, s2, result
|
136
|
+
end
|
137
|
+
|
138
|
+
describe 'sequences %w(a b c) & %w(x y z)' do
|
139
|
+
s1 = %w(a b c)
|
140
|
+
s2 = %w(x y z)
|
141
|
+
result = [
|
142
|
+
['!', 0, 0],
|
143
|
+
['!', 1, 1],
|
144
|
+
['!', 2, 2]
|
145
|
+
]
|
146
|
+
|
147
|
+
it_has_behavior 'with a #change callback', s1, s2, result
|
148
|
+
it_has_behavior 'without a #change callback', s1, s2, result
|
149
|
+
end
|
150
|
+
|
151
|
+
describe 'sequences %w(abcd efgh ijkl mnoopqrstuvwxyz) & []' do
|
152
|
+
s1 = %w(abcd efgh ijkl mnopqrstuvwxyz)
|
153
|
+
s2 = []
|
154
|
+
result = [
|
155
|
+
['<', 0, 0],
|
156
|
+
['<', 1, 0],
|
157
|
+
['<', 2, 0],
|
158
|
+
['<', 3, 0]
|
159
|
+
]
|
160
|
+
|
161
|
+
it_has_behavior 'with a #change callback', s1, s2, result
|
162
|
+
it_has_behavior 'without a #change callback', s1, s2, result
|
163
|
+
end
|
164
|
+
|
165
|
+
describe 'strings %q(a b c) & %q(a x c)' do
|
166
|
+
s1 = 'a b c'
|
167
|
+
s2 = 'a x c'
|
168
|
+
|
169
|
+
result = [
|
170
|
+
['=', 0, 0],
|
171
|
+
['=', 1, 1],
|
172
|
+
['!', 2, 2],
|
173
|
+
['=', 3, 3],
|
174
|
+
['=', 4, 4]
|
175
|
+
]
|
176
|
+
|
177
|
+
it_has_behavior 'with a #change callback', s1, s2, result
|
178
|
+
it_has_behavior 'without a #change callback', s1, s2, result
|
179
|
+
end
|
180
|
+
|
181
|
+
describe 'strings %q(a x y c) & %q(a v w c)' do
|
182
|
+
s1 = 'a x y c'
|
183
|
+
s2 = 'a v w c'
|
184
|
+
|
185
|
+
result = [
|
186
|
+
['=', 0, 0],
|
187
|
+
['=', 1, 1],
|
188
|
+
['!', 2, 2],
|
189
|
+
['=', 3, 3],
|
190
|
+
['!', 4, 4],
|
191
|
+
['=', 5, 5],
|
192
|
+
['=', 6, 6]
|
193
|
+
]
|
194
|
+
|
195
|
+
it_has_behavior 'with a #change callback', s1, s2, result
|
196
|
+
it_has_behavior 'without a #change callback', s1, s2, result
|
197
|
+
end
|
198
|
+
|
199
|
+
describe 'strings %q(x y c) & %q(v w c)' do
|
200
|
+
s1 = 'x y c'
|
201
|
+
s2 = 'v w c'
|
202
|
+
result = [
|
203
|
+
['!', 0, 0],
|
204
|
+
['=', 1, 1],
|
205
|
+
['!', 2, 2],
|
206
|
+
['=', 3, 3],
|
207
|
+
['=', 4, 4]
|
208
|
+
]
|
209
|
+
|
210
|
+
it_has_behavior 'with a #change callback', s1, s2, result
|
211
|
+
it_has_behavior 'without a #change callback', s1, s2, result
|
212
|
+
end
|
213
|
+
|
214
|
+
describe 'strings %q(a x y z) & %q(b v w)' do
|
215
|
+
s1 = 'a x y z'
|
216
|
+
s2 = 'b v w'
|
217
|
+
result = [
|
218
|
+
['!', 0, 0],
|
219
|
+
['=', 1, 1],
|
220
|
+
['!', 2, 2],
|
221
|
+
['=', 3, 3],
|
222
|
+
['!', 4, 4],
|
223
|
+
['<', 5, 5],
|
224
|
+
['<', 6, 5]
|
225
|
+
]
|
226
|
+
|
227
|
+
it_has_behavior 'with a #change callback', s1, s2, result
|
228
|
+
it_has_behavior 'without a #change callback', s1, s2, result
|
229
|
+
end
|
230
|
+
|
231
|
+
describe 'strings %q(a z) & %q(a)' do
|
232
|
+
s1 = 'a z'
|
233
|
+
s2 = 'a'
|
234
|
+
result = [
|
235
|
+
['=', 0, 0],
|
236
|
+
['<', 1, 1],
|
237
|
+
['<', 2, 1]
|
238
|
+
]
|
239
|
+
|
240
|
+
it_has_behavior 'with a #change callback', s1, s2, result
|
241
|
+
it_has_behavior 'without a #change callback', s1, s2, result
|
242
|
+
end
|
243
|
+
|
244
|
+
describe 'strings %q(z a) & %q(a)' do
|
245
|
+
s1 = 'z a'
|
246
|
+
s2 = 'a'
|
247
|
+
result = [
|
248
|
+
['<', 0, 0],
|
249
|
+
['<', 1, 0],
|
250
|
+
['=', 2, 0]
|
251
|
+
]
|
252
|
+
|
253
|
+
it_has_behavior 'with a #change callback', s1, s2, result
|
254
|
+
it_has_behavior 'without a #change callback', s1, s2, result
|
255
|
+
end
|
256
|
+
|
257
|
+
describe 'strings %q(a b c) & %q(x y z)' do
|
258
|
+
s1 = 'a b c'
|
259
|
+
s2 = 'x y z'
|
260
|
+
result = [
|
261
|
+
['!', 0, 0],
|
262
|
+
['=', 1, 1],
|
263
|
+
['!', 2, 2],
|
264
|
+
['=', 3, 3],
|
265
|
+
['!', 4, 4]
|
266
|
+
]
|
267
|
+
|
268
|
+
it_has_behavior 'with a #change callback', s1, s2, result
|
269
|
+
it_has_behavior 'without a #change callback', s1, s2, result
|
270
|
+
end
|
271
|
+
|
272
|
+
describe 'strings %q(abcd efgh ijkl mnopqrstuvwxyz) & %q()' do
|
273
|
+
s1 = 'abcd efgh ijkl mnopqrstuvwxyz'
|
274
|
+
s2 = ''
|
275
|
+
result = [
|
276
|
+
['<', 0, 0],
|
277
|
+
['<', 1, 0],
|
278
|
+
['<', 2, 0],
|
279
|
+
['<', 3, 0],
|
280
|
+
['<', 4, 0],
|
281
|
+
['<', 5, 0],
|
282
|
+
['<', 6, 0],
|
283
|
+
['<', 7, 0],
|
284
|
+
['<', 8, 0],
|
285
|
+
['<', 9, 0],
|
286
|
+
['<', 10, 0],
|
287
|
+
['<', 11, 0],
|
288
|
+
['<', 12, 0],
|
289
|
+
['<', 13, 0],
|
290
|
+
['<', 14, 0],
|
291
|
+
['<', 15, 0],
|
292
|
+
['<', 16, 0],
|
293
|
+
['<', 17, 0],
|
294
|
+
['<', 18, 0],
|
295
|
+
['<', 19, 0],
|
296
|
+
['<', 20, 0],
|
297
|
+
['<', 21, 0],
|
298
|
+
['<', 22, 0],
|
299
|
+
['<', 23, 0],
|
300
|
+
['<', 24, 0],
|
301
|
+
['<', 25, 0],
|
302
|
+
['<', 26, 0],
|
303
|
+
['<', 27, 0],
|
304
|
+
['<', 28, 0]
|
305
|
+
]
|
306
|
+
|
307
|
+
it_has_behavior 'with a #change callback', s1, s2, result
|
308
|
+
it_has_behavior 'without a #change callback', s1, s2, result
|
309
|
+
end
|
310
|
+
end
|
data/vendor/bundle/ruby/2.6.0/gems/{diff-lcs-1.3 → diff-lcs-1.4.4}/spec/traverse_sequences_spec.rb
RENAMED
@@ -1,10 +1,10 @@
|
|
1
|
-
#
|
1
|
+
# frozen_string_literal: true
|
2
2
|
|
3
3
|
require 'spec_helper'
|
4
4
|
|
5
|
-
describe
|
6
|
-
describe
|
7
|
-
describe
|
5
|
+
describe 'Diff::LCS.traverse_sequences' do
|
6
|
+
describe 'callback with no finishers' do
|
7
|
+
describe 'over (seq1, seq2)' do
|
8
8
|
before(:each) do
|
9
9
|
@callback_s1_s2 = simple_callback_no_finishers
|
10
10
|
Diff::LCS.traverse_sequences(seq1, seq2, @callback_s1_s2)
|
@@ -13,27 +13,27 @@ describe "Diff::LCS.traverse_sequences" do
|
|
13
13
|
Diff::LCS.traverse_sequences(seq2, seq1, @callback_s2_s1)
|
14
14
|
end
|
15
15
|
|
16
|
-
it
|
16
|
+
it 'has the correct LCS result on left-matches' do
|
17
17
|
expect(@callback_s1_s2.matched_a).to eq(correct_lcs)
|
18
18
|
expect(@callback_s2_s1.matched_a).to eq(correct_lcs)
|
19
19
|
end
|
20
20
|
|
21
|
-
it
|
21
|
+
it 'has the correct LCS result on right-matches' do
|
22
22
|
expect(@callback_s1_s2.matched_b).to eq(correct_lcs)
|
23
23
|
expect(@callback_s2_s1.matched_b).to eq(correct_lcs)
|
24
24
|
end
|
25
25
|
|
26
|
-
it
|
26
|
+
it 'has the correct skipped sequences with the left sequence' do
|
27
27
|
expect(@callback_s1_s2.discards_a).to eq(skipped_seq1)
|
28
28
|
expect(@callback_s2_s1.discards_a).to eq(skipped_seq2)
|
29
29
|
end
|
30
30
|
|
31
|
-
it
|
31
|
+
it 'has the correct skipped sequences with the right sequence' do
|
32
32
|
expect(@callback_s1_s2.discards_b).to eq(skipped_seq2)
|
33
33
|
expect(@callback_s2_s1.discards_b).to eq(skipped_seq1)
|
34
34
|
end
|
35
35
|
|
36
|
-
it
|
36
|
+
it 'does not have anything done markers from the left or right sequences' do
|
37
37
|
expect(@callback_s1_s2.done_a).to be_empty
|
38
38
|
expect(@callback_s1_s2.done_b).to be_empty
|
39
39
|
expect(@callback_s2_s1.done_a).to be_empty
|
@@ -41,64 +41,64 @@ describe "Diff::LCS.traverse_sequences" do
|
|
41
41
|
end
|
42
42
|
end
|
43
43
|
|
44
|
-
describe
|
44
|
+
describe 'over (hello, hello)' do
|
45
45
|
before(:each) do
|
46
46
|
@callback = simple_callback_no_finishers
|
47
47
|
Diff::LCS.traverse_sequences(hello, hello, @callback)
|
48
48
|
end
|
49
49
|
|
50
|
-
it
|
50
|
+
it 'has the correct LCS result on left-matches' do
|
51
51
|
expect(@callback.matched_a).to eq(hello.split(//))
|
52
52
|
end
|
53
53
|
|
54
|
-
it
|
54
|
+
it 'has the correct LCS result on right-matches' do
|
55
55
|
expect(@callback.matched_b).to eq(hello.split(//))
|
56
56
|
end
|
57
57
|
|
58
|
-
it
|
58
|
+
it 'has the correct skipped sequences with the left sequence', :only => true do
|
59
59
|
expect(@callback.discards_a).to be_empty
|
60
60
|
end
|
61
61
|
|
62
|
-
it
|
62
|
+
it 'has the correct skipped sequences with the right sequence' do
|
63
63
|
expect(@callback.discards_b).to be_empty
|
64
64
|
end
|
65
65
|
|
66
|
-
it
|
66
|
+
it 'does not have anything done markers from the left or right sequences' do
|
67
67
|
expect(@callback.done_a).to be_empty
|
68
68
|
expect(@callback.done_b).to be_empty
|
69
69
|
end
|
70
70
|
end
|
71
71
|
|
72
|
-
describe
|
72
|
+
describe 'over (hello_ary, hello_ary)' do
|
73
73
|
before(:each) do
|
74
74
|
@callback = simple_callback_no_finishers
|
75
75
|
Diff::LCS.traverse_sequences(hello_ary, hello_ary, @callback)
|
76
76
|
end
|
77
77
|
|
78
|
-
it
|
78
|
+
it 'has the correct LCS result on left-matches' do
|
79
79
|
expect(@callback.matched_a).to eq(hello_ary)
|
80
80
|
end
|
81
81
|
|
82
|
-
it
|
82
|
+
it 'has the correct LCS result on right-matches' do
|
83
83
|
expect(@callback.matched_b).to eq(hello_ary)
|
84
84
|
end
|
85
85
|
|
86
|
-
it
|
86
|
+
it 'has the correct skipped sequences with the left sequence' do
|
87
87
|
expect(@callback.discards_a).to be_empty
|
88
88
|
end
|
89
89
|
|
90
|
-
it
|
90
|
+
it 'has the correct skipped sequences with the right sequence' do
|
91
91
|
expect(@callback.discards_b).to be_empty
|
92
92
|
end
|
93
93
|
|
94
|
-
it
|
94
|
+
it 'does not have anything done markers from the left or right sequences' do
|
95
95
|
expect(@callback.done_a).to be_empty
|
96
96
|
expect(@callback.done_b).to be_empty
|
97
97
|
end
|
98
98
|
end
|
99
99
|
end
|
100
100
|
|
101
|
-
describe
|
101
|
+
describe 'callback with finisher' do
|
102
102
|
before(:each) do
|
103
103
|
@callback_s1_s2 = simple_callback
|
104
104
|
Diff::LCS.traverse_sequences(seq1, seq2, @callback_s1_s2)
|
@@ -106,28 +106,28 @@ describe "Diff::LCS.traverse_sequences" do
|
|
106
106
|
Diff::LCS.traverse_sequences(seq2, seq1, @callback_s2_s1)
|
107
107
|
end
|
108
108
|
|
109
|
-
it
|
109
|
+
it 'has the correct LCS result on left-matches' do
|
110
110
|
expect(@callback_s1_s2.matched_a).to eq(correct_lcs)
|
111
111
|
expect(@callback_s2_s1.matched_a).to eq(correct_lcs)
|
112
112
|
end
|
113
113
|
|
114
|
-
it
|
114
|
+
it 'has the correct LCS result on right-matches' do
|
115
115
|
expect(@callback_s1_s2.matched_b).to eq(correct_lcs)
|
116
116
|
expect(@callback_s2_s1.matched_b).to eq(correct_lcs)
|
117
117
|
end
|
118
118
|
|
119
|
-
it
|
119
|
+
it 'has the correct skipped sequences for the left sequence' do
|
120
120
|
expect(@callback_s1_s2.discards_a).to eq(skipped_seq1)
|
121
121
|
expect(@callback_s2_s1.discards_a).to eq(skipped_seq2)
|
122
122
|
end
|
123
123
|
|
124
|
-
it
|
124
|
+
it 'has the correct skipped sequences for the right sequence' do
|
125
125
|
expect(@callback_s1_s2.discards_b).to eq(skipped_seq2)
|
126
126
|
expect(@callback_s2_s1.discards_b).to eq(skipped_seq1)
|
127
127
|
end
|
128
128
|
|
129
|
-
it
|
130
|
-
expect(@callback_s1_s2.done_a).to eq([[
|
129
|
+
it 'has done markers differently-sized sequences' do
|
130
|
+
expect(@callback_s1_s2.done_a).to eq([['p', 9, 's', 10]])
|
131
131
|
expect(@callback_s1_s2.done_b).to be_empty
|
132
132
|
|
133
133
|
# 20110731 I don't yet understand why this particular behaviour
|