mercadopago-custom-checkout 0.1.1
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +7 -0
- data/.gitignore +23 -0
- data/.gs/bin/rake +23 -0
- data/.gs/cache/faraday-0.9.2.gem +0 -0
- data/.gs/cache/minitest-5.9.0.gem +0 -0
- data/.gs/cache/multi_json-1.12.1.gem +0 -0
- data/.gs/cache/multipart-post-2.0.0.gem +0 -0
- data/.gs/cache/rake-10.5.0.gem +0 -0
- data/.gs/gems/faraday-0.9.2/LICENSE.md +20 -0
- data/.gs/gems/faraday-0.9.2/README.md +245 -0
- data/.gs/gems/faraday-0.9.2/lib/faraday.rb +268 -0
- data/.gs/gems/faraday-0.9.2/lib/faraday/adapter.rb +46 -0
- data/.gs/gems/faraday-0.9.2/lib/faraday/adapter/em_http.rb +237 -0
- data/.gs/gems/faraday-0.9.2/lib/faraday/adapter/em_http_ssl_patch.rb +56 -0
- data/.gs/gems/faraday-0.9.2/lib/faraday/adapter/em_synchrony.rb +100 -0
- data/.gs/gems/faraday-0.9.2/lib/faraday/adapter/em_synchrony/parallel_manager.rb +66 -0
- data/.gs/gems/faraday-0.9.2/lib/faraday/adapter/excon.rb +81 -0
- data/.gs/gems/faraday-0.9.2/lib/faraday/adapter/httpclient.rb +117 -0
- data/.gs/gems/faraday-0.9.2/lib/faraday/adapter/net_http.rb +130 -0
- data/.gs/gems/faraday-0.9.2/lib/faraday/adapter/net_http_persistent.rb +49 -0
- data/.gs/gems/faraday-0.9.2/lib/faraday/adapter/patron.rb +78 -0
- data/.gs/gems/faraday-0.9.2/lib/faraday/adapter/rack.rb +58 -0
- data/.gs/gems/faraday-0.9.2/lib/faraday/adapter/test.rb +162 -0
- data/.gs/gems/faraday-0.9.2/lib/faraday/adapter/typhoeus.rb +123 -0
- data/.gs/gems/faraday-0.9.2/lib/faraday/autoload.rb +84 -0
- data/.gs/gems/faraday-0.9.2/lib/faraday/connection.rb +437 -0
- data/.gs/gems/faraday-0.9.2/lib/faraday/error.rb +53 -0
- data/.gs/gems/faraday-0.9.2/lib/faraday/middleware.rb +37 -0
- data/.gs/gems/faraday-0.9.2/lib/faraday/options.rb +359 -0
- data/.gs/gems/faraday-0.9.2/lib/faraday/parameters.rb +197 -0
- data/.gs/gems/faraday-0.9.2/lib/faraday/rack_builder.rb +213 -0
- data/.gs/gems/faraday-0.9.2/lib/faraday/request.rb +92 -0
- data/.gs/gems/faraday-0.9.2/lib/faraday/request/authorization.rb +42 -0
- data/.gs/gems/faraday-0.9.2/lib/faraday/request/basic_authentication.rb +13 -0
- data/.gs/gems/faraday-0.9.2/lib/faraday/request/instrumentation.rb +36 -0
- data/.gs/gems/faraday-0.9.2/lib/faraday/request/multipart.rb +63 -0
- data/.gs/gems/faraday-0.9.2/lib/faraday/request/retry.rb +154 -0
- data/.gs/gems/faraday-0.9.2/lib/faraday/request/token_authentication.rb +15 -0
- data/.gs/gems/faraday-0.9.2/lib/faraday/request/url_encoded.rb +36 -0
- data/.gs/gems/faraday-0.9.2/lib/faraday/response.rb +93 -0
- data/.gs/gems/faraday-0.9.2/lib/faraday/response/logger.rb +59 -0
- data/.gs/gems/faraday-0.9.2/lib/faraday/response/raise_error.rb +21 -0
- data/.gs/gems/faraday-0.9.2/lib/faraday/upload_io.rb +67 -0
- data/.gs/gems/faraday-0.9.2/lib/faraday/utils.rb +309 -0
- data/.gs/gems/minitest-5.9.0/.autotest +34 -0
- data/.gs/gems/minitest-5.9.0/History.rdoc +1176 -0
- data/.gs/gems/minitest-5.9.0/Manifest.txt +26 -0
- data/.gs/gems/minitest-5.9.0/README.rdoc +656 -0
- data/.gs/gems/minitest-5.9.0/Rakefile +72 -0
- data/.gs/gems/minitest-5.9.0/design_rationale.rb +52 -0
- data/.gs/gems/minitest-5.9.0/lib/hoe/minitest.rb +26 -0
- data/.gs/gems/minitest-5.9.0/lib/minitest.rb +815 -0
- data/.gs/gems/minitest-5.9.0/lib/minitest/assertions.rb +674 -0
- data/.gs/gems/minitest-5.9.0/lib/minitest/autorun.rb +13 -0
- data/.gs/gems/minitest-5.9.0/lib/minitest/benchmark.rb +424 -0
- data/.gs/gems/minitest-5.9.0/lib/minitest/expectations.rb +284 -0
- data/.gs/gems/minitest-5.9.0/lib/minitest/hell.rb +17 -0
- data/.gs/gems/minitest-5.9.0/lib/minitest/mock.rb +232 -0
- data/.gs/gems/minitest-5.9.0/lib/minitest/parallel.rb +69 -0
- data/.gs/gems/minitest-5.9.0/lib/minitest/pride.rb +4 -0
- data/.gs/gems/minitest-5.9.0/lib/minitest/pride_plugin.rb +142 -0
- data/.gs/gems/minitest-5.9.0/lib/minitest/spec.rb +331 -0
- data/.gs/gems/minitest-5.9.0/lib/minitest/test.rb +284 -0
- data/.gs/gems/minitest-5.9.0/lib/minitest/unit.rb +45 -0
- data/.gs/gems/minitest-5.9.0/test/minitest/metametameta.rb +90 -0
- data/.gs/gems/minitest-5.9.0/test/minitest/test_minitest_benchmark.rb +137 -0
- data/.gs/gems/minitest-5.9.0/test/minitest/test_minitest_mock.rb +512 -0
- data/.gs/gems/minitest-5.9.0/test/minitest/test_minitest_reporter.rb +281 -0
- data/.gs/gems/minitest-5.9.0/test/minitest/test_minitest_spec.rb +967 -0
- data/.gs/gems/minitest-5.9.0/test/minitest/test_minitest_test.rb +1983 -0
- data/.gs/gems/multi_json-1.12.1/CHANGELOG.md +245 -0
- data/.gs/gems/multi_json-1.12.1/CONTRIBUTING.md +46 -0
- data/.gs/gems/multi_json-1.12.1/LICENSE.md +20 -0
- data/.gs/gems/multi_json-1.12.1/README.md +121 -0
- data/.gs/gems/multi_json-1.12.1/lib/multi_json.rb +161 -0
- data/.gs/gems/multi_json-1.12.1/lib/multi_json/adapter.rb +49 -0
- data/.gs/gems/multi_json-1.12.1/lib/multi_json/adapter_error.rb +15 -0
- data/.gs/gems/multi_json-1.12.1/lib/multi_json/adapters/gson.rb +20 -0
- data/.gs/gems/multi_json-1.12.1/lib/multi_json/adapters/jr_jackson.rb +25 -0
- data/.gs/gems/multi_json-1.12.1/lib/multi_json/adapters/json_common.rb +23 -0
- data/.gs/gems/multi_json-1.12.1/lib/multi_json/adapters/json_gem.rb +11 -0
- data/.gs/gems/multi_json-1.12.1/lib/multi_json/adapters/json_pure.rb +11 -0
- data/.gs/gems/multi_json-1.12.1/lib/multi_json/adapters/nsjsonserialization.rb +32 -0
- data/.gs/gems/multi_json-1.12.1/lib/multi_json/adapters/oj.rb +25 -0
- data/.gs/gems/multi_json-1.12.1/lib/multi_json/adapters/ok_json.rb +23 -0
- data/.gs/gems/multi_json-1.12.1/lib/multi_json/adapters/yajl.rb +19 -0
- data/.gs/gems/multi_json-1.12.1/lib/multi_json/convertible_hash_keys.rb +43 -0
- data/.gs/gems/multi_json-1.12.1/lib/multi_json/options.rb +39 -0
- data/.gs/gems/multi_json-1.12.1/lib/multi_json/options_cache.rb +29 -0
- data/.gs/gems/multi_json-1.12.1/lib/multi_json/parse_error.rb +17 -0
- data/.gs/gems/multi_json-1.12.1/lib/multi_json/vendor/okjson.rb +606 -0
- data/.gs/gems/multi_json-1.12.1/lib/multi_json/version.rb +17 -0
- data/.gs/gems/multi_json-1.12.1/multi_json.gemspec +20 -0
- data/.gs/gems/multipart-post-2.0.0/.gitignore +6 -0
- data/.gs/gems/multipart-post-2.0.0/.travis.yml +7 -0
- data/.gs/gems/multipart-post-2.0.0/Gemfile +14 -0
- data/.gs/gems/multipart-post-2.0.0/History.txt +60 -0
- data/.gs/gems/multipart-post-2.0.0/Manifest.txt +9 -0
- data/.gs/gems/multipart-post-2.0.0/README.md +77 -0
- data/.gs/gems/multipart-post-2.0.0/Rakefile +9 -0
- data/.gs/gems/multipart-post-2.0.0/lib/composite_io.rb +108 -0
- data/.gs/gems/multipart-post-2.0.0/lib/multipart_post.rb +9 -0
- data/.gs/gems/multipart-post-2.0.0/lib/multipartable.rb +29 -0
- data/.gs/gems/multipart-post-2.0.0/lib/net/http/post/multipart.rb +27 -0
- data/.gs/gems/multipart-post-2.0.0/lib/parts.rb +96 -0
- data/.gs/gems/multipart-post-2.0.0/multipart-post.gemspec +22 -0
- data/.gs/gems/multipart-post-2.0.0/test/multibyte.txt +1 -0
- data/.gs/gems/multipart-post-2.0.0/test/net/http/post/test_multipart.rb +110 -0
- data/.gs/gems/multipart-post-2.0.0/test/test_composite_io.rb +115 -0
- data/.gs/gems/multipart-post-2.0.0/test/test_parts.rb +86 -0
- data/.gs/gems/rake-10.5.0/.autotest +7 -0
- data/.gs/gems/rake-10.5.0/.rubocop.yml +27 -0
- data/.gs/gems/rake-10.5.0/.togglerc +7 -0
- data/.gs/gems/rake-10.5.0/CONTRIBUTING.rdoc +38 -0
- data/.gs/gems/rake-10.5.0/History.rdoc +659 -0
- data/.gs/gems/rake-10.5.0/MIT-LICENSE +21 -0
- data/.gs/gems/rake-10.5.0/Manifest.txt +166 -0
- data/.gs/gems/rake-10.5.0/README.rdoc +139 -0
- data/.gs/gems/rake-10.5.0/Rakefile +81 -0
- data/.gs/gems/rake-10.5.0/bin/rake +33 -0
- data/.gs/gems/rake-10.5.0/doc/command_line_usage.rdoc +158 -0
- data/.gs/gems/rake-10.5.0/doc/example/Rakefile1 +38 -0
- data/.gs/gems/rake-10.5.0/doc/example/Rakefile2 +35 -0
- data/.gs/gems/rake-10.5.0/doc/example/a.c +6 -0
- data/.gs/gems/rake-10.5.0/doc/example/b.c +6 -0
- data/.gs/gems/rake-10.5.0/doc/example/main.c +11 -0
- data/.gs/gems/rake-10.5.0/doc/glossary.rdoc +42 -0
- data/.gs/gems/rake-10.5.0/doc/jamis.rb +591 -0
- data/.gs/gems/rake-10.5.0/doc/proto_rake.rdoc +127 -0
- data/.gs/gems/rake-10.5.0/doc/rake.1 +141 -0
- data/.gs/gems/rake-10.5.0/doc/rakefile.rdoc +624 -0
- data/.gs/gems/rake-10.5.0/doc/rational.rdoc +151 -0
- data/.gs/gems/rake-10.5.0/doc/release_notes/rake-0.4.14.rdoc +23 -0
- data/.gs/gems/rake-10.5.0/doc/release_notes/rake-0.4.15.rdoc +35 -0
- data/.gs/gems/rake-10.5.0/doc/release_notes/rake-0.5.0.rdoc +53 -0
- data/.gs/gems/rake-10.5.0/doc/release_notes/rake-0.5.3.rdoc +78 -0
- data/.gs/gems/rake-10.5.0/doc/release_notes/rake-0.5.4.rdoc +46 -0
- data/.gs/gems/rake-10.5.0/doc/release_notes/rake-0.6.0.rdoc +141 -0
- data/.gs/gems/rake-10.5.0/doc/release_notes/rake-0.7.0.rdoc +119 -0
- data/.gs/gems/rake-10.5.0/doc/release_notes/rake-0.7.1.rdoc +59 -0
- data/.gs/gems/rake-10.5.0/doc/release_notes/rake-0.7.2.rdoc +121 -0
- data/.gs/gems/rake-10.5.0/doc/release_notes/rake-0.7.3.rdoc +47 -0
- data/.gs/gems/rake-10.5.0/doc/release_notes/rake-0.8.0.rdoc +114 -0
- data/.gs/gems/rake-10.5.0/doc/release_notes/rake-0.8.2.rdoc +165 -0
- data/.gs/gems/rake-10.5.0/doc/release_notes/rake-0.8.3.rdoc +112 -0
- data/.gs/gems/rake-10.5.0/doc/release_notes/rake-0.8.4.rdoc +147 -0
- data/.gs/gems/rake-10.5.0/doc/release_notes/rake-0.8.5.rdoc +53 -0
- data/.gs/gems/rake-10.5.0/doc/release_notes/rake-0.8.6.rdoc +37 -0
- data/.gs/gems/rake-10.5.0/doc/release_notes/rake-0.8.7.rdoc +55 -0
- data/.gs/gems/rake-10.5.0/doc/release_notes/rake-0.9.0.rdoc +112 -0
- data/.gs/gems/rake-10.5.0/doc/release_notes/rake-0.9.1.rdoc +52 -0
- data/.gs/gems/rake-10.5.0/doc/release_notes/rake-0.9.2.2.rdoc +55 -0
- data/.gs/gems/rake-10.5.0/doc/release_notes/rake-0.9.2.rdoc +49 -0
- data/.gs/gems/rake-10.5.0/doc/release_notes/rake-0.9.3.rdoc +102 -0
- data/.gs/gems/rake-10.5.0/doc/release_notes/rake-0.9.4.rdoc +60 -0
- data/.gs/gems/rake-10.5.0/doc/release_notes/rake-0.9.5.rdoc +55 -0
- data/.gs/gems/rake-10.5.0/doc/release_notes/rake-0.9.6.rdoc +64 -0
- data/.gs/gems/rake-10.5.0/doc/release_notes/rake-10.0.0.rdoc +178 -0
- data/.gs/gems/rake-10.5.0/doc/release_notes/rake-10.0.1.rdoc +58 -0
- data/.gs/gems/rake-10.5.0/doc/release_notes/rake-10.0.2.rdoc +53 -0
- data/.gs/gems/rake-10.5.0/doc/release_notes/rake-10.0.3.rdoc +191 -0
- data/.gs/gems/rake-10.5.0/doc/release_notes/rake-10.1.0.rdoc +61 -0
- data/.gs/gems/rake-10.5.0/lib/rake.rb +79 -0
- data/.gs/gems/rake-10.5.0/lib/rake/alt_system.rb +110 -0
- data/.gs/gems/rake-10.5.0/lib/rake/application.rb +790 -0
- data/.gs/gems/rake-10.5.0/lib/rake/backtrace.rb +23 -0
- data/.gs/gems/rake-10.5.0/lib/rake/clean.rb +76 -0
- data/.gs/gems/rake-10.5.0/lib/rake/cloneable.rb +16 -0
- data/.gs/gems/rake-10.5.0/lib/rake/contrib/.document +1 -0
- data/.gs/gems/rake-10.5.0/lib/rake/contrib/compositepublisher.rb +21 -0
- data/.gs/gems/rake-10.5.0/lib/rake/contrib/ftptools.rb +137 -0
- data/.gs/gems/rake-10.5.0/lib/rake/contrib/publisher.rb +81 -0
- data/.gs/gems/rake-10.5.0/lib/rake/contrib/rubyforgepublisher.rb +18 -0
- data/.gs/gems/rake-10.5.0/lib/rake/contrib/sshpublisher.rb +61 -0
- data/.gs/gems/rake-10.5.0/lib/rake/contrib/sys.rb +4 -0
- data/.gs/gems/rake-10.5.0/lib/rake/cpu_counter.rb +125 -0
- data/.gs/gems/rake-10.5.0/lib/rake/default_loader.rb +14 -0
- data/.gs/gems/rake-10.5.0/lib/rake/dsl_definition.rb +201 -0
- data/.gs/gems/rake-10.5.0/lib/rake/early_time.rb +21 -0
- data/.gs/gems/rake-10.5.0/lib/rake/ext/core.rb +25 -0
- data/.gs/gems/rake-10.5.0/lib/rake/ext/module.rb +2 -0
- data/.gs/gems/rake-10.5.0/lib/rake/ext/pathname.rb +25 -0
- data/.gs/gems/rake-10.5.0/lib/rake/ext/string.rb +175 -0
- data/.gs/gems/rake-10.5.0/lib/rake/ext/time.rb +18 -0
- data/.gs/gems/rake-10.5.0/lib/rake/file_creation_task.rb +24 -0
- data/.gs/gems/rake-10.5.0/lib/rake/file_list.rb +428 -0
- data/.gs/gems/rake-10.5.0/lib/rake/file_task.rb +46 -0
- data/.gs/gems/rake-10.5.0/lib/rake/file_utils.rb +128 -0
- data/.gs/gems/rake-10.5.0/lib/rake/file_utils_ext.rb +144 -0
- data/.gs/gems/rake-10.5.0/lib/rake/gempackagetask.rb +4 -0
- data/.gs/gems/rake-10.5.0/lib/rake/invocation_chain.rb +56 -0
- data/.gs/gems/rake-10.5.0/lib/rake/invocation_exception_mixin.rb +16 -0
- data/.gs/gems/rake-10.5.0/lib/rake/late_time.rb +17 -0
- data/.gs/gems/rake-10.5.0/lib/rake/linked_list.rb +103 -0
- data/.gs/gems/rake-10.5.0/lib/rake/loaders/makefile.rb +53 -0
- data/.gs/gems/rake-10.5.0/lib/rake/multi_task.rb +13 -0
- data/.gs/gems/rake-10.5.0/lib/rake/name_space.rb +38 -0
- data/.gs/gems/rake-10.5.0/lib/rake/packagetask.rb +199 -0
- data/.gs/gems/rake-10.5.0/lib/rake/pathmap.rb +3 -0
- data/.gs/gems/rake-10.5.0/lib/rake/phony.rb +15 -0
- data/.gs/gems/rake-10.5.0/lib/rake/private_reader.rb +20 -0
- data/.gs/gems/rake-10.5.0/lib/rake/promise.rb +99 -0
- data/.gs/gems/rake-10.5.0/lib/rake/pseudo_status.rb +29 -0
- data/.gs/gems/rake-10.5.0/lib/rake/rake_module.rb +38 -0
- data/.gs/gems/rake-10.5.0/lib/rake/rake_test_loader.rb +22 -0
- data/.gs/gems/rake-10.5.0/lib/rake/rdoctask.rb +4 -0
- data/.gs/gems/rake-10.5.0/lib/rake/ruby182_test_unit_fix.rb +29 -0
- data/.gs/gems/rake-10.5.0/lib/rake/rule_recursion_overflow_error.rb +20 -0
- data/.gs/gems/rake-10.5.0/lib/rake/runtest.rb +27 -0
- data/.gs/gems/rake-10.5.0/lib/rake/scope.rb +42 -0
- data/.gs/gems/rake-10.5.0/lib/rake/task.rb +383 -0
- data/.gs/gems/rake-10.5.0/lib/rake/task_argument_error.rb +7 -0
- data/.gs/gems/rake-10.5.0/lib/rake/task_arguments.rb +98 -0
- data/.gs/gems/rake-10.5.0/lib/rake/task_manager.rb +307 -0
- data/.gs/gems/rake-10.5.0/lib/rake/tasklib.rb +24 -0
- data/.gs/gems/rake-10.5.0/lib/rake/testtask.rb +213 -0
- data/.gs/gems/rake-10.5.0/lib/rake/thread_history_display.rb +48 -0
- data/.gs/gems/rake-10.5.0/lib/rake/thread_pool.rb +164 -0
- data/.gs/gems/rake-10.5.0/lib/rake/trace_output.rb +22 -0
- data/.gs/gems/rake-10.5.0/lib/rake/version.rb +7 -0
- data/.gs/gems/rake-10.5.0/lib/rake/win32.rb +56 -0
- data/.gs/gems/rake-10.5.0/rakelib/publish.rake +20 -0
- data/.gs/gems/rake-10.5.0/rakelib/test_times.rake +25 -0
- data/.gs/gems/rake-10.5.0/test/file_creation.rb +34 -0
- data/.gs/gems/rake-10.5.0/test/helper.rb +129 -0
- data/.gs/gems/rake-10.5.0/test/support/rakefile_definitions.rb +478 -0
- data/.gs/gems/rake-10.5.0/test/support/ruby_runner.rb +34 -0
- data/.gs/gems/rake-10.5.0/test/test_private_reader.rb +42 -0
- data/.gs/gems/rake-10.5.0/test/test_rake.rb +40 -0
- data/.gs/gems/rake-10.5.0/test/test_rake_application.rb +643 -0
- data/.gs/gems/rake-10.5.0/test/test_rake_application_options.rb +468 -0
- data/.gs/gems/rake-10.5.0/test/test_rake_backtrace.rb +119 -0
- data/.gs/gems/rake-10.5.0/test/test_rake_clean.rb +61 -0
- data/.gs/gems/rake-10.5.0/test/test_rake_cpu_counter.rb +68 -0
- data/.gs/gems/rake-10.5.0/test/test_rake_definitions.rb +84 -0
- data/.gs/gems/rake-10.5.0/test/test_rake_directory_task.rb +76 -0
- data/.gs/gems/rake-10.5.0/test/test_rake_dsl.rb +40 -0
- data/.gs/gems/rake-10.5.0/test/test_rake_early_time.rb +31 -0
- data/.gs/gems/rake-10.5.0/test/test_rake_extension.rb +59 -0
- data/.gs/gems/rake-10.5.0/test/test_rake_file_creation_task.rb +56 -0
- data/.gs/gems/rake-10.5.0/test/test_rake_file_list.rb +670 -0
- data/.gs/gems/rake-10.5.0/test/test_rake_file_list_path_map.rb +8 -0
- data/.gs/gems/rake-10.5.0/test/test_rake_file_task.rb +197 -0
- data/.gs/gems/rake-10.5.0/test/test_rake_file_utils.rb +314 -0
- data/.gs/gems/rake-10.5.0/test/test_rake_ftp_file.rb +74 -0
- data/.gs/gems/rake-10.5.0/test/test_rake_functional.rb +482 -0
- data/.gs/gems/rake-10.5.0/test/test_rake_invocation_chain.rb +64 -0
- data/.gs/gems/rake-10.5.0/test/test_rake_late_time.rb +18 -0
- data/.gs/gems/rake-10.5.0/test/test_rake_linked_list.rb +84 -0
- data/.gs/gems/rake-10.5.0/test/test_rake_makefile_loader.rb +46 -0
- data/.gs/gems/rake-10.5.0/test/test_rake_multi_task.rb +64 -0
- data/.gs/gems/rake-10.5.0/test/test_rake_name_space.rb +57 -0
- data/.gs/gems/rake-10.5.0/test/test_rake_package_task.rb +79 -0
- data/.gs/gems/rake-10.5.0/test/test_rake_path_map.rb +168 -0
- data/.gs/gems/rake-10.5.0/test/test_rake_path_map_explode.rb +34 -0
- data/.gs/gems/rake-10.5.0/test/test_rake_path_map_partial.rb +18 -0
- data/.gs/gems/rake-10.5.0/test/test_rake_pathname_extensions.rb +15 -0
- data/.gs/gems/rake-10.5.0/test/test_rake_pseudo_status.rb +21 -0
- data/.gs/gems/rake-10.5.0/test/test_rake_rake_test_loader.rb +20 -0
- data/.gs/gems/rake-10.5.0/test/test_rake_reduce_compat.rb +26 -0
- data/.gs/gems/rake-10.5.0/test/test_rake_require.rb +40 -0
- data/.gs/gems/rake-10.5.0/test/test_rake_rules.rb +388 -0
- data/.gs/gems/rake-10.5.0/test/test_rake_scope.rb +44 -0
- data/.gs/gems/rake-10.5.0/test/test_rake_task.rb +393 -0
- data/.gs/gems/rake-10.5.0/test/test_rake_task_argument_parsing.rb +119 -0
- data/.gs/gems/rake-10.5.0/test/test_rake_task_arguments.rb +127 -0
- data/.gs/gems/rake-10.5.0/test/test_rake_task_lib.rb +9 -0
- data/.gs/gems/rake-10.5.0/test/test_rake_task_manager.rb +178 -0
- data/.gs/gems/rake-10.5.0/test/test_rake_task_manager_argument_resolution.rb +19 -0
- data/.gs/gems/rake-10.5.0/test/test_rake_task_with_arguments.rb +172 -0
- data/.gs/gems/rake-10.5.0/test/test_rake_test_task.rb +146 -0
- data/.gs/gems/rake-10.5.0/test/test_rake_thread_pool.rb +145 -0
- data/.gs/gems/rake-10.5.0/test/test_rake_top_level_functions.rb +71 -0
- data/.gs/gems/rake-10.5.0/test/test_rake_win32.rb +72 -0
- data/.gs/gems/rake-10.5.0/test/test_thread_history_display.rb +101 -0
- data/.gs/gems/rake-10.5.0/test/test_trace_output.rb +52 -0
- data/.gs/specifications/faraday-0.9.2.gemspec +31 -0
- data/.gs/specifications/minitest-5.9.0.gemspec +39 -0
- data/.gs/specifications/multi_json-1.12.1.gemspec +33 -0
- data/.gs/specifications/multipart-post-2.0.0.gemspec +22 -0
- data/.gs/specifications/rake-10.5.0.gemspec +43 -0
- data/.rubocop.yml +36 -0
- data/.ruby-version +1 -0
- data/.travis.yml +7 -0
- data/CODE_OF_CONDUCT.md +49 -0
- data/Gemfile +10 -0
- data/LICENSE.txt +21 -0
- data/README.md +35 -0
- data/Rakefile +38 -0
- data/bin/console +14 -0
- data/bin/setup +8 -0
- data/lib/mercadopago/core/client.rb +70 -0
- data/lib/mercadopago/core/endpoints.rb +134 -0
- data/lib/mercadopago/core/errors.rb +6 -0
- data/lib/mercadopago/core/gateway.rb +84 -0
- data/lib/mercadopago/custom_checkout.rb +29 -0
- data/lib/mercadopago/custom_checkout/account.rb +162 -0
- data/lib/mercadopago/custom_checkout/card_issuer.rb +20 -0
- data/lib/mercadopago/custom_checkout/card_token.rb +57 -0
- data/lib/mercadopago/custom_checkout/customer.rb +84 -0
- data/lib/mercadopago/custom_checkout/errors.rb +6 -0
- data/lib/mercadopago/custom_checkout/identification_type.rb +19 -0
- data/lib/mercadopago/custom_checkout/payment_method.rb +42 -0
- data/lib/mercadopago/custom_checkout/payments.rb +24 -0
- data/lib/mercadopago/custom_checkout/resource.rb +14 -0
- data/lib/mercadopago/custom_checkout/version.rb +5 -0
- data/mercadopago-custom-checkout.gemspec +30 -0
- metadata +455 -0
@@ -0,0 +1,245 @@
|
|
1
|
+
1.12.1
|
2
|
+
------
|
3
|
+
|
4
|
+
* [Prevent meory leak in OptionsCache](https://github.com/intridea/multi_json/commit/aa7498199ad272f3d4a13750d7c568a66047e2ee)
|
5
|
+
|
6
|
+
1.12.0
|
7
|
+
------
|
8
|
+
|
9
|
+
* [Introduce global options cache to improve peroformance](https://github.com/intridea/multi_json/commit/7aaef2a1bc2b83c95e4208b12dad5d1d87ff20a6)
|
10
|
+
|
11
|
+
1.11.2
|
12
|
+
------
|
13
|
+
|
14
|
+
* [Only pass one argument to JrJackson when two is not supported](https://github.com/intridea/multi_json/commit/e798fa517c817fc706982d3f3c61129b6651d601)
|
15
|
+
|
16
|
+
1.11.1
|
17
|
+
------
|
18
|
+
|
19
|
+
* [Dump method passes options throught for JrJackson adapter](https://github.com/intridea/multi_json/commit/3c730fd12135c3e7bf212f878958004908f13909)
|
20
|
+
|
21
|
+
1.11.0
|
22
|
+
------
|
23
|
+
|
24
|
+
* [Make all adapters read IO object before load](https://github.com/intridea/multi_json/commit/167f559e18d4efee05e1f160a2661d16dbb215d4)
|
25
|
+
|
26
|
+
1.10.1
|
27
|
+
------
|
28
|
+
* [Explicitly require stringio for Gson adapter](https://github.com/intridea/multi_json/commit/623ec8142d4a212fa0db763bb71295789a119929)
|
29
|
+
* [Do not read StringIO object before passing it to JrJackson](https://github.com/intridea/multi_json/commit/a6dc935df08e7b3d5d701fbb9298384c96df0fde)
|
30
|
+
|
31
|
+
1.10.0
|
32
|
+
------
|
33
|
+
* [Performance tweaks](https://github.com/intridea/multi_json/commit/58724acfed31866d079eaafb1cd824e341ade287)
|
34
|
+
|
35
|
+
1.9.3
|
36
|
+
-----
|
37
|
+
* [Convert indent option to Fixnum before passing to Oj](https://github.com/intridea/multi_json/commit/826fc5535b863b74fc9f981dfdda3e26f1ee4e5b)
|
38
|
+
|
39
|
+
1.9.2
|
40
|
+
-----
|
41
|
+
* [Enable use_to_json option for Oj adapter by default](https://github.com/intridea/multi_json/commit/76a4aaf697b10bbabd5d535d83cf1149efcfe5c7)
|
42
|
+
|
43
|
+
1.9.1
|
44
|
+
-----
|
45
|
+
* [Remove unused LoadError file](https://github.com/intridea/multi_json/commit/65dedd84d59baeefc25c477fedf0bbe85e7ce2cd)
|
46
|
+
|
47
|
+
1.9.0
|
48
|
+
----
|
49
|
+
* [Rename LoadError to ParseError](https://github.com/intridea/multi_json/commit/4abb98fe3a90b2a7b3d1594515c8a06042b4a27d)
|
50
|
+
* [Adapter load failure throws AdapterError instead of ArgumentError](https://github.com/intridea/multi_json/commit/4da612b617bd932bb6fa1cc4c43210327f98f271)
|
51
|
+
|
52
|
+
1.8.4
|
53
|
+
-----
|
54
|
+
* [Make Gson adapter explicitly read StringIO object](https://github.com/intridea/multi_json/commit/b58b498747ff6e94f41488c971b2a30a98760ef2)
|
55
|
+
|
56
|
+
1.8.3
|
57
|
+
-----
|
58
|
+
* [Make JrJackson explicitly read StringIO objects](https://github.com/intridea/multi_json/commit/e1f162d5b668e5e4db5afa175361a601a8aa2b05)
|
59
|
+
* [Prevent calling #downcase on alias symbols](https://github.com/intridea/multi_json/commit/c1cf075453ce0110f7decc4f906444b1233bb67c)
|
60
|
+
|
61
|
+
1.8.2
|
62
|
+
-----
|
63
|
+
* [Downcase adapter string name for OS compatibility](https://github.com/intridea/multi_json/commit/b8e15a032247a63f1410d21a18add05035f3fa66)
|
64
|
+
|
65
|
+
1.8.1
|
66
|
+
-----
|
67
|
+
* [Let the adapter handle strings with invalid encoding](https://github.com/intridea/multi_json/commit/6af2bf87b89f44eabf2ae9ca96779febc65ea94b)
|
68
|
+
|
69
|
+
1.8.0
|
70
|
+
-----
|
71
|
+
* [Raise MultiJson::LoadError on blank input](https://github.com/intridea/multi_json/commit/c44f9c928bb25fe672246ad394b3e5b991be32e6)
|
72
|
+
|
73
|
+
1.7.9
|
74
|
+
-----
|
75
|
+
* [Explicitly require json gem code even when constant is defined](https://github.com/intridea/multi_json/commit/36f7906c66477eb4b55b7afeaa3684b6db69eff2)
|
76
|
+
|
77
|
+
1.7.8
|
78
|
+
-----
|
79
|
+
* [Reorder JrJackson before json_gem](https://github.com/intridea/multi_json/commit/315b6e460b6e4dcdb6c82e04e4be8ee975d395da)
|
80
|
+
* [Update vendored OkJson to version 43](https://github.com/intridea/multi_json/commit/99a6b662f6ef4036e3ee94d7eb547fa72fb2ab50)
|
81
|
+
|
82
|
+
1.7.7
|
83
|
+
-----
|
84
|
+
* [Fix options caching issues](https://github.com/intridea/multi_json/commit/a3f14c3661688c5927638fa6088c7b46a67e875e)
|
85
|
+
|
86
|
+
1.7.6
|
87
|
+
-----
|
88
|
+
* [Bring back MultiJson::VERSION constant](https://github.com/intridea/multi_json/commit/31b990c2725e6673bf8ce57540fe66b57a751a72)
|
89
|
+
|
90
|
+
1.7.5
|
91
|
+
-----
|
92
|
+
* [Fix warning '*' interpreted as argument prefix](https://github.com/intridea/multi_json/commit/b698962c7f64430222a1f06430669706a47aff89)
|
93
|
+
* [Remove stdlib warning](https://github.com/intridea/multi_json/commit/d06eec6b7996ac8b4ff0e2229efd835379b0c30f)
|
94
|
+
|
95
|
+
1.7.4
|
96
|
+
-----
|
97
|
+
* [Cache options for better performance](https://github.com/intridea/multi_json/commit/8a26ee93140c4bed36194ed9fb887a1b6919257b)
|
98
|
+
|
99
|
+
1.7.3
|
100
|
+
-----
|
101
|
+
* [Require json/ext to ensure extension version gets loaded for json_gem](https://github.com/intridea/multi_json/commit/942686f7e8597418c6f90ee69e1d45242fac07b1)
|
102
|
+
* [Rename JrJackson](https://github.com/intridea/multi_json/commit/078de7ba8b6035343c3e96b4767549e9ec43369a)
|
103
|
+
* [Prefer JrJackson to JSON gem if present](https://github.com/intridea/multi_json/commit/af8bd9799a66855f04b3aff1c488485950cec7bf)
|
104
|
+
* [Print a warning if outdated gem versions are used](https://github.com/intridea/multi_json/commit/e7438e7ba2be0236cfa24c2bb9ad40ee821286d1)
|
105
|
+
* [Loosen required_rubygems_version for compatibility with Ubuntu 10.04](https://github.com/intridea/multi_json/commit/59fad014e8fe41dbc6f09485ea0dc21fc42fd7a7)
|
106
|
+
|
107
|
+
1.7.2
|
108
|
+
-----
|
109
|
+
* [Rename Jrjackson adapter to JrJackson](https://github.com/intridea/multi_json/commit/b36dc915fc0e6548cbad06b5db6f520e040c9c8b)
|
110
|
+
* [Implement jrjackson -> jr_jackson alias for back-compatability](https://github.com/intridea/multi_json/commit/aa50ab8b7bb646b8b75d5d65dfeadae8248a4f10)
|
111
|
+
* [Update vendored OkJson module](https://github.com/intridea/multi_json/commit/30a3f474e17dd86a697c3fab04f468d1a4fd69d7)
|
112
|
+
|
113
|
+
1.7.1
|
114
|
+
-----
|
115
|
+
* [Fix capitalization of JrJackson class](https://github.com/intridea/multi_json/commit/5373a5e38c647f02427a0477cb8e0e0dafad1b8d)
|
116
|
+
|
117
|
+
1.7.0
|
118
|
+
-----
|
119
|
+
* [Add load_options/dump_options to MultiJson](https://github.com/intridea/multi_json/commit/a153956be6b0df06ea1705ce3c1ff0b5b0e27ea5)
|
120
|
+
* [MultiJson does not modify arguments](https://github.com/intridea/multi_json/commit/58525b01c4c2f6635ba2ac13d6fd987b79f3962f)
|
121
|
+
* [Enable quirks_mode by default for json_gem/json_pure adapters](https://github.com/intridea/multi_json/commit/1fd4e6635c436515b7d7d5a0bee4548de8571520)
|
122
|
+
* [Add JrJackson adapter](https://github.com/intridea/multi_json/commit/4dd86fa96300aaaf6d762578b9b31ea82adb056d)
|
123
|
+
* [Raise ArgumentError on bad adapter input](https://github.com/intridea/multi_json/commit/911a3756bdff2cb5ac06497da3fa3e72199cb7ad)
|
124
|
+
|
125
|
+
1.6.1
|
126
|
+
-----
|
127
|
+
* [Revert "Use JSON.generate instead of #to_json"](https://github.com/intridea/multi_json/issues/86)
|
128
|
+
|
129
|
+
1.6.0
|
130
|
+
-----
|
131
|
+
* [Add gson.rb support](https://github.com/intridea/multi_json/pull/71)
|
132
|
+
* [Add MultiJson.default_options](https://github.com/intridea/multi_json/pull/70)
|
133
|
+
* [Add MultiJson.with_adapter](https://github.com/intridea/multi_json/pull/67)
|
134
|
+
* [Stringify all possible keys for ok_json](https://github.com/intridea/multi_json/pull/66)
|
135
|
+
* [Use JSON.generate instead of #to_json](https://github.com/intridea/multi_json/issues/73)
|
136
|
+
* [Alias `MultiJson::DecodeError` to `MultiJson::LoadError`](https://github.com/intridea/multi_json/pull/79)
|
137
|
+
|
138
|
+
1.5.1
|
139
|
+
-----
|
140
|
+
* [Do not allow Oj or JSON to create symbols by searching for classes](https://github.com/intridea/multi_json/commit/193e28cf4dc61b6e7b7b7d80f06f74c76df65c41)
|
141
|
+
|
142
|
+
1.5.0
|
143
|
+
-----
|
144
|
+
* [Add `MultiJson.with_adapter` method](https://github.com/intridea/multi_json/commit/d14c5d28cae96557a0421298621b9499e1f28104)
|
145
|
+
* [Stringify all possible keys for `ok_json`](https://github.com/intridea/multi_json/commit/73998074058e1e58c557ffa7b9541d486d6041fa)
|
146
|
+
|
147
|
+
1.4.0
|
148
|
+
-----
|
149
|
+
* [Allow `load`/`dump` of JSON fragments](https://github.com/intridea/multi_json/commit/707aae7d48d39c85b38febbd2c210ba87f6e4a36)
|
150
|
+
|
151
|
+
1.3.7
|
152
|
+
-----
|
153
|
+
* [Fix rescue clause for MagLev](https://github.com/intridea/multi_json/commit/39abdf50199828c50e85b2ce8f8ba31fcbbc9332)
|
154
|
+
* [Remove unnecessary check for string version of options key](https://github.com/intridea/multi_json/commit/660101b70e962b3c007d0b90d45944fa47d13ec4)
|
155
|
+
* [Explicitly set default adapter when adapter is set to `nil` or `false`](https://github.com/intridea/multi_json/commit/a9e587d5a63eafb4baee9fb211265e4dd96a26bc)
|
156
|
+
* [Fix Oj `ParseError` mapping for Oj 1.4.0](https://github.com/intridea/multi_json/commit/7d9045338cc9029401c16f3c409d54ce97f275e2)
|
157
|
+
|
158
|
+
1.3.6
|
159
|
+
-----
|
160
|
+
* [Allow adapter-specific options to be passed through to Oj](https://github.com/intridea/multi_json/commit/d0e5feeebcba0bc69400dd203a295f5c30971223)
|
161
|
+
|
162
|
+
1.3.5
|
163
|
+
-----
|
164
|
+
* [Add pretty support to Oj adapter](https://github.com/intridea/multi_json/commit/0c8f75f03020c53bcf4c6be258faf433d24b2c2b)
|
165
|
+
|
166
|
+
1.3.4
|
167
|
+
-----
|
168
|
+
* [Use `class << self` instead of `module_function` to create aliases](https://github.com/intridea/multi_json/commit/ba1451c4c48baa297e049889be241a424cb05980)
|
169
|
+
|
170
|
+
1.3.3
|
171
|
+
-----
|
172
|
+
* [Remove deprecation warnings](https://github.com/intridea/multi_json/commit/36b524e71544eb0186826a891bcc03b2820a008f)
|
173
|
+
|
174
|
+
1.3.2
|
175
|
+
-----
|
176
|
+
* [Add ability to use adapter per call](https://github.com/intridea/multi_json/commit/106bbec469d5d0a832bfa31fffcb8c0f0cdc9bd3)
|
177
|
+
* [Add and deprecate `default_engine` method](https://github.com/intridea/multi_json/commit/fc3df0c7a3e2ab9ce0c2c7e7617a4da97dd13f6e)
|
178
|
+
|
179
|
+
1.3.1
|
180
|
+
-----
|
181
|
+
* [Only warn once for each instance a deprecated method is called](https://github.com/intridea/multi_json/commit/e21d6eb7da74b3f283995c1d27d5880e75f0ae84)
|
182
|
+
|
183
|
+
1.3.0
|
184
|
+
-----
|
185
|
+
* [Implement `load`/`dump`; deprecate `decode`/`encode`](https://github.com/intridea/multi_json/commit/e90fd6cb1b0293eb0c73c2f4eb0f7a1764370216)
|
186
|
+
* [Rename engines to adapters](https://github.com/intridea/multi_json/commit/ae7fd144a7949a9c221dcaa446196ec23db908df)
|
187
|
+
|
188
|
+
1.2.0
|
189
|
+
-----
|
190
|
+
* [Add support for Oj](https://github.com/intridea/multi_json/commit/acd06b233edabe6c44f226873db7b49dab560c60)
|
191
|
+
|
192
|
+
1.1.0
|
193
|
+
-----
|
194
|
+
* [`NSJSONSerialization` support for MacRuby](https://github.com/intridea/multi_json/commit/f862e2fc966cac8867fe7da3997fc76e8a6cf5d4)
|
195
|
+
|
196
|
+
1.0.4
|
197
|
+
-----
|
198
|
+
* [Set data context to `DecodeError` exception](https://github.com/intridea/multi_json/commit/19ddafd44029c6681f66fae2a0f6eabfd0f85176)
|
199
|
+
* [Allow `ok_json` to fallback to `to_json`](https://github.com/intridea/multi_json/commit/c157240b1193b283d06d1bd4d4b5b06bcf3761f8)
|
200
|
+
* [Add warning when using `ok_json`](https://github.com/intridea/multi_json/commit/dd4b68810c84f826fb98f9713bfb29ab96888d57)
|
201
|
+
* [Options can be passed to an engine on encode](https://github.com/intridea/multi_json/commit/e0a7ff5d5ff621ffccc61617ed8aeec5816e81f7)
|
202
|
+
|
203
|
+
1.0.3
|
204
|
+
-----
|
205
|
+
* [`Array` support for `stringify_keys`](https://github.com/intridea/multi_json/commit/644d1c5c7c7f6a27663b11668527b346094e38b9)
|
206
|
+
* [`Array` support for `symbolize_keys`](https://github.com/intridea/multi_json/commit/c885377d47a2aa39cb0d971fea78db2d2fa479a7)
|
207
|
+
|
208
|
+
1.0.2
|
209
|
+
-----
|
210
|
+
* [Allow encoding of rootless JSON when `ok_json` is used](https://github.com/intridea/multi_json/commit/d1cde7de97cb0f6152aef8daf14037521cdce8c6)
|
211
|
+
|
212
|
+
1.0.1
|
213
|
+
-----
|
214
|
+
* [Correct an issue with `ok_json` not being returned as the default engine](https://github.com/intridea/multi_json/commit/d33c141619c54cccd770199694da8fd1bd8f449d)
|
215
|
+
|
216
|
+
1.0.0
|
217
|
+
-----
|
218
|
+
* [Remove `ActiveSupport::JSON` support](https://github.com/intridea/multi_json/commit/c2f4140141d785a24b3f56e58811b0e561b37f6a)
|
219
|
+
* [Fix `@engine` ivar warning](https://github.com/intridea/multi_json/commit/3b978a8995721a8dffedc3b75a7f49e5494ec553)
|
220
|
+
* [Only `rescue` from parsing errors during decoding, not any `StandardError`](https://github.com/intridea/multi_json/commit/391d00b5e85294d42d41347605d8d46b4a7f66cc)
|
221
|
+
* [Rename `okjson` engine and vendored lib to `ok_json`](https://github.com/intridea/multi_json/commit/5bd1afc977a8208ddb0443e1d57cb79665c019f1)
|
222
|
+
* [Add `StringIO` support to `json` gem and `ok_json`](https://github.com/intridea/multi_json/commit/1706b11568db7f50af451fce5f4d679aeb3bbe8f)
|
223
|
+
|
224
|
+
0.0.5
|
225
|
+
-----
|
226
|
+
* [Trap all JSON decoding errors; raise `MultiJson::DecodeError`](https://github.com/intridea/multi_json/commit/dea9a1aef6dd1212aa1e5a37ab1669f9b045b732)
|
227
|
+
|
228
|
+
0.0.4
|
229
|
+
-----
|
230
|
+
* [Fix default_engine check for `json` gem](https://github.com/intridea/multi_json/commit/caced0c4e8c795922a109ebc00c3c4fa8635bed8)
|
231
|
+
* [Make requirement mapper an `Array` to preserve order in Ruby versions < 1.9](https://github.com/intridea/multi_json/commit/526f5f29a42131574a088ad9bbb43d7f48439b2c)
|
232
|
+
|
233
|
+
0.0.3
|
234
|
+
-----
|
235
|
+
* [Improve defaulting and documentation](https://github.com/sferik/twitter/commit/3a0e41b9e4b0909201045fa47704b78c9d949b73)
|
236
|
+
|
237
|
+
0.0.2
|
238
|
+
-----
|
239
|
+
|
240
|
+
* [Rename to `multi_json`](https://github.com/sferik/twitter/commit/461ab89ce071c8c9fabfc183581e0ec523788b62)
|
241
|
+
|
242
|
+
0.0.1
|
243
|
+
-----
|
244
|
+
|
245
|
+
* [Initial commit](https://github.com/sferik/twitter/commit/518c21ab299c500527491e6c049ab2229e22a805)
|
@@ -0,0 +1,46 @@
|
|
1
|
+
## Contributing
|
2
|
+
In the spirit of [free software][free-sw], **everyone** is encouraged to help
|
3
|
+
improve this project.
|
4
|
+
|
5
|
+
[free-sw]: http://www.fsf.org/licensing/essays/free-sw.html
|
6
|
+
|
7
|
+
Here are some ways *you* can contribute:
|
8
|
+
|
9
|
+
* by using alpha, beta, and prerelease versions
|
10
|
+
* by reporting bugs
|
11
|
+
* by suggesting new features
|
12
|
+
* by writing or editing documentation
|
13
|
+
* by writing specifications
|
14
|
+
* by writing code (**no patch is too small**: fix typos, add comments, clean up
|
15
|
+
inconsistent whitespace)
|
16
|
+
* by refactoring code
|
17
|
+
* by closing [issues][]
|
18
|
+
* by reviewing patches
|
19
|
+
|
20
|
+
[issues]: https://github.com/intridea/multi_json/issues
|
21
|
+
|
22
|
+
## Submitting an Issue
|
23
|
+
We use the [GitHub issue tracker][issues] to track bugs and features. Before
|
24
|
+
submitting a bug report or feature request, check to make sure it hasn't
|
25
|
+
already been submitted. When submitting a bug report, please include a [Gist][]
|
26
|
+
that includes a stack trace and any details that may be necessary to reproduce
|
27
|
+
the bug, including your gem version, Ruby version, and operating system.
|
28
|
+
Ideally, a bug report should include a pull request with failing specs.
|
29
|
+
|
30
|
+
[gist]: https://gist.github.com/
|
31
|
+
|
32
|
+
## Submitting a Pull Request
|
33
|
+
1. [Fork the repository.][fork]
|
34
|
+
2. [Create a topic branch.][branch]
|
35
|
+
3. Add specs for your unimplemented feature or bug fix.
|
36
|
+
4. Run `bundle exec rake spec`. If your specs pass, return to step 3.
|
37
|
+
5. Implement your feature or bug fix.
|
38
|
+
6. Run `bundle exec rake spec`. If your specs fail, return to step 5.
|
39
|
+
7. Run `open coverage/index.html`. If your changes are not completely covered
|
40
|
+
by your tests, return to step 3.
|
41
|
+
8. Add, commit, and push your changes.
|
42
|
+
9. [Submit a pull request.][pr]
|
43
|
+
|
44
|
+
[fork]: http://help.github.com/fork-a-repo/
|
45
|
+
[branch]: http://learn.github.com/p/branching.html
|
46
|
+
[pr]: http://help.github.com/send-pull-requests/
|
@@ -0,0 +1,20 @@
|
|
1
|
+
Copyright (c) 2010-2013 Michael Bleigh, Josh Kalderimis, Erik Michaels-Ober, Pavel Pravosud
|
2
|
+
|
3
|
+
Permission is hereby granted, free of charge, to any person obtaining
|
4
|
+
a copy of this software and associated documentation files (the
|
5
|
+
"Software"), to deal in the Software without restriction, including
|
6
|
+
without limitation the rights to use, copy, modify, merge, publish,
|
7
|
+
distribute, sublicense, and/or sell copies of the Software, and to
|
8
|
+
permit persons to whom the Software is furnished to do so, subject to
|
9
|
+
the following conditions:
|
10
|
+
|
11
|
+
The above copyright notice and this permission notice shall be
|
12
|
+
included in all copies or substantial portions of the Software.
|
13
|
+
|
14
|
+
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
|
15
|
+
EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
|
16
|
+
MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND
|
17
|
+
NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE
|
18
|
+
LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION
|
19
|
+
OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION
|
20
|
+
WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
|
@@ -0,0 +1,121 @@
|
|
1
|
+
# MultiJSON
|
2
|
+
|
3
|
+
[![Gem Version](http://img.shields.io/gem/v/multi_json.svg)][gem]
|
4
|
+
[![Build Status](http://travis-ci.org/intridea/multi_json.svg)][travis]
|
5
|
+
[![Dependency Status](http://img.shields.io/gemnasium/intridea/multi_json.svg)][gemnasium]
|
6
|
+
[![Code Climate](http://img.shields.io/codeclimate/github/intridea/multi_json.svg)][codeclimate]
|
7
|
+
|
8
|
+
[gem]: https://rubygems.org/gems/multi_json
|
9
|
+
[travis]: http://travis-ci.org/intridea/multi_json
|
10
|
+
[gemnasium]: https://gemnasium.com/intridea/multi_json
|
11
|
+
[codeclimate]: https://codeclimate.com/github/intridea/multi_json
|
12
|
+
|
13
|
+
Lots of Ruby libraries parse JSON and everyone has their favorite JSON coder.
|
14
|
+
Instead of choosing a single JSON coder and forcing users of your library to be
|
15
|
+
stuck with it, you can use MultiJSON instead, which will simply choose the
|
16
|
+
fastest available JSON coder. Here's how to use it:
|
17
|
+
|
18
|
+
```ruby
|
19
|
+
require 'multi_json'
|
20
|
+
|
21
|
+
MultiJson.load('{"abc":"def"}') #=> {"abc" => "def"}
|
22
|
+
MultiJson.load('{"abc":"def"}', :symbolize_keys => true) #=> {:abc => "def"}
|
23
|
+
MultiJson.dump({:abc => 'def'}) # convert Ruby back to JSON
|
24
|
+
MultiJson.dump({:abc => 'def'}, :pretty => true) # encoded in a pretty form (if supported by the coder)
|
25
|
+
```
|
26
|
+
|
27
|
+
When loading invalid JSON, MultiJson will throw a `MultiJson::ParseError`. `MultiJson::DecodeError` and `MultiJson::LoadError` are aliases for backwards compatibility.
|
28
|
+
|
29
|
+
```ruby
|
30
|
+
begin
|
31
|
+
MultiJson.load('{invalid json}')
|
32
|
+
rescue MultiJson::ParseError => exception
|
33
|
+
exception.data # => "{invalid json}"
|
34
|
+
exception.cause # => JSON::ParserError: 795: unexpected token at '{invalid json}'
|
35
|
+
end
|
36
|
+
```
|
37
|
+
|
38
|
+
`ParseError` instance has `cause` reader which contains the original exception.
|
39
|
+
It also has `data` reader with the input that caused the problem.
|
40
|
+
|
41
|
+
The `use` method, which sets the MultiJson adapter, takes either a symbol or a
|
42
|
+
class (to allow for custom JSON parsers) that responds to both `.load` and `.dump`
|
43
|
+
at the class level.
|
44
|
+
|
45
|
+
When MultiJson fails to load the specified adapter, it'll throw `MultiJson::AdapterError`
|
46
|
+
which inherits from `ArgumentError`.
|
47
|
+
|
48
|
+
MultiJSON tries to have intelligent defaulting. That is, if you have any of the
|
49
|
+
supported engines already loaded, it will utilize them before attempting to
|
50
|
+
load any. When loading, libraries are ordered by speed. First Oj, then Yajl,
|
51
|
+
then the JSON gem, then JSON pure. If no other JSON library is available,
|
52
|
+
MultiJSON falls back to [OkJson][], a simple, vendorable JSON parser.
|
53
|
+
|
54
|
+
[okjson]: https://github.com/kr/okjson
|
55
|
+
|
56
|
+
## Supported JSON Engines
|
57
|
+
|
58
|
+
* [Oj](https://github.com/ohler55/oj) Optimized JSON by Peter Ohler
|
59
|
+
* [Yajl](https://github.com/brianmario/yajl-ruby) Yet Another JSON Library by Brian Lopez
|
60
|
+
* [JSON](https://github.com/flori/json) The default JSON gem with C-extensions (ships with Ruby 1.9)
|
61
|
+
* [JSON Pure](https://github.com/flori/json) A Ruby variant of the JSON gem
|
62
|
+
* [NSJSONSerialization](https://developer.apple.com/library/ios/#documentation/Foundation/Reference/NSJSONSerialization_Class/Reference/Reference.html) Wrapper for Apple's NSJSONSerialization in the Cocoa Framework (MacRuby only)
|
63
|
+
* [gson.rb](https://github.com/avsej/gson.rb) A Ruby wrapper for google-gson library (JRuby only)
|
64
|
+
* [JrJackson](https://github.com/guyboertje/jrjackson) JRuby wrapper for Jackson (JRuby only)
|
65
|
+
* [OkJson][okjson] A simple, vendorable JSON parser
|
66
|
+
|
67
|
+
## Supported Ruby Versions
|
68
|
+
This library aims to support and is [tested against][travis] the following Ruby
|
69
|
+
implementations:
|
70
|
+
|
71
|
+
* Ruby 1.8.7
|
72
|
+
* Ruby 1.9.2
|
73
|
+
* Ruby 1.9.3
|
74
|
+
* Ruby 2.0.0
|
75
|
+
* Ruby 2.1
|
76
|
+
* Ruby 2.2.4
|
77
|
+
* Ruby 2.3.1
|
78
|
+
* [JRuby][]
|
79
|
+
* [Rubinius][]
|
80
|
+
* [MacRuby][] (not tested on Travis CI)
|
81
|
+
|
82
|
+
[jruby]: http://www.jruby.org/
|
83
|
+
[rubinius]: http://rubini.us/
|
84
|
+
[macruby]: http://www.macruby.org/
|
85
|
+
|
86
|
+
If something doesn't work on one of these interpreters, it's a bug.
|
87
|
+
|
88
|
+
This library may inadvertently work (or seem to work) on other Ruby
|
89
|
+
implementations, however support will only be provided for the versions listed
|
90
|
+
above.
|
91
|
+
|
92
|
+
If you would like this library to support another Ruby version, you may
|
93
|
+
volunteer to be a maintainer. Being a maintainer entails making sure all tests
|
94
|
+
run and pass on that implementation. When something breaks on your
|
95
|
+
implementation, you will be responsible for providing patches in a timely
|
96
|
+
fashion. If critical issues for a particular implementation exist at the time
|
97
|
+
of a major release, support for that Ruby version may be dropped.
|
98
|
+
|
99
|
+
## Versioning
|
100
|
+
|
101
|
+
This library aims to adhere to [Semantic Versioning 2.0.0][semver]. Violations
|
102
|
+
of this scheme should be reported as bugs. Specifically, if a minor or patch
|
103
|
+
version is released that breaks backward compatibility, that version should be
|
104
|
+
immediately yanked and/or a new version should be immediately released that
|
105
|
+
restores compatibility. Breaking changes to the public API will only be
|
106
|
+
introduced with new major versions. As a result of this policy, you can (and
|
107
|
+
should) specify a dependency on this gem using the [Pessimistic Version
|
108
|
+
Constraint][pvc] with two digits of precision. For example:
|
109
|
+
|
110
|
+
```ruby
|
111
|
+
spec.add_dependency 'multi_json', '~> 1.0'
|
112
|
+
```
|
113
|
+
|
114
|
+
[semver]: http://semver.org/
|
115
|
+
[pvc]: http://docs.rubygems.org/read/chapter/16#page74
|
116
|
+
|
117
|
+
## Copyright
|
118
|
+
Copyright (c) 2010-2013 Michael Bleigh, Josh Kalderimis, Erik Michaels-Ober,
|
119
|
+
and Pavel Pravosud. See [LICENSE][] for details.
|
120
|
+
|
121
|
+
[license]: LICENSE.md
|
@@ -0,0 +1,161 @@
|
|
1
|
+
require 'multi_json/options'
|
2
|
+
require 'multi_json/version'
|
3
|
+
require 'multi_json/adapter_error'
|
4
|
+
require 'multi_json/parse_error'
|
5
|
+
require 'multi_json/options_cache'
|
6
|
+
|
7
|
+
module MultiJson
|
8
|
+
include Options
|
9
|
+
extend self
|
10
|
+
|
11
|
+
def default_options=(value)
|
12
|
+
Kernel.warn "MultiJson.default_options setter is deprecated\n" \
|
13
|
+
'Use MultiJson.load_options and MultiJson.dump_options instead'
|
14
|
+
|
15
|
+
self.load_options = self.dump_options = value
|
16
|
+
end
|
17
|
+
|
18
|
+
def default_options
|
19
|
+
Kernel.warn "MultiJson.default_options is deprecated\n" \
|
20
|
+
'Use MultiJson.load_options or MultiJson.dump_options instead'
|
21
|
+
|
22
|
+
load_options
|
23
|
+
end
|
24
|
+
|
25
|
+
%w(cached_options reset_cached_options!).each do |method_name|
|
26
|
+
define_method method_name do |*|
|
27
|
+
Kernel.warn "MultiJson.#{method_name} method is deprecated and no longer used."
|
28
|
+
end
|
29
|
+
end
|
30
|
+
|
31
|
+
ALIASES = {'jrjackson' => 'jr_jackson'}
|
32
|
+
|
33
|
+
REQUIREMENT_MAP = [
|
34
|
+
[:oj, 'oj'],
|
35
|
+
[:yajl, 'yajl'],
|
36
|
+
[:jr_jackson, 'jrjackson'],
|
37
|
+
[:json_gem, 'json/ext'],
|
38
|
+
[:gson, 'gson'],
|
39
|
+
[:json_pure, 'json/pure'],
|
40
|
+
]
|
41
|
+
|
42
|
+
# The default adapter based on what you currently
|
43
|
+
# have loaded and installed. First checks to see
|
44
|
+
# if any adapters are already loaded, then checks
|
45
|
+
# to see which are installed if none are loaded.
|
46
|
+
def default_adapter
|
47
|
+
return :oj if defined?(::Oj)
|
48
|
+
return :yajl if defined?(::Yajl)
|
49
|
+
return :jr_jackson if defined?(::JrJackson)
|
50
|
+
return :json_gem if defined?(::JSON::JSON_LOADED)
|
51
|
+
return :gson if defined?(::Gson)
|
52
|
+
|
53
|
+
REQUIREMENT_MAP.each do |adapter, library|
|
54
|
+
begin
|
55
|
+
require library
|
56
|
+
return adapter
|
57
|
+
rescue ::LoadError
|
58
|
+
next
|
59
|
+
end
|
60
|
+
end
|
61
|
+
|
62
|
+
Kernel.warn '[WARNING] MultiJson is using the default adapter (ok_json). ' \
|
63
|
+
'We recommend loading a different JSON library to improve performance.'
|
64
|
+
|
65
|
+
:ok_json
|
66
|
+
end
|
67
|
+
alias_method :default_engine, :default_adapter
|
68
|
+
|
69
|
+
# Get the current adapter class.
|
70
|
+
def adapter
|
71
|
+
return @adapter if defined?(@adapter) && @adapter
|
72
|
+
|
73
|
+
use nil # load default adapter
|
74
|
+
|
75
|
+
@adapter
|
76
|
+
end
|
77
|
+
alias_method :engine, :adapter
|
78
|
+
|
79
|
+
# Set the JSON parser utilizing a symbol, string, or class.
|
80
|
+
# Supported by default are:
|
81
|
+
#
|
82
|
+
# * <tt>:oj</tt>
|
83
|
+
# * <tt>:json_gem</tt>
|
84
|
+
# * <tt>:json_pure</tt>
|
85
|
+
# * <tt>:ok_json</tt>
|
86
|
+
# * <tt>:yajl</tt>
|
87
|
+
# * <tt>:nsjsonserialization</tt> (MacRuby only)
|
88
|
+
# * <tt>:gson</tt> (JRuby only)
|
89
|
+
# * <tt>:jr_jackson</tt> (JRuby only)
|
90
|
+
def use(new_adapter)
|
91
|
+
@adapter = load_adapter(new_adapter)
|
92
|
+
ensure
|
93
|
+
OptionsCache.reset
|
94
|
+
end
|
95
|
+
alias_method :adapter=, :use
|
96
|
+
alias_method :engine=, :use
|
97
|
+
|
98
|
+
def load_adapter(new_adapter)
|
99
|
+
case new_adapter
|
100
|
+
when String, Symbol
|
101
|
+
load_adapter_from_string_name new_adapter.to_s
|
102
|
+
when NilClass, FalseClass
|
103
|
+
load_adapter default_adapter
|
104
|
+
when Class, Module
|
105
|
+
new_adapter
|
106
|
+
else
|
107
|
+
fail ::LoadError, new_adapter
|
108
|
+
end
|
109
|
+
rescue ::LoadError => exception
|
110
|
+
raise AdapterError.build(exception)
|
111
|
+
end
|
112
|
+
|
113
|
+
# Decode a JSON string into Ruby.
|
114
|
+
#
|
115
|
+
# <b>Options</b>
|
116
|
+
#
|
117
|
+
# <tt>:symbolize_keys</tt> :: If true, will use symbols instead of strings for the keys.
|
118
|
+
# <tt>:adapter</tt> :: If set, the selected adapter will be used for this call.
|
119
|
+
def load(string, options = {})
|
120
|
+
adapter = current_adapter(options)
|
121
|
+
begin
|
122
|
+
adapter.load(string, options)
|
123
|
+
rescue adapter::ParseError => exception
|
124
|
+
raise ParseError.build(exception, string)
|
125
|
+
end
|
126
|
+
end
|
127
|
+
alias_method :decode, :load
|
128
|
+
|
129
|
+
def current_adapter(options = {})
|
130
|
+
if (new_adapter = options[:adapter])
|
131
|
+
load_adapter(new_adapter)
|
132
|
+
else
|
133
|
+
adapter
|
134
|
+
end
|
135
|
+
end
|
136
|
+
|
137
|
+
# Encodes a Ruby object as JSON.
|
138
|
+
def dump(object, options = {})
|
139
|
+
current_adapter(options).dump(object, options)
|
140
|
+
end
|
141
|
+
alias_method :encode, :dump
|
142
|
+
|
143
|
+
# Executes passed block using specified adapter.
|
144
|
+
def with_adapter(new_adapter)
|
145
|
+
old_adapter = adapter
|
146
|
+
self.adapter = new_adapter
|
147
|
+
yield
|
148
|
+
ensure
|
149
|
+
self.adapter = old_adapter
|
150
|
+
end
|
151
|
+
alias_method :with_engine, :with_adapter
|
152
|
+
|
153
|
+
private
|
154
|
+
|
155
|
+
def load_adapter_from_string_name(name)
|
156
|
+
name = ALIASES.fetch(name, name)
|
157
|
+
require "multi_json/adapters/#{name.downcase}"
|
158
|
+
klass_name = name.to_s.split('_').map(&:capitalize) * ''
|
159
|
+
MultiJson::Adapters.const_get(klass_name)
|
160
|
+
end
|
161
|
+
end
|