rj_schema 0.2.3 → 0.2.4
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- metadata +3 -615
- data/ext/rj_schema/rapidjson/CHANGELOG.md +0 -158
- data/ext/rj_schema/rapidjson/CMakeLists.txt +0 -221
- data/ext/rj_schema/rapidjson/CMakeModules/FindGTestSrc.cmake +0 -30
- data/ext/rj_schema/rapidjson/RapidJSON.pc.in +0 -7
- data/ext/rj_schema/rapidjson/RapidJSONConfig.cmake.in +0 -15
- data/ext/rj_schema/rapidjson/RapidJSONConfigVersion.cmake.in +0 -10
- data/ext/rj_schema/rapidjson/appveyor.yml +0 -41
- data/ext/rj_schema/rapidjson/bin/data/glossary.json +0 -22
- data/ext/rj_schema/rapidjson/bin/data/menu.json +0 -27
- data/ext/rj_schema/rapidjson/bin/data/readme.txt +0 -1
- data/ext/rj_schema/rapidjson/bin/data/sample.json +0 -3315
- data/ext/rj_schema/rapidjson/bin/data/webapp.json +0 -88
- data/ext/rj_schema/rapidjson/bin/data/widget.json +0 -26
- data/ext/rj_schema/rapidjson/bin/draft-04/schema +0 -150
- data/ext/rj_schema/rapidjson/bin/encodings/utf16be.json +0 -0
- data/ext/rj_schema/rapidjson/bin/encodings/utf16bebom.json +0 -0
- data/ext/rj_schema/rapidjson/bin/encodings/utf16le.json +0 -0
- data/ext/rj_schema/rapidjson/bin/encodings/utf16lebom.json +0 -0
- data/ext/rj_schema/rapidjson/bin/encodings/utf32be.json +0 -0
- data/ext/rj_schema/rapidjson/bin/encodings/utf32bebom.json +0 -0
- data/ext/rj_schema/rapidjson/bin/encodings/utf32le.json +0 -0
- data/ext/rj_schema/rapidjson/bin/encodings/utf32lebom.json +0 -0
- data/ext/rj_schema/rapidjson/bin/encodings/utf8.json +0 -7
- data/ext/rj_schema/rapidjson/bin/encodings/utf8bom.json +0 -7
- data/ext/rj_schema/rapidjson/bin/jsonchecker/fail1.json +0 -1
- data/ext/rj_schema/rapidjson/bin/jsonchecker/fail10.json +0 -1
- data/ext/rj_schema/rapidjson/bin/jsonchecker/fail11.json +0 -1
- data/ext/rj_schema/rapidjson/bin/jsonchecker/fail12.json +0 -1
- data/ext/rj_schema/rapidjson/bin/jsonchecker/fail13.json +0 -1
- data/ext/rj_schema/rapidjson/bin/jsonchecker/fail14.json +0 -1
- data/ext/rj_schema/rapidjson/bin/jsonchecker/fail15.json +0 -1
- data/ext/rj_schema/rapidjson/bin/jsonchecker/fail16.json +0 -1
- data/ext/rj_schema/rapidjson/bin/jsonchecker/fail17.json +0 -1
- data/ext/rj_schema/rapidjson/bin/jsonchecker/fail18.json +0 -1
- data/ext/rj_schema/rapidjson/bin/jsonchecker/fail19.json +0 -1
- data/ext/rj_schema/rapidjson/bin/jsonchecker/fail2.json +0 -1
- data/ext/rj_schema/rapidjson/bin/jsonchecker/fail20.json +0 -1
- data/ext/rj_schema/rapidjson/bin/jsonchecker/fail21.json +0 -1
- data/ext/rj_schema/rapidjson/bin/jsonchecker/fail22.json +0 -1
- data/ext/rj_schema/rapidjson/bin/jsonchecker/fail23.json +0 -1
- data/ext/rj_schema/rapidjson/bin/jsonchecker/fail24.json +0 -1
- data/ext/rj_schema/rapidjson/bin/jsonchecker/fail25.json +0 -1
- data/ext/rj_schema/rapidjson/bin/jsonchecker/fail26.json +0 -1
- data/ext/rj_schema/rapidjson/bin/jsonchecker/fail27.json +0 -2
- data/ext/rj_schema/rapidjson/bin/jsonchecker/fail28.json +0 -2
- data/ext/rj_schema/rapidjson/bin/jsonchecker/fail29.json +0 -1
- data/ext/rj_schema/rapidjson/bin/jsonchecker/fail3.json +0 -1
- data/ext/rj_schema/rapidjson/bin/jsonchecker/fail30.json +0 -1
- data/ext/rj_schema/rapidjson/bin/jsonchecker/fail31.json +0 -1
- data/ext/rj_schema/rapidjson/bin/jsonchecker/fail32.json +0 -1
- data/ext/rj_schema/rapidjson/bin/jsonchecker/fail33.json +0 -1
- data/ext/rj_schema/rapidjson/bin/jsonchecker/fail4.json +0 -1
- data/ext/rj_schema/rapidjson/bin/jsonchecker/fail5.json +0 -1
- data/ext/rj_schema/rapidjson/bin/jsonchecker/fail6.json +0 -1
- data/ext/rj_schema/rapidjson/bin/jsonchecker/fail7.json +0 -1
- data/ext/rj_schema/rapidjson/bin/jsonchecker/fail8.json +0 -1
- data/ext/rj_schema/rapidjson/bin/jsonchecker/fail9.json +0 -1
- data/ext/rj_schema/rapidjson/bin/jsonchecker/pass1.json +0 -58
- data/ext/rj_schema/rapidjson/bin/jsonchecker/pass2.json +0 -1
- data/ext/rj_schema/rapidjson/bin/jsonchecker/pass3.json +0 -6
- data/ext/rj_schema/rapidjson/bin/jsonchecker/readme.txt +0 -3
- data/ext/rj_schema/rapidjson/bin/jsonschema/LICENSE +0 -19
- data/ext/rj_schema/rapidjson/bin/jsonschema/README.md +0 -148
- data/ext/rj_schema/rapidjson/bin/jsonschema/bin/jsonschema_suite +0 -283
- data/ext/rj_schema/rapidjson/bin/jsonschema/remotes/folder/folderInteger.json +0 -3
- data/ext/rj_schema/rapidjson/bin/jsonschema/remotes/integer.json +0 -3
- data/ext/rj_schema/rapidjson/bin/jsonschema/remotes/subSchemas.json +0 -8
- data/ext/rj_schema/rapidjson/bin/jsonschema/tests/draft3/additionalItems.json +0 -82
- data/ext/rj_schema/rapidjson/bin/jsonschema/tests/draft3/additionalProperties.json +0 -88
- data/ext/rj_schema/rapidjson/bin/jsonschema/tests/draft3/default.json +0 -49
- data/ext/rj_schema/rapidjson/bin/jsonschema/tests/draft3/dependencies.json +0 -108
- data/ext/rj_schema/rapidjson/bin/jsonschema/tests/draft3/disallow.json +0 -80
- data/ext/rj_schema/rapidjson/bin/jsonschema/tests/draft3/divisibleBy.json +0 -60
- data/ext/rj_schema/rapidjson/bin/jsonschema/tests/draft3/enum.json +0 -71
- data/ext/rj_schema/rapidjson/bin/jsonschema/tests/draft3/extends.json +0 -94
- data/ext/rj_schema/rapidjson/bin/jsonschema/tests/draft3/items.json +0 -46
- data/ext/rj_schema/rapidjson/bin/jsonschema/tests/draft3/maxItems.json +0 -28
- data/ext/rj_schema/rapidjson/bin/jsonschema/tests/draft3/maxLength.json +0 -33
- data/ext/rj_schema/rapidjson/bin/jsonschema/tests/draft3/maximum.json +0 -42
- data/ext/rj_schema/rapidjson/bin/jsonschema/tests/draft3/minItems.json +0 -28
- data/ext/rj_schema/rapidjson/bin/jsonschema/tests/draft3/minLength.json +0 -33
- data/ext/rj_schema/rapidjson/bin/jsonschema/tests/draft3/minimum.json +0 -42
- data/ext/rj_schema/rapidjson/bin/jsonschema/tests/draft3/optional/bignum.json +0 -107
- data/ext/rj_schema/rapidjson/bin/jsonschema/tests/draft3/optional/format.json +0 -222
- data/ext/rj_schema/rapidjson/bin/jsonschema/tests/draft3/optional/jsregex.json +0 -18
- data/ext/rj_schema/rapidjson/bin/jsonschema/tests/draft3/optional/zeroTerminatedFloats.json +0 -15
- data/ext/rj_schema/rapidjson/bin/jsonschema/tests/draft3/pattern.json +0 -34
- data/ext/rj_schema/rapidjson/bin/jsonschema/tests/draft3/patternProperties.json +0 -110
- data/ext/rj_schema/rapidjson/bin/jsonschema/tests/draft3/properties.json +0 -92
- data/ext/rj_schema/rapidjson/bin/jsonschema/tests/draft3/ref.json +0 -159
- data/ext/rj_schema/rapidjson/bin/jsonschema/tests/draft3/refRemote.json +0 -74
- data/ext/rj_schema/rapidjson/bin/jsonschema/tests/draft3/required.json +0 -53
- data/ext/rj_schema/rapidjson/bin/jsonschema/tests/draft3/type.json +0 -474
- data/ext/rj_schema/rapidjson/bin/jsonschema/tests/draft3/uniqueItems.json +0 -79
- data/ext/rj_schema/rapidjson/bin/jsonschema/tests/draft4/additionalItems.json +0 -82
- data/ext/rj_schema/rapidjson/bin/jsonschema/tests/draft4/additionalProperties.json +0 -88
- data/ext/rj_schema/rapidjson/bin/jsonschema/tests/draft4/allOf.json +0 -112
- data/ext/rj_schema/rapidjson/bin/jsonschema/tests/draft4/anyOf.json +0 -68
- data/ext/rj_schema/rapidjson/bin/jsonschema/tests/draft4/default.json +0 -49
- data/ext/rj_schema/rapidjson/bin/jsonschema/tests/draft4/definitions.json +0 -32
- data/ext/rj_schema/rapidjson/bin/jsonschema/tests/draft4/dependencies.json +0 -113
- data/ext/rj_schema/rapidjson/bin/jsonschema/tests/draft4/enum.json +0 -72
- data/ext/rj_schema/rapidjson/bin/jsonschema/tests/draft4/items.json +0 -46
- data/ext/rj_schema/rapidjson/bin/jsonschema/tests/draft4/maxItems.json +0 -28
- data/ext/rj_schema/rapidjson/bin/jsonschema/tests/draft4/maxLength.json +0 -33
- data/ext/rj_schema/rapidjson/bin/jsonschema/tests/draft4/maxProperties.json +0 -28
- data/ext/rj_schema/rapidjson/bin/jsonschema/tests/draft4/maximum.json +0 -42
- data/ext/rj_schema/rapidjson/bin/jsonschema/tests/draft4/minItems.json +0 -28
- data/ext/rj_schema/rapidjson/bin/jsonschema/tests/draft4/minLength.json +0 -33
- data/ext/rj_schema/rapidjson/bin/jsonschema/tests/draft4/minProperties.json +0 -28
- data/ext/rj_schema/rapidjson/bin/jsonschema/tests/draft4/minimum.json +0 -42
- data/ext/rj_schema/rapidjson/bin/jsonschema/tests/draft4/multipleOf.json +0 -60
- data/ext/rj_schema/rapidjson/bin/jsonschema/tests/draft4/not.json +0 -96
- data/ext/rj_schema/rapidjson/bin/jsonschema/tests/draft4/oneOf.json +0 -68
- data/ext/rj_schema/rapidjson/bin/jsonschema/tests/draft4/optional/bignum.json +0 -107
- data/ext/rj_schema/rapidjson/bin/jsonschema/tests/draft4/optional/format.json +0 -148
- data/ext/rj_schema/rapidjson/bin/jsonschema/tests/draft4/optional/zeroTerminatedFloats.json +0 -15
- data/ext/rj_schema/rapidjson/bin/jsonschema/tests/draft4/pattern.json +0 -34
- data/ext/rj_schema/rapidjson/bin/jsonschema/tests/draft4/patternProperties.json +0 -110
- data/ext/rj_schema/rapidjson/bin/jsonschema/tests/draft4/properties.json +0 -92
- data/ext/rj_schema/rapidjson/bin/jsonschema/tests/draft4/ref.json +0 -159
- data/ext/rj_schema/rapidjson/bin/jsonschema/tests/draft4/refRemote.json +0 -74
- data/ext/rj_schema/rapidjson/bin/jsonschema/tests/draft4/required.json +0 -39
- data/ext/rj_schema/rapidjson/bin/jsonschema/tests/draft4/type.json +0 -330
- data/ext/rj_schema/rapidjson/bin/jsonschema/tests/draft4/uniqueItems.json +0 -79
- data/ext/rj_schema/rapidjson/bin/jsonschema/tox.ini +0 -8
- data/ext/rj_schema/rapidjson/bin/types/booleans.json +0 -102
- data/ext/rj_schema/rapidjson/bin/types/floats.json +0 -102
- data/ext/rj_schema/rapidjson/bin/types/guids.json +0 -102
- data/ext/rj_schema/rapidjson/bin/types/integers.json +0 -102
- data/ext/rj_schema/rapidjson/bin/types/mixed.json +0 -592
- data/ext/rj_schema/rapidjson/bin/types/nulls.json +0 -102
- data/ext/rj_schema/rapidjson/bin/types/paragraphs.json +0 -102
- data/ext/rj_schema/rapidjson/bin/types/readme.txt +0 -1
- data/ext/rj_schema/rapidjson/contrib/natvis/LICENSE +0 -45
- data/ext/rj_schema/rapidjson/contrib/natvis/README.md +0 -7
- data/ext/rj_schema/rapidjson/contrib/natvis/rapidjson.natvis +0 -38
- data/ext/rj_schema/rapidjson/doc/CMakeLists.txt +0 -27
- data/ext/rj_schema/rapidjson/doc/Doxyfile.in +0 -2369
- data/ext/rj_schema/rapidjson/doc/Doxyfile.zh-cn.in +0 -2369
- data/ext/rj_schema/rapidjson/doc/diagram/architecture.dot +0 -50
- data/ext/rj_schema/rapidjson/doc/diagram/architecture.png +0 -0
- data/ext/rj_schema/rapidjson/doc/diagram/insituparsing.dot +0 -65
- data/ext/rj_schema/rapidjson/doc/diagram/insituparsing.png +0 -0
- data/ext/rj_schema/rapidjson/doc/diagram/iterative-parser-states-diagram.dot +0 -62
- data/ext/rj_schema/rapidjson/doc/diagram/iterative-parser-states-diagram.png +0 -0
- data/ext/rj_schema/rapidjson/doc/diagram/makefile +0 -8
- data/ext/rj_schema/rapidjson/doc/diagram/move1.dot +0 -47
- data/ext/rj_schema/rapidjson/doc/diagram/move1.png +0 -0
- data/ext/rj_schema/rapidjson/doc/diagram/move2.dot +0 -62
- data/ext/rj_schema/rapidjson/doc/diagram/move2.png +0 -0
- data/ext/rj_schema/rapidjson/doc/diagram/move3.dot +0 -60
- data/ext/rj_schema/rapidjson/doc/diagram/move3.png +0 -0
- data/ext/rj_schema/rapidjson/doc/diagram/normalparsing.dot +0 -56
- data/ext/rj_schema/rapidjson/doc/diagram/normalparsing.png +0 -0
- data/ext/rj_schema/rapidjson/doc/diagram/simpledom.dot +0 -54
- data/ext/rj_schema/rapidjson/doc/diagram/simpledom.png +0 -0
- data/ext/rj_schema/rapidjson/doc/diagram/tutorial.dot +0 -58
- data/ext/rj_schema/rapidjson/doc/diagram/tutorial.png +0 -0
- data/ext/rj_schema/rapidjson/doc/diagram/utilityclass.dot +0 -73
- data/ext/rj_schema/rapidjson/doc/diagram/utilityclass.png +0 -0
- data/ext/rj_schema/rapidjson/doc/dom.md +0 -280
- data/ext/rj_schema/rapidjson/doc/dom.zh-cn.md +0 -284
- data/ext/rj_schema/rapidjson/doc/encoding.md +0 -146
- data/ext/rj_schema/rapidjson/doc/encoding.zh-cn.md +0 -152
- data/ext/rj_schema/rapidjson/doc/faq.md +0 -289
- data/ext/rj_schema/rapidjson/doc/faq.zh-cn.md +0 -290
- data/ext/rj_schema/rapidjson/doc/features.md +0 -104
- data/ext/rj_schema/rapidjson/doc/features.zh-cn.md +0 -103
- data/ext/rj_schema/rapidjson/doc/internals.md +0 -368
- data/ext/rj_schema/rapidjson/doc/internals.zh-cn.md +0 -363
- data/ext/rj_schema/rapidjson/doc/logo/rapidjson.png +0 -0
- data/ext/rj_schema/rapidjson/doc/logo/rapidjson.svg +0 -119
- data/ext/rj_schema/rapidjson/doc/misc/DoxygenLayout.xml +0 -194
- data/ext/rj_schema/rapidjson/doc/misc/doxygenextra.css +0 -274
- data/ext/rj_schema/rapidjson/doc/misc/footer.html +0 -11
- data/ext/rj_schema/rapidjson/doc/misc/header.html +0 -24
- data/ext/rj_schema/rapidjson/doc/npm.md +0 -31
- data/ext/rj_schema/rapidjson/doc/performance.md +0 -26
- data/ext/rj_schema/rapidjson/doc/performance.zh-cn.md +0 -26
- data/ext/rj_schema/rapidjson/doc/pointer.md +0 -234
- data/ext/rj_schema/rapidjson/doc/pointer.zh-cn.md +0 -234
- data/ext/rj_schema/rapidjson/doc/sax.md +0 -509
- data/ext/rj_schema/rapidjson/doc/sax.zh-cn.md +0 -487
- data/ext/rj_schema/rapidjson/doc/schema.md +0 -505
- data/ext/rj_schema/rapidjson/doc/schema.zh-cn.md +0 -237
- data/ext/rj_schema/rapidjson/doc/stream.md +0 -429
- data/ext/rj_schema/rapidjson/doc/stream.zh-cn.md +0 -429
- data/ext/rj_schema/rapidjson/doc/tutorial.md +0 -536
- data/ext/rj_schema/rapidjson/doc/tutorial.zh-cn.md +0 -534
- data/ext/rj_schema/rapidjson/docker/debian/Dockerfile +0 -8
- data/ext/rj_schema/rapidjson/example/CMakeLists.txt +0 -45
- data/ext/rj_schema/rapidjson/example/archiver/archiver.cpp +0 -292
- data/ext/rj_schema/rapidjson/example/archiver/archiver.h +0 -145
- data/ext/rj_schema/rapidjson/example/archiver/archivertest.cpp +0 -287
- data/ext/rj_schema/rapidjson/example/capitalize/capitalize.cpp +0 -67
- data/ext/rj_schema/rapidjson/example/condense/condense.cpp +0 -32
- data/ext/rj_schema/rapidjson/example/filterkey/filterkey.cpp +0 -135
- data/ext/rj_schema/rapidjson/example/filterkeydom/filterkeydom.cpp +0 -170
- data/ext/rj_schema/rapidjson/example/jsonx/jsonx.cpp +0 -207
- data/ext/rj_schema/rapidjson/example/lookaheadparser/lookaheadparser.cpp +0 -350
- data/ext/rj_schema/rapidjson/example/messagereader/messagereader.cpp +0 -105
- data/ext/rj_schema/rapidjson/example/parsebyparts/parsebyparts.cpp +0 -176
- data/ext/rj_schema/rapidjson/example/pretty/pretty.cpp +0 -30
- data/ext/rj_schema/rapidjson/example/prettyauto/prettyauto.cpp +0 -56
- data/ext/rj_schema/rapidjson/example/schemavalidator/schemavalidator.cpp +0 -78
- data/ext/rj_schema/rapidjson/example/serialize/serialize.cpp +0 -173
- data/ext/rj_schema/rapidjson/example/simpledom/simpledom.cpp +0 -29
- data/ext/rj_schema/rapidjson/example/simplepullreader/simplepullreader.cpp +0 -53
- data/ext/rj_schema/rapidjson/example/simplereader/simplereader.cpp +0 -42
- data/ext/rj_schema/rapidjson/example/simplewriter/simplewriter.cpp +0 -36
- data/ext/rj_schema/rapidjson/example/tutorial/tutorial.cpp +0 -151
- data/ext/rj_schema/rapidjson/include/rapidjson/allocators.h +0 -284
- data/ext/rj_schema/rapidjson/include/rapidjson/cursorstreamwrapper.h +0 -78
- data/ext/rj_schema/rapidjson/include/rapidjson/document.h +0 -2648
- data/ext/rj_schema/rapidjson/include/rapidjson/encodedstream.h +0 -299
- data/ext/rj_schema/rapidjson/include/rapidjson/encodings.h +0 -716
- data/ext/rj_schema/rapidjson/include/rapidjson/error/en.h +0 -74
- data/ext/rj_schema/rapidjson/include/rapidjson/error/error.h +0 -161
- data/ext/rj_schema/rapidjson/include/rapidjson/filereadstream.h +0 -99
- data/ext/rj_schema/rapidjson/include/rapidjson/filewritestream.h +0 -104
- data/ext/rj_schema/rapidjson/include/rapidjson/fwd.h +0 -151
- data/ext/rj_schema/rapidjson/include/rapidjson/internal/biginteger.h +0 -290
- data/ext/rj_schema/rapidjson/include/rapidjson/internal/diyfp.h +0 -271
- data/ext/rj_schema/rapidjson/include/rapidjson/internal/dtoa.h +0 -245
- data/ext/rj_schema/rapidjson/include/rapidjson/internal/ieee754.h +0 -78
- data/ext/rj_schema/rapidjson/include/rapidjson/internal/itoa.h +0 -308
- data/ext/rj_schema/rapidjson/include/rapidjson/internal/meta.h +0 -186
- data/ext/rj_schema/rapidjson/include/rapidjson/internal/pow10.h +0 -55
- data/ext/rj_schema/rapidjson/include/rapidjson/internal/regex.h +0 -732
- data/ext/rj_schema/rapidjson/include/rapidjson/internal/stack.h +0 -231
- data/ext/rj_schema/rapidjson/include/rapidjson/internal/strfunc.h +0 -69
- data/ext/rj_schema/rapidjson/include/rapidjson/internal/strtod.h +0 -290
- data/ext/rj_schema/rapidjson/include/rapidjson/internal/swap.h +0 -46
- data/ext/rj_schema/rapidjson/include/rapidjson/istreamwrapper.h +0 -113
- data/ext/rj_schema/rapidjson/include/rapidjson/memorybuffer.h +0 -70
- data/ext/rj_schema/rapidjson/include/rapidjson/memorystream.h +0 -71
- data/ext/rj_schema/rapidjson/include/rapidjson/msinttypes/inttypes.h +0 -316
- data/ext/rj_schema/rapidjson/include/rapidjson/msinttypes/stdint.h +0 -300
- data/ext/rj_schema/rapidjson/include/rapidjson/ostreamwrapper.h +0 -81
- data/ext/rj_schema/rapidjson/include/rapidjson/pointer.h +0 -1357
- data/ext/rj_schema/rapidjson/include/rapidjson/prettywriter.h +0 -277
- data/ext/rj_schema/rapidjson/include/rapidjson/rapidjson.h +0 -630
- data/ext/rj_schema/rapidjson/include/rapidjson/reader.h +0 -2230
- data/ext/rj_schema/rapidjson/include/rapidjson/schema.h +0 -2494
- data/ext/rj_schema/rapidjson/include/rapidjson/stream.h +0 -223
- data/ext/rj_schema/rapidjson/include/rapidjson/stringbuffer.h +0 -121
- data/ext/rj_schema/rapidjson/include/rapidjson/writer.h +0 -710
- data/ext/rj_schema/rapidjson/include_dirs.js +0 -2
- data/ext/rj_schema/rapidjson/library.json +0 -15
- data/ext/rj_schema/rapidjson/license.txt +0 -57
- data/ext/rj_schema/rapidjson/package.json +0 -24
- data/ext/rj_schema/rapidjson/rapidjson.autopkg +0 -77
- data/ext/rj_schema/rapidjson/readme.md +0 -160
- data/ext/rj_schema/rapidjson/readme.zh-cn.md +0 -152
- data/ext/rj_schema/rapidjson/test/CMakeLists.txt +0 -20
- data/ext/rj_schema/rapidjson/test/perftest/CMakeLists.txt +0 -28
- data/ext/rj_schema/rapidjson/test/perftest/misctest.cpp +0 -974
- data/ext/rj_schema/rapidjson/test/perftest/perftest.cpp +0 -24
- data/ext/rj_schema/rapidjson/test/perftest/perftest.h +0 -185
- data/ext/rj_schema/rapidjson/test/perftest/platformtest.cpp +0 -166
- data/ext/rj_schema/rapidjson/test/perftest/rapidjsontest.cpp +0 -472
- data/ext/rj_schema/rapidjson/test/perftest/schematest.cpp +0 -223
- data/ext/rj_schema/rapidjson/test/unittest/CMakeLists.txt +0 -92
- data/ext/rj_schema/rapidjson/test/unittest/allocatorstest.cpp +0 -100
- data/ext/rj_schema/rapidjson/test/unittest/bigintegertest.cpp +0 -138
- data/ext/rj_schema/rapidjson/test/unittest/cursorstreamwrappertest.cpp +0 -115
- data/ext/rj_schema/rapidjson/test/unittest/documenttest.cpp +0 -672
- data/ext/rj_schema/rapidjson/test/unittest/dtoatest.cpp +0 -98
- data/ext/rj_schema/rapidjson/test/unittest/encodedstreamtest.cpp +0 -313
- data/ext/rj_schema/rapidjson/test/unittest/encodingstest.cpp +0 -451
- data/ext/rj_schema/rapidjson/test/unittest/filestreamtest.cpp +0 -112
- data/ext/rj_schema/rapidjson/test/unittest/fwdtest.cpp +0 -230
- data/ext/rj_schema/rapidjson/test/unittest/istreamwrappertest.cpp +0 -181
- data/ext/rj_schema/rapidjson/test/unittest/itoatest.cpp +0 -160
- data/ext/rj_schema/rapidjson/test/unittest/jsoncheckertest.cpp +0 -143
- data/ext/rj_schema/rapidjson/test/unittest/namespacetest.cpp +0 -70
- data/ext/rj_schema/rapidjson/test/unittest/ostreamwrappertest.cpp +0 -92
- data/ext/rj_schema/rapidjson/test/unittest/pointertest.cpp +0 -1529
- data/ext/rj_schema/rapidjson/test/unittest/prettywritertest.cpp +0 -373
- data/ext/rj_schema/rapidjson/test/unittest/readertest.cpp +0 -2190
- data/ext/rj_schema/rapidjson/test/unittest/regextest.cpp +0 -638
- data/ext/rj_schema/rapidjson/test/unittest/schematest.cpp +0 -2072
- data/ext/rj_schema/rapidjson/test/unittest/simdtest.cpp +0 -219
- data/ext/rj_schema/rapidjson/test/unittest/strfunctest.cpp +0 -30
- data/ext/rj_schema/rapidjson/test/unittest/stringbuffertest.cpp +0 -192
- data/ext/rj_schema/rapidjson/test/unittest/strtodtest.cpp +0 -132
- data/ext/rj_schema/rapidjson/test/unittest/unittest.cpp +0 -51
- data/ext/rj_schema/rapidjson/test/unittest/unittest.h +0 -140
- data/ext/rj_schema/rapidjson/test/unittest/valuetest.cpp +0 -1851
- data/ext/rj_schema/rapidjson/test/unittest/writertest.cpp +0 -598
- data/ext/rj_schema/rapidjson/test/valgrind.supp +0 -17
- data/ext/rj_schema/rapidjson/thirdparty/gtest/CMakeLists.txt +0 -16
- data/ext/rj_schema/rapidjson/thirdparty/gtest/README.md +0 -141
- data/ext/rj_schema/rapidjson/thirdparty/gtest/googlemock/CHANGES +0 -126
- data/ext/rj_schema/rapidjson/thirdparty/gtest/googlemock/CMakeLists.txt +0 -202
- data/ext/rj_schema/rapidjson/thirdparty/gtest/googlemock/CONTRIBUTORS +0 -40
- data/ext/rj_schema/rapidjson/thirdparty/gtest/googlemock/LICENSE +0 -28
- data/ext/rj_schema/rapidjson/thirdparty/gtest/googlemock/Makefile.am +0 -224
- data/ext/rj_schema/rapidjson/thirdparty/gtest/googlemock/README.md +0 -333
- data/ext/rj_schema/rapidjson/thirdparty/gtest/googlemock/configure.ac +0 -146
- data/ext/rj_schema/rapidjson/thirdparty/gtest/googlemock/docs/CheatSheet.md +0 -562
- data/ext/rj_schema/rapidjson/thirdparty/gtest/googlemock/docs/CookBook.md +0 -3675
- data/ext/rj_schema/rapidjson/thirdparty/gtest/googlemock/docs/DesignDoc.md +0 -280
- data/ext/rj_schema/rapidjson/thirdparty/gtest/googlemock/docs/DevGuide.md +0 -132
- data/ext/rj_schema/rapidjson/thirdparty/gtest/googlemock/docs/Documentation.md +0 -12
- data/ext/rj_schema/rapidjson/thirdparty/gtest/googlemock/docs/ForDummies.md +0 -439
- data/ext/rj_schema/rapidjson/thirdparty/gtest/googlemock/docs/FrequentlyAskedQuestions.md +0 -628
- data/ext/rj_schema/rapidjson/thirdparty/gtest/googlemock/docs/KnownIssues.md +0 -19
- data/ext/rj_schema/rapidjson/thirdparty/gtest/googlemock/docs/v1_5/CheatSheet.md +0 -525
- data/ext/rj_schema/rapidjson/thirdparty/gtest/googlemock/docs/v1_5/CookBook.md +0 -3250
- data/ext/rj_schema/rapidjson/thirdparty/gtest/googlemock/docs/v1_5/Documentation.md +0 -11
- data/ext/rj_schema/rapidjson/thirdparty/gtest/googlemock/docs/v1_5/ForDummies.md +0 -439
- data/ext/rj_schema/rapidjson/thirdparty/gtest/googlemock/docs/v1_5/FrequentlyAskedQuestions.md +0 -624
- data/ext/rj_schema/rapidjson/thirdparty/gtest/googlemock/docs/v1_6/CheatSheet.md +0 -534
- data/ext/rj_schema/rapidjson/thirdparty/gtest/googlemock/docs/v1_6/CookBook.md +0 -3342
- data/ext/rj_schema/rapidjson/thirdparty/gtest/googlemock/docs/v1_6/Documentation.md +0 -12
- data/ext/rj_schema/rapidjson/thirdparty/gtest/googlemock/docs/v1_6/ForDummies.md +0 -439
- data/ext/rj_schema/rapidjson/thirdparty/gtest/googlemock/docs/v1_6/FrequentlyAskedQuestions.md +0 -628
- data/ext/rj_schema/rapidjson/thirdparty/gtest/googlemock/docs/v1_7/CheatSheet.md +0 -556
- data/ext/rj_schema/rapidjson/thirdparty/gtest/googlemock/docs/v1_7/CookBook.md +0 -3432
- data/ext/rj_schema/rapidjson/thirdparty/gtest/googlemock/docs/v1_7/Documentation.md +0 -12
- data/ext/rj_schema/rapidjson/thirdparty/gtest/googlemock/docs/v1_7/ForDummies.md +0 -439
- data/ext/rj_schema/rapidjson/thirdparty/gtest/googlemock/docs/v1_7/FrequentlyAskedQuestions.md +0 -628
- data/ext/rj_schema/rapidjson/thirdparty/gtest/googlemock/include/gmock/gmock-actions.h +0 -1205
- data/ext/rj_schema/rapidjson/thirdparty/gtest/googlemock/include/gmock/gmock-cardinalities.h +0 -147
- data/ext/rj_schema/rapidjson/thirdparty/gtest/googlemock/include/gmock/gmock-generated-actions.h +0 -2377
- data/ext/rj_schema/rapidjson/thirdparty/gtest/googlemock/include/gmock/gmock-generated-actions.h.pump +0 -794
- data/ext/rj_schema/rapidjson/thirdparty/gtest/googlemock/include/gmock/gmock-generated-function-mockers.h +0 -1095
- data/ext/rj_schema/rapidjson/thirdparty/gtest/googlemock/include/gmock/gmock-generated-function-mockers.h.pump +0 -291
- data/ext/rj_schema/rapidjson/thirdparty/gtest/googlemock/include/gmock/gmock-generated-matchers.h +0 -2179
- data/ext/rj_schema/rapidjson/thirdparty/gtest/googlemock/include/gmock/gmock-generated-matchers.h.pump +0 -672
- data/ext/rj_schema/rapidjson/thirdparty/gtest/googlemock/include/gmock/gmock-generated-nice-strict.h +0 -397
- data/ext/rj_schema/rapidjson/thirdparty/gtest/googlemock/include/gmock/gmock-generated-nice-strict.h.pump +0 -161
- data/ext/rj_schema/rapidjson/thirdparty/gtest/googlemock/include/gmock/gmock-matchers.h +0 -4399
- data/ext/rj_schema/rapidjson/thirdparty/gtest/googlemock/include/gmock/gmock-more-actions.h +0 -246
- data/ext/rj_schema/rapidjson/thirdparty/gtest/googlemock/include/gmock/gmock-more-matchers.h +0 -58
- data/ext/rj_schema/rapidjson/thirdparty/gtest/googlemock/include/gmock/gmock-spec-builders.h +0 -1847
- data/ext/rj_schema/rapidjson/thirdparty/gtest/googlemock/include/gmock/gmock.h +0 -94
- data/ext/rj_schema/rapidjson/thirdparty/gtest/googlemock/include/gmock/internal/custom/gmock-generated-actions.h +0 -8
- data/ext/rj_schema/rapidjson/thirdparty/gtest/googlemock/include/gmock/internal/custom/gmock-generated-actions.h.pump +0 -10
- data/ext/rj_schema/rapidjson/thirdparty/gtest/googlemock/include/gmock/internal/custom/gmock-matchers.h +0 -39
- data/ext/rj_schema/rapidjson/thirdparty/gtest/googlemock/include/gmock/internal/custom/gmock-port.h +0 -46
- data/ext/rj_schema/rapidjson/thirdparty/gtest/googlemock/include/gmock/internal/gmock-generated-internal-utils.h +0 -279
- data/ext/rj_schema/rapidjson/thirdparty/gtest/googlemock/include/gmock/internal/gmock-generated-internal-utils.h.pump +0 -136
- data/ext/rj_schema/rapidjson/thirdparty/gtest/googlemock/include/gmock/internal/gmock-internal-utils.h +0 -511
- data/ext/rj_schema/rapidjson/thirdparty/gtest/googlemock/include/gmock/internal/gmock-port.h +0 -91
- data/ext/rj_schema/rapidjson/thirdparty/gtest/googlemock/make/Makefile +0 -101
- data/ext/rj_schema/rapidjson/thirdparty/gtest/googlemock/msvc/2005/gmock.sln +0 -32
- data/ext/rj_schema/rapidjson/thirdparty/gtest/googlemock/msvc/2005/gmock.vcproj +0 -191
- data/ext/rj_schema/rapidjson/thirdparty/gtest/googlemock/msvc/2005/gmock_config.vsprops +0 -15
- data/ext/rj_schema/rapidjson/thirdparty/gtest/googlemock/msvc/2005/gmock_main.vcproj +0 -187
- data/ext/rj_schema/rapidjson/thirdparty/gtest/googlemock/msvc/2005/gmock_test.vcproj +0 -201
- data/ext/rj_schema/rapidjson/thirdparty/gtest/googlemock/msvc/2010/gmock.sln +0 -32
- data/ext/rj_schema/rapidjson/thirdparty/gtest/googlemock/msvc/2010/gmock.vcxproj +0 -82
- data/ext/rj_schema/rapidjson/thirdparty/gtest/googlemock/msvc/2010/gmock_config.props +0 -19
- data/ext/rj_schema/rapidjson/thirdparty/gtest/googlemock/msvc/2010/gmock_main.vcxproj +0 -88
- data/ext/rj_schema/rapidjson/thirdparty/gtest/googlemock/msvc/2010/gmock_test.vcxproj +0 -101
- data/ext/rj_schema/rapidjson/thirdparty/gtest/googlemock/msvc/2015/gmock.sln +0 -32
- data/ext/rj_schema/rapidjson/thirdparty/gtest/googlemock/msvc/2015/gmock.vcxproj +0 -84
- data/ext/rj_schema/rapidjson/thirdparty/gtest/googlemock/msvc/2015/gmock_config.props +0 -19
- data/ext/rj_schema/rapidjson/thirdparty/gtest/googlemock/msvc/2015/gmock_main.vcxproj +0 -90
- data/ext/rj_schema/rapidjson/thirdparty/gtest/googlemock/msvc/2015/gmock_test.vcxproj +0 -103
- data/ext/rj_schema/rapidjson/thirdparty/gtest/googlemock/scripts/fuse_gmock_files.py +0 -240
- data/ext/rj_schema/rapidjson/thirdparty/gtest/googlemock/scripts/generator/LICENSE +0 -203
- data/ext/rj_schema/rapidjson/thirdparty/gtest/googlemock/scripts/generator/README +0 -35
- data/ext/rj_schema/rapidjson/thirdparty/gtest/googlemock/scripts/generator/README.cppclean +0 -115
- data/ext/rj_schema/rapidjson/thirdparty/gtest/googlemock/scripts/generator/cpp/__init__.py +0 -0
- data/ext/rj_schema/rapidjson/thirdparty/gtest/googlemock/scripts/generator/cpp/ast.py +0 -1733
- data/ext/rj_schema/rapidjson/thirdparty/gtest/googlemock/scripts/generator/cpp/gmock_class.py +0 -227
- data/ext/rj_schema/rapidjson/thirdparty/gtest/googlemock/scripts/generator/cpp/gmock_class_test.py +0 -448
- data/ext/rj_schema/rapidjson/thirdparty/gtest/googlemock/scripts/generator/cpp/keywords.py +0 -59
- data/ext/rj_schema/rapidjson/thirdparty/gtest/googlemock/scripts/generator/cpp/tokenize.py +0 -287
- data/ext/rj_schema/rapidjson/thirdparty/gtest/googlemock/scripts/generator/cpp/utils.py +0 -41
- data/ext/rj_schema/rapidjson/thirdparty/gtest/googlemock/scripts/generator/gmock_gen.py +0 -31
- data/ext/rj_schema/rapidjson/thirdparty/gtest/googlemock/scripts/gmock-config.in +0 -303
- data/ext/rj_schema/rapidjson/thirdparty/gtest/googlemock/scripts/gmock_doctor.py +0 -640
- data/ext/rj_schema/rapidjson/thirdparty/gtest/googlemock/scripts/upload.py +0 -1387
- data/ext/rj_schema/rapidjson/thirdparty/gtest/googlemock/scripts/upload_gmock.py +0 -78
- data/ext/rj_schema/rapidjson/thirdparty/gtest/googlemock/src/gmock-all.cc +0 -47
- data/ext/rj_schema/rapidjson/thirdparty/gtest/googlemock/src/gmock-cardinalities.cc +0 -156
- data/ext/rj_schema/rapidjson/thirdparty/gtest/googlemock/src/gmock-internal-utils.cc +0 -174
- data/ext/rj_schema/rapidjson/thirdparty/gtest/googlemock/src/gmock-matchers.cc +0 -498
- data/ext/rj_schema/rapidjson/thirdparty/gtest/googlemock/src/gmock-spec-builders.cc +0 -823
- data/ext/rj_schema/rapidjson/thirdparty/gtest/googlemock/src/gmock.cc +0 -183
- data/ext/rj_schema/rapidjson/thirdparty/gtest/googlemock/src/gmock_main.cc +0 -54
- data/ext/rj_schema/rapidjson/thirdparty/gtest/googlemock/test/gmock-actions_test.cc +0 -1411
- data/ext/rj_schema/rapidjson/thirdparty/gtest/googlemock/test/gmock-cardinalities_test.cc +0 -428
- data/ext/rj_schema/rapidjson/thirdparty/gtest/googlemock/test/gmock-generated-actions_test.cc +0 -1228
- data/ext/rj_schema/rapidjson/thirdparty/gtest/googlemock/test/gmock-generated-function-mockers_test.cc +0 -622
- data/ext/rj_schema/rapidjson/thirdparty/gtest/googlemock/test/gmock-generated-internal-utils_test.cc +0 -127
- data/ext/rj_schema/rapidjson/thirdparty/gtest/googlemock/test/gmock-generated-matchers_test.cc +0 -1286
- data/ext/rj_schema/rapidjson/thirdparty/gtest/googlemock/test/gmock-internal-utils_test.cc +0 -699
- data/ext/rj_schema/rapidjson/thirdparty/gtest/googlemock/test/gmock-matchers_test.cc +0 -5648
- data/ext/rj_schema/rapidjson/thirdparty/gtest/googlemock/test/gmock-more-actions_test.cc +0 -708
- data/ext/rj_schema/rapidjson/thirdparty/gtest/googlemock/test/gmock-nice-strict_test.cc +0 -424
- data/ext/rj_schema/rapidjson/thirdparty/gtest/googlemock/test/gmock-port_test.cc +0 -43
- data/ext/rj_schema/rapidjson/thirdparty/gtest/googlemock/test/gmock-spec-builders_test.cc +0 -2644
- data/ext/rj_schema/rapidjson/thirdparty/gtest/googlemock/test/gmock_all_test.cc +0 -51
- data/ext/rj_schema/rapidjson/thirdparty/gtest/googlemock/test/gmock_ex_test.cc +0 -81
- data/ext/rj_schema/rapidjson/thirdparty/gtest/googlemock/test/gmock_leak_test.py +0 -108
- data/ext/rj_schema/rapidjson/thirdparty/gtest/googlemock/test/gmock_leak_test_.cc +0 -100
- data/ext/rj_schema/rapidjson/thirdparty/gtest/googlemock/test/gmock_link2_test.cc +0 -40
- data/ext/rj_schema/rapidjson/thirdparty/gtest/googlemock/test/gmock_link_test.cc +0 -40
- data/ext/rj_schema/rapidjson/thirdparty/gtest/googlemock/test/gmock_link_test.h +0 -669
- data/ext/rj_schema/rapidjson/thirdparty/gtest/googlemock/test/gmock_output_test.py +0 -180
- data/ext/rj_schema/rapidjson/thirdparty/gtest/googlemock/test/gmock_output_test_.cc +0 -291
- data/ext/rj_schema/rapidjson/thirdparty/gtest/googlemock/test/gmock_output_test_golden.txt +0 -310
- data/ext/rj_schema/rapidjson/thirdparty/gtest/googlemock/test/gmock_stress_test.cc +0 -322
- data/ext/rj_schema/rapidjson/thirdparty/gtest/googlemock/test/gmock_test.cc +0 -220
- data/ext/rj_schema/rapidjson/thirdparty/gtest/googlemock/test/gmock_test_utils.py +0 -112
- data/ext/rj_schema/rapidjson/thirdparty/gtest/googletest/CHANGES +0 -157
- data/ext/rj_schema/rapidjson/thirdparty/gtest/googletest/CMakeLists.txt +0 -286
- data/ext/rj_schema/rapidjson/thirdparty/gtest/googletest/CONTRIBUTORS +0 -37
- data/ext/rj_schema/rapidjson/thirdparty/gtest/googletest/LICENSE +0 -28
- data/ext/rj_schema/rapidjson/thirdparty/gtest/googletest/Makefile.am +0 -310
- data/ext/rj_schema/rapidjson/thirdparty/gtest/googletest/README.md +0 -280
- data/ext/rj_schema/rapidjson/thirdparty/gtest/googletest/cmake/internal_utils.cmake +0 -242
- data/ext/rj_schema/rapidjson/thirdparty/gtest/googletest/codegear/gtest.cbproj +0 -138
- data/ext/rj_schema/rapidjson/thirdparty/gtest/googletest/codegear/gtest.groupproj +0 -54
- data/ext/rj_schema/rapidjson/thirdparty/gtest/googletest/codegear/gtest_all.cc +0 -38
- data/ext/rj_schema/rapidjson/thirdparty/gtest/googletest/codegear/gtest_link.cc +0 -40
- data/ext/rj_schema/rapidjson/thirdparty/gtest/googletest/codegear/gtest_main.cbproj +0 -82
- data/ext/rj_schema/rapidjson/thirdparty/gtest/googletest/codegear/gtest_unittest.cbproj +0 -88
- data/ext/rj_schema/rapidjson/thirdparty/gtest/googletest/configure.ac +0 -68
- data/ext/rj_schema/rapidjson/thirdparty/gtest/googletest/docs/AdvancedGuide.md +0 -2182
- data/ext/rj_schema/rapidjson/thirdparty/gtest/googletest/docs/DevGuide.md +0 -126
- data/ext/rj_schema/rapidjson/thirdparty/gtest/googletest/docs/Documentation.md +0 -14
- data/ext/rj_schema/rapidjson/thirdparty/gtest/googletest/docs/FAQ.md +0 -1087
- data/ext/rj_schema/rapidjson/thirdparty/gtest/googletest/docs/Primer.md +0 -502
- data/ext/rj_schema/rapidjson/thirdparty/gtest/googletest/docs/PumpManual.md +0 -177
- data/ext/rj_schema/rapidjson/thirdparty/gtest/googletest/docs/Samples.md +0 -14
- data/ext/rj_schema/rapidjson/thirdparty/gtest/googletest/docs/V1_5_AdvancedGuide.md +0 -2096
- data/ext/rj_schema/rapidjson/thirdparty/gtest/googletest/docs/V1_5_Documentation.md +0 -12
- data/ext/rj_schema/rapidjson/thirdparty/gtest/googletest/docs/V1_5_FAQ.md +0 -886
- data/ext/rj_schema/rapidjson/thirdparty/gtest/googletest/docs/V1_5_Primer.md +0 -497
- data/ext/rj_schema/rapidjson/thirdparty/gtest/googletest/docs/V1_5_PumpManual.md +0 -177
- data/ext/rj_schema/rapidjson/thirdparty/gtest/googletest/docs/V1_5_XcodeGuide.md +0 -93
- data/ext/rj_schema/rapidjson/thirdparty/gtest/googletest/docs/V1_6_AdvancedGuide.md +0 -2178
- data/ext/rj_schema/rapidjson/thirdparty/gtest/googletest/docs/V1_6_Documentation.md +0 -14
- data/ext/rj_schema/rapidjson/thirdparty/gtest/googletest/docs/V1_6_FAQ.md +0 -1038
- data/ext/rj_schema/rapidjson/thirdparty/gtest/googletest/docs/V1_6_Primer.md +0 -501
- data/ext/rj_schema/rapidjson/thirdparty/gtest/googletest/docs/V1_6_PumpManual.md +0 -177
- data/ext/rj_schema/rapidjson/thirdparty/gtest/googletest/docs/V1_6_Samples.md +0 -14
- data/ext/rj_schema/rapidjson/thirdparty/gtest/googletest/docs/V1_6_XcodeGuide.md +0 -93
- data/ext/rj_schema/rapidjson/thirdparty/gtest/googletest/docs/V1_7_AdvancedGuide.md +0 -2181
- data/ext/rj_schema/rapidjson/thirdparty/gtest/googletest/docs/V1_7_Documentation.md +0 -14
- data/ext/rj_schema/rapidjson/thirdparty/gtest/googletest/docs/V1_7_FAQ.md +0 -1082
- data/ext/rj_schema/rapidjson/thirdparty/gtest/googletest/docs/V1_7_Primer.md +0 -501
- data/ext/rj_schema/rapidjson/thirdparty/gtest/googletest/docs/V1_7_PumpManual.md +0 -177
- data/ext/rj_schema/rapidjson/thirdparty/gtest/googletest/docs/V1_7_Samples.md +0 -14
- data/ext/rj_schema/rapidjson/thirdparty/gtest/googletest/docs/V1_7_XcodeGuide.md +0 -93
- data/ext/rj_schema/rapidjson/thirdparty/gtest/googletest/docs/XcodeGuide.md +0 -93
- data/ext/rj_schema/rapidjson/thirdparty/gtest/googletest/include/gtest/gtest-death-test.h +0 -294
- data/ext/rj_schema/rapidjson/thirdparty/gtest/googletest/include/gtest/gtest-message.h +0 -250
- data/ext/rj_schema/rapidjson/thirdparty/gtest/googletest/include/gtest/gtest-param-test.h +0 -1444
- data/ext/rj_schema/rapidjson/thirdparty/gtest/googletest/include/gtest/gtest-param-test.h.pump +0 -510
- data/ext/rj_schema/rapidjson/thirdparty/gtest/googletest/include/gtest/gtest-printers.h +0 -993
- data/ext/rj_schema/rapidjson/thirdparty/gtest/googletest/include/gtest/gtest-spi.h +0 -232
- data/ext/rj_schema/rapidjson/thirdparty/gtest/googletest/include/gtest/gtest-test-part.h +0 -179
- data/ext/rj_schema/rapidjson/thirdparty/gtest/googletest/include/gtest/gtest-typed-test.h +0 -263
- data/ext/rj_schema/rapidjson/thirdparty/gtest/googletest/include/gtest/gtest.h +0 -2236
- data/ext/rj_schema/rapidjson/thirdparty/gtest/googletest/include/gtest/gtest_pred_impl.h +0 -358
- data/ext/rj_schema/rapidjson/thirdparty/gtest/googletest/include/gtest/gtest_prod.h +0 -58
- data/ext/rj_schema/rapidjson/thirdparty/gtest/googletest/include/gtest/internal/custom/gtest-port.h +0 -69
- data/ext/rj_schema/rapidjson/thirdparty/gtest/googletest/include/gtest/internal/custom/gtest-printers.h +0 -42
- data/ext/rj_schema/rapidjson/thirdparty/gtest/googletest/include/gtest/internal/custom/gtest.h +0 -41
- data/ext/rj_schema/rapidjson/thirdparty/gtest/googletest/include/gtest/internal/gtest-death-test-internal.h +0 -319
- data/ext/rj_schema/rapidjson/thirdparty/gtest/googletest/include/gtest/internal/gtest-filepath.h +0 -206
- data/ext/rj_schema/rapidjson/thirdparty/gtest/googletest/include/gtest/internal/gtest-internal.h +0 -1238
- data/ext/rj_schema/rapidjson/thirdparty/gtest/googletest/include/gtest/internal/gtest-linked_ptr.h +0 -243
- data/ext/rj_schema/rapidjson/thirdparty/gtest/googletest/include/gtest/internal/gtest-param-util-generated.h +0 -5146
- data/ext/rj_schema/rapidjson/thirdparty/gtest/googletest/include/gtest/internal/gtest-param-util-generated.h.pump +0 -286
- data/ext/rj_schema/rapidjson/thirdparty/gtest/googletest/include/gtest/internal/gtest-param-util.h +0 -731
- data/ext/rj_schema/rapidjson/thirdparty/gtest/googletest/include/gtest/internal/gtest-port-arch.h +0 -93
- data/ext/rj_schema/rapidjson/thirdparty/gtest/googletest/include/gtest/internal/gtest-port.h +0 -2554
- data/ext/rj_schema/rapidjson/thirdparty/gtest/googletest/include/gtest/internal/gtest-string.h +0 -167
- data/ext/rj_schema/rapidjson/thirdparty/gtest/googletest/include/gtest/internal/gtest-tuple.h +0 -1020
- data/ext/rj_schema/rapidjson/thirdparty/gtest/googletest/include/gtest/internal/gtest-tuple.h.pump +0 -347
- data/ext/rj_schema/rapidjson/thirdparty/gtest/googletest/include/gtest/internal/gtest-type-util.h +0 -3331
- data/ext/rj_schema/rapidjson/thirdparty/gtest/googletest/include/gtest/internal/gtest-type-util.h.pump +0 -297
- data/ext/rj_schema/rapidjson/thirdparty/gtest/googletest/m4/acx_pthread.m4 +0 -363
- data/ext/rj_schema/rapidjson/thirdparty/gtest/googletest/m4/gtest.m4 +0 -74
- data/ext/rj_schema/rapidjson/thirdparty/gtest/googletest/make/Makefile +0 -82
- data/ext/rj_schema/rapidjson/thirdparty/gtest/googletest/msvc/gtest-md.sln +0 -45
- data/ext/rj_schema/rapidjson/thirdparty/gtest/googletest/msvc/gtest-md.vcproj +0 -126
- data/ext/rj_schema/rapidjson/thirdparty/gtest/googletest/msvc/gtest.sln +0 -45
- data/ext/rj_schema/rapidjson/thirdparty/gtest/googletest/msvc/gtest.vcproj +0 -126
- data/ext/rj_schema/rapidjson/thirdparty/gtest/googletest/msvc/gtest_main-md.vcproj +0 -129
- data/ext/rj_schema/rapidjson/thirdparty/gtest/googletest/msvc/gtest_main.vcproj +0 -129
- data/ext/rj_schema/rapidjson/thirdparty/gtest/googletest/msvc/gtest_prod_test-md.vcproj +0 -164
- data/ext/rj_schema/rapidjson/thirdparty/gtest/googletest/msvc/gtest_prod_test.vcproj +0 -164
- data/ext/rj_schema/rapidjson/thirdparty/gtest/googletest/msvc/gtest_unittest-md.vcproj +0 -147
- data/ext/rj_schema/rapidjson/thirdparty/gtest/googletest/msvc/gtest_unittest.vcproj +0 -147
- data/ext/rj_schema/rapidjson/thirdparty/gtest/googletest/samples/prime_tables.h +0 -123
- data/ext/rj_schema/rapidjson/thirdparty/gtest/googletest/samples/sample1.cc +0 -68
- data/ext/rj_schema/rapidjson/thirdparty/gtest/googletest/samples/sample1.h +0 -43
- data/ext/rj_schema/rapidjson/thirdparty/gtest/googletest/samples/sample10_unittest.cc +0 -144
- data/ext/rj_schema/rapidjson/thirdparty/gtest/googletest/samples/sample1_unittest.cc +0 -153
- data/ext/rj_schema/rapidjson/thirdparty/gtest/googletest/samples/sample2.cc +0 -56
- data/ext/rj_schema/rapidjson/thirdparty/gtest/googletest/samples/sample2.h +0 -85
- data/ext/rj_schema/rapidjson/thirdparty/gtest/googletest/samples/sample2_unittest.cc +0 -109
- data/ext/rj_schema/rapidjson/thirdparty/gtest/googletest/samples/sample3-inl.h +0 -172
- data/ext/rj_schema/rapidjson/thirdparty/gtest/googletest/samples/sample3_unittest.cc +0 -151
- data/ext/rj_schema/rapidjson/thirdparty/gtest/googletest/samples/sample4.cc +0 -46
- data/ext/rj_schema/rapidjson/thirdparty/gtest/googletest/samples/sample4.h +0 -53
- data/ext/rj_schema/rapidjson/thirdparty/gtest/googletest/samples/sample4_unittest.cc +0 -45
- data/ext/rj_schema/rapidjson/thirdparty/gtest/googletest/samples/sample5_unittest.cc +0 -199
- data/ext/rj_schema/rapidjson/thirdparty/gtest/googletest/samples/sample6_unittest.cc +0 -224
- data/ext/rj_schema/rapidjson/thirdparty/gtest/googletest/samples/sample7_unittest.cc +0 -130
- data/ext/rj_schema/rapidjson/thirdparty/gtest/googletest/samples/sample8_unittest.cc +0 -173
- data/ext/rj_schema/rapidjson/thirdparty/gtest/googletest/samples/sample9_unittest.cc +0 -160
- data/ext/rj_schema/rapidjson/thirdparty/gtest/googletest/scripts/common.py +0 -83
- data/ext/rj_schema/rapidjson/thirdparty/gtest/googletest/scripts/fuse_gtest_files.py +0 -253
- data/ext/rj_schema/rapidjson/thirdparty/gtest/googletest/scripts/gen_gtest_pred_impl.py +0 -730
- data/ext/rj_schema/rapidjson/thirdparty/gtest/googletest/scripts/gtest-config.in +0 -274
- data/ext/rj_schema/rapidjson/thirdparty/gtest/googletest/scripts/pump.py +0 -855
- data/ext/rj_schema/rapidjson/thirdparty/gtest/googletest/scripts/release_docs.py +0 -158
- data/ext/rj_schema/rapidjson/thirdparty/gtest/googletest/scripts/test/Makefile +0 -59
- data/ext/rj_schema/rapidjson/thirdparty/gtest/googletest/scripts/upload.py +0 -1387
- data/ext/rj_schema/rapidjson/thirdparty/gtest/googletest/scripts/upload_gtest.py +0 -78
- data/ext/rj_schema/rapidjson/thirdparty/gtest/googletest/src/gtest-all.cc +0 -48
- data/ext/rj_schema/rapidjson/thirdparty/gtest/googletest/src/gtest-death-test.cc +0 -1342
- data/ext/rj_schema/rapidjson/thirdparty/gtest/googletest/src/gtest-filepath.cc +0 -387
- data/ext/rj_schema/rapidjson/thirdparty/gtest/googletest/src/gtest-internal-inl.h +0 -1183
- data/ext/rj_schema/rapidjson/thirdparty/gtest/googletest/src/gtest-port.cc +0 -1259
- data/ext/rj_schema/rapidjson/thirdparty/gtest/googletest/src/gtest-printers.cc +0 -373
- data/ext/rj_schema/rapidjson/thirdparty/gtest/googletest/src/gtest-test-part.cc +0 -110
- data/ext/rj_schema/rapidjson/thirdparty/gtest/googletest/src/gtest-typed-test.cc +0 -118
- data/ext/rj_schema/rapidjson/thirdparty/gtest/googletest/src/gtest.cc +0 -5388
- data/ext/rj_schema/rapidjson/thirdparty/gtest/googletest/src/gtest_main.cc +0 -38
- data/ext/rj_schema/rapidjson/thirdparty/gtest/googletest/test/gtest-death-test_ex_test.cc +0 -93
- data/ext/rj_schema/rapidjson/thirdparty/gtest/googletest/test/gtest-death-test_test.cc +0 -1427
- data/ext/rj_schema/rapidjson/thirdparty/gtest/googletest/test/gtest-filepath_test.cc +0 -662
- data/ext/rj_schema/rapidjson/thirdparty/gtest/googletest/test/gtest-linked_ptr_test.cc +0 -154
- data/ext/rj_schema/rapidjson/thirdparty/gtest/googletest/test/gtest-listener_test.cc +0 -311
- data/ext/rj_schema/rapidjson/thirdparty/gtest/googletest/test/gtest-message_test.cc +0 -159
- data/ext/rj_schema/rapidjson/thirdparty/gtest/googletest/test/gtest-options_test.cc +0 -215
- data/ext/rj_schema/rapidjson/thirdparty/gtest/googletest/test/gtest-param-test2_test.cc +0 -65
- data/ext/rj_schema/rapidjson/thirdparty/gtest/googletest/test/gtest-param-test_test.cc +0 -1055
- data/ext/rj_schema/rapidjson/thirdparty/gtest/googletest/test/gtest-param-test_test.h +0 -57
- data/ext/rj_schema/rapidjson/thirdparty/gtest/googletest/test/gtest-port_test.cc +0 -1304
- data/ext/rj_schema/rapidjson/thirdparty/gtest/googletest/test/gtest-printers_test.cc +0 -1635
- data/ext/rj_schema/rapidjson/thirdparty/gtest/googletest/test/gtest-test-part_test.cc +0 -208
- data/ext/rj_schema/rapidjson/thirdparty/gtest/googletest/test/gtest-tuple_test.cc +0 -320
- data/ext/rj_schema/rapidjson/thirdparty/gtest/googletest/test/gtest-typed-test2_test.cc +0 -45
- data/ext/rj_schema/rapidjson/thirdparty/gtest/googletest/test/gtest-typed-test_test.cc +0 -380
- data/ext/rj_schema/rapidjson/thirdparty/gtest/googletest/test/gtest-typed-test_test.h +0 -66
- data/ext/rj_schema/rapidjson/thirdparty/gtest/googletest/test/gtest-unittest-api_test.cc +0 -341
- data/ext/rj_schema/rapidjson/thirdparty/gtest/googletest/test/gtest_all_test.cc +0 -47
- data/ext/rj_schema/rapidjson/thirdparty/gtest/googletest/test/gtest_break_on_failure_unittest.py +0 -212
- data/ext/rj_schema/rapidjson/thirdparty/gtest/googletest/test/gtest_break_on_failure_unittest_.cc +0 -88
- data/ext/rj_schema/rapidjson/thirdparty/gtest/googletest/test/gtest_catch_exceptions_test.py +0 -237
- data/ext/rj_schema/rapidjson/thirdparty/gtest/googletest/test/gtest_catch_exceptions_test_.cc +0 -311
- data/ext/rj_schema/rapidjson/thirdparty/gtest/googletest/test/gtest_color_test.py +0 -130
- data/ext/rj_schema/rapidjson/thirdparty/gtest/googletest/test/gtest_color_test_.cc +0 -71
- data/ext/rj_schema/rapidjson/thirdparty/gtest/googletest/test/gtest_env_var_test.py +0 -117
- data/ext/rj_schema/rapidjson/thirdparty/gtest/googletest/test/gtest_env_var_test_.cc +0 -126
- data/ext/rj_schema/rapidjson/thirdparty/gtest/googletest/test/gtest_environment_test.cc +0 -192
- data/ext/rj_schema/rapidjson/thirdparty/gtest/googletest/test/gtest_filter_unittest.py +0 -636
- data/ext/rj_schema/rapidjson/thirdparty/gtest/googletest/test/gtest_filter_unittest_.cc +0 -140
- data/ext/rj_schema/rapidjson/thirdparty/gtest/googletest/test/gtest_help_test.py +0 -172
- data/ext/rj_schema/rapidjson/thirdparty/gtest/googletest/test/gtest_help_test_.cc +0 -46
- data/ext/rj_schema/rapidjson/thirdparty/gtest/googletest/test/gtest_list_tests_unittest.py +0 -207
- data/ext/rj_schema/rapidjson/thirdparty/gtest/googletest/test/gtest_list_tests_unittest_.cc +0 -157
- data/ext/rj_schema/rapidjson/thirdparty/gtest/googletest/test/gtest_main_unittest.cc +0 -45
- data/ext/rj_schema/rapidjson/thirdparty/gtest/googletest/test/gtest_no_test_unittest.cc +0 -56
- data/ext/rj_schema/rapidjson/thirdparty/gtest/googletest/test/gtest_output_test.py +0 -340
- data/ext/rj_schema/rapidjson/thirdparty/gtest/googletest/test/gtest_output_test_.cc +0 -1062
- data/ext/rj_schema/rapidjson/thirdparty/gtest/googletest/test/gtest_output_test_golden_lin.txt +0 -743
- data/ext/rj_schema/rapidjson/thirdparty/gtest/googletest/test/gtest_pred_impl_unittest.cc +0 -2427
- data/ext/rj_schema/rapidjson/thirdparty/gtest/googletest/test/gtest_premature_exit_test.cc +0 -127
- data/ext/rj_schema/rapidjson/thirdparty/gtest/googletest/test/gtest_prod_test.cc +0 -57
- data/ext/rj_schema/rapidjson/thirdparty/gtest/googletest/test/gtest_repeat_test.cc +0 -253
- data/ext/rj_schema/rapidjson/thirdparty/gtest/googletest/test/gtest_shuffle_test.py +0 -325
- data/ext/rj_schema/rapidjson/thirdparty/gtest/googletest/test/gtest_shuffle_test_.cc +0 -103
- data/ext/rj_schema/rapidjson/thirdparty/gtest/googletest/test/gtest_sole_header_test.cc +0 -57
- data/ext/rj_schema/rapidjson/thirdparty/gtest/googletest/test/gtest_stress_test.cc +0 -256
- data/ext/rj_schema/rapidjson/thirdparty/gtest/googletest/test/gtest_test_utils.py +0 -320
- data/ext/rj_schema/rapidjson/thirdparty/gtest/googletest/test/gtest_throw_on_failure_ex_test.cc +0 -92
- data/ext/rj_schema/rapidjson/thirdparty/gtest/googletest/test/gtest_throw_on_failure_test.py +0 -171
- data/ext/rj_schema/rapidjson/thirdparty/gtest/googletest/test/gtest_throw_on_failure_test_.cc +0 -72
- data/ext/rj_schema/rapidjson/thirdparty/gtest/googletest/test/gtest_uninitialized_test.py +0 -70
- data/ext/rj_schema/rapidjson/thirdparty/gtest/googletest/test/gtest_uninitialized_test_.cc +0 -43
- data/ext/rj_schema/rapidjson/thirdparty/gtest/googletest/test/gtest_unittest.cc +0 -7706
- data/ext/rj_schema/rapidjson/thirdparty/gtest/googletest/test/gtest_xml_outfile1_test_.cc +0 -49
- data/ext/rj_schema/rapidjson/thirdparty/gtest/googletest/test/gtest_xml_outfile2_test_.cc +0 -49
- data/ext/rj_schema/rapidjson/thirdparty/gtest/googletest/test/gtest_xml_outfiles_test.py +0 -132
- data/ext/rj_schema/rapidjson/thirdparty/gtest/googletest/test/gtest_xml_output_unittest.py +0 -308
- data/ext/rj_schema/rapidjson/thirdparty/gtest/googletest/test/gtest_xml_output_unittest_.cc +0 -181
- data/ext/rj_schema/rapidjson/thirdparty/gtest/googletest/test/gtest_xml_test_utils.py +0 -194
- data/ext/rj_schema/rapidjson/thirdparty/gtest/googletest/test/production.cc +0 -36
- data/ext/rj_schema/rapidjson/thirdparty/gtest/googletest/test/production.h +0 -55
- data/ext/rj_schema/rapidjson/thirdparty/gtest/googletest/xcode/Config/DebugProject.xcconfig +0 -30
- data/ext/rj_schema/rapidjson/thirdparty/gtest/googletest/xcode/Config/FrameworkTarget.xcconfig +0 -17
- data/ext/rj_schema/rapidjson/thirdparty/gtest/googletest/xcode/Config/General.xcconfig +0 -41
- data/ext/rj_schema/rapidjson/thirdparty/gtest/googletest/xcode/Config/ReleaseProject.xcconfig +0 -32
- data/ext/rj_schema/rapidjson/thirdparty/gtest/googletest/xcode/Config/StaticLibraryTarget.xcconfig +0 -18
- data/ext/rj_schema/rapidjson/thirdparty/gtest/googletest/xcode/Config/TestTarget.xcconfig +0 -8
- data/ext/rj_schema/rapidjson/thirdparty/gtest/googletest/xcode/Resources/Info.plist +0 -30
- data/ext/rj_schema/rapidjson/thirdparty/gtest/googletest/xcode/Samples/FrameworkSample/Info.plist +0 -28
- data/ext/rj_schema/rapidjson/thirdparty/gtest/googletest/xcode/Samples/FrameworkSample/WidgetFramework.xcodeproj/project.pbxproj +0 -457
- data/ext/rj_schema/rapidjson/thirdparty/gtest/googletest/xcode/Samples/FrameworkSample/runtests.sh +0 -62
- data/ext/rj_schema/rapidjson/thirdparty/gtest/googletest/xcode/Samples/FrameworkSample/widget.cc +0 -63
- data/ext/rj_schema/rapidjson/thirdparty/gtest/googletest/xcode/Samples/FrameworkSample/widget.h +0 -59
- data/ext/rj_schema/rapidjson/thirdparty/gtest/googletest/xcode/Samples/FrameworkSample/widget_test.cc +0 -68
- data/ext/rj_schema/rapidjson/thirdparty/gtest/googletest/xcode/Scripts/runtests.sh +0 -65
- data/ext/rj_schema/rapidjson/thirdparty/gtest/googletest/xcode/Scripts/versiongenerate.py +0 -100
- data/ext/rj_schema/rapidjson/thirdparty/gtest/googletest/xcode/gtest.xcodeproj/project.pbxproj +0 -1135
- data/ext/rj_schema/rapidjson/thirdparty/gtest/travis.sh +0 -15
- data/ext/rj_schema/rapidjson/travis-doxygen.sh +0 -121
@@ -1,823 +0,0 @@
|
|
1
|
-
// Copyright 2007, Google Inc.
|
2
|
-
// All rights reserved.
|
3
|
-
//
|
4
|
-
// Redistribution and use in source and binary forms, with or without
|
5
|
-
// modification, are permitted provided that the following conditions are
|
6
|
-
// met:
|
7
|
-
//
|
8
|
-
// * Redistributions of source code must retain the above copyright
|
9
|
-
// notice, this list of conditions and the following disclaimer.
|
10
|
-
// * Redistributions in binary form must reproduce the above
|
11
|
-
// copyright notice, this list of conditions and the following disclaimer
|
12
|
-
// in the documentation and/or other materials provided with the
|
13
|
-
// distribution.
|
14
|
-
// * Neither the name of Google Inc. nor the names of its
|
15
|
-
// contributors may be used to endorse or promote products derived from
|
16
|
-
// this software without specific prior written permission.
|
17
|
-
//
|
18
|
-
// THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS
|
19
|
-
// "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT
|
20
|
-
// LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR
|
21
|
-
// A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT
|
22
|
-
// OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
|
23
|
-
// SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
|
24
|
-
// LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
|
25
|
-
// DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY
|
26
|
-
// THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
|
27
|
-
// (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
|
28
|
-
// OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
|
29
|
-
//
|
30
|
-
// Author: wan@google.com (Zhanyong Wan)
|
31
|
-
|
32
|
-
// Google Mock - a framework for writing C++ mock classes.
|
33
|
-
//
|
34
|
-
// This file implements the spec builder syntax (ON_CALL and
|
35
|
-
// EXPECT_CALL).
|
36
|
-
|
37
|
-
#include "gmock/gmock-spec-builders.h"
|
38
|
-
|
39
|
-
#include <stdlib.h>
|
40
|
-
#include <iostream> // NOLINT
|
41
|
-
#include <map>
|
42
|
-
#include <set>
|
43
|
-
#include <string>
|
44
|
-
#include "gmock/gmock.h"
|
45
|
-
#include "gtest/gtest.h"
|
46
|
-
|
47
|
-
#if GTEST_OS_CYGWIN || GTEST_OS_LINUX || GTEST_OS_MAC
|
48
|
-
# include <unistd.h> // NOLINT
|
49
|
-
#endif
|
50
|
-
|
51
|
-
namespace testing {
|
52
|
-
namespace internal {
|
53
|
-
|
54
|
-
// Protects the mock object registry (in class Mock), all function
|
55
|
-
// mockers, and all expectations.
|
56
|
-
GTEST_API_ GTEST_DEFINE_STATIC_MUTEX_(g_gmock_mutex);
|
57
|
-
|
58
|
-
// Logs a message including file and line number information.
|
59
|
-
GTEST_API_ void LogWithLocation(testing::internal::LogSeverity severity,
|
60
|
-
const char* file, int line,
|
61
|
-
const string& message) {
|
62
|
-
::std::ostringstream s;
|
63
|
-
s << file << ":" << line << ": " << message << ::std::endl;
|
64
|
-
Log(severity, s.str(), 0);
|
65
|
-
}
|
66
|
-
|
67
|
-
// Constructs an ExpectationBase object.
|
68
|
-
ExpectationBase::ExpectationBase(const char* a_file,
|
69
|
-
int a_line,
|
70
|
-
const string& a_source_text)
|
71
|
-
: file_(a_file),
|
72
|
-
line_(a_line),
|
73
|
-
source_text_(a_source_text),
|
74
|
-
cardinality_specified_(false),
|
75
|
-
cardinality_(Exactly(1)),
|
76
|
-
call_count_(0),
|
77
|
-
retired_(false),
|
78
|
-
extra_matcher_specified_(false),
|
79
|
-
repeated_action_specified_(false),
|
80
|
-
retires_on_saturation_(false),
|
81
|
-
last_clause_(kNone),
|
82
|
-
action_count_checked_(false) {}
|
83
|
-
|
84
|
-
// Destructs an ExpectationBase object.
|
85
|
-
ExpectationBase::~ExpectationBase() {}
|
86
|
-
|
87
|
-
// Explicitly specifies the cardinality of this expectation. Used by
|
88
|
-
// the subclasses to implement the .Times() clause.
|
89
|
-
void ExpectationBase::SpecifyCardinality(const Cardinality& a_cardinality) {
|
90
|
-
cardinality_specified_ = true;
|
91
|
-
cardinality_ = a_cardinality;
|
92
|
-
}
|
93
|
-
|
94
|
-
// Retires all pre-requisites of this expectation.
|
95
|
-
void ExpectationBase::RetireAllPreRequisites()
|
96
|
-
GTEST_EXCLUSIVE_LOCK_REQUIRED_(g_gmock_mutex) {
|
97
|
-
if (is_retired()) {
|
98
|
-
// We can take this short-cut as we never retire an expectation
|
99
|
-
// until we have retired all its pre-requisites.
|
100
|
-
return;
|
101
|
-
}
|
102
|
-
|
103
|
-
for (ExpectationSet::const_iterator it = immediate_prerequisites_.begin();
|
104
|
-
it != immediate_prerequisites_.end(); ++it) {
|
105
|
-
ExpectationBase* const prerequisite = it->expectation_base().get();
|
106
|
-
if (!prerequisite->is_retired()) {
|
107
|
-
prerequisite->RetireAllPreRequisites();
|
108
|
-
prerequisite->Retire();
|
109
|
-
}
|
110
|
-
}
|
111
|
-
}
|
112
|
-
|
113
|
-
// Returns true iff all pre-requisites of this expectation have been
|
114
|
-
// satisfied.
|
115
|
-
bool ExpectationBase::AllPrerequisitesAreSatisfied() const
|
116
|
-
GTEST_EXCLUSIVE_LOCK_REQUIRED_(g_gmock_mutex) {
|
117
|
-
g_gmock_mutex.AssertHeld();
|
118
|
-
for (ExpectationSet::const_iterator it = immediate_prerequisites_.begin();
|
119
|
-
it != immediate_prerequisites_.end(); ++it) {
|
120
|
-
if (!(it->expectation_base()->IsSatisfied()) ||
|
121
|
-
!(it->expectation_base()->AllPrerequisitesAreSatisfied()))
|
122
|
-
return false;
|
123
|
-
}
|
124
|
-
return true;
|
125
|
-
}
|
126
|
-
|
127
|
-
// Adds unsatisfied pre-requisites of this expectation to 'result'.
|
128
|
-
void ExpectationBase::FindUnsatisfiedPrerequisites(ExpectationSet* result) const
|
129
|
-
GTEST_EXCLUSIVE_LOCK_REQUIRED_(g_gmock_mutex) {
|
130
|
-
g_gmock_mutex.AssertHeld();
|
131
|
-
for (ExpectationSet::const_iterator it = immediate_prerequisites_.begin();
|
132
|
-
it != immediate_prerequisites_.end(); ++it) {
|
133
|
-
if (it->expectation_base()->IsSatisfied()) {
|
134
|
-
// If *it is satisfied and has a call count of 0, some of its
|
135
|
-
// pre-requisites may not be satisfied yet.
|
136
|
-
if (it->expectation_base()->call_count_ == 0) {
|
137
|
-
it->expectation_base()->FindUnsatisfiedPrerequisites(result);
|
138
|
-
}
|
139
|
-
} else {
|
140
|
-
// Now that we know *it is unsatisfied, we are not so interested
|
141
|
-
// in whether its pre-requisites are satisfied. Therefore we
|
142
|
-
// don't recursively call FindUnsatisfiedPrerequisites() here.
|
143
|
-
*result += *it;
|
144
|
-
}
|
145
|
-
}
|
146
|
-
}
|
147
|
-
|
148
|
-
// Describes how many times a function call matching this
|
149
|
-
// expectation has occurred.
|
150
|
-
void ExpectationBase::DescribeCallCountTo(::std::ostream* os) const
|
151
|
-
GTEST_EXCLUSIVE_LOCK_REQUIRED_(g_gmock_mutex) {
|
152
|
-
g_gmock_mutex.AssertHeld();
|
153
|
-
|
154
|
-
// Describes how many times the function is expected to be called.
|
155
|
-
*os << " Expected: to be ";
|
156
|
-
cardinality().DescribeTo(os);
|
157
|
-
*os << "\n Actual: ";
|
158
|
-
Cardinality::DescribeActualCallCountTo(call_count(), os);
|
159
|
-
|
160
|
-
// Describes the state of the expectation (e.g. is it satisfied?
|
161
|
-
// is it active?).
|
162
|
-
*os << " - " << (IsOverSaturated() ? "over-saturated" :
|
163
|
-
IsSaturated() ? "saturated" :
|
164
|
-
IsSatisfied() ? "satisfied" : "unsatisfied")
|
165
|
-
<< " and "
|
166
|
-
<< (is_retired() ? "retired" : "active");
|
167
|
-
}
|
168
|
-
|
169
|
-
// Checks the action count (i.e. the number of WillOnce() and
|
170
|
-
// WillRepeatedly() clauses) against the cardinality if this hasn't
|
171
|
-
// been done before. Prints a warning if there are too many or too
|
172
|
-
// few actions.
|
173
|
-
void ExpectationBase::CheckActionCountIfNotDone() const
|
174
|
-
GTEST_LOCK_EXCLUDED_(mutex_) {
|
175
|
-
bool should_check = false;
|
176
|
-
{
|
177
|
-
MutexLock l(&mutex_);
|
178
|
-
if (!action_count_checked_) {
|
179
|
-
action_count_checked_ = true;
|
180
|
-
should_check = true;
|
181
|
-
}
|
182
|
-
}
|
183
|
-
|
184
|
-
if (should_check) {
|
185
|
-
if (!cardinality_specified_) {
|
186
|
-
// The cardinality was inferred - no need to check the action
|
187
|
-
// count against it.
|
188
|
-
return;
|
189
|
-
}
|
190
|
-
|
191
|
-
// The cardinality was explicitly specified.
|
192
|
-
const int action_count = static_cast<int>(untyped_actions_.size());
|
193
|
-
const int upper_bound = cardinality().ConservativeUpperBound();
|
194
|
-
const int lower_bound = cardinality().ConservativeLowerBound();
|
195
|
-
bool too_many; // True if there are too many actions, or false
|
196
|
-
// if there are too few.
|
197
|
-
if (action_count > upper_bound ||
|
198
|
-
(action_count == upper_bound && repeated_action_specified_)) {
|
199
|
-
too_many = true;
|
200
|
-
} else if (0 < action_count && action_count < lower_bound &&
|
201
|
-
!repeated_action_specified_) {
|
202
|
-
too_many = false;
|
203
|
-
} else {
|
204
|
-
return;
|
205
|
-
}
|
206
|
-
|
207
|
-
::std::stringstream ss;
|
208
|
-
DescribeLocationTo(&ss);
|
209
|
-
ss << "Too " << (too_many ? "many" : "few")
|
210
|
-
<< " actions specified in " << source_text() << "...\n"
|
211
|
-
<< "Expected to be ";
|
212
|
-
cardinality().DescribeTo(&ss);
|
213
|
-
ss << ", but has " << (too_many ? "" : "only ")
|
214
|
-
<< action_count << " WillOnce()"
|
215
|
-
<< (action_count == 1 ? "" : "s");
|
216
|
-
if (repeated_action_specified_) {
|
217
|
-
ss << " and a WillRepeatedly()";
|
218
|
-
}
|
219
|
-
ss << ".";
|
220
|
-
Log(kWarning, ss.str(), -1); // -1 means "don't print stack trace".
|
221
|
-
}
|
222
|
-
}
|
223
|
-
|
224
|
-
// Implements the .Times() clause.
|
225
|
-
void ExpectationBase::UntypedTimes(const Cardinality& a_cardinality) {
|
226
|
-
if (last_clause_ == kTimes) {
|
227
|
-
ExpectSpecProperty(false,
|
228
|
-
".Times() cannot appear "
|
229
|
-
"more than once in an EXPECT_CALL().");
|
230
|
-
} else {
|
231
|
-
ExpectSpecProperty(last_clause_ < kTimes,
|
232
|
-
".Times() cannot appear after "
|
233
|
-
".InSequence(), .WillOnce(), .WillRepeatedly(), "
|
234
|
-
"or .RetiresOnSaturation().");
|
235
|
-
}
|
236
|
-
last_clause_ = kTimes;
|
237
|
-
|
238
|
-
SpecifyCardinality(a_cardinality);
|
239
|
-
}
|
240
|
-
|
241
|
-
// Points to the implicit sequence introduced by a living InSequence
|
242
|
-
// object (if any) in the current thread or NULL.
|
243
|
-
GTEST_API_ ThreadLocal<Sequence*> g_gmock_implicit_sequence;
|
244
|
-
|
245
|
-
// Reports an uninteresting call (whose description is in msg) in the
|
246
|
-
// manner specified by 'reaction'.
|
247
|
-
void ReportUninterestingCall(CallReaction reaction, const string& msg) {
|
248
|
-
// Include a stack trace only if --gmock_verbose=info is specified.
|
249
|
-
const int stack_frames_to_skip =
|
250
|
-
GMOCK_FLAG(verbose) == kInfoVerbosity ? 3 : -1;
|
251
|
-
switch (reaction) {
|
252
|
-
case kAllow:
|
253
|
-
Log(kInfo, msg, stack_frames_to_skip);
|
254
|
-
break;
|
255
|
-
case kWarn:
|
256
|
-
Log(kWarning,
|
257
|
-
msg +
|
258
|
-
"\nNOTE: You can safely ignore the above warning unless this "
|
259
|
-
"call should not happen. Do not suppress it by blindly adding "
|
260
|
-
"an EXPECT_CALL() if you don't mean to enforce the call. "
|
261
|
-
"See https://github.com/google/googletest/blob/master/googlemock/docs/CookBook.md#"
|
262
|
-
"knowing-when-to-expect for details.\n",
|
263
|
-
stack_frames_to_skip);
|
264
|
-
break;
|
265
|
-
default: // FAIL
|
266
|
-
Expect(false, NULL, -1, msg);
|
267
|
-
}
|
268
|
-
}
|
269
|
-
|
270
|
-
UntypedFunctionMockerBase::UntypedFunctionMockerBase()
|
271
|
-
: mock_obj_(NULL), name_("") {}
|
272
|
-
|
273
|
-
UntypedFunctionMockerBase::~UntypedFunctionMockerBase() {}
|
274
|
-
|
275
|
-
// Sets the mock object this mock method belongs to, and registers
|
276
|
-
// this information in the global mock registry. Will be called
|
277
|
-
// whenever an EXPECT_CALL() or ON_CALL() is executed on this mock
|
278
|
-
// method.
|
279
|
-
void UntypedFunctionMockerBase::RegisterOwner(const void* mock_obj)
|
280
|
-
GTEST_LOCK_EXCLUDED_(g_gmock_mutex) {
|
281
|
-
{
|
282
|
-
MutexLock l(&g_gmock_mutex);
|
283
|
-
mock_obj_ = mock_obj;
|
284
|
-
}
|
285
|
-
Mock::Register(mock_obj, this);
|
286
|
-
}
|
287
|
-
|
288
|
-
// Sets the mock object this mock method belongs to, and sets the name
|
289
|
-
// of the mock function. Will be called upon each invocation of this
|
290
|
-
// mock function.
|
291
|
-
void UntypedFunctionMockerBase::SetOwnerAndName(const void* mock_obj,
|
292
|
-
const char* name)
|
293
|
-
GTEST_LOCK_EXCLUDED_(g_gmock_mutex) {
|
294
|
-
// We protect name_ under g_gmock_mutex in case this mock function
|
295
|
-
// is called from two threads concurrently.
|
296
|
-
MutexLock l(&g_gmock_mutex);
|
297
|
-
mock_obj_ = mock_obj;
|
298
|
-
name_ = name;
|
299
|
-
}
|
300
|
-
|
301
|
-
// Returns the name of the function being mocked. Must be called
|
302
|
-
// after RegisterOwner() or SetOwnerAndName() has been called.
|
303
|
-
const void* UntypedFunctionMockerBase::MockObject() const
|
304
|
-
GTEST_LOCK_EXCLUDED_(g_gmock_mutex) {
|
305
|
-
const void* mock_obj;
|
306
|
-
{
|
307
|
-
// We protect mock_obj_ under g_gmock_mutex in case this mock
|
308
|
-
// function is called from two threads concurrently.
|
309
|
-
MutexLock l(&g_gmock_mutex);
|
310
|
-
Assert(mock_obj_ != NULL, __FILE__, __LINE__,
|
311
|
-
"MockObject() must not be called before RegisterOwner() or "
|
312
|
-
"SetOwnerAndName() has been called.");
|
313
|
-
mock_obj = mock_obj_;
|
314
|
-
}
|
315
|
-
return mock_obj;
|
316
|
-
}
|
317
|
-
|
318
|
-
// Returns the name of this mock method. Must be called after
|
319
|
-
// SetOwnerAndName() has been called.
|
320
|
-
const char* UntypedFunctionMockerBase::Name() const
|
321
|
-
GTEST_LOCK_EXCLUDED_(g_gmock_mutex) {
|
322
|
-
const char* name;
|
323
|
-
{
|
324
|
-
// We protect name_ under g_gmock_mutex in case this mock
|
325
|
-
// function is called from two threads concurrently.
|
326
|
-
MutexLock l(&g_gmock_mutex);
|
327
|
-
Assert(name_ != NULL, __FILE__, __LINE__,
|
328
|
-
"Name() must not be called before SetOwnerAndName() has "
|
329
|
-
"been called.");
|
330
|
-
name = name_;
|
331
|
-
}
|
332
|
-
return name;
|
333
|
-
}
|
334
|
-
|
335
|
-
// Calculates the result of invoking this mock function with the given
|
336
|
-
// arguments, prints it, and returns it. The caller is responsible
|
337
|
-
// for deleting the result.
|
338
|
-
UntypedActionResultHolderBase*
|
339
|
-
UntypedFunctionMockerBase::UntypedInvokeWith(const void* const untyped_args)
|
340
|
-
GTEST_LOCK_EXCLUDED_(g_gmock_mutex) {
|
341
|
-
if (untyped_expectations_.size() == 0) {
|
342
|
-
// No expectation is set on this mock method - we have an
|
343
|
-
// uninteresting call.
|
344
|
-
|
345
|
-
// We must get Google Mock's reaction on uninteresting calls
|
346
|
-
// made on this mock object BEFORE performing the action,
|
347
|
-
// because the action may DELETE the mock object and make the
|
348
|
-
// following expression meaningless.
|
349
|
-
const CallReaction reaction =
|
350
|
-
Mock::GetReactionOnUninterestingCalls(MockObject());
|
351
|
-
|
352
|
-
// True iff we need to print this call's arguments and return
|
353
|
-
// value. This definition must be kept in sync with
|
354
|
-
// the behavior of ReportUninterestingCall().
|
355
|
-
const bool need_to_report_uninteresting_call =
|
356
|
-
// If the user allows this uninteresting call, we print it
|
357
|
-
// only when he wants informational messages.
|
358
|
-
reaction == kAllow ? LogIsVisible(kInfo) :
|
359
|
-
// If the user wants this to be a warning, we print it only
|
360
|
-
// when he wants to see warnings.
|
361
|
-
reaction == kWarn ? LogIsVisible(kWarning) :
|
362
|
-
// Otherwise, the user wants this to be an error, and we
|
363
|
-
// should always print detailed information in the error.
|
364
|
-
true;
|
365
|
-
|
366
|
-
if (!need_to_report_uninteresting_call) {
|
367
|
-
// Perform the action without printing the call information.
|
368
|
-
return this->UntypedPerformDefaultAction(untyped_args, "");
|
369
|
-
}
|
370
|
-
|
371
|
-
// Warns about the uninteresting call.
|
372
|
-
::std::stringstream ss;
|
373
|
-
this->UntypedDescribeUninterestingCall(untyped_args, &ss);
|
374
|
-
|
375
|
-
// Calculates the function result.
|
376
|
-
UntypedActionResultHolderBase* const result =
|
377
|
-
this->UntypedPerformDefaultAction(untyped_args, ss.str());
|
378
|
-
|
379
|
-
// Prints the function result.
|
380
|
-
if (result != NULL)
|
381
|
-
result->PrintAsActionResult(&ss);
|
382
|
-
|
383
|
-
ReportUninterestingCall(reaction, ss.str());
|
384
|
-
return result;
|
385
|
-
}
|
386
|
-
|
387
|
-
bool is_excessive = false;
|
388
|
-
::std::stringstream ss;
|
389
|
-
::std::stringstream why;
|
390
|
-
::std::stringstream loc;
|
391
|
-
const void* untyped_action = NULL;
|
392
|
-
|
393
|
-
// The UntypedFindMatchingExpectation() function acquires and
|
394
|
-
// releases g_gmock_mutex.
|
395
|
-
const ExpectationBase* const untyped_expectation =
|
396
|
-
this->UntypedFindMatchingExpectation(
|
397
|
-
untyped_args, &untyped_action, &is_excessive,
|
398
|
-
&ss, &why);
|
399
|
-
const bool found = untyped_expectation != NULL;
|
400
|
-
|
401
|
-
// True iff we need to print the call's arguments and return value.
|
402
|
-
// This definition must be kept in sync with the uses of Expect()
|
403
|
-
// and Log() in this function.
|
404
|
-
const bool need_to_report_call =
|
405
|
-
!found || is_excessive || LogIsVisible(kInfo);
|
406
|
-
if (!need_to_report_call) {
|
407
|
-
// Perform the action without printing the call information.
|
408
|
-
return
|
409
|
-
untyped_action == NULL ?
|
410
|
-
this->UntypedPerformDefaultAction(untyped_args, "") :
|
411
|
-
this->UntypedPerformAction(untyped_action, untyped_args);
|
412
|
-
}
|
413
|
-
|
414
|
-
ss << " Function call: " << Name();
|
415
|
-
this->UntypedPrintArgs(untyped_args, &ss);
|
416
|
-
|
417
|
-
// In case the action deletes a piece of the expectation, we
|
418
|
-
// generate the message beforehand.
|
419
|
-
if (found && !is_excessive) {
|
420
|
-
untyped_expectation->DescribeLocationTo(&loc);
|
421
|
-
}
|
422
|
-
|
423
|
-
UntypedActionResultHolderBase* const result =
|
424
|
-
untyped_action == NULL ?
|
425
|
-
this->UntypedPerformDefaultAction(untyped_args, ss.str()) :
|
426
|
-
this->UntypedPerformAction(untyped_action, untyped_args);
|
427
|
-
if (result != NULL)
|
428
|
-
result->PrintAsActionResult(&ss);
|
429
|
-
ss << "\n" << why.str();
|
430
|
-
|
431
|
-
if (!found) {
|
432
|
-
// No expectation matches this call - reports a failure.
|
433
|
-
Expect(false, NULL, -1, ss.str());
|
434
|
-
} else if (is_excessive) {
|
435
|
-
// We had an upper-bound violation and the failure message is in ss.
|
436
|
-
Expect(false, untyped_expectation->file(),
|
437
|
-
untyped_expectation->line(), ss.str());
|
438
|
-
} else {
|
439
|
-
// We had an expected call and the matching expectation is
|
440
|
-
// described in ss.
|
441
|
-
Log(kInfo, loc.str() + ss.str(), 2);
|
442
|
-
}
|
443
|
-
|
444
|
-
return result;
|
445
|
-
}
|
446
|
-
|
447
|
-
// Returns an Expectation object that references and co-owns exp,
|
448
|
-
// which must be an expectation on this mock function.
|
449
|
-
Expectation UntypedFunctionMockerBase::GetHandleOf(ExpectationBase* exp) {
|
450
|
-
for (UntypedExpectations::const_iterator it =
|
451
|
-
untyped_expectations_.begin();
|
452
|
-
it != untyped_expectations_.end(); ++it) {
|
453
|
-
if (it->get() == exp) {
|
454
|
-
return Expectation(*it);
|
455
|
-
}
|
456
|
-
}
|
457
|
-
|
458
|
-
Assert(false, __FILE__, __LINE__, "Cannot find expectation.");
|
459
|
-
return Expectation();
|
460
|
-
// The above statement is just to make the code compile, and will
|
461
|
-
// never be executed.
|
462
|
-
}
|
463
|
-
|
464
|
-
// Verifies that all expectations on this mock function have been
|
465
|
-
// satisfied. Reports one or more Google Test non-fatal failures
|
466
|
-
// and returns false if not.
|
467
|
-
bool UntypedFunctionMockerBase::VerifyAndClearExpectationsLocked()
|
468
|
-
GTEST_EXCLUSIVE_LOCK_REQUIRED_(g_gmock_mutex) {
|
469
|
-
g_gmock_mutex.AssertHeld();
|
470
|
-
bool expectations_met = true;
|
471
|
-
for (UntypedExpectations::const_iterator it =
|
472
|
-
untyped_expectations_.begin();
|
473
|
-
it != untyped_expectations_.end(); ++it) {
|
474
|
-
ExpectationBase* const untyped_expectation = it->get();
|
475
|
-
if (untyped_expectation->IsOverSaturated()) {
|
476
|
-
// There was an upper-bound violation. Since the error was
|
477
|
-
// already reported when it occurred, there is no need to do
|
478
|
-
// anything here.
|
479
|
-
expectations_met = false;
|
480
|
-
} else if (!untyped_expectation->IsSatisfied()) {
|
481
|
-
expectations_met = false;
|
482
|
-
::std::stringstream ss;
|
483
|
-
ss << "Actual function call count doesn't match "
|
484
|
-
<< untyped_expectation->source_text() << "...\n";
|
485
|
-
// No need to show the source file location of the expectation
|
486
|
-
// in the description, as the Expect() call that follows already
|
487
|
-
// takes care of it.
|
488
|
-
untyped_expectation->MaybeDescribeExtraMatcherTo(&ss);
|
489
|
-
untyped_expectation->DescribeCallCountTo(&ss);
|
490
|
-
Expect(false, untyped_expectation->file(),
|
491
|
-
untyped_expectation->line(), ss.str());
|
492
|
-
}
|
493
|
-
}
|
494
|
-
|
495
|
-
// Deleting our expectations may trigger other mock objects to be deleted, for
|
496
|
-
// example if an action contains a reference counted smart pointer to that
|
497
|
-
// mock object, and that is the last reference. So if we delete our
|
498
|
-
// expectations within the context of the global mutex we may deadlock when
|
499
|
-
// this method is called again. Instead, make a copy of the set of
|
500
|
-
// expectations to delete, clear our set within the mutex, and then clear the
|
501
|
-
// copied set outside of it.
|
502
|
-
UntypedExpectations expectations_to_delete;
|
503
|
-
untyped_expectations_.swap(expectations_to_delete);
|
504
|
-
|
505
|
-
g_gmock_mutex.Unlock();
|
506
|
-
expectations_to_delete.clear();
|
507
|
-
g_gmock_mutex.Lock();
|
508
|
-
|
509
|
-
return expectations_met;
|
510
|
-
}
|
511
|
-
|
512
|
-
} // namespace internal
|
513
|
-
|
514
|
-
// Class Mock.
|
515
|
-
|
516
|
-
namespace {
|
517
|
-
|
518
|
-
typedef std::set<internal::UntypedFunctionMockerBase*> FunctionMockers;
|
519
|
-
|
520
|
-
// The current state of a mock object. Such information is needed for
|
521
|
-
// detecting leaked mock objects and explicitly verifying a mock's
|
522
|
-
// expectations.
|
523
|
-
struct MockObjectState {
|
524
|
-
MockObjectState()
|
525
|
-
: first_used_file(NULL), first_used_line(-1), leakable(false) {}
|
526
|
-
|
527
|
-
// Where in the source file an ON_CALL or EXPECT_CALL is first
|
528
|
-
// invoked on this mock object.
|
529
|
-
const char* first_used_file;
|
530
|
-
int first_used_line;
|
531
|
-
::std::string first_used_test_case;
|
532
|
-
::std::string first_used_test;
|
533
|
-
bool leakable; // true iff it's OK to leak the object.
|
534
|
-
FunctionMockers function_mockers; // All registered methods of the object.
|
535
|
-
};
|
536
|
-
|
537
|
-
// A global registry holding the state of all mock objects that are
|
538
|
-
// alive. A mock object is added to this registry the first time
|
539
|
-
// Mock::AllowLeak(), ON_CALL(), or EXPECT_CALL() is called on it. It
|
540
|
-
// is removed from the registry in the mock object's destructor.
|
541
|
-
class MockObjectRegistry {
|
542
|
-
public:
|
543
|
-
// Maps a mock object (identified by its address) to its state.
|
544
|
-
typedef std::map<const void*, MockObjectState> StateMap;
|
545
|
-
|
546
|
-
// This destructor will be called when a program exits, after all
|
547
|
-
// tests in it have been run. By then, there should be no mock
|
548
|
-
// object alive. Therefore we report any living object as test
|
549
|
-
// failure, unless the user explicitly asked us to ignore it.
|
550
|
-
~MockObjectRegistry() {
|
551
|
-
// "using ::std::cout;" doesn't work with Symbian's STLport, where cout is
|
552
|
-
// a macro.
|
553
|
-
|
554
|
-
if (!GMOCK_FLAG(catch_leaked_mocks))
|
555
|
-
return;
|
556
|
-
|
557
|
-
int leaked_count = 0;
|
558
|
-
for (StateMap::const_iterator it = states_.begin(); it != states_.end();
|
559
|
-
++it) {
|
560
|
-
if (it->second.leakable) // The user said it's fine to leak this object.
|
561
|
-
continue;
|
562
|
-
|
563
|
-
// TODO(wan@google.com): Print the type of the leaked object.
|
564
|
-
// This can help the user identify the leaked object.
|
565
|
-
std::cout << "\n";
|
566
|
-
const MockObjectState& state = it->second;
|
567
|
-
std::cout << internal::FormatFileLocation(state.first_used_file,
|
568
|
-
state.first_used_line);
|
569
|
-
std::cout << " ERROR: this mock object";
|
570
|
-
if (state.first_used_test != "") {
|
571
|
-
std::cout << " (used in test " << state.first_used_test_case << "."
|
572
|
-
<< state.first_used_test << ")";
|
573
|
-
}
|
574
|
-
std::cout << " should be deleted but never is. Its address is @"
|
575
|
-
<< it->first << ".";
|
576
|
-
leaked_count++;
|
577
|
-
}
|
578
|
-
if (leaked_count > 0) {
|
579
|
-
std::cout << "\nERROR: " << leaked_count
|
580
|
-
<< " leaked mock " << (leaked_count == 1 ? "object" : "objects")
|
581
|
-
<< " found at program exit.\n";
|
582
|
-
std::cout.flush();
|
583
|
-
::std::cerr.flush();
|
584
|
-
// RUN_ALL_TESTS() has already returned when this destructor is
|
585
|
-
// called. Therefore we cannot use the normal Google Test
|
586
|
-
// failure reporting mechanism.
|
587
|
-
_exit(1); // We cannot call exit() as it is not reentrant and
|
588
|
-
// may already have been called.
|
589
|
-
}
|
590
|
-
}
|
591
|
-
|
592
|
-
StateMap& states() { return states_; }
|
593
|
-
|
594
|
-
private:
|
595
|
-
StateMap states_;
|
596
|
-
};
|
597
|
-
|
598
|
-
// Protected by g_gmock_mutex.
|
599
|
-
MockObjectRegistry g_mock_object_registry;
|
600
|
-
|
601
|
-
// Maps a mock object to the reaction Google Mock should have when an
|
602
|
-
// uninteresting method is called. Protected by g_gmock_mutex.
|
603
|
-
std::map<const void*, internal::CallReaction> g_uninteresting_call_reaction;
|
604
|
-
|
605
|
-
// Sets the reaction Google Mock should have when an uninteresting
|
606
|
-
// method of the given mock object is called.
|
607
|
-
void SetReactionOnUninterestingCalls(const void* mock_obj,
|
608
|
-
internal::CallReaction reaction)
|
609
|
-
GTEST_LOCK_EXCLUDED_(internal::g_gmock_mutex) {
|
610
|
-
internal::MutexLock l(&internal::g_gmock_mutex);
|
611
|
-
g_uninteresting_call_reaction[mock_obj] = reaction;
|
612
|
-
}
|
613
|
-
|
614
|
-
} // namespace
|
615
|
-
|
616
|
-
// Tells Google Mock to allow uninteresting calls on the given mock
|
617
|
-
// object.
|
618
|
-
void Mock::AllowUninterestingCalls(const void* mock_obj)
|
619
|
-
GTEST_LOCK_EXCLUDED_(internal::g_gmock_mutex) {
|
620
|
-
SetReactionOnUninterestingCalls(mock_obj, internal::kAllow);
|
621
|
-
}
|
622
|
-
|
623
|
-
// Tells Google Mock to warn the user about uninteresting calls on the
|
624
|
-
// given mock object.
|
625
|
-
void Mock::WarnUninterestingCalls(const void* mock_obj)
|
626
|
-
GTEST_LOCK_EXCLUDED_(internal::g_gmock_mutex) {
|
627
|
-
SetReactionOnUninterestingCalls(mock_obj, internal::kWarn);
|
628
|
-
}
|
629
|
-
|
630
|
-
// Tells Google Mock to fail uninteresting calls on the given mock
|
631
|
-
// object.
|
632
|
-
void Mock::FailUninterestingCalls(const void* mock_obj)
|
633
|
-
GTEST_LOCK_EXCLUDED_(internal::g_gmock_mutex) {
|
634
|
-
SetReactionOnUninterestingCalls(mock_obj, internal::kFail);
|
635
|
-
}
|
636
|
-
|
637
|
-
// Tells Google Mock the given mock object is being destroyed and its
|
638
|
-
// entry in the call-reaction table should be removed.
|
639
|
-
void Mock::UnregisterCallReaction(const void* mock_obj)
|
640
|
-
GTEST_LOCK_EXCLUDED_(internal::g_gmock_mutex) {
|
641
|
-
internal::MutexLock l(&internal::g_gmock_mutex);
|
642
|
-
g_uninteresting_call_reaction.erase(mock_obj);
|
643
|
-
}
|
644
|
-
|
645
|
-
// Returns the reaction Google Mock will have on uninteresting calls
|
646
|
-
// made on the given mock object.
|
647
|
-
internal::CallReaction Mock::GetReactionOnUninterestingCalls(
|
648
|
-
const void* mock_obj)
|
649
|
-
GTEST_LOCK_EXCLUDED_(internal::g_gmock_mutex) {
|
650
|
-
internal::MutexLock l(&internal::g_gmock_mutex);
|
651
|
-
return (g_uninteresting_call_reaction.count(mock_obj) == 0) ?
|
652
|
-
internal::kDefault : g_uninteresting_call_reaction[mock_obj];
|
653
|
-
}
|
654
|
-
|
655
|
-
// Tells Google Mock to ignore mock_obj when checking for leaked mock
|
656
|
-
// objects.
|
657
|
-
void Mock::AllowLeak(const void* mock_obj)
|
658
|
-
GTEST_LOCK_EXCLUDED_(internal::g_gmock_mutex) {
|
659
|
-
internal::MutexLock l(&internal::g_gmock_mutex);
|
660
|
-
g_mock_object_registry.states()[mock_obj].leakable = true;
|
661
|
-
}
|
662
|
-
|
663
|
-
// Verifies and clears all expectations on the given mock object. If
|
664
|
-
// the expectations aren't satisfied, generates one or more Google
|
665
|
-
// Test non-fatal failures and returns false.
|
666
|
-
bool Mock::VerifyAndClearExpectations(void* mock_obj)
|
667
|
-
GTEST_LOCK_EXCLUDED_(internal::g_gmock_mutex) {
|
668
|
-
internal::MutexLock l(&internal::g_gmock_mutex);
|
669
|
-
return VerifyAndClearExpectationsLocked(mock_obj);
|
670
|
-
}
|
671
|
-
|
672
|
-
// Verifies all expectations on the given mock object and clears its
|
673
|
-
// default actions and expectations. Returns true iff the
|
674
|
-
// verification was successful.
|
675
|
-
bool Mock::VerifyAndClear(void* mock_obj)
|
676
|
-
GTEST_LOCK_EXCLUDED_(internal::g_gmock_mutex) {
|
677
|
-
internal::MutexLock l(&internal::g_gmock_mutex);
|
678
|
-
ClearDefaultActionsLocked(mock_obj);
|
679
|
-
return VerifyAndClearExpectationsLocked(mock_obj);
|
680
|
-
}
|
681
|
-
|
682
|
-
// Verifies and clears all expectations on the given mock object. If
|
683
|
-
// the expectations aren't satisfied, generates one or more Google
|
684
|
-
// Test non-fatal failures and returns false.
|
685
|
-
bool Mock::VerifyAndClearExpectationsLocked(void* mock_obj)
|
686
|
-
GTEST_EXCLUSIVE_LOCK_REQUIRED_(internal::g_gmock_mutex) {
|
687
|
-
internal::g_gmock_mutex.AssertHeld();
|
688
|
-
if (g_mock_object_registry.states().count(mock_obj) == 0) {
|
689
|
-
// No EXPECT_CALL() was set on the given mock object.
|
690
|
-
return true;
|
691
|
-
}
|
692
|
-
|
693
|
-
// Verifies and clears the expectations on each mock method in the
|
694
|
-
// given mock object.
|
695
|
-
bool expectations_met = true;
|
696
|
-
FunctionMockers& mockers =
|
697
|
-
g_mock_object_registry.states()[mock_obj].function_mockers;
|
698
|
-
for (FunctionMockers::const_iterator it = mockers.begin();
|
699
|
-
it != mockers.end(); ++it) {
|
700
|
-
if (!(*it)->VerifyAndClearExpectationsLocked()) {
|
701
|
-
expectations_met = false;
|
702
|
-
}
|
703
|
-
}
|
704
|
-
|
705
|
-
// We don't clear the content of mockers, as they may still be
|
706
|
-
// needed by ClearDefaultActionsLocked().
|
707
|
-
return expectations_met;
|
708
|
-
}
|
709
|
-
|
710
|
-
// Registers a mock object and a mock method it owns.
|
711
|
-
void Mock::Register(const void* mock_obj,
|
712
|
-
internal::UntypedFunctionMockerBase* mocker)
|
713
|
-
GTEST_LOCK_EXCLUDED_(internal::g_gmock_mutex) {
|
714
|
-
internal::MutexLock l(&internal::g_gmock_mutex);
|
715
|
-
g_mock_object_registry.states()[mock_obj].function_mockers.insert(mocker);
|
716
|
-
}
|
717
|
-
|
718
|
-
// Tells Google Mock where in the source code mock_obj is used in an
|
719
|
-
// ON_CALL or EXPECT_CALL. In case mock_obj is leaked, this
|
720
|
-
// information helps the user identify which object it is.
|
721
|
-
void Mock::RegisterUseByOnCallOrExpectCall(const void* mock_obj,
|
722
|
-
const char* file, int line)
|
723
|
-
GTEST_LOCK_EXCLUDED_(internal::g_gmock_mutex) {
|
724
|
-
internal::MutexLock l(&internal::g_gmock_mutex);
|
725
|
-
MockObjectState& state = g_mock_object_registry.states()[mock_obj];
|
726
|
-
if (state.first_used_file == NULL) {
|
727
|
-
state.first_used_file = file;
|
728
|
-
state.first_used_line = line;
|
729
|
-
const TestInfo* const test_info =
|
730
|
-
UnitTest::GetInstance()->current_test_info();
|
731
|
-
if (test_info != NULL) {
|
732
|
-
// TODO(wan@google.com): record the test case name when the
|
733
|
-
// ON_CALL or EXPECT_CALL is invoked from SetUpTestCase() or
|
734
|
-
// TearDownTestCase().
|
735
|
-
state.first_used_test_case = test_info->test_case_name();
|
736
|
-
state.first_used_test = test_info->name();
|
737
|
-
}
|
738
|
-
}
|
739
|
-
}
|
740
|
-
|
741
|
-
// Unregisters a mock method; removes the owning mock object from the
|
742
|
-
// registry when the last mock method associated with it has been
|
743
|
-
// unregistered. This is called only in the destructor of
|
744
|
-
// FunctionMockerBase.
|
745
|
-
void Mock::UnregisterLocked(internal::UntypedFunctionMockerBase* mocker)
|
746
|
-
GTEST_EXCLUSIVE_LOCK_REQUIRED_(internal::g_gmock_mutex) {
|
747
|
-
internal::g_gmock_mutex.AssertHeld();
|
748
|
-
for (MockObjectRegistry::StateMap::iterator it =
|
749
|
-
g_mock_object_registry.states().begin();
|
750
|
-
it != g_mock_object_registry.states().end(); ++it) {
|
751
|
-
FunctionMockers& mockers = it->second.function_mockers;
|
752
|
-
if (mockers.erase(mocker) > 0) {
|
753
|
-
// mocker was in mockers and has been just removed.
|
754
|
-
if (mockers.empty()) {
|
755
|
-
g_mock_object_registry.states().erase(it);
|
756
|
-
}
|
757
|
-
return;
|
758
|
-
}
|
759
|
-
}
|
760
|
-
}
|
761
|
-
|
762
|
-
// Clears all ON_CALL()s set on the given mock object.
|
763
|
-
void Mock::ClearDefaultActionsLocked(void* mock_obj)
|
764
|
-
GTEST_EXCLUSIVE_LOCK_REQUIRED_(internal::g_gmock_mutex) {
|
765
|
-
internal::g_gmock_mutex.AssertHeld();
|
766
|
-
|
767
|
-
if (g_mock_object_registry.states().count(mock_obj) == 0) {
|
768
|
-
// No ON_CALL() was set on the given mock object.
|
769
|
-
return;
|
770
|
-
}
|
771
|
-
|
772
|
-
// Clears the default actions for each mock method in the given mock
|
773
|
-
// object.
|
774
|
-
FunctionMockers& mockers =
|
775
|
-
g_mock_object_registry.states()[mock_obj].function_mockers;
|
776
|
-
for (FunctionMockers::const_iterator it = mockers.begin();
|
777
|
-
it != mockers.end(); ++it) {
|
778
|
-
(*it)->ClearDefaultActionsLocked();
|
779
|
-
}
|
780
|
-
|
781
|
-
// We don't clear the content of mockers, as they may still be
|
782
|
-
// needed by VerifyAndClearExpectationsLocked().
|
783
|
-
}
|
784
|
-
|
785
|
-
Expectation::Expectation() {}
|
786
|
-
|
787
|
-
Expectation::Expectation(
|
788
|
-
const internal::linked_ptr<internal::ExpectationBase>& an_expectation_base)
|
789
|
-
: expectation_base_(an_expectation_base) {}
|
790
|
-
|
791
|
-
Expectation::~Expectation() {}
|
792
|
-
|
793
|
-
// Adds an expectation to a sequence.
|
794
|
-
void Sequence::AddExpectation(const Expectation& expectation) const {
|
795
|
-
if (*last_expectation_ != expectation) {
|
796
|
-
if (last_expectation_->expectation_base() != NULL) {
|
797
|
-
expectation.expectation_base()->immediate_prerequisites_
|
798
|
-
+= *last_expectation_;
|
799
|
-
}
|
800
|
-
*last_expectation_ = expectation;
|
801
|
-
}
|
802
|
-
}
|
803
|
-
|
804
|
-
// Creates the implicit sequence if there isn't one.
|
805
|
-
InSequence::InSequence() {
|
806
|
-
if (internal::g_gmock_implicit_sequence.get() == NULL) {
|
807
|
-
internal::g_gmock_implicit_sequence.set(new Sequence);
|
808
|
-
sequence_created_ = true;
|
809
|
-
} else {
|
810
|
-
sequence_created_ = false;
|
811
|
-
}
|
812
|
-
}
|
813
|
-
|
814
|
-
// Deletes the implicit sequence if it was created by the constructor
|
815
|
-
// of this object.
|
816
|
-
InSequence::~InSequence() {
|
817
|
-
if (sequence_created_) {
|
818
|
-
delete internal::g_gmock_implicit_sequence.get();
|
819
|
-
internal::g_gmock_implicit_sequence.set(NULL);
|
820
|
-
}
|
821
|
-
}
|
822
|
-
|
823
|
-
} // namespace testing
|