nutshell-crm 0.0.1
Sign up to get free protection for your applications and to get access to all the features.
- data/.gitignore +21 -0
- data/.rspec +2 -0
- data/Gemfile +4 -0
- data/README +0 -0
- data/Rakefile +2 -0
- data/lib/nutshell-crm.rb +78 -0
- data/lib/nutshell-crm/version.rb +3 -0
- data/nutshell-crm.gemspec +28 -0
- data/spec/nutshell-crm_spec.rb +212 -0
- data/spec/spec_helper.rb +8 -0
- data/vendor/bundle/bin/autospec +19 -0
- data/vendor/bundle/bin/htmldiff +21 -0
- data/vendor/bundle/bin/httparty +19 -0
- data/vendor/bundle/bin/ldiff +21 -0
- data/vendor/bundle/bin/rspec +19 -0
- data/vendor/bundle/gems/diff-lcs-1.1.3/.gemtest +0 -0
- data/vendor/bundle/gems/diff-lcs-1.1.3/History.rdoc +54 -0
- data/vendor/bundle/gems/diff-lcs-1.1.3/License.rdoc +38 -0
- data/vendor/bundle/gems/diff-lcs-1.1.3/Manifest.txt +27 -0
- data/vendor/bundle/gems/diff-lcs-1.1.3/README.rdoc +72 -0
- data/vendor/bundle/gems/diff-lcs-1.1.3/Rakefile +26 -0
- data/vendor/bundle/gems/diff-lcs-1.1.3/bin/htmldiff +32 -0
- data/vendor/bundle/gems/diff-lcs-1.1.3/bin/ldiff +6 -0
- data/vendor/bundle/gems/diff-lcs-1.1.3/diff-lcs.gemspec +51 -0
- data/vendor/bundle/gems/diff-lcs-1.1.3/docs/COPYING.txt +340 -0
- data/vendor/bundle/gems/diff-lcs-1.1.3/docs/artistic.html +289 -0
- data/vendor/bundle/gems/diff-lcs-1.1.3/lib/diff-lcs.rb +5 -0
- data/vendor/bundle/gems/diff-lcs-1.1.3/lib/diff/lcs.rb +1105 -0
- data/vendor/bundle/gems/diff-lcs-1.1.3/lib/diff/lcs/array.rb +21 -0
- data/vendor/bundle/gems/diff-lcs-1.1.3/lib/diff/lcs/block.rb +51 -0
- data/vendor/bundle/gems/diff-lcs-1.1.3/lib/diff/lcs/callbacks.rb +322 -0
- data/vendor/bundle/gems/diff-lcs-1.1.3/lib/diff/lcs/change.rb +169 -0
- data/vendor/bundle/gems/diff-lcs-1.1.3/lib/diff/lcs/htmldiff.rb +151 -0
- data/vendor/bundle/gems/diff-lcs-1.1.3/lib/diff/lcs/hunk.rb +242 -0
- data/vendor/bundle/gems/diff-lcs-1.1.3/lib/diff/lcs/ldiff.rb +210 -0
- data/vendor/bundle/gems/diff-lcs-1.1.3/lib/diff/lcs/string.rb +19 -0
- data/vendor/bundle/gems/diff-lcs-1.1.3/spec/diff_spec.rb +35 -0
- data/vendor/bundle/gems/diff-lcs-1.1.3/spec/lcs_spec.rb +36 -0
- data/vendor/bundle/gems/diff-lcs-1.1.3/spec/patch_spec.rb +390 -0
- data/vendor/bundle/gems/diff-lcs-1.1.3/spec/sdiff_spec.rb +204 -0
- data/vendor/bundle/gems/diff-lcs-1.1.3/spec/spec_helper.rb +284 -0
- data/vendor/bundle/gems/diff-lcs-1.1.3/spec/traverse_balanced_spec.rb +286 -0
- data/vendor/bundle/gems/diff-lcs-1.1.3/spec/traverse_sequences_spec.rb +83 -0
- data/vendor/bundle/gems/httparty-0.8.1/.gitignore +9 -0
- data/vendor/bundle/gems/httparty-0.8.1/Gemfile +8 -0
- data/vendor/bundle/gems/httparty-0.8.1/History +259 -0
- data/vendor/bundle/gems/httparty-0.8.1/MIT-LICENSE +20 -0
- data/vendor/bundle/gems/httparty-0.8.1/README.rdoc +54 -0
- data/vendor/bundle/gems/httparty-0.8.1/Rakefile +15 -0
- data/vendor/bundle/gems/httparty-0.8.1/bin/httparty +108 -0
- data/vendor/bundle/gems/httparty-0.8.1/cucumber.yml +1 -0
- data/vendor/bundle/gems/httparty-0.8.1/examples/aaws.rb +32 -0
- data/vendor/bundle/gems/httparty-0.8.1/examples/basic.rb +32 -0
- data/vendor/bundle/gems/httparty-0.8.1/examples/crack.rb +19 -0
- data/vendor/bundle/gems/httparty-0.8.1/examples/custom_parsers.rb +67 -0
- data/vendor/bundle/gems/httparty-0.8.1/examples/delicious.rb +37 -0
- data/vendor/bundle/gems/httparty-0.8.1/examples/google.rb +16 -0
- data/vendor/bundle/gems/httparty-0.8.1/examples/rubyurl.rb +14 -0
- data/vendor/bundle/gems/httparty-0.8.1/examples/tripit_sign_in.rb +33 -0
- data/vendor/bundle/gems/httparty-0.8.1/examples/twitter.rb +31 -0
- data/vendor/bundle/gems/httparty-0.8.1/examples/whoismyrep.rb +10 -0
- data/vendor/bundle/gems/httparty-0.8.1/features/basic_authentication.feature +20 -0
- data/vendor/bundle/gems/httparty-0.8.1/features/command_line.feature +7 -0
- data/vendor/bundle/gems/httparty-0.8.1/features/deals_with_http_error_codes.feature +26 -0
- data/vendor/bundle/gems/httparty-0.8.1/features/digest_authentication.feature +20 -0
- data/vendor/bundle/gems/httparty-0.8.1/features/handles_compressed_responses.feature +19 -0
- data/vendor/bundle/gems/httparty-0.8.1/features/handles_multiple_formats.feature +34 -0
- data/vendor/bundle/gems/httparty-0.8.1/features/steps/env.rb +22 -0
- data/vendor/bundle/gems/httparty-0.8.1/features/steps/httparty_response_steps.rb +26 -0
- data/vendor/bundle/gems/httparty-0.8.1/features/steps/httparty_steps.rb +27 -0
- data/vendor/bundle/gems/httparty-0.8.1/features/steps/mongrel_helper.rb +94 -0
- data/vendor/bundle/gems/httparty-0.8.1/features/steps/remote_service_steps.rb +69 -0
- data/vendor/bundle/gems/httparty-0.8.1/features/supports_redirection.feature +22 -0
- data/vendor/bundle/gems/httparty-0.8.1/features/supports_timeout_option.feature +13 -0
- data/vendor/bundle/gems/httparty-0.8.1/httparty.gemspec +24 -0
- data/vendor/bundle/gems/httparty-0.8.1/lib/httparty.rb +452 -0
- data/vendor/bundle/gems/httparty-0.8.1/lib/httparty/cookie_hash.rb +22 -0
- data/vendor/bundle/gems/httparty-0.8.1/lib/httparty/core_extensions.rb +9 -0
- data/vendor/bundle/gems/httparty-0.8.1/lib/httparty/exceptions.rb +26 -0
- data/vendor/bundle/gems/httparty-0.8.1/lib/httparty/hash_conversions.rb +51 -0
- data/vendor/bundle/gems/httparty-0.8.1/lib/httparty/module_inheritable_attributes.rb +34 -0
- data/vendor/bundle/gems/httparty-0.8.1/lib/httparty/net_digest_auth.rb +71 -0
- data/vendor/bundle/gems/httparty-0.8.1/lib/httparty/parser.rb +141 -0
- data/vendor/bundle/gems/httparty-0.8.1/lib/httparty/request.rb +257 -0
- data/vendor/bundle/gems/httparty-0.8.1/lib/httparty/response.rb +85 -0
- data/vendor/bundle/gems/httparty-0.8.1/lib/httparty/version.rb +3 -0
- data/vendor/bundle/gems/httparty-0.8.1/spec/fixtures/delicious.xml +23 -0
- data/vendor/bundle/gems/httparty-0.8.1/spec/fixtures/empty.xml +0 -0
- data/vendor/bundle/gems/httparty-0.8.1/spec/fixtures/google.html +3 -0
- data/vendor/bundle/gems/httparty-0.8.1/spec/fixtures/ssl/generate.sh +29 -0
- data/vendor/bundle/gems/httparty-0.8.1/spec/fixtures/ssl/generated/1fe462c2.0 +16 -0
- data/vendor/bundle/gems/httparty-0.8.1/spec/fixtures/ssl/generated/bogushost.crt +13 -0
- data/vendor/bundle/gems/httparty-0.8.1/spec/fixtures/ssl/generated/ca.crt +16 -0
- data/vendor/bundle/gems/httparty-0.8.1/spec/fixtures/ssl/generated/ca.key +15 -0
- data/vendor/bundle/gems/httparty-0.8.1/spec/fixtures/ssl/generated/selfsigned.crt +14 -0
- data/vendor/bundle/gems/httparty-0.8.1/spec/fixtures/ssl/generated/server.crt +13 -0
- data/vendor/bundle/gems/httparty-0.8.1/spec/fixtures/ssl/generated/server.key +15 -0
- data/vendor/bundle/gems/httparty-0.8.1/spec/fixtures/ssl/openssl-exts.cnf +9 -0
- data/vendor/bundle/gems/httparty-0.8.1/spec/fixtures/twitter.json +1 -0
- data/vendor/bundle/gems/httparty-0.8.1/spec/fixtures/twitter.xml +403 -0
- data/vendor/bundle/gems/httparty-0.8.1/spec/fixtures/undefined_method_add_node_for_nil.xml +2 -0
- data/vendor/bundle/gems/httparty-0.8.1/spec/httparty/cookie_hash_spec.rb +71 -0
- data/vendor/bundle/gems/httparty-0.8.1/spec/httparty/net_digest_auth_spec.rb +93 -0
- data/vendor/bundle/gems/httparty-0.8.1/spec/httparty/parser_spec.rb +155 -0
- data/vendor/bundle/gems/httparty-0.8.1/spec/httparty/request_spec.rb +544 -0
- data/vendor/bundle/gems/httparty-0.8.1/spec/httparty/response_spec.rb +193 -0
- data/vendor/bundle/gems/httparty-0.8.1/spec/httparty/ssl_spec.rb +54 -0
- data/vendor/bundle/gems/httparty-0.8.1/spec/httparty_spec.rb +621 -0
- data/vendor/bundle/gems/httparty-0.8.1/spec/spec.opts +3 -0
- data/vendor/bundle/gems/httparty-0.8.1/spec/spec_helper.rb +22 -0
- data/vendor/bundle/gems/httparty-0.8.1/spec/support/ssl_test_helper.rb +25 -0
- data/vendor/bundle/gems/httparty-0.8.1/spec/support/ssl_test_server.rb +69 -0
- data/vendor/bundle/gems/httparty-0.8.1/spec/support/stub_response.rb +30 -0
- data/vendor/bundle/gems/httparty-0.8.1/website/css/common.css +47 -0
- data/vendor/bundle/gems/httparty-0.8.1/website/index.html +73 -0
- data/vendor/bundle/gems/json-1.6.3/.gitignore +8 -0
- data/vendor/bundle/gems/json-1.6.3/.travis.yml +15 -0
- data/vendor/bundle/gems/json-1.6.3/CHANGES +223 -0
- data/vendor/bundle/gems/json-1.6.3/COPYING +58 -0
- data/vendor/bundle/gems/json-1.6.3/COPYING-json-jruby +57 -0
- data/vendor/bundle/gems/json-1.6.3/GPL +340 -0
- data/vendor/bundle/gems/json-1.6.3/Gemfile +11 -0
- data/vendor/bundle/gems/json-1.6.3/README-json-jruby.markdown +33 -0
- data/vendor/bundle/gems/json-1.6.3/README.rdoc +358 -0
- data/vendor/bundle/gems/json-1.6.3/Rakefile +408 -0
- data/vendor/bundle/gems/json-1.6.3/TODO +1 -0
- data/vendor/bundle/gems/json-1.6.3/VERSION +1 -0
- data/vendor/bundle/gems/json-1.6.3/benchmarks/data-p4-3GHz-ruby18/.keep +0 -0
- data/vendor/bundle/gems/json-1.6.3/benchmarks/data-p4-3GHz-ruby18/GeneratorBenchmarkComparison.log +52 -0
- data/vendor/bundle/gems/json-1.6.3/benchmarks/data-p4-3GHz-ruby18/GeneratorBenchmarkExt#generator_fast-autocorrelation.dat +1000 -0
- data/vendor/bundle/gems/json-1.6.3/benchmarks/data-p4-3GHz-ruby18/GeneratorBenchmarkExt#generator_fast.dat +1001 -0
- data/vendor/bundle/gems/json-1.6.3/benchmarks/data-p4-3GHz-ruby18/GeneratorBenchmarkExt#generator_pretty-autocorrelation.dat +900 -0
- data/vendor/bundle/gems/json-1.6.3/benchmarks/data-p4-3GHz-ruby18/GeneratorBenchmarkExt#generator_pretty.dat +901 -0
- data/vendor/bundle/gems/json-1.6.3/benchmarks/data-p4-3GHz-ruby18/GeneratorBenchmarkExt#generator_safe-autocorrelation.dat +1000 -0
- data/vendor/bundle/gems/json-1.6.3/benchmarks/data-p4-3GHz-ruby18/GeneratorBenchmarkExt#generator_safe.dat +1001 -0
- data/vendor/bundle/gems/json-1.6.3/benchmarks/data-p4-3GHz-ruby18/GeneratorBenchmarkExt.log +261 -0
- data/vendor/bundle/gems/json-1.6.3/benchmarks/data-p4-3GHz-ruby18/GeneratorBenchmarkPure#generator_fast-autocorrelation.dat +1000 -0
- data/vendor/bundle/gems/json-1.6.3/benchmarks/data-p4-3GHz-ruby18/GeneratorBenchmarkPure#generator_fast.dat +1001 -0
- data/vendor/bundle/gems/json-1.6.3/benchmarks/data-p4-3GHz-ruby18/GeneratorBenchmarkPure#generator_pretty-autocorrelation.dat +1000 -0
- data/vendor/bundle/gems/json-1.6.3/benchmarks/data-p4-3GHz-ruby18/GeneratorBenchmarkPure#generator_pretty.dat +1001 -0
- data/vendor/bundle/gems/json-1.6.3/benchmarks/data-p4-3GHz-ruby18/GeneratorBenchmarkPure#generator_safe-autocorrelation.dat +1000 -0
- data/vendor/bundle/gems/json-1.6.3/benchmarks/data-p4-3GHz-ruby18/GeneratorBenchmarkPure#generator_safe.dat +1001 -0
- data/vendor/bundle/gems/json-1.6.3/benchmarks/data-p4-3GHz-ruby18/GeneratorBenchmarkPure.log +262 -0
- data/vendor/bundle/gems/json-1.6.3/benchmarks/data-p4-3GHz-ruby18/GeneratorBenchmarkRails#generator-autocorrelation.dat +1000 -0
- data/vendor/bundle/gems/json-1.6.3/benchmarks/data-p4-3GHz-ruby18/GeneratorBenchmarkRails#generator.dat +1001 -0
- data/vendor/bundle/gems/json-1.6.3/benchmarks/data-p4-3GHz-ruby18/GeneratorBenchmarkRails.log +82 -0
- data/vendor/bundle/gems/json-1.6.3/benchmarks/data-p4-3GHz-ruby18/ParserBenchmarkComparison.log +34 -0
- data/vendor/bundle/gems/json-1.6.3/benchmarks/data-p4-3GHz-ruby18/ParserBenchmarkExt#parser-autocorrelation.dat +900 -0
- data/vendor/bundle/gems/json-1.6.3/benchmarks/data-p4-3GHz-ruby18/ParserBenchmarkExt#parser.dat +901 -0
- data/vendor/bundle/gems/json-1.6.3/benchmarks/data-p4-3GHz-ruby18/ParserBenchmarkExt.log +81 -0
- data/vendor/bundle/gems/json-1.6.3/benchmarks/data-p4-3GHz-ruby18/ParserBenchmarkPure#parser-autocorrelation.dat +1000 -0
- data/vendor/bundle/gems/json-1.6.3/benchmarks/data-p4-3GHz-ruby18/ParserBenchmarkPure#parser.dat +1001 -0
- data/vendor/bundle/gems/json-1.6.3/benchmarks/data-p4-3GHz-ruby18/ParserBenchmarkPure.log +82 -0
- data/vendor/bundle/gems/json-1.6.3/benchmarks/data-p4-3GHz-ruby18/ParserBenchmarkRails#parser-autocorrelation.dat +1000 -0
- data/vendor/bundle/gems/json-1.6.3/benchmarks/data-p4-3GHz-ruby18/ParserBenchmarkRails#parser.dat +1001 -0
- data/vendor/bundle/gems/json-1.6.3/benchmarks/data-p4-3GHz-ruby18/ParserBenchmarkRails.log +82 -0
- data/vendor/bundle/gems/json-1.6.3/benchmarks/data-p4-3GHz-ruby18/ParserBenchmarkYAML#parser-autocorrelation.dat +1000 -0
- data/vendor/bundle/gems/json-1.6.3/benchmarks/data-p4-3GHz-ruby18/ParserBenchmarkYAML#parser.dat +1001 -0
- data/vendor/bundle/gems/json-1.6.3/benchmarks/data-p4-3GHz-ruby18/ParserBenchmarkYAML.log +82 -0
- data/vendor/bundle/gems/json-1.6.3/benchmarks/data/.keep +0 -0
- data/vendor/bundle/gems/json-1.6.3/benchmarks/generator2_benchmark.rb +222 -0
- data/vendor/bundle/gems/json-1.6.3/benchmarks/generator_benchmark.rb +224 -0
- data/vendor/bundle/gems/json-1.6.3/benchmarks/ohai.json +1216 -0
- data/vendor/bundle/gems/json-1.6.3/benchmarks/ohai.ruby +1 -0
- data/vendor/bundle/gems/json-1.6.3/benchmarks/parser2_benchmark.rb +251 -0
- data/vendor/bundle/gems/json-1.6.3/benchmarks/parser_benchmark.rb +259 -0
- data/vendor/bundle/gems/json-1.6.3/data/example.json +1 -0
- data/vendor/bundle/gems/json-1.6.3/data/index.html +38 -0
- data/vendor/bundle/gems/json-1.6.3/data/prototype.js +4184 -0
- data/vendor/bundle/gems/json-1.6.3/diagrams/.keep +0 -0
- data/vendor/bundle/gems/json-1.6.3/ext/json/ext/fbuffer/fbuffer.h +156 -0
- data/vendor/bundle/gems/json-1.6.3/ext/json/ext/generator/Makefile +187 -0
- data/vendor/bundle/gems/json-1.6.3/ext/json/ext/generator/extconf.rb +13 -0
- data/vendor/bundle/gems/json-1.6.3/ext/json/ext/generator/generator.bundle +0 -0
- data/vendor/bundle/gems/json-1.6.3/ext/json/ext/generator/generator.c +1384 -0
- data/vendor/bundle/gems/json-1.6.3/ext/json/ext/generator/generator.h +161 -0
- data/vendor/bundle/gems/json-1.6.3/ext/json/ext/generator/generator.o +0 -0
- data/vendor/bundle/gems/json-1.6.3/ext/json/ext/json/ext/generator.bundle +0 -0
- data/vendor/bundle/gems/json-1.6.3/ext/json/ext/json/ext/parser.bundle +0 -0
- data/vendor/bundle/gems/json-1.6.3/ext/json/ext/parser/Makefile +187 -0
- data/vendor/bundle/gems/json-1.6.3/ext/json/ext/parser/extconf.rb +13 -0
- data/vendor/bundle/gems/json-1.6.3/ext/json/ext/parser/parser.bundle +0 -0
- data/vendor/bundle/gems/json-1.6.3/ext/json/ext/parser/parser.c +2197 -0
- data/vendor/bundle/gems/json-1.6.3/ext/json/ext/parser/parser.h +77 -0
- data/vendor/bundle/gems/json-1.6.3/ext/json/ext/parser/parser.o +0 -0
- data/vendor/bundle/gems/json-1.6.3/ext/json/ext/parser/parser.rl +920 -0
- data/vendor/bundle/gems/json-1.6.3/install.rb +19 -0
- data/vendor/bundle/gems/json-1.6.3/java/lib/bytelist-1.0.6.jar +0 -0
- data/vendor/bundle/gems/json-1.6.3/java/lib/jcodings.jar +0 -0
- data/vendor/bundle/gems/json-1.6.3/java/src/json/ext/ByteListTranscoder.java +167 -0
- data/vendor/bundle/gems/json-1.6.3/java/src/json/ext/Generator.java +437 -0
- data/vendor/bundle/gems/json-1.6.3/java/src/json/ext/GeneratorMethods.java +232 -0
- data/vendor/bundle/gems/json-1.6.3/java/src/json/ext/GeneratorService.java +43 -0
- data/vendor/bundle/gems/json-1.6.3/java/src/json/ext/GeneratorState.java +522 -0
- data/vendor/bundle/gems/json-1.6.3/java/src/json/ext/OptionsReader.java +119 -0
- data/vendor/bundle/gems/json-1.6.3/java/src/json/ext/Parser.java +2589 -0
- data/vendor/bundle/gems/json-1.6.3/java/src/json/ext/Parser.rl +913 -0
- data/vendor/bundle/gems/json-1.6.3/java/src/json/ext/ParserService.java +35 -0
- data/vendor/bundle/gems/json-1.6.3/java/src/json/ext/RuntimeInfo.java +121 -0
- data/vendor/bundle/gems/json-1.6.3/java/src/json/ext/StringDecoder.java +166 -0
- data/vendor/bundle/gems/json-1.6.3/java/src/json/ext/StringEncoder.java +106 -0
- data/vendor/bundle/gems/json-1.6.3/java/src/json/ext/Utils.java +89 -0
- data/vendor/bundle/gems/json-1.6.3/json-java.gemspec +22 -0
- data/vendor/bundle/gems/json-1.6.3/json.gemspec +40 -0
- data/vendor/bundle/gems/json-1.6.3/json_pure.gemspec +42 -0
- data/vendor/bundle/gems/json-1.6.3/lib/json.rb +62 -0
- data/vendor/bundle/gems/json-1.6.3/lib/json/add/bigdecimal.rb +21 -0
- data/vendor/bundle/gems/json-1.6.3/lib/json/add/complex.rb +22 -0
- data/vendor/bundle/gems/json-1.6.3/lib/json/add/core.rb +11 -0
- data/vendor/bundle/gems/json-1.6.3/lib/json/add/date.rb +34 -0
- data/vendor/bundle/gems/json-1.6.3/lib/json/add/date_time.rb +50 -0
- data/vendor/bundle/gems/json-1.6.3/lib/json/add/exception.rb +31 -0
- data/vendor/bundle/gems/json-1.6.3/lib/json/add/ostruct.rb +31 -0
- data/vendor/bundle/gems/json-1.6.3/lib/json/add/range.rb +29 -0
- data/vendor/bundle/gems/json-1.6.3/lib/json/add/rational.rb +22 -0
- data/vendor/bundle/gems/json-1.6.3/lib/json/add/regexp.rb +30 -0
- data/vendor/bundle/gems/json-1.6.3/lib/json/add/struct.rb +30 -0
- data/vendor/bundle/gems/json-1.6.3/lib/json/add/symbol.rb +25 -0
- data/vendor/bundle/gems/json-1.6.3/lib/json/add/time.rb +35 -0
- data/vendor/bundle/gems/json-1.6.3/lib/json/common.rb +470 -0
- data/vendor/bundle/gems/json-1.6.3/lib/json/ext.rb +21 -0
- data/vendor/bundle/gems/json-1.6.3/lib/json/ext/.keep +0 -0
- data/vendor/bundle/gems/json-1.6.3/lib/json/pure.rb +21 -0
- data/vendor/bundle/gems/json-1.6.3/lib/json/pure/generator.rb +468 -0
- data/vendor/bundle/gems/json-1.6.3/lib/json/pure/parser.rb +359 -0
- data/vendor/bundle/gems/json-1.6.3/lib/json/version.rb +8 -0
- data/vendor/bundle/gems/json-1.6.3/tests/fixtures/fail1.json +1 -0
- data/vendor/bundle/gems/json-1.6.3/tests/fixtures/fail10.json +1 -0
- data/vendor/bundle/gems/json-1.6.3/tests/fixtures/fail11.json +1 -0
- data/vendor/bundle/gems/json-1.6.3/tests/fixtures/fail12.json +1 -0
- data/vendor/bundle/gems/json-1.6.3/tests/fixtures/fail13.json +1 -0
- data/vendor/bundle/gems/json-1.6.3/tests/fixtures/fail14.json +1 -0
- data/vendor/bundle/gems/json-1.6.3/tests/fixtures/fail18.json +1 -0
- data/vendor/bundle/gems/json-1.6.3/tests/fixtures/fail19.json +1 -0
- data/vendor/bundle/gems/json-1.6.3/tests/fixtures/fail2.json +1 -0
- data/vendor/bundle/gems/json-1.6.3/tests/fixtures/fail20.json +1 -0
- data/vendor/bundle/gems/json-1.6.3/tests/fixtures/fail21.json +1 -0
- data/vendor/bundle/gems/json-1.6.3/tests/fixtures/fail22.json +1 -0
- data/vendor/bundle/gems/json-1.6.3/tests/fixtures/fail23.json +1 -0
- data/vendor/bundle/gems/json-1.6.3/tests/fixtures/fail24.json +1 -0
- data/vendor/bundle/gems/json-1.6.3/tests/fixtures/fail25.json +1 -0
- data/vendor/bundle/gems/json-1.6.3/tests/fixtures/fail27.json +2 -0
- data/vendor/bundle/gems/json-1.6.3/tests/fixtures/fail28.json +2 -0
- data/vendor/bundle/gems/json-1.6.3/tests/fixtures/fail3.json +1 -0
- data/vendor/bundle/gems/json-1.6.3/tests/fixtures/fail4.json +1 -0
- data/vendor/bundle/gems/json-1.6.3/tests/fixtures/fail5.json +1 -0
- data/vendor/bundle/gems/json-1.6.3/tests/fixtures/fail6.json +1 -0
- data/vendor/bundle/gems/json-1.6.3/tests/fixtures/fail7.json +1 -0
- data/vendor/bundle/gems/json-1.6.3/tests/fixtures/fail8.json +1 -0
- data/vendor/bundle/gems/json-1.6.3/tests/fixtures/fail9.json +1 -0
- data/vendor/bundle/gems/json-1.6.3/tests/fixtures/pass1.json +56 -0
- data/vendor/bundle/gems/json-1.6.3/tests/fixtures/pass15.json +1 -0
- data/vendor/bundle/gems/json-1.6.3/tests/fixtures/pass16.json +1 -0
- data/vendor/bundle/gems/json-1.6.3/tests/fixtures/pass17.json +1 -0
- data/vendor/bundle/gems/json-1.6.3/tests/fixtures/pass2.json +1 -0
- data/vendor/bundle/gems/json-1.6.3/tests/fixtures/pass26.json +1 -0
- data/vendor/bundle/gems/json-1.6.3/tests/fixtures/pass3.json +6 -0
- data/vendor/bundle/gems/json-1.6.3/tests/setup_variant.rb +11 -0
- data/vendor/bundle/gems/json-1.6.3/tests/test_json.rb +476 -0
- data/vendor/bundle/gems/json-1.6.3/tests/test_json_addition.rb +188 -0
- data/vendor/bundle/gems/json-1.6.3/tests/test_json_encoding.rb +65 -0
- data/vendor/bundle/gems/json-1.6.3/tests/test_json_fixtures.rb +35 -0
- data/vendor/bundle/gems/json-1.6.3/tests/test_json_generate.rb +249 -0
- data/vendor/bundle/gems/json-1.6.3/tests/test_json_string_matching.rb +40 -0
- data/vendor/bundle/gems/json-1.6.3/tests/test_json_unicode.rb +72 -0
- data/vendor/bundle/gems/json-1.6.3/tools/fuzz.rb +139 -0
- data/vendor/bundle/gems/json-1.6.3/tools/server.rb +62 -0
- data/vendor/bundle/gems/multi_json-1.0.4/.document +5 -0
- data/vendor/bundle/gems/multi_json-1.0.4/.rspec +3 -0
- data/vendor/bundle/gems/multi_json-1.0.4/.travis.yml +7 -0
- data/vendor/bundle/gems/multi_json-1.0.4/Gemfile +6 -0
- data/vendor/bundle/gems/multi_json-1.0.4/LICENSE.md +20 -0
- data/vendor/bundle/gems/multi_json-1.0.4/README.md +94 -0
- data/vendor/bundle/gems/multi_json-1.0.4/Rakefile +25 -0
- data/vendor/bundle/gems/multi_json-1.0.4/lib/multi_json.rb +85 -0
- data/vendor/bundle/gems/multi_json-1.0.4/lib/multi_json/engines/json_common.rb +27 -0
- data/vendor/bundle/gems/multi_json-1.0.4/lib/multi_json/engines/json_gem.rb +12 -0
- data/vendor/bundle/gems/multi_json-1.0.4/lib/multi_json/engines/json_pure.rb +12 -0
- data/vendor/bundle/gems/multi_json-1.0.4/lib/multi_json/engines/ok_json.rb +48 -0
- data/vendor/bundle/gems/multi_json-1.0.4/lib/multi_json/engines/yajl.rb +18 -0
- data/vendor/bundle/gems/multi_json-1.0.4/lib/multi_json/vendor/ok_json.rb +587 -0
- data/vendor/bundle/gems/multi_json-1.0.4/lib/multi_json/version.rb +3 -0
- data/vendor/bundle/gems/multi_json-1.0.4/multi_json.gemspec +22 -0
- data/vendor/bundle/gems/multi_json-1.0.4/spec/helper.rb +35 -0
- data/vendor/bundle/gems/multi_json-1.0.4/spec/multi_json_spec.rb +178 -0
- data/vendor/bundle/gems/multi_xml-0.4.1/.gemtest +0 -0
- data/vendor/bundle/gems/multi_xml-0.4.1/.gitignore +10 -0
- data/vendor/bundle/gems/multi_xml-0.4.1/.rspec +3 -0
- data/vendor/bundle/gems/multi_xml-0.4.1/.travis.yml +7 -0
- data/vendor/bundle/gems/multi_xml-0.4.1/.yardopts +5 -0
- data/vendor/bundle/gems/multi_xml-0.4.1/Gemfile +9 -0
- data/vendor/bundle/gems/multi_xml-0.4.1/LICENSE.md +20 -0
- data/vendor/bundle/gems/multi_xml-0.4.1/README.md +113 -0
- data/vendor/bundle/gems/multi_xml-0.4.1/Rakefile +23 -0
- data/vendor/bundle/gems/multi_xml-0.4.1/lib/multi_xml.rb +237 -0
- data/vendor/bundle/gems/multi_xml-0.4.1/lib/multi_xml/parsers/libxml.rb +30 -0
- data/vendor/bundle/gems/multi_xml-0.4.1/lib/multi_xml/parsers/libxml2_parser.rb +66 -0
- data/vendor/bundle/gems/multi_xml-0.4.1/lib/multi_xml/parsers/nokogiri.rb +32 -0
- data/vendor/bundle/gems/multi_xml-0.4.1/lib/multi_xml/parsers/ox.rb +97 -0
- data/vendor/bundle/gems/multi_xml-0.4.1/lib/multi_xml/parsers/rexml.rb +113 -0
- data/vendor/bundle/gems/multi_xml-0.4.1/lib/multi_xml/version.rb +3 -0
- data/vendor/bundle/gems/multi_xml-0.4.1/multi_xml.gemspec +24 -0
- data/vendor/bundle/gems/multi_xml-0.4.1/spec/helper.rb +3 -0
- data/vendor/bundle/gems/multi_xml-0.4.1/spec/multi_xml_spec.rb +41 -0
- data/vendor/bundle/gems/multi_xml-0.4.1/spec/parser_shared_example.rb +552 -0
- data/vendor/bundle/gems/multi_xml-0.4.1/spec/speed.rb +63 -0
- data/vendor/bundle/gems/rspec-2.7.0/.document +2 -0
- data/vendor/bundle/gems/rspec-2.7.0/.gitignore +8 -0
- data/vendor/bundle/gems/rspec-2.7.0/Gemfile +7 -0
- data/vendor/bundle/gems/rspec-2.7.0/License.txt +22 -0
- data/vendor/bundle/gems/rspec-2.7.0/README.markdown +47 -0
- data/vendor/bundle/gems/rspec-2.7.0/Rakefile +30 -0
- data/vendor/bundle/gems/rspec-2.7.0/lib/rspec.rb +4 -0
- data/vendor/bundle/gems/rspec-2.7.0/lib/rspec/version.rb +5 -0
- data/vendor/bundle/gems/rspec-2.7.0/rspec.gemspec +33 -0
- data/vendor/bundle/gems/rspec-core-2.7.1/README.md +68 -0
- data/vendor/bundle/gems/rspec-core-2.7.1/exe/autospec +13 -0
- data/vendor/bundle/gems/rspec-core-2.7.1/exe/rspec +25 -0
- data/vendor/bundle/gems/rspec-core-2.7.1/features/Autotest.md +38 -0
- data/vendor/bundle/gems/rspec-core-2.7.1/features/README.md +17 -0
- data/vendor/bundle/gems/rspec-core-2.7.1/features/Upgrade.md +364 -0
- data/vendor/bundle/gems/rspec-core-2.7.1/features/command_line/README.md +28 -0
- data/vendor/bundle/gems/rspec-core-2.7.1/features/command_line/configure.feature +22 -0
- data/vendor/bundle/gems/rspec-core-2.7.1/features/command_line/example_name_option.feature +86 -0
- data/vendor/bundle/gems/rspec-core-2.7.1/features/command_line/exit_status.feature +83 -0
- data/vendor/bundle/gems/rspec-core-2.7.1/features/command_line/format_option.feature +81 -0
- data/vendor/bundle/gems/rspec-core-2.7.1/features/command_line/line_number_appended_to_path.feature +140 -0
- data/vendor/bundle/gems/rspec-core-2.7.1/features/command_line/line_number_option.feature +58 -0
- data/vendor/bundle/gems/rspec-core-2.7.1/features/command_line/pattern_option.feature +31 -0
- data/vendor/bundle/gems/rspec-core-2.7.1/features/command_line/rake_task.feature +68 -0
- data/vendor/bundle/gems/rspec-core-2.7.1/features/command_line/ruby.feature +22 -0
- data/vendor/bundle/gems/rspec-core-2.7.1/features/command_line/tag.feature +90 -0
- data/vendor/bundle/gems/rspec-core-2.7.1/features/configuration/alias_example_to.feature +48 -0
- data/vendor/bundle/gems/rspec-core-2.7.1/features/configuration/custom_settings.feature +84 -0
- data/vendor/bundle/gems/rspec-core-2.7.1/features/configuration/default_path.feature +38 -0
- data/vendor/bundle/gems/rspec-core-2.7.1/features/configuration/fail_fast.feature +77 -0
- data/vendor/bundle/gems/rspec-core-2.7.1/features/configuration/read_options_from_file.feature +87 -0
- data/vendor/bundle/gems/rspec-core-2.7.1/features/example_groups/basic_structure.feature +55 -0
- data/vendor/bundle/gems/rspec-core-2.7.1/features/example_groups/shared_context.feature +74 -0
- data/vendor/bundle/gems/rspec-core-2.7.1/features/example_groups/shared_examples.feature +204 -0
- data/vendor/bundle/gems/rspec-core-2.7.1/features/expectation_framework_integration/configure_expectation_framework.feature +73 -0
- data/vendor/bundle/gems/rspec-core-2.7.1/features/filtering/exclusion_filters.feature +139 -0
- data/vendor/bundle/gems/rspec-core-2.7.1/features/filtering/if_and_unless.feature +168 -0
- data/vendor/bundle/gems/rspec-core-2.7.1/features/filtering/inclusion_filters.feature +105 -0
- data/vendor/bundle/gems/rspec-core-2.7.1/features/filtering/run_all_when_everything_filtered.feature +46 -0
- data/vendor/bundle/gems/rspec-core-2.7.1/features/formatters/custom_formatter.feature +36 -0
- data/vendor/bundle/gems/rspec-core-2.7.1/features/formatters/text_formatter.feature +46 -0
- data/vendor/bundle/gems/rspec-core-2.7.1/features/helper_methods/arbitrary_methods.feature +40 -0
- data/vendor/bundle/gems/rspec-core-2.7.1/features/helper_methods/let.feature +50 -0
- data/vendor/bundle/gems/rspec-core-2.7.1/features/helper_methods/modules.feature +149 -0
- data/vendor/bundle/gems/rspec-core-2.7.1/features/hooks/around_hooks.feature +343 -0
- data/vendor/bundle/gems/rspec-core-2.7.1/features/hooks/before_and_after_hooks.feature +423 -0
- data/vendor/bundle/gems/rspec-core-2.7.1/features/hooks/filtering.feature +234 -0
- data/vendor/bundle/gems/rspec-core-2.7.1/features/metadata/current_example.feature +17 -0
- data/vendor/bundle/gems/rspec-core-2.7.1/features/metadata/described_class.feature +17 -0
- data/vendor/bundle/gems/rspec-core-2.7.1/features/metadata/user_defined.feature +113 -0
- data/vendor/bundle/gems/rspec-core-2.7.1/features/mock_framework_integration/use_any_framework.feature +106 -0
- data/vendor/bundle/gems/rspec-core-2.7.1/features/mock_framework_integration/use_flexmock.feature +96 -0
- data/vendor/bundle/gems/rspec-core-2.7.1/features/mock_framework_integration/use_mocha.feature +97 -0
- data/vendor/bundle/gems/rspec-core-2.7.1/features/mock_framework_integration/use_rr.feature +98 -0
- data/vendor/bundle/gems/rspec-core-2.7.1/features/mock_framework_integration/use_rspec.feature +97 -0
- data/vendor/bundle/gems/rspec-core-2.7.1/features/pending/pending_examples.feature +229 -0
- data/vendor/bundle/gems/rspec-core-2.7.1/features/spec_files/arbitrary_file_suffix.feature +13 -0
- data/vendor/bundle/gems/rspec-core-2.7.1/features/step_definitions/additional_cli_steps.rb +30 -0
- data/vendor/bundle/gems/rspec-core-2.7.1/features/subject/attribute_of_subject.feature +122 -0
- data/vendor/bundle/gems/rspec-core-2.7.1/features/subject/explicit_subject.feature +78 -0
- data/vendor/bundle/gems/rspec-core-2.7.1/features/subject/implicit_receiver.feature +29 -0
- data/vendor/bundle/gems/rspec-core-2.7.1/features/subject/implicit_subject.feature +30 -0
- data/vendor/bundle/gems/rspec-core-2.7.1/features/support/env.rb +5 -0
- data/vendor/bundle/gems/rspec-core-2.7.1/lib/autotest/discover.rb +1 -0
- data/vendor/bundle/gems/rspec-core-2.7.1/lib/autotest/rspec2.rb +73 -0
- data/vendor/bundle/gems/rspec-core-2.7.1/lib/rspec/autorun.rb +2 -0
- data/vendor/bundle/gems/rspec-core-2.7.1/lib/rspec/core.rb +81 -0
- data/vendor/bundle/gems/rspec-core-2.7.1/lib/rspec/core/backward_compatibility.rb +63 -0
- data/vendor/bundle/gems/rspec-core-2.7.1/lib/rspec/core/command_line.rb +32 -0
- data/vendor/bundle/gems/rspec-core-2.7.1/lib/rspec/core/command_line_configuration.rb +62 -0
- data/vendor/bundle/gems/rspec-core-2.7.1/lib/rspec/core/configuration.rb +558 -0
- data/vendor/bundle/gems/rspec-core-2.7.1/lib/rspec/core/configuration_options.rb +139 -0
- data/vendor/bundle/gems/rspec-core-2.7.1/lib/rspec/core/deprecation.rb +48 -0
- data/vendor/bundle/gems/rspec-core-2.7.1/lib/rspec/core/drb_command_line.rb +23 -0
- data/vendor/bundle/gems/rspec-core-2.7.1/lib/rspec/core/dsl.rb +11 -0
- data/vendor/bundle/gems/rspec-core-2.7.1/lib/rspec/core/errors.rb +13 -0
- data/vendor/bundle/gems/rspec-core-2.7.1/lib/rspec/core/example.rb +178 -0
- data/vendor/bundle/gems/rspec-core-2.7.1/lib/rspec/core/example_group.rb +348 -0
- data/vendor/bundle/gems/rspec-core-2.7.1/lib/rspec/core/expecting/with_rspec.rb +9 -0
- data/vendor/bundle/gems/rspec-core-2.7.1/lib/rspec/core/expecting/with_stdlib.rb +9 -0
- data/vendor/bundle/gems/rspec-core-2.7.1/lib/rspec/core/extensions.rb +3 -0
- data/vendor/bundle/gems/rspec-core-2.7.1/lib/rspec/core/extensions/instance_eval_with_args.rb +39 -0
- data/vendor/bundle/gems/rspec-core-2.7.1/lib/rspec/core/extensions/kernel.rb +9 -0
- data/vendor/bundle/gems/rspec-core-2.7.1/lib/rspec/core/extensions/module_eval_with_args.rb +34 -0
- data/vendor/bundle/gems/rspec-core-2.7.1/lib/rspec/core/formatters/base_formatter.rb +172 -0
- data/vendor/bundle/gems/rspec-core-2.7.1/lib/rspec/core/formatters/base_text_formatter.rb +185 -0
- data/vendor/bundle/gems/rspec-core-2.7.1/lib/rspec/core/formatters/documentation_formatter.rb +71 -0
- data/vendor/bundle/gems/rspec-core-2.7.1/lib/rspec/core/formatters/helpers.rb +24 -0
- data/vendor/bundle/gems/rspec-core-2.7.1/lib/rspec/core/formatters/html_formatter.rb +458 -0
- data/vendor/bundle/gems/rspec-core-2.7.1/lib/rspec/core/formatters/progress_formatter.rb +32 -0
- data/vendor/bundle/gems/rspec-core-2.7.1/lib/rspec/core/formatters/snippet_extractor.rb +58 -0
- data/vendor/bundle/gems/rspec-core-2.7.1/lib/rspec/core/formatters/text_mate_formatter.rb +34 -0
- data/vendor/bundle/gems/rspec-core-2.7.1/lib/rspec/core/hooks.rb +160 -0
- data/vendor/bundle/gems/rspec-core-2.7.1/lib/rspec/core/let.rb +101 -0
- data/vendor/bundle/gems/rspec-core-2.7.1/lib/rspec/core/load_path.rb +3 -0
- data/vendor/bundle/gems/rspec-core-2.7.1/lib/rspec/core/metadata.rb +229 -0
- data/vendor/bundle/gems/rspec-core-2.7.1/lib/rspec/core/metadata_hash_builder.rb +93 -0
- data/vendor/bundle/gems/rspec-core-2.7.1/lib/rspec/core/mocking/with_absolutely_nothing.rb +11 -0
- data/vendor/bundle/gems/rspec-core-2.7.1/lib/rspec/core/mocking/with_flexmock.rb +27 -0
- data/vendor/bundle/gems/rspec-core-2.7.1/lib/rspec/core/mocking/with_mocha.rb +23 -0
- data/vendor/bundle/gems/rspec-core-2.7.1/lib/rspec/core/mocking/with_rr.rb +27 -0
- data/vendor/bundle/gems/rspec-core-2.7.1/lib/rspec/core/mocking/with_rspec.rb +23 -0
- data/vendor/bundle/gems/rspec-core-2.7.1/lib/rspec/core/option_parser.rb +147 -0
- data/vendor/bundle/gems/rspec-core-2.7.1/lib/rspec/core/pending.rb +38 -0
- data/vendor/bundle/gems/rspec-core-2.7.1/lib/rspec/core/rake_task.rb +201 -0
- data/vendor/bundle/gems/rspec-core-2.7.1/lib/rspec/core/reporter.rb +78 -0
- data/vendor/bundle/gems/rspec-core-2.7.1/lib/rspec/core/ruby_project.rb +44 -0
- data/vendor/bundle/gems/rspec-core-2.7.1/lib/rspec/core/runner.rb +86 -0
- data/vendor/bundle/gems/rspec-core-2.7.1/lib/rspec/core/shared_context.rb +16 -0
- data/vendor/bundle/gems/rspec-core-2.7.1/lib/rspec/core/shared_example_group.rb +67 -0
- data/vendor/bundle/gems/rspec-core-2.7.1/lib/rspec/core/subject.rb +175 -0
- data/vendor/bundle/gems/rspec-core-2.7.1/lib/rspec/core/version.rb +7 -0
- data/vendor/bundle/gems/rspec-core-2.7.1/lib/rspec/core/world.rb +150 -0
- data/vendor/bundle/gems/rspec-core-2.7.1/lib/rspec/monkey.rb +1 -0
- data/vendor/bundle/gems/rspec-core-2.7.1/lib/rspec/monkey/spork/test_framework/rspec.rb +8 -0
- data/vendor/bundle/gems/rspec-core-2.7.1/spec/autotest/discover_spec.rb +19 -0
- data/vendor/bundle/gems/rspec-core-2.7.1/spec/autotest/failed_results_re_spec.rb +45 -0
- data/vendor/bundle/gems/rspec-core-2.7.1/spec/autotest/rspec_spec.rb +123 -0
- data/vendor/bundle/gems/rspec-core-2.7.1/spec/rspec/core/command_line_configuration_spec.rb +26 -0
- data/vendor/bundle/gems/rspec-core-2.7.1/spec/rspec/core/command_line_spec.rb +169 -0
- data/vendor/bundle/gems/rspec-core-2.7.1/spec/rspec/core/command_line_spec_output.txt +0 -0
- data/vendor/bundle/gems/rspec-core-2.7.1/spec/rspec/core/configuration_options_spec.rb +437 -0
- data/vendor/bundle/gems/rspec-core-2.7.1/spec/rspec/core/configuration_spec.rb +920 -0
- data/vendor/bundle/gems/rspec-core-2.7.1/spec/rspec/core/deprecations_spec.rb +66 -0
- data/vendor/bundle/gems/rspec-core-2.7.1/spec/rspec/core/drb_command_line_spec.rb +124 -0
- data/vendor/bundle/gems/rspec-core-2.7.1/spec/rspec/core/example_group_spec.rb +1046 -0
- data/vendor/bundle/gems/rspec-core-2.7.1/spec/rspec/core/example_spec.rb +289 -0
- data/vendor/bundle/gems/rspec-core-2.7.1/spec/rspec/core/formatters/base_formatter_spec.rb +80 -0
- data/vendor/bundle/gems/rspec-core-2.7.1/spec/rspec/core/formatters/base_text_formatter_spec.rb +344 -0
- data/vendor/bundle/gems/rspec-core-2.7.1/spec/rspec/core/formatters/documentation_formatter_spec.rb +66 -0
- data/vendor/bundle/gems/rspec-core-2.7.1/spec/rspec/core/formatters/helpers_spec.rb +46 -0
- data/vendor/bundle/gems/rspec-core-2.7.1/spec/rspec/core/formatters/html_formatted-1.8.7-jruby.html +462 -0
- data/vendor/bundle/gems/rspec-core-2.7.1/spec/rspec/core/formatters/html_formatted-1.8.7.html +399 -0
- data/vendor/bundle/gems/rspec-core-2.7.1/spec/rspec/core/formatters/html_formatted-1.9.2.html +406 -0
- data/vendor/bundle/gems/rspec-core-2.7.1/spec/rspec/core/formatters/html_formatted-1.9.3.html +406 -0
- data/vendor/bundle/gems/rspec-core-2.7.1/spec/rspec/core/formatters/html_formatter_spec.rb +81 -0
- data/vendor/bundle/gems/rspec-core-2.7.1/spec/rspec/core/formatters/progress_formatter_spec.rb +30 -0
- data/vendor/bundle/gems/rspec-core-2.7.1/spec/rspec/core/formatters/snippet_extractor_spec.rb +18 -0
- data/vendor/bundle/gems/rspec-core-2.7.1/spec/rspec/core/formatters/text_mate_formatted-1.8.7-jruby.html +462 -0
- data/vendor/bundle/gems/rspec-core-2.7.1/spec/rspec/core/formatters/text_mate_formatted-1.8.7.html +399 -0
- data/vendor/bundle/gems/rspec-core-2.7.1/spec/rspec/core/formatters/text_mate_formatted-1.9.2.html +406 -0
- data/vendor/bundle/gems/rspec-core-2.7.1/spec/rspec/core/formatters/text_mate_formatted-1.9.3.html +406 -0
- data/vendor/bundle/gems/rspec-core-2.7.1/spec/rspec/core/formatters/text_mate_formatter_spec.rb +84 -0
- data/vendor/bundle/gems/rspec-core-2.7.1/spec/rspec/core/hooks_filtering_spec.rb +227 -0
- data/vendor/bundle/gems/rspec-core-2.7.1/spec/rspec/core/hooks_spec.rb +143 -0
- data/vendor/bundle/gems/rspec-core-2.7.1/spec/rspec/core/kernel_extensions_spec.rb +9 -0
- data/vendor/bundle/gems/rspec-core-2.7.1/spec/rspec/core/let_spec.rb +55 -0
- data/vendor/bundle/gems/rspec-core-2.7.1/spec/rspec/core/metadata_spec.rb +383 -0
- data/vendor/bundle/gems/rspec-core-2.7.1/spec/rspec/core/option_parser_spec.rb +86 -0
- data/vendor/bundle/gems/rspec-core-2.7.1/spec/rspec/core/pending_example_spec.rb +187 -0
- data/vendor/bundle/gems/rspec-core-2.7.1/spec/rspec/core/rake_task_spec.rb +138 -0
- data/vendor/bundle/gems/rspec-core-2.7.1/spec/rspec/core/reporter_spec.rb +86 -0
- data/vendor/bundle/gems/rspec-core-2.7.1/spec/rspec/core/resources/a_bar.rb +0 -0
- data/vendor/bundle/gems/rspec-core-2.7.1/spec/rspec/core/resources/a_foo.rb +0 -0
- data/vendor/bundle/gems/rspec-core-2.7.1/spec/rspec/core/resources/a_spec.rb +1 -0
- data/vendor/bundle/gems/rspec-core-2.7.1/spec/rspec/core/resources/custom_example_group_runner.rb +14 -0
- data/vendor/bundle/gems/rspec-core-2.7.1/spec/rspec/core/resources/formatter_specs.rb +60 -0
- data/vendor/bundle/gems/rspec-core-2.7.1/spec/rspec/core/resources/utf8_encoded.rb +8 -0
- data/vendor/bundle/gems/rspec-core-2.7.1/spec/rspec/core/rspec_matchers_spec.rb +45 -0
- data/vendor/bundle/gems/rspec-core-2.7.1/spec/rspec/core/ruby_project_spec.rb +24 -0
- data/vendor/bundle/gems/rspec-core-2.7.1/spec/rspec/core/runner_spec.rb +82 -0
- data/vendor/bundle/gems/rspec-core-2.7.1/spec/rspec/core/shared_context_spec.rb +30 -0
- data/vendor/bundle/gems/rspec-core-2.7.1/spec/rspec/core/shared_example_group_spec.rb +84 -0
- data/vendor/bundle/gems/rspec-core-2.7.1/spec/rspec/core/subject_spec.rb +199 -0
- data/vendor/bundle/gems/rspec-core-2.7.1/spec/rspec/core/world_spec.rb +315 -0
- data/vendor/bundle/gems/rspec-core-2.7.1/spec/rspec/core_spec.rb +31 -0
- data/vendor/bundle/gems/rspec-core-2.7.1/spec/spec_helper.rb +92 -0
- data/vendor/bundle/gems/rspec-core-2.7.1/spec/support/matchers.rb +75 -0
- data/vendor/bundle/gems/rspec-core-2.7.1/spec/support/shared_example_groups.rb +41 -0
- data/vendor/bundle/gems/rspec-core-2.7.1/spec/support/spec_files.rb +44 -0
- data/vendor/bundle/gems/rspec-expectations-2.7.0/README.md +24 -0
- data/vendor/bundle/gems/rspec-expectations-2.7.0/features/README.markdown +49 -0
- data/vendor/bundle/gems/rspec-expectations-2.7.0/features/Upgrade.md +53 -0
- data/vendor/bundle/gems/rspec-expectations-2.7.0/features/built_in_matchers/README.md +73 -0
- data/vendor/bundle/gems/rspec-expectations-2.7.0/features/built_in_matchers/be.feature +135 -0
- data/vendor/bundle/gems/rspec-expectations-2.7.0/features/built_in_matchers/be_within.feature +43 -0
- data/vendor/bundle/gems/rspec-expectations-2.7.0/features/built_in_matchers/cover.feature +45 -0
- data/vendor/bundle/gems/rspec-expectations-2.7.0/features/built_in_matchers/equality.feature +145 -0
- data/vendor/bundle/gems/rspec-expectations-2.7.0/features/built_in_matchers/exist.feature +43 -0
- data/vendor/bundle/gems/rspec-expectations-2.7.0/features/built_in_matchers/expect_change.feature +59 -0
- data/vendor/bundle/gems/rspec-expectations-2.7.0/features/built_in_matchers/expect_error.feature +138 -0
- data/vendor/bundle/gems/rspec-expectations-2.7.0/features/built_in_matchers/have.feature +103 -0
- data/vendor/bundle/gems/rspec-expectations-2.7.0/features/built_in_matchers/include.feature +121 -0
- data/vendor/bundle/gems/rspec-expectations-2.7.0/features/built_in_matchers/match.feature +50 -0
- data/vendor/bundle/gems/rspec-expectations-2.7.0/features/built_in_matchers/operators.feature +221 -0
- data/vendor/bundle/gems/rspec-expectations-2.7.0/features/built_in_matchers/predicates.feature +128 -0
- data/vendor/bundle/gems/rspec-expectations-2.7.0/features/built_in_matchers/respond_to.feature +78 -0
- data/vendor/bundle/gems/rspec-expectations-2.7.0/features/built_in_matchers/satisfy.feature +31 -0
- data/vendor/bundle/gems/rspec-expectations-2.7.0/features/built_in_matchers/throw_symbol.feature +85 -0
- data/vendor/bundle/gems/rspec-expectations-2.7.0/features/built_in_matchers/types.feature +114 -0
- data/vendor/bundle/gems/rspec-expectations-2.7.0/features/custom_matchers/access_running_example.feature +53 -0
- data/vendor/bundle/gems/rspec-expectations-2.7.0/features/custom_matchers/define_diffable_matcher.feature +27 -0
- data/vendor/bundle/gems/rspec-expectations-2.7.0/features/custom_matchers/define_matcher.feature +340 -0
- data/vendor/bundle/gems/rspec-expectations-2.7.0/features/custom_matchers/define_matcher_outside_rspec.feature +38 -0
- data/vendor/bundle/gems/rspec-expectations-2.7.0/features/custom_matchers/define_matcher_with_fluent_interface.feature +24 -0
- data/vendor/bundle/gems/rspec-expectations-2.7.0/features/customized_message.feature +22 -0
- data/vendor/bundle/gems/rspec-expectations-2.7.0/features/diffing.feature +85 -0
- data/vendor/bundle/gems/rspec-expectations-2.7.0/features/implicit_docstrings.feature +52 -0
- data/vendor/bundle/gems/rspec-expectations-2.7.0/features/step_definitions/additional_cli_steps.rb +22 -0
- data/vendor/bundle/gems/rspec-expectations-2.7.0/features/support/env.rb +5 -0
- data/vendor/bundle/gems/rspec-expectations-2.7.0/features/test_frameworks/test_unit.feature +46 -0
- data/vendor/bundle/gems/rspec-expectations-2.7.0/lib/rspec-expectations.rb +1 -0
- data/vendor/bundle/gems/rspec-expectations-2.7.0/lib/rspec/expectations.rb +37 -0
- data/vendor/bundle/gems/rspec-expectations-2.7.0/lib/rspec/expectations/deprecation.rb +38 -0
- data/vendor/bundle/gems/rspec-expectations-2.7.0/lib/rspec/expectations/differ.rb +62 -0
- data/vendor/bundle/gems/rspec-expectations-2.7.0/lib/rspec/expectations/errors.rb +9 -0
- data/vendor/bundle/gems/rspec-expectations-2.7.0/lib/rspec/expectations/extensions.rb +3 -0
- data/vendor/bundle/gems/rspec-expectations-2.7.0/lib/rspec/expectations/extensions/array.rb +9 -0
- data/vendor/bundle/gems/rspec-expectations-2.7.0/lib/rspec/expectations/extensions/kernel.rb +26 -0
- data/vendor/bundle/gems/rspec-expectations-2.7.0/lib/rspec/expectations/extensions/object.rb +39 -0
- data/vendor/bundle/gems/rspec-expectations-2.7.0/lib/rspec/expectations/fail_with.rb +54 -0
- data/vendor/bundle/gems/rspec-expectations-2.7.0/lib/rspec/expectations/handler.rb +50 -0
- data/vendor/bundle/gems/rspec-expectations-2.7.0/lib/rspec/expectations/version.rb +8 -0
- data/vendor/bundle/gems/rspec-expectations-2.7.0/lib/rspec/matchers.rb +206 -0
- data/vendor/bundle/gems/rspec-expectations-2.7.0/lib/rspec/matchers/be.rb +213 -0
- data/vendor/bundle/gems/rspec-expectations-2.7.0/lib/rspec/matchers/be_close.rb +9 -0
- data/vendor/bundle/gems/rspec-expectations-2.7.0/lib/rspec/matchers/be_instance_of.rb +26 -0
- data/vendor/bundle/gems/rspec-expectations-2.7.0/lib/rspec/matchers/be_kind_of.rb +26 -0
- data/vendor/bundle/gems/rspec-expectations-2.7.0/lib/rspec/matchers/be_within.rb +37 -0
- data/vendor/bundle/gems/rspec-expectations-2.7.0/lib/rspec/matchers/block_aliases.rb +19 -0
- data/vendor/bundle/gems/rspec-expectations-2.7.0/lib/rspec/matchers/change.rb +197 -0
- data/vendor/bundle/gems/rspec-expectations-2.7.0/lib/rspec/matchers/compatibility.rb +14 -0
- data/vendor/bundle/gems/rspec-expectations-2.7.0/lib/rspec/matchers/cover.rb +35 -0
- data/vendor/bundle/gems/rspec-expectations-2.7.0/lib/rspec/matchers/dsl.rb +22 -0
- data/vendor/bundle/gems/rspec-expectations-2.7.0/lib/rspec/matchers/eq.rb +46 -0
- data/vendor/bundle/gems/rspec-expectations-2.7.0/lib/rspec/matchers/eql.rb +41 -0
- data/vendor/bundle/gems/rspec-expectations-2.7.0/lib/rspec/matchers/equal.rb +48 -0
- data/vendor/bundle/gems/rspec-expectations-2.7.0/lib/rspec/matchers/errors.rb +5 -0
- data/vendor/bundle/gems/rspec-expectations-2.7.0/lib/rspec/matchers/exist.rb +26 -0
- data/vendor/bundle/gems/rspec-expectations-2.7.0/lib/rspec/matchers/extensions/instance_eval_with_args.rb +39 -0
- data/vendor/bundle/gems/rspec-expectations-2.7.0/lib/rspec/matchers/generated_descriptions.rb +36 -0
- data/vendor/bundle/gems/rspec-expectations-2.7.0/lib/rspec/matchers/has.rb +44 -0
- data/vendor/bundle/gems/rspec-expectations-2.7.0/lib/rspec/matchers/have.rb +168 -0
- data/vendor/bundle/gems/rspec-expectations-2.7.0/lib/rspec/matchers/include.rb +54 -0
- data/vendor/bundle/gems/rspec-expectations-2.7.0/lib/rspec/matchers/match.rb +21 -0
- data/vendor/bundle/gems/rspec-expectations-2.7.0/lib/rspec/matchers/match_array.rb +71 -0
- data/vendor/bundle/gems/rspec-expectations-2.7.0/lib/rspec/matchers/matcher.rb +165 -0
- data/vendor/bundle/gems/rspec-expectations-2.7.0/lib/rspec/matchers/method_missing.rb +12 -0
- data/vendor/bundle/gems/rspec-expectations-2.7.0/lib/rspec/matchers/operator_matcher.rb +87 -0
- data/vendor/bundle/gems/rspec-expectations-2.7.0/lib/rspec/matchers/pretty.rb +37 -0
- data/vendor/bundle/gems/rspec-expectations-2.7.0/lib/rspec/matchers/raise_error.rb +130 -0
- data/vendor/bundle/gems/rspec-expectations-2.7.0/lib/rspec/matchers/respond_to.rb +85 -0
- data/vendor/bundle/gems/rspec-expectations-2.7.0/lib/rspec/matchers/satisfy.rb +51 -0
- data/vendor/bundle/gems/rspec-expectations-2.7.0/lib/rspec/matchers/throw_symbol.rb +121 -0
- data/vendor/bundle/gems/rspec-expectations-2.7.0/spec/rspec/expectations/differ_spec.rb +96 -0
- data/vendor/bundle/gems/rspec-expectations-2.7.0/spec/rspec/expectations/extensions/kernel_spec.rb +45 -0
- data/vendor/bundle/gems/rspec-expectations-2.7.0/spec/rspec/expectations/fail_with_spec.rb +70 -0
- data/vendor/bundle/gems/rspec-expectations-2.7.0/spec/rspec/expectations/handler_spec.rb +206 -0
- data/vendor/bundle/gems/rspec-expectations-2.7.0/spec/rspec/matchers/be_close_spec.rb +22 -0
- data/vendor/bundle/gems/rspec-expectations-2.7.0/spec/rspec/matchers/be_instance_of_spec.rb +36 -0
- data/vendor/bundle/gems/rspec-expectations-2.7.0/spec/rspec/matchers/be_kind_of_spec.rb +33 -0
- data/vendor/bundle/gems/rspec-expectations-2.7.0/spec/rspec/matchers/be_spec.rb +452 -0
- data/vendor/bundle/gems/rspec-expectations-2.7.0/spec/rspec/matchers/be_within_spec.rb +64 -0
- data/vendor/bundle/gems/rspec-expectations-2.7.0/spec/rspec/matchers/change_spec.rb +522 -0
- data/vendor/bundle/gems/rspec-expectations-2.7.0/spec/rspec/matchers/compatibility_spec.rb +28 -0
- data/vendor/bundle/gems/rspec-expectations-2.7.0/spec/rspec/matchers/cover_spec.rb +65 -0
- data/vendor/bundle/gems/rspec-expectations-2.7.0/spec/rspec/matchers/description_generation_spec.rb +176 -0
- data/vendor/bundle/gems/rspec-expectations-2.7.0/spec/rspec/matchers/dsl_spec.rb +25 -0
- data/vendor/bundle/gems/rspec-expectations-2.7.0/spec/rspec/matchers/eq_spec.rb +38 -0
- data/vendor/bundle/gems/rspec-expectations-2.7.0/spec/rspec/matchers/eql_spec.rb +37 -0
- data/vendor/bundle/gems/rspec-expectations-2.7.0/spec/rspec/matchers/equal_spec.rb +57 -0
- data/vendor/bundle/gems/rspec-expectations-2.7.0/spec/rspec/matchers/exist_spec.rb +104 -0
- data/vendor/bundle/gems/rspec-expectations-2.7.0/spec/rspec/matchers/has_spec.rb +113 -0
- data/vendor/bundle/gems/rspec-expectations-2.7.0/spec/rspec/matchers/have_spec.rb +458 -0
- data/vendor/bundle/gems/rspec-expectations-2.7.0/spec/rspec/matchers/include_spec.rb +341 -0
- data/vendor/bundle/gems/rspec-expectations-2.7.0/spec/rspec/matchers/match_array_spec.rb +108 -0
- data/vendor/bundle/gems/rspec-expectations-2.7.0/spec/rspec/matchers/match_spec.rb +57 -0
- data/vendor/bundle/gems/rspec-expectations-2.7.0/spec/rspec/matchers/matcher_spec.rb +420 -0
- data/vendor/bundle/gems/rspec-expectations-2.7.0/spec/rspec/matchers/matchers_spec.rb +31 -0
- data/vendor/bundle/gems/rspec-expectations-2.7.0/spec/rspec/matchers/method_missing_spec.rb +23 -0
- data/vendor/bundle/gems/rspec-expectations-2.7.0/spec/rspec/matchers/operator_matcher_spec.rb +221 -0
- data/vendor/bundle/gems/rspec-expectations-2.7.0/spec/rspec/matchers/raise_error_spec.rb +339 -0
- data/vendor/bundle/gems/rspec-expectations-2.7.0/spec/rspec/matchers/respond_to_spec.rb +292 -0
- data/vendor/bundle/gems/rspec-expectations-2.7.0/spec/rspec/matchers/satisfy_spec.rb +40 -0
- data/vendor/bundle/gems/rspec-expectations-2.7.0/spec/rspec/matchers/throw_symbol_spec.rb +113 -0
- data/vendor/bundle/gems/rspec-expectations-2.7.0/spec/spec_helper.rb +26 -0
- data/vendor/bundle/gems/rspec-expectations-2.7.0/spec/support/classes.rb +56 -0
- data/vendor/bundle/gems/rspec-expectations-2.7.0/spec/support/matchers.rb +22 -0
- data/vendor/bundle/gems/rspec-expectations-2.7.0/spec/support/ruby_version.rb +10 -0
- data/vendor/bundle/gems/rspec-mocks-2.7.0/README.md +40 -0
- data/vendor/bundle/gems/rspec-mocks-2.7.0/features/README.markdown +67 -0
- data/vendor/bundle/gems/rspec-mocks-2.7.0/features/Scope.md +17 -0
- data/vendor/bundle/gems/rspec-mocks-2.7.0/features/Upgrade.md +22 -0
- data/vendor/bundle/gems/rspec-mocks-2.7.0/features/argument_matchers/README.md +27 -0
- data/vendor/bundle/gems/rspec-mocks-2.7.0/features/argument_matchers/explicit.feature +60 -0
- data/vendor/bundle/gems/rspec-mocks-2.7.0/features/argument_matchers/general_matchers.feature +85 -0
- data/vendor/bundle/gems/rspec-mocks-2.7.0/features/argument_matchers/type_matchers.feature +25 -0
- data/vendor/bundle/gems/rspec-mocks-2.7.0/features/message_expectations/README.md +58 -0
- data/vendor/bundle/gems/rspec-mocks-2.7.0/features/message_expectations/any_instance.feature +21 -0
- data/vendor/bundle/gems/rspec-mocks-2.7.0/features/message_expectations/block_local_expectations.feature.pending +55 -0
- data/vendor/bundle/gems/rspec-mocks-2.7.0/features/message_expectations/expect_message.feature +94 -0
- data/vendor/bundle/gems/rspec-mocks-2.7.0/features/message_expectations/receive_counts.feature +209 -0
- data/vendor/bundle/gems/rspec-mocks-2.7.0/features/message_expectations/warn_when_expectation_is_set_on_nil.feature +50 -0
- data/vendor/bundle/gems/rspec-mocks-2.7.0/features/method_stubs/README.md +43 -0
- data/vendor/bundle/gems/rspec-mocks-2.7.0/features/method_stubs/any_instance.feature +133 -0
- data/vendor/bundle/gems/rspec-mocks-2.7.0/features/method_stubs/as_null_object.feature +36 -0
- data/vendor/bundle/gems/rspec-mocks-2.7.0/features/method_stubs/simple_return_value.feature +64 -0
- data/vendor/bundle/gems/rspec-mocks-2.7.0/features/method_stubs/stub_chain.feature +51 -0
- data/vendor/bundle/gems/rspec-mocks-2.7.0/features/method_stubs/stub_implementation.feature +26 -0
- data/vendor/bundle/gems/rspec-mocks-2.7.0/features/method_stubs/to_ary.feature +47 -0
- data/vendor/bundle/gems/rspec-mocks-2.7.0/features/outside_rspec/configuration.feature +82 -0
- data/vendor/bundle/gems/rspec-mocks-2.7.0/features/outside_rspec/standalone.feature +32 -0
- data/vendor/bundle/gems/rspec-mocks-2.7.0/features/step_definitions/additional_cli_steps.rb +4 -0
- data/vendor/bundle/gems/rspec-mocks-2.7.0/features/support/env.rb +6 -0
- data/vendor/bundle/gems/rspec-mocks-2.7.0/lib/rspec/mocks.rb +196 -0
- data/vendor/bundle/gems/rspec-mocks-2.7.0/lib/rspec/mocks/any_instance.rb +29 -0
- data/vendor/bundle/gems/rspec-mocks-2.7.0/lib/rspec/mocks/any_instance/chain.rb +49 -0
- data/vendor/bundle/gems/rspec-mocks-2.7.0/lib/rspec/mocks/any_instance/expectation_chain.rb +33 -0
- data/vendor/bundle/gems/rspec-mocks-2.7.0/lib/rspec/mocks/any_instance/message_chains.rb +48 -0
- data/vendor/bundle/gems/rspec-mocks-2.7.0/lib/rspec/mocks/any_instance/recorder.rb +168 -0
- data/vendor/bundle/gems/rspec-mocks-2.7.0/lib/rspec/mocks/any_instance/stub_chain.rb +35 -0
- data/vendor/bundle/gems/rspec-mocks-2.7.0/lib/rspec/mocks/any_instance/stub_chain_chain.rb +34 -0
- data/vendor/bundle/gems/rspec-mocks-2.7.0/lib/rspec/mocks/argument_expectation.rb +54 -0
- data/vendor/bundle/gems/rspec-mocks-2.7.0/lib/rspec/mocks/argument_matchers.rb +227 -0
- data/vendor/bundle/gems/rspec-mocks-2.7.0/lib/rspec/mocks/error_generator.rb +97 -0
- data/vendor/bundle/gems/rspec-mocks-2.7.0/lib/rspec/mocks/errors.rb +10 -0
- data/vendor/bundle/gems/rspec-mocks-2.7.0/lib/rspec/mocks/extensions/instance_exec.rb +31 -0
- data/vendor/bundle/gems/rspec-mocks-2.7.0/lib/rspec/mocks/extensions/marshal.rb +23 -0
- data/vendor/bundle/gems/rspec-mocks-2.7.0/lib/rspec/mocks/extensions/psych.rb +23 -0
- data/vendor/bundle/gems/rspec-mocks-2.7.0/lib/rspec/mocks/framework.rb +18 -0
- data/vendor/bundle/gems/rspec-mocks-2.7.0/lib/rspec/mocks/message_expectation.rb +357 -0
- data/vendor/bundle/gems/rspec-mocks-2.7.0/lib/rspec/mocks/method_double.rb +165 -0
- data/vendor/bundle/gems/rspec-mocks-2.7.0/lib/rspec/mocks/methods.rb +98 -0
- data/vendor/bundle/gems/rspec-mocks-2.7.0/lib/rspec/mocks/mock.rb +79 -0
- data/vendor/bundle/gems/rspec-mocks-2.7.0/lib/rspec/mocks/order_group.rb +29 -0
- data/vendor/bundle/gems/rspec-mocks-2.7.0/lib/rspec/mocks/proxy.rb +158 -0
- data/vendor/bundle/gems/rspec-mocks-2.7.0/lib/rspec/mocks/serialization.rb +28 -0
- data/vendor/bundle/gems/rspec-mocks-2.7.0/lib/rspec/mocks/space.rb +28 -0
- data/vendor/bundle/gems/rspec-mocks-2.7.0/lib/rspec/mocks/spec_methods.rb +53 -0
- data/vendor/bundle/gems/rspec-mocks-2.7.0/lib/rspec/mocks/standalone.rb +3 -0
- data/vendor/bundle/gems/rspec-mocks-2.7.0/lib/rspec/mocks/version.rb +7 -0
- data/vendor/bundle/gems/rspec-mocks-2.7.0/lib/spec/mocks.rb +2 -0
- data/vendor/bundle/gems/rspec-mocks-2.7.0/spec/rspec/mocks/and_yield_spec.rb +114 -0
- data/vendor/bundle/gems/rspec-mocks-2.7.0/spec/rspec/mocks/any_instance/message_chains_spec.rb +40 -0
- data/vendor/bundle/gems/rspec-mocks-2.7.0/spec/rspec/mocks/any_instance_spec.rb +785 -0
- data/vendor/bundle/gems/rspec-mocks-2.7.0/spec/rspec/mocks/any_number_of_times_spec.rb +30 -0
- data/vendor/bundle/gems/rspec-mocks-2.7.0/spec/rspec/mocks/argument_expectation_spec.rb +37 -0
- data/vendor/bundle/gems/rspec-mocks-2.7.0/spec/rspec/mocks/at_least_spec.rb +103 -0
- data/vendor/bundle/gems/rspec-mocks-2.7.0/spec/rspec/mocks/at_most_spec.rb +99 -0
- data/vendor/bundle/gems/rspec-mocks-2.7.0/spec/rspec/mocks/block_return_value_spec.rb +45 -0
- data/vendor/bundle/gems/rspec-mocks-2.7.0/spec/rspec/mocks/bug_report_10260_spec.rb +8 -0
- data/vendor/bundle/gems/rspec-mocks-2.7.0/spec/rspec/mocks/bug_report_10263_spec.rb +25 -0
- data/vendor/bundle/gems/rspec-mocks-2.7.0/spec/rspec/mocks/bug_report_11545_spec.rb +32 -0
- data/vendor/bundle/gems/rspec-mocks-2.7.0/spec/rspec/mocks/bug_report_496_spec.rb +17 -0
- data/vendor/bundle/gems/rspec-mocks-2.7.0/spec/rspec/mocks/bug_report_600_spec.rb +22 -0
- data/vendor/bundle/gems/rspec-mocks-2.7.0/spec/rspec/mocks/bug_report_7611_spec.rb +16 -0
- data/vendor/bundle/gems/rspec-mocks-2.7.0/spec/rspec/mocks/bug_report_8165_spec.rb +31 -0
- data/vendor/bundle/gems/rspec-mocks-2.7.0/spec/rspec/mocks/bug_report_830_spec.rb +21 -0
- data/vendor/bundle/gems/rspec-mocks-2.7.0/spec/rspec/mocks/bug_report_957_spec.rb +22 -0
- data/vendor/bundle/gems/rspec-mocks-2.7.0/spec/rspec/mocks/double_spec.rb +12 -0
- data/vendor/bundle/gems/rspec-mocks-2.7.0/spec/rspec/mocks/failing_argument_matchers_spec.rb +95 -0
- data/vendor/bundle/gems/rspec-mocks-2.7.0/spec/rspec/mocks/hash_including_matcher_spec.rb +90 -0
- data/vendor/bundle/gems/rspec-mocks-2.7.0/spec/rspec/mocks/hash_not_including_matcher_spec.rb +67 -0
- data/vendor/bundle/gems/rspec-mocks-2.7.0/spec/rspec/mocks/mock_ordering_spec.rb +94 -0
- data/vendor/bundle/gems/rspec-mocks-2.7.0/spec/rspec/mocks/mock_space_spec.rb +54 -0
- data/vendor/bundle/gems/rspec-mocks-2.7.0/spec/rspec/mocks/mock_spec.rb +702 -0
- data/vendor/bundle/gems/rspec-mocks-2.7.0/spec/rspec/mocks/multiple_return_value_spec.rb +191 -0
- data/vendor/bundle/gems/rspec-mocks-2.7.0/spec/rspec/mocks/nil_expectation_warning_spec.rb +62 -0
- data/vendor/bundle/gems/rspec-mocks-2.7.0/spec/rspec/mocks/null_object_mock_spec.rb +78 -0
- data/vendor/bundle/gems/rspec-mocks-2.7.0/spec/rspec/mocks/once_counts_spec.rb +53 -0
- data/vendor/bundle/gems/rspec-mocks-2.7.0/spec/rspec/mocks/options_hash_spec.rb +35 -0
- data/vendor/bundle/gems/rspec-mocks-2.7.0/spec/rspec/mocks/partial_mock_spec.rb +156 -0
- data/vendor/bundle/gems/rspec-mocks-2.7.0/spec/rspec/mocks/partial_mock_using_mocks_directly_spec.rb +95 -0
- data/vendor/bundle/gems/rspec-mocks-2.7.0/spec/rspec/mocks/passing_argument_matchers_spec.rb +142 -0
- data/vendor/bundle/gems/rspec-mocks-2.7.0/spec/rspec/mocks/precise_counts_spec.rb +58 -0
- data/vendor/bundle/gems/rspec-mocks-2.7.0/spec/rspec/mocks/record_messages_spec.rb +26 -0
- data/vendor/bundle/gems/rspec-mocks-2.7.0/spec/rspec/mocks/serialization_spec.rb +111 -0
- data/vendor/bundle/gems/rspec-mocks-2.7.0/spec/rspec/mocks/stash_spec.rb +27 -0
- data/vendor/bundle/gems/rspec-mocks-2.7.0/spec/rspec/mocks/stub_chain_spec.rb +149 -0
- data/vendor/bundle/gems/rspec-mocks-2.7.0/spec/rspec/mocks/stub_implementation_spec.rb +68 -0
- data/vendor/bundle/gems/rspec-mocks-2.7.0/spec/rspec/mocks/stub_spec.rb +235 -0
- data/vendor/bundle/gems/rspec-mocks-2.7.0/spec/rspec/mocks/stubbed_message_expectations_spec.rb +26 -0
- data/vendor/bundle/gems/rspec-mocks-2.7.0/spec/rspec/mocks/to_ary_spec.rb +40 -0
- data/vendor/bundle/gems/rspec-mocks-2.7.0/spec/rspec/mocks/twice_counts_spec.rb +67 -0
- data/vendor/bundle/gems/rspec-mocks-2.7.0/spec/rspec/mocks_spec.rb +51 -0
- data/vendor/bundle/gems/rspec-mocks-2.7.0/spec/spec_helper.rb +52 -0
- data/vendor/bundle/specifications/diff-lcs-1.1.3.gemspec +35 -0
- data/vendor/bundle/specifications/httparty-0.8.1.gemspec +34 -0
- data/vendor/bundle/specifications/json-1.6.3.gemspec +39 -0
- data/vendor/bundle/specifications/multi_json-1.0.4.gemspec +40 -0
- data/vendor/bundle/specifications/multi_xml-0.4.1.gemspec +49 -0
- data/vendor/bundle/specifications/rspec-2.7.0.gemspec +38 -0
- data/vendor/bundle/specifications/rspec-core-2.7.1.gemspec +31 -0
- data/vendor/bundle/specifications/rspec-expectations-2.7.0.gemspec +32 -0
- data/vendor/bundle/specifications/rspec-mocks-2.7.0.gemspec +29 -0
- metadata +771 -0
@@ -0,0 +1,232 @@
|
|
1
|
+
/*
|
2
|
+
* This code is copyrighted work by Daniel Luz <dev at mernen dot com>.
|
3
|
+
*
|
4
|
+
* Distributed under the Ruby and GPLv2 licenses; see COPYING and GPL files
|
5
|
+
* for details.
|
6
|
+
*/
|
7
|
+
package json.ext;
|
8
|
+
|
9
|
+
import java.lang.ref.WeakReference;
|
10
|
+
import org.jruby.Ruby;
|
11
|
+
import org.jruby.RubyArray;
|
12
|
+
import org.jruby.RubyBoolean;
|
13
|
+
import org.jruby.RubyFixnum;
|
14
|
+
import org.jruby.RubyFloat;
|
15
|
+
import org.jruby.RubyHash;
|
16
|
+
import org.jruby.RubyInteger;
|
17
|
+
import org.jruby.RubyModule;
|
18
|
+
import org.jruby.RubyNumeric;
|
19
|
+
import org.jruby.RubyString;
|
20
|
+
import org.jruby.anno.JRubyMethod;
|
21
|
+
import org.jruby.runtime.ThreadContext;
|
22
|
+
import org.jruby.runtime.builtin.IRubyObject;
|
23
|
+
import org.jruby.util.ByteList;
|
24
|
+
|
25
|
+
/**
|
26
|
+
* A class that populates the
|
27
|
+
* <code>Json::Ext::Generator::GeneratorMethods</code> module.
|
28
|
+
*
|
29
|
+
* @author mernen
|
30
|
+
*/
|
31
|
+
class GeneratorMethods {
|
32
|
+
/**
|
33
|
+
* Populates the given module with all modules and their methods
|
34
|
+
* @param info
|
35
|
+
* @param generatorMethodsModule The module to populate
|
36
|
+
* (normally <code>JSON::Generator::GeneratorMethods</code>)
|
37
|
+
*/
|
38
|
+
static void populate(RuntimeInfo info, RubyModule module) {
|
39
|
+
defineMethods(module, "Array", RbArray.class);
|
40
|
+
defineMethods(module, "FalseClass", RbFalse.class);
|
41
|
+
defineMethods(module, "Float", RbFloat.class);
|
42
|
+
defineMethods(module, "Hash", RbHash.class);
|
43
|
+
defineMethods(module, "Integer", RbInteger.class);
|
44
|
+
defineMethods(module, "NilClass", RbNil.class);
|
45
|
+
defineMethods(module, "Object", RbObject.class);
|
46
|
+
defineMethods(module, "String", RbString.class);
|
47
|
+
defineMethods(module, "TrueClass", RbTrue.class);
|
48
|
+
|
49
|
+
info.stringExtendModule = new WeakReference<RubyModule>(module.defineModuleUnder("String")
|
50
|
+
.defineModuleUnder("Extend"));
|
51
|
+
info.stringExtendModule.get().defineAnnotatedMethods(StringExtend.class);
|
52
|
+
}
|
53
|
+
|
54
|
+
/**
|
55
|
+
* Convenience method for defining methods on a submodule.
|
56
|
+
* @param parentModule
|
57
|
+
* @param submoduleName
|
58
|
+
* @param klass
|
59
|
+
*/
|
60
|
+
private static void defineMethods(RubyModule parentModule,
|
61
|
+
String submoduleName, Class klass) {
|
62
|
+
RubyModule submodule = parentModule.defineModuleUnder(submoduleName);
|
63
|
+
submodule.defineAnnotatedMethods(klass);
|
64
|
+
}
|
65
|
+
|
66
|
+
|
67
|
+
public static class RbHash {
|
68
|
+
@JRubyMethod(rest=true)
|
69
|
+
public static IRubyObject to_json(ThreadContext context,
|
70
|
+
IRubyObject vSelf, IRubyObject[] args) {
|
71
|
+
return Generator.generateJson(context, (RubyHash)vSelf,
|
72
|
+
Generator.HASH_HANDLER, args);
|
73
|
+
}
|
74
|
+
}
|
75
|
+
|
76
|
+
public static class RbArray {
|
77
|
+
@JRubyMethod(rest=true)
|
78
|
+
public static IRubyObject to_json(ThreadContext context,
|
79
|
+
IRubyObject vSelf, IRubyObject[] args) {
|
80
|
+
return Generator.generateJson(context, (RubyArray)vSelf,
|
81
|
+
Generator.ARRAY_HANDLER, args);
|
82
|
+
}
|
83
|
+
}
|
84
|
+
|
85
|
+
public static class RbInteger {
|
86
|
+
@JRubyMethod(rest=true)
|
87
|
+
public static IRubyObject to_json(ThreadContext context,
|
88
|
+
IRubyObject vSelf, IRubyObject[] args) {
|
89
|
+
return Generator.generateJson(context, vSelf, args);
|
90
|
+
}
|
91
|
+
}
|
92
|
+
|
93
|
+
public static class RbFloat {
|
94
|
+
@JRubyMethod(rest=true)
|
95
|
+
public static IRubyObject to_json(ThreadContext context,
|
96
|
+
IRubyObject vSelf, IRubyObject[] args) {
|
97
|
+
return Generator.generateJson(context, (RubyFloat)vSelf,
|
98
|
+
Generator.FLOAT_HANDLER, args);
|
99
|
+
}
|
100
|
+
}
|
101
|
+
|
102
|
+
public static class RbString {
|
103
|
+
@JRubyMethod(rest=true)
|
104
|
+
public static IRubyObject to_json(ThreadContext context,
|
105
|
+
IRubyObject vSelf, IRubyObject[] args) {
|
106
|
+
return Generator.generateJson(context, (RubyString)vSelf,
|
107
|
+
Generator.STRING_HANDLER, args);
|
108
|
+
}
|
109
|
+
|
110
|
+
/**
|
111
|
+
* <code>{@link RubyString String}#to_json_raw(*)</code>
|
112
|
+
*
|
113
|
+
* <p>This method creates a JSON text from the result of a call to
|
114
|
+
* {@link #to_json_raw_object} of this String.
|
115
|
+
*/
|
116
|
+
@JRubyMethod(rest=true)
|
117
|
+
public static IRubyObject to_json_raw(ThreadContext context,
|
118
|
+
IRubyObject vSelf, IRubyObject[] args) {
|
119
|
+
RubyHash obj = toJsonRawObject(context, Utils.ensureString(vSelf));
|
120
|
+
return Generator.generateJson(context, obj,
|
121
|
+
Generator.HASH_HANDLER, args);
|
122
|
+
}
|
123
|
+
|
124
|
+
/**
|
125
|
+
* <code>{@link RubyString String}#to_json_raw_object(*)</code>
|
126
|
+
*
|
127
|
+
* <p>This method creates a raw object Hash, that can be nested into
|
128
|
+
* other data structures and will be unparsed as a raw string. This
|
129
|
+
* method should be used if you want to convert raw strings to JSON
|
130
|
+
* instead of UTF-8 strings, e.g. binary data.
|
131
|
+
*/
|
132
|
+
@JRubyMethod(rest=true)
|
133
|
+
public static IRubyObject to_json_raw_object(ThreadContext context,
|
134
|
+
IRubyObject vSelf, IRubyObject[] args) {
|
135
|
+
return toJsonRawObject(context, Utils.ensureString(vSelf));
|
136
|
+
}
|
137
|
+
|
138
|
+
private static RubyHash toJsonRawObject(ThreadContext context,
|
139
|
+
RubyString self) {
|
140
|
+
Ruby runtime = context.getRuntime();
|
141
|
+
RubyHash result = RubyHash.newHash(runtime);
|
142
|
+
|
143
|
+
IRubyObject createId = RuntimeInfo.forRuntime(runtime)
|
144
|
+
.jsonModule.get().callMethod(context, "create_id");
|
145
|
+
result.op_aset(context, createId, self.getMetaClass().to_s());
|
146
|
+
|
147
|
+
ByteList bl = self.getByteList();
|
148
|
+
byte[] uBytes = bl.unsafeBytes();
|
149
|
+
RubyArray array = runtime.newArray(bl.length());
|
150
|
+
for (int i = bl.begin(), t = bl.begin() + bl.length(); i < t; i++) {
|
151
|
+
array.store(i, runtime.newFixnum(uBytes[i] & 0xff));
|
152
|
+
}
|
153
|
+
|
154
|
+
result.op_aset(context, runtime.newString("raw"), array);
|
155
|
+
return result;
|
156
|
+
}
|
157
|
+
|
158
|
+
@JRubyMethod(required=1, module=true)
|
159
|
+
public static IRubyObject included(ThreadContext context,
|
160
|
+
IRubyObject vSelf, IRubyObject module) {
|
161
|
+
RuntimeInfo info = RuntimeInfo.forRuntime(context.getRuntime());
|
162
|
+
return module.callMethod(context, "extend", info.stringExtendModule.get());
|
163
|
+
}
|
164
|
+
}
|
165
|
+
|
166
|
+
public static class StringExtend {
|
167
|
+
/**
|
168
|
+
* <code>{@link RubyString String}#json_create(o)</code>
|
169
|
+
*
|
170
|
+
* <p>Raw Strings are JSON Objects (the raw bytes are stored in an
|
171
|
+
* array for the key "raw"). The Ruby String can be created by this
|
172
|
+
* module method.
|
173
|
+
*/
|
174
|
+
@JRubyMethod(required=1)
|
175
|
+
public static IRubyObject json_create(ThreadContext context,
|
176
|
+
IRubyObject vSelf, IRubyObject vHash) {
|
177
|
+
Ruby runtime = context.getRuntime();
|
178
|
+
RubyHash o = vHash.convertToHash();
|
179
|
+
IRubyObject rawData = o.fastARef(runtime.newString("raw"));
|
180
|
+
if (rawData == null) {
|
181
|
+
throw runtime.newArgumentError("\"raw\" value not defined "
|
182
|
+
+ "for encoded String");
|
183
|
+
}
|
184
|
+
RubyArray ary = Utils.ensureArray(rawData);
|
185
|
+
byte[] bytes = new byte[ary.getLength()];
|
186
|
+
for (int i = 0, t = ary.getLength(); i < t; i++) {
|
187
|
+
IRubyObject element = ary.eltInternal(i);
|
188
|
+
if (element instanceof RubyFixnum) {
|
189
|
+
bytes[i] = (byte)RubyNumeric.fix2long(element);
|
190
|
+
} else {
|
191
|
+
throw runtime.newTypeError(element, runtime.getFixnum());
|
192
|
+
}
|
193
|
+
}
|
194
|
+
return runtime.newString(new ByteList(bytes, false));
|
195
|
+
}
|
196
|
+
}
|
197
|
+
|
198
|
+
public static class RbTrue {
|
199
|
+
@JRubyMethod(rest=true)
|
200
|
+
public static IRubyObject to_json(ThreadContext context,
|
201
|
+
IRubyObject vSelf, IRubyObject[] args) {
|
202
|
+
return Generator.generateJson(context, (RubyBoolean)vSelf,
|
203
|
+
Generator.TRUE_HANDLER, args);
|
204
|
+
}
|
205
|
+
}
|
206
|
+
|
207
|
+
public static class RbFalse {
|
208
|
+
@JRubyMethod(rest=true)
|
209
|
+
public static IRubyObject to_json(ThreadContext context,
|
210
|
+
IRubyObject vSelf, IRubyObject[] args) {
|
211
|
+
return Generator.generateJson(context, (RubyBoolean)vSelf,
|
212
|
+
Generator.FALSE_HANDLER, args);
|
213
|
+
}
|
214
|
+
}
|
215
|
+
|
216
|
+
public static class RbNil {
|
217
|
+
@JRubyMethod(rest=true)
|
218
|
+
public static IRubyObject to_json(ThreadContext context,
|
219
|
+
IRubyObject vSelf, IRubyObject[] args) {
|
220
|
+
return Generator.generateJson(context, vSelf,
|
221
|
+
Generator.NIL_HANDLER, args);
|
222
|
+
}
|
223
|
+
}
|
224
|
+
|
225
|
+
public static class RbObject {
|
226
|
+
@JRubyMethod(rest=true)
|
227
|
+
public static IRubyObject to_json(ThreadContext context,
|
228
|
+
IRubyObject self, IRubyObject[] args) {
|
229
|
+
return RbString.to_json(context, self.asString(), args);
|
230
|
+
}
|
231
|
+
}
|
232
|
+
}
|
@@ -0,0 +1,43 @@
|
|
1
|
+
/*
|
2
|
+
* This code is copyrighted work by Daniel Luz <dev at mernen dot com>.
|
3
|
+
*
|
4
|
+
* Distributed under the Ruby and GPLv2 licenses; see COPYING and GPL files
|
5
|
+
* for details.
|
6
|
+
*/
|
7
|
+
package json.ext;
|
8
|
+
|
9
|
+
import java.io.IOException;
|
10
|
+
import java.lang.ref.WeakReference;
|
11
|
+
|
12
|
+
import org.jruby.Ruby;
|
13
|
+
import org.jruby.RubyClass;
|
14
|
+
import org.jruby.RubyModule;
|
15
|
+
import org.jruby.runtime.load.BasicLibraryService;
|
16
|
+
|
17
|
+
/**
|
18
|
+
* The service invoked by JRuby's {@link org.jruby.runtime.load.LoadService LoadService}.
|
19
|
+
* Defines the <code>JSON::Ext::Generator</code> module.
|
20
|
+
* @author mernen
|
21
|
+
*/
|
22
|
+
public class GeneratorService implements BasicLibraryService {
|
23
|
+
public boolean basicLoad(Ruby runtime) throws IOException {
|
24
|
+
runtime.getLoadService().require("json/common");
|
25
|
+
RuntimeInfo info = RuntimeInfo.initRuntime(runtime);
|
26
|
+
|
27
|
+
info.jsonModule = new WeakReference<RubyModule>(runtime.defineModule("JSON"));
|
28
|
+
RubyModule jsonExtModule = info.jsonModule.get().defineModuleUnder("Ext");
|
29
|
+
RubyModule generatorModule = jsonExtModule.defineModuleUnder("Generator");
|
30
|
+
|
31
|
+
RubyClass stateClass =
|
32
|
+
generatorModule.defineClassUnder("State", runtime.getObject(),
|
33
|
+
GeneratorState.ALLOCATOR);
|
34
|
+
stateClass.defineAnnotatedMethods(GeneratorState.class);
|
35
|
+
info.generatorStateClass = new WeakReference<RubyClass>(stateClass);
|
36
|
+
|
37
|
+
RubyModule generatorMethods =
|
38
|
+
generatorModule.defineModuleUnder("GeneratorMethods");
|
39
|
+
GeneratorMethods.populate(info, generatorMethods);
|
40
|
+
|
41
|
+
return true;
|
42
|
+
}
|
43
|
+
}
|
@@ -0,0 +1,522 @@
|
|
1
|
+
/*
|
2
|
+
* This code is copyrighted work by Daniel Luz <dev at mernen dot com>.
|
3
|
+
*
|
4
|
+
* Distributed under the Ruby and GPLv2 licenses; see COPYING and GPL files
|
5
|
+
* for details.
|
6
|
+
*/
|
7
|
+
package json.ext;
|
8
|
+
|
9
|
+
import org.jruby.Ruby;
|
10
|
+
import org.jruby.RubyBoolean;
|
11
|
+
import org.jruby.RubyClass;
|
12
|
+
import org.jruby.RubyHash;
|
13
|
+
import org.jruby.RubyInteger;
|
14
|
+
import org.jruby.RubyNumeric;
|
15
|
+
import org.jruby.RubyObject;
|
16
|
+
import org.jruby.RubyString;
|
17
|
+
import org.jruby.anno.JRubyMethod;
|
18
|
+
import org.jruby.runtime.Block;
|
19
|
+
import org.jruby.runtime.ObjectAllocator;
|
20
|
+
import org.jruby.runtime.ThreadContext;
|
21
|
+
import org.jruby.runtime.Visibility;
|
22
|
+
import org.jruby.runtime.builtin.IRubyObject;
|
23
|
+
import org.jruby.util.ByteList;
|
24
|
+
|
25
|
+
/**
|
26
|
+
* The <code>JSON::Ext::Generator::State</code> class.
|
27
|
+
*
|
28
|
+
* <p>This class is used to create State instances, that are use to hold data
|
29
|
+
* while generating a JSON text from a a Ruby data structure.
|
30
|
+
*
|
31
|
+
* @author mernen
|
32
|
+
*/
|
33
|
+
public class GeneratorState extends RubyObject {
|
34
|
+
/**
|
35
|
+
* The indenting unit string. Will be repeated several times for larger
|
36
|
+
* indenting levels.
|
37
|
+
*/
|
38
|
+
private ByteList indent = ByteList.EMPTY_BYTELIST;
|
39
|
+
/**
|
40
|
+
* The spacing to be added after a semicolon on a JSON object.
|
41
|
+
* @see #spaceBefore
|
42
|
+
*/
|
43
|
+
private ByteList space = ByteList.EMPTY_BYTELIST;
|
44
|
+
/**
|
45
|
+
* The spacing to be added before a semicolon on a JSON object.
|
46
|
+
* @see #space
|
47
|
+
*/
|
48
|
+
private ByteList spaceBefore = ByteList.EMPTY_BYTELIST;
|
49
|
+
/**
|
50
|
+
* Any suffix to be added after the comma for each element on a JSON object.
|
51
|
+
* It is assumed to be a newline, if set.
|
52
|
+
*/
|
53
|
+
private ByteList objectNl = ByteList.EMPTY_BYTELIST;
|
54
|
+
/**
|
55
|
+
* Any suffix to be added after the comma for each element on a JSON Array.
|
56
|
+
* It is assumed to be a newline, if set.
|
57
|
+
*/
|
58
|
+
private ByteList arrayNl = ByteList.EMPTY_BYTELIST;
|
59
|
+
|
60
|
+
/**
|
61
|
+
* The maximum level of nesting of structures allowed.
|
62
|
+
* <code>0</code> means disabled.
|
63
|
+
*/
|
64
|
+
private int maxNesting = DEFAULT_MAX_NESTING;
|
65
|
+
static final int DEFAULT_MAX_NESTING = 19;
|
66
|
+
/**
|
67
|
+
* Whether special float values (<code>NaN</code>, <code>Infinity</code>,
|
68
|
+
* <code>-Infinity</code>) are accepted.
|
69
|
+
* If set to <code>false</code>, an exception will be thrown upon
|
70
|
+
* encountering one.
|
71
|
+
*/
|
72
|
+
private boolean allowNaN = DEFAULT_ALLOW_NAN;
|
73
|
+
static final boolean DEFAULT_ALLOW_NAN = false;
|
74
|
+
/**
|
75
|
+
* If set to <code>true</code> all JSON documents generated do not contain
|
76
|
+
* any other characters than ASCII characters.
|
77
|
+
*/
|
78
|
+
private boolean asciiOnly = DEFAULT_ASCII_ONLY;
|
79
|
+
static final boolean DEFAULT_ASCII_ONLY = false;
|
80
|
+
/**
|
81
|
+
* If set to <code>true</code> all JSON values generated might not be
|
82
|
+
* RFC-conform JSON documents.
|
83
|
+
*/
|
84
|
+
private boolean quirksMode = DEFAULT_QUIRKS_MODE;
|
85
|
+
static final boolean DEFAULT_QUIRKS_MODE = false;
|
86
|
+
/**
|
87
|
+
* The initial buffer length of this state. (This isn't really used on all
|
88
|
+
* non-C implementations.)
|
89
|
+
*/
|
90
|
+
private int bufferInitialLength = DEFAULT_BUFFER_INITIAL_LENGTH;
|
91
|
+
static final int DEFAULT_BUFFER_INITIAL_LENGTH = 1024;
|
92
|
+
|
93
|
+
/**
|
94
|
+
* The current depth (inside a #to_json call)
|
95
|
+
*/
|
96
|
+
private int depth = 0;
|
97
|
+
|
98
|
+
static final ObjectAllocator ALLOCATOR = new ObjectAllocator() {
|
99
|
+
public IRubyObject allocate(Ruby runtime, RubyClass klazz) {
|
100
|
+
return new GeneratorState(runtime, klazz);
|
101
|
+
}
|
102
|
+
};
|
103
|
+
|
104
|
+
public GeneratorState(Ruby runtime, RubyClass metaClass) {
|
105
|
+
super(runtime, metaClass);
|
106
|
+
}
|
107
|
+
|
108
|
+
/**
|
109
|
+
* <code>State.from_state(opts)</code>
|
110
|
+
*
|
111
|
+
* <p>Creates a State object from <code>opts</code>, which ought to be
|
112
|
+
* {@link RubyHash Hash} to create a new <code>State</code> instance
|
113
|
+
* configured by <codes>opts</code>, something else to create an
|
114
|
+
* unconfigured instance. If <code>opts</code> is a <code>State</code>
|
115
|
+
* object, it is just returned.
|
116
|
+
* @param clazzParam The receiver of the method call
|
117
|
+
* ({@link RubyClass} <code>State</code>)
|
118
|
+
* @param opts The object to use as a base for the new <code>State</code>
|
119
|
+
* @param block The block passed to the method
|
120
|
+
* @return A <code>GeneratorState</code> as determined above
|
121
|
+
*/
|
122
|
+
@JRubyMethod(meta=true)
|
123
|
+
public static IRubyObject from_state(ThreadContext context,
|
124
|
+
IRubyObject klass, IRubyObject opts) {
|
125
|
+
return fromState(context, opts);
|
126
|
+
}
|
127
|
+
|
128
|
+
static GeneratorState fromState(ThreadContext context, IRubyObject opts) {
|
129
|
+
return fromState(context, RuntimeInfo.forRuntime(context.getRuntime()), opts);
|
130
|
+
}
|
131
|
+
|
132
|
+
static GeneratorState fromState(ThreadContext context, RuntimeInfo info,
|
133
|
+
IRubyObject opts) {
|
134
|
+
RubyClass klass = info.generatorStateClass.get();
|
135
|
+
if (opts != null) {
|
136
|
+
// if the given parameter is a Generator::State, return itself
|
137
|
+
if (klass.isInstance(opts)) return (GeneratorState)opts;
|
138
|
+
|
139
|
+
// if the given parameter is a Hash, pass it to the instantiator
|
140
|
+
if (context.getRuntime().getHash().isInstance(opts)) {
|
141
|
+
return (GeneratorState)klass.newInstance(context,
|
142
|
+
new IRubyObject[] {opts}, Block.NULL_BLOCK);
|
143
|
+
}
|
144
|
+
}
|
145
|
+
|
146
|
+
// for other values, return the safe prototype
|
147
|
+
return (GeneratorState)info.getSafeStatePrototype(context).dup();
|
148
|
+
}
|
149
|
+
|
150
|
+
/**
|
151
|
+
* <code>State#initialize(opts = {})</code>
|
152
|
+
*
|
153
|
+
* Instantiates a new <code>State</code> object, configured by <code>opts</code>.
|
154
|
+
*
|
155
|
+
* <code>opts</code> can have the following keys:
|
156
|
+
*
|
157
|
+
* <dl>
|
158
|
+
* <dt><code>:indent</code>
|
159
|
+
* <dd>a {@link RubyString String} used to indent levels (default: <code>""</code>)
|
160
|
+
* <dt><code>:space</code>
|
161
|
+
* <dd>a String that is put after a <code>':'</code> or <code>','</code>
|
162
|
+
* delimiter (default: <code>""</code>)
|
163
|
+
* <dt><code>:space_before</code>
|
164
|
+
* <dd>a String that is put before a <code>":"</code> pair delimiter
|
165
|
+
* (default: <code>""</code>)
|
166
|
+
* <dt><code>:object_nl</code>
|
167
|
+
* <dd>a String that is put at the end of a JSON object (default: <code>""</code>)
|
168
|
+
* <dt><code>:array_nl</code>
|
169
|
+
* <dd>a String that is put at the end of a JSON array (default: <code>""</code>)
|
170
|
+
* <dt><code>:allow_nan</code>
|
171
|
+
* <dd><code>true</code> if <code>NaN</code>, <code>Infinity</code>, and
|
172
|
+
* <code>-Infinity</code> should be generated, otherwise an exception is
|
173
|
+
* thrown if these values are encountered.
|
174
|
+
* This options defaults to <code>false</code>.
|
175
|
+
*/
|
176
|
+
@JRubyMethod(optional=1, visibility=Visibility.PRIVATE)
|
177
|
+
public IRubyObject initialize(ThreadContext context, IRubyObject[] args) {
|
178
|
+
configure(context, args.length > 0 ? args[0] : null);
|
179
|
+
return this;
|
180
|
+
}
|
181
|
+
|
182
|
+
@JRubyMethod
|
183
|
+
public IRubyObject initialize_copy(ThreadContext context, IRubyObject vOrig) {
|
184
|
+
Ruby runtime = context.getRuntime();
|
185
|
+
if (!(vOrig instanceof GeneratorState)) {
|
186
|
+
throw runtime.newTypeError(vOrig, getType());
|
187
|
+
}
|
188
|
+
GeneratorState orig = (GeneratorState)vOrig;
|
189
|
+
this.indent = orig.indent;
|
190
|
+
this.space = orig.space;
|
191
|
+
this.spaceBefore = orig.spaceBefore;
|
192
|
+
this.objectNl = orig.objectNl;
|
193
|
+
this.arrayNl = orig.arrayNl;
|
194
|
+
this.maxNesting = orig.maxNesting;
|
195
|
+
this.allowNaN = orig.allowNaN;
|
196
|
+
this.asciiOnly = orig.asciiOnly;
|
197
|
+
this.quirksMode = orig.quirksMode;
|
198
|
+
this.bufferInitialLength = orig.bufferInitialLength;
|
199
|
+
this.depth = orig.depth;
|
200
|
+
return this;
|
201
|
+
}
|
202
|
+
|
203
|
+
/**
|
204
|
+
* Generates a valid JSON document from object <code>obj</code> and returns
|
205
|
+
* the result. If no valid JSON document can be created this method raises
|
206
|
+
* a GeneratorError exception.
|
207
|
+
*/
|
208
|
+
@JRubyMethod
|
209
|
+
public IRubyObject generate(ThreadContext context, IRubyObject obj) {
|
210
|
+
RubyString result = Generator.generateJson(context, obj, this);
|
211
|
+
if (!quirksMode && !objectOrArrayLiteral(result)) {
|
212
|
+
throw Utils.newException(context, Utils.M_GENERATOR_ERROR,
|
213
|
+
"only generation of JSON objects or arrays allowed");
|
214
|
+
}
|
215
|
+
return result;
|
216
|
+
}
|
217
|
+
|
218
|
+
/**
|
219
|
+
* Ensures the given string is in the form "[...]" or "{...}", being
|
220
|
+
* possibly surrounded by white space.
|
221
|
+
* The string's encoding must be ASCII-compatible.
|
222
|
+
* @param value
|
223
|
+
* @return
|
224
|
+
*/
|
225
|
+
private static boolean objectOrArrayLiteral(RubyString value) {
|
226
|
+
ByteList bl = value.getByteList();
|
227
|
+
int len = bl.length();
|
228
|
+
|
229
|
+
for (int pos = 0; pos < len - 1; pos++) {
|
230
|
+
int b = bl.get(pos);
|
231
|
+
if (Character.isWhitespace(b)) continue;
|
232
|
+
|
233
|
+
// match the opening brace
|
234
|
+
switch (b) {
|
235
|
+
case '[':
|
236
|
+
return matchClosingBrace(bl, pos, len, ']');
|
237
|
+
case '{':
|
238
|
+
return matchClosingBrace(bl, pos, len, '}');
|
239
|
+
default:
|
240
|
+
return false;
|
241
|
+
}
|
242
|
+
}
|
243
|
+
return false;
|
244
|
+
}
|
245
|
+
|
246
|
+
private static boolean matchClosingBrace(ByteList bl, int pos, int len,
|
247
|
+
int brace) {
|
248
|
+
for (int endPos = len - 1; endPos > pos; endPos--) {
|
249
|
+
int b = bl.get(endPos);
|
250
|
+
if (Character.isWhitespace(b)) continue;
|
251
|
+
return b == brace;
|
252
|
+
}
|
253
|
+
return false;
|
254
|
+
}
|
255
|
+
|
256
|
+
@JRubyMethod(name="[]", required=1)
|
257
|
+
public IRubyObject op_aref(ThreadContext context, IRubyObject vName) {
|
258
|
+
String name = vName.asJavaString();
|
259
|
+
if (getMetaClass().isMethodBound(name, true)) {
|
260
|
+
return send(context, vName, Block.NULL_BLOCK);
|
261
|
+
}
|
262
|
+
return context.getRuntime().getNil();
|
263
|
+
}
|
264
|
+
|
265
|
+
public ByteList getIndent() {
|
266
|
+
return indent;
|
267
|
+
}
|
268
|
+
|
269
|
+
@JRubyMethod(name="indent")
|
270
|
+
public RubyString indent_get(ThreadContext context) {
|
271
|
+
return context.getRuntime().newString(indent);
|
272
|
+
}
|
273
|
+
|
274
|
+
@JRubyMethod(name="indent=")
|
275
|
+
public IRubyObject indent_set(ThreadContext context, IRubyObject indent) {
|
276
|
+
this.indent = prepareByteList(context, indent);
|
277
|
+
return indent;
|
278
|
+
}
|
279
|
+
|
280
|
+
public ByteList getSpace() {
|
281
|
+
return space;
|
282
|
+
}
|
283
|
+
|
284
|
+
@JRubyMethod(name="space")
|
285
|
+
public RubyString space_get(ThreadContext context) {
|
286
|
+
return context.getRuntime().newString(space);
|
287
|
+
}
|
288
|
+
|
289
|
+
@JRubyMethod(name="space=")
|
290
|
+
public IRubyObject space_set(ThreadContext context, IRubyObject space) {
|
291
|
+
this.space = prepareByteList(context, space);
|
292
|
+
return space;
|
293
|
+
}
|
294
|
+
|
295
|
+
public ByteList getSpaceBefore() {
|
296
|
+
return spaceBefore;
|
297
|
+
}
|
298
|
+
|
299
|
+
@JRubyMethod(name="space_before")
|
300
|
+
public RubyString space_before_get(ThreadContext context) {
|
301
|
+
return context.getRuntime().newString(spaceBefore);
|
302
|
+
}
|
303
|
+
|
304
|
+
@JRubyMethod(name="space_before=")
|
305
|
+
public IRubyObject space_before_set(ThreadContext context,
|
306
|
+
IRubyObject spaceBefore) {
|
307
|
+
this.spaceBefore = prepareByteList(context, spaceBefore);
|
308
|
+
return spaceBefore;
|
309
|
+
}
|
310
|
+
|
311
|
+
public ByteList getObjectNl() {
|
312
|
+
return objectNl;
|
313
|
+
}
|
314
|
+
|
315
|
+
@JRubyMethod(name="object_nl")
|
316
|
+
public RubyString object_nl_get(ThreadContext context) {
|
317
|
+
return context.getRuntime().newString(objectNl);
|
318
|
+
}
|
319
|
+
|
320
|
+
@JRubyMethod(name="object_nl=")
|
321
|
+
public IRubyObject object_nl_set(ThreadContext context,
|
322
|
+
IRubyObject objectNl) {
|
323
|
+
this.objectNl = prepareByteList(context, objectNl);
|
324
|
+
return objectNl;
|
325
|
+
}
|
326
|
+
|
327
|
+
public ByteList getArrayNl() {
|
328
|
+
return arrayNl;
|
329
|
+
}
|
330
|
+
|
331
|
+
@JRubyMethod(name="array_nl")
|
332
|
+
public RubyString array_nl_get(ThreadContext context) {
|
333
|
+
return context.getRuntime().newString(arrayNl);
|
334
|
+
}
|
335
|
+
|
336
|
+
@JRubyMethod(name="array_nl=")
|
337
|
+
public IRubyObject array_nl_set(ThreadContext context,
|
338
|
+
IRubyObject arrayNl) {
|
339
|
+
this.arrayNl = prepareByteList(context, arrayNl);
|
340
|
+
return arrayNl;
|
341
|
+
}
|
342
|
+
|
343
|
+
@JRubyMethod(name="check_circular?")
|
344
|
+
public RubyBoolean check_circular_p(ThreadContext context) {
|
345
|
+
return context.getRuntime().newBoolean(maxNesting != 0);
|
346
|
+
}
|
347
|
+
|
348
|
+
/**
|
349
|
+
* Returns the maximum level of nesting configured for this state.
|
350
|
+
*/
|
351
|
+
public int getMaxNesting() {
|
352
|
+
return maxNesting;
|
353
|
+
}
|
354
|
+
|
355
|
+
@JRubyMethod(name="max_nesting")
|
356
|
+
public RubyInteger max_nesting_get(ThreadContext context) {
|
357
|
+
return context.getRuntime().newFixnum(maxNesting);
|
358
|
+
}
|
359
|
+
|
360
|
+
@JRubyMethod(name="max_nesting=")
|
361
|
+
public IRubyObject max_nesting_set(IRubyObject max_nesting) {
|
362
|
+
maxNesting = RubyNumeric.fix2int(max_nesting);
|
363
|
+
return max_nesting;
|
364
|
+
}
|
365
|
+
|
366
|
+
public boolean allowNaN() {
|
367
|
+
return allowNaN;
|
368
|
+
}
|
369
|
+
|
370
|
+
@JRubyMethod(name="allow_nan?")
|
371
|
+
public RubyBoolean allow_nan_p(ThreadContext context) {
|
372
|
+
return context.getRuntime().newBoolean(allowNaN);
|
373
|
+
}
|
374
|
+
|
375
|
+
public boolean asciiOnly() {
|
376
|
+
return asciiOnly;
|
377
|
+
}
|
378
|
+
|
379
|
+
@JRubyMethod(name="ascii_only?")
|
380
|
+
public RubyBoolean ascii_only_p(ThreadContext context) {
|
381
|
+
return context.getRuntime().newBoolean(asciiOnly);
|
382
|
+
}
|
383
|
+
|
384
|
+
@JRubyMethod(name="quirks_mode")
|
385
|
+
public RubyBoolean quirks_mode_get(ThreadContext context) {
|
386
|
+
return context.getRuntime().newBoolean(quirksMode);
|
387
|
+
}
|
388
|
+
|
389
|
+
@JRubyMethod(name="quirks_mode=")
|
390
|
+
public IRubyObject quirks_mode_set(IRubyObject quirks_mode) {
|
391
|
+
quirksMode = quirks_mode.isTrue();
|
392
|
+
return quirks_mode.getRuntime().newBoolean(quirksMode);
|
393
|
+
}
|
394
|
+
|
395
|
+
@JRubyMethod(name="buffer_initial_length")
|
396
|
+
public RubyInteger buffer_initial_length_get(ThreadContext context) {
|
397
|
+
return context.getRuntime().newFixnum(bufferInitialLength);
|
398
|
+
}
|
399
|
+
|
400
|
+
@JRubyMethod(name="buffer_initial_length=")
|
401
|
+
public IRubyObject buffer_initial_length_set(IRubyObject buffer_initial_length) {
|
402
|
+
int newLength = RubyNumeric.fix2int(buffer_initial_length);
|
403
|
+
if (newLength > 0) bufferInitialLength = newLength;
|
404
|
+
return buffer_initial_length;
|
405
|
+
}
|
406
|
+
|
407
|
+
@JRubyMethod(name="quirks_mode?")
|
408
|
+
public RubyBoolean quirks_mode_p(ThreadContext context) {
|
409
|
+
return context.getRuntime().newBoolean(quirksMode);
|
410
|
+
}
|
411
|
+
|
412
|
+
public int getDepth() {
|
413
|
+
return depth;
|
414
|
+
}
|
415
|
+
|
416
|
+
@JRubyMethod(name="depth")
|
417
|
+
public RubyInteger depth_get(ThreadContext context) {
|
418
|
+
return context.getRuntime().newFixnum(depth);
|
419
|
+
}
|
420
|
+
|
421
|
+
@JRubyMethod(name="depth=")
|
422
|
+
public IRubyObject depth_set(IRubyObject vDepth) {
|
423
|
+
depth = RubyNumeric.fix2int(vDepth);
|
424
|
+
return vDepth;
|
425
|
+
}
|
426
|
+
|
427
|
+
private ByteList prepareByteList(ThreadContext context, IRubyObject value) {
|
428
|
+
RubyString str = value.convertToString();
|
429
|
+
RuntimeInfo info = RuntimeInfo.forRuntime(context.getRuntime());
|
430
|
+
if (info.encodingsSupported() && str.encoding(context) != info.utf8.get()) {
|
431
|
+
str = (RubyString)str.encode(context, info.utf8.get());
|
432
|
+
}
|
433
|
+
return str.getByteList().dup();
|
434
|
+
}
|
435
|
+
|
436
|
+
/**
|
437
|
+
* <code>State#configure(opts)</code>
|
438
|
+
*
|
439
|
+
* <p>Configures this State instance with the {@link RubyHash Hash}
|
440
|
+
* <code>opts</code>, and returns itself.
|
441
|
+
* @param vOpts The options hash
|
442
|
+
* @return The receiver
|
443
|
+
*/
|
444
|
+
@JRubyMethod
|
445
|
+
public IRubyObject configure(ThreadContext context, IRubyObject vOpts) {
|
446
|
+
OptionsReader opts = new OptionsReader(context, vOpts);
|
447
|
+
|
448
|
+
ByteList indent = opts.getString("indent");
|
449
|
+
if (indent != null) this.indent = indent;
|
450
|
+
|
451
|
+
ByteList space = opts.getString("space");
|
452
|
+
if (space != null) this.space = space;
|
453
|
+
|
454
|
+
ByteList spaceBefore = opts.getString("space_before");
|
455
|
+
if (spaceBefore != null) this.spaceBefore = spaceBefore;
|
456
|
+
|
457
|
+
ByteList arrayNl = opts.getString("array_nl");
|
458
|
+
if (arrayNl != null) this.arrayNl = arrayNl;
|
459
|
+
|
460
|
+
ByteList objectNl = opts.getString("object_nl");
|
461
|
+
if (objectNl != null) this.objectNl = objectNl;
|
462
|
+
|
463
|
+
maxNesting = opts.getInt("max_nesting", DEFAULT_MAX_NESTING);
|
464
|
+
allowNaN = opts.getBool("allow_nan", DEFAULT_ALLOW_NAN);
|
465
|
+
asciiOnly = opts.getBool("ascii_only", DEFAULT_ASCII_ONLY);
|
466
|
+
quirksMode = opts.getBool("quirks_mode", DEFAULT_QUIRKS_MODE);
|
467
|
+
bufferInitialLength = opts.getInt("buffer_initial_length", DEFAULT_BUFFER_INITIAL_LENGTH);
|
468
|
+
|
469
|
+
depth = opts.getInt("depth", 0);
|
470
|
+
|
471
|
+
return this;
|
472
|
+
}
|
473
|
+
|
474
|
+
/**
|
475
|
+
* <code>State#to_h()</code>
|
476
|
+
*
|
477
|
+
* <p>Returns the configuration instance variables as a hash, that can be
|
478
|
+
* passed to the configure method.
|
479
|
+
* @return
|
480
|
+
*/
|
481
|
+
@JRubyMethod
|
482
|
+
public RubyHash to_h(ThreadContext context) {
|
483
|
+
Ruby runtime = context.getRuntime();
|
484
|
+
RubyHash result = RubyHash.newHash(runtime);
|
485
|
+
|
486
|
+
result.op_aset(context, runtime.newSymbol("indent"), indent_get(context));
|
487
|
+
result.op_aset(context, runtime.newSymbol("space"), space_get(context));
|
488
|
+
result.op_aset(context, runtime.newSymbol("space_before"), space_before_get(context));
|
489
|
+
result.op_aset(context, runtime.newSymbol("object_nl"), object_nl_get(context));
|
490
|
+
result.op_aset(context, runtime.newSymbol("array_nl"), array_nl_get(context));
|
491
|
+
result.op_aset(context, runtime.newSymbol("allow_nan"), allow_nan_p(context));
|
492
|
+
result.op_aset(context, runtime.newSymbol("ascii_only"), ascii_only_p(context));
|
493
|
+
result.op_aset(context, runtime.newSymbol("quirks_mode"), quirks_mode_p(context));
|
494
|
+
result.op_aset(context, runtime.newSymbol("max_nesting"), max_nesting_get(context));
|
495
|
+
result.op_aset(context, runtime.newSymbol("depth"), depth_get(context));
|
496
|
+
result.op_aset(context, runtime.newSymbol("buffer_initial_length"), buffer_initial_length_get(context));
|
497
|
+
return result;
|
498
|
+
}
|
499
|
+
|
500
|
+
public int increaseDepth() {
|
501
|
+
depth++;
|
502
|
+
checkMaxNesting();
|
503
|
+
return depth;
|
504
|
+
}
|
505
|
+
|
506
|
+
public int decreaseDepth() {
|
507
|
+
return --depth;
|
508
|
+
}
|
509
|
+
|
510
|
+
/**
|
511
|
+
* Checks if the current depth is allowed as per this state's options.
|
512
|
+
* @param context
|
513
|
+
* @param depth The corrent depth
|
514
|
+
*/
|
515
|
+
private void checkMaxNesting() {
|
516
|
+
if (maxNesting != 0 && depth > maxNesting) {
|
517
|
+
depth--;
|
518
|
+
throw Utils.newException(getRuntime().getCurrentContext(),
|
519
|
+
Utils.M_NESTING_ERROR, "nesting of " + depth + " is too deep");
|
520
|
+
}
|
521
|
+
}
|
522
|
+
}
|