rj_schema 0.2.2 → 1.0.0

Sign up to get free protection for your applications and to get access to all the features.
Files changed (371) hide show
  1. checksums.yaml +4 -4
  2. data/ext/rj_schema/rapidjson/CMakeLists.txt +9 -4
  3. data/ext/rj_schema/rapidjson/RapidJSONConfig.cmake.in +10 -0
  4. data/ext/rj_schema/rapidjson/appveyor.yml +22 -9
  5. data/ext/rj_schema/rapidjson/bin/data/abcde.txt +1 -0
  6. data/ext/rj_schema/rapidjson/bin/unittestschema/address.json +139 -0
  7. data/ext/rj_schema/rapidjson/bin/unittestschema/allOf_address.json +7 -0
  8. data/ext/rj_schema/rapidjson/bin/unittestschema/anyOf_address.json +7 -0
  9. data/ext/rj_schema/rapidjson/bin/unittestschema/oneOf_address.json +7 -0
  10. data/ext/rj_schema/rapidjson/contrib/natvis/rapidjson.natvis +2 -2
  11. data/ext/rj_schema/rapidjson/doc/dom.md +1 -0
  12. data/ext/rj_schema/rapidjson/doc/dom.zh-cn.md +1 -0
  13. data/ext/rj_schema/rapidjson/doc/faq.md +3 -3
  14. data/ext/rj_schema/rapidjson/doc/faq.zh-cn.md +8 -8
  15. data/ext/rj_schema/rapidjson/doc/internals.md +1 -1
  16. data/ext/rj_schema/rapidjson/doc/internals.zh-cn.md +2 -2
  17. data/ext/rj_schema/rapidjson/doc/pointer.zh-cn.md +1 -1
  18. data/ext/rj_schema/rapidjson/doc/sax.md +1 -1
  19. data/ext/rj_schema/rapidjson/doc/sax.zh-cn.md +2 -2
  20. data/ext/rj_schema/rapidjson/doc/stream.md +1 -1
  21. data/ext/rj_schema/rapidjson/doc/tutorial.md +1 -1
  22. data/ext/rj_schema/rapidjson/doc/tutorial.zh-cn.md +7 -6
  23. data/ext/rj_schema/rapidjson/example/CMakeLists.txt +1 -0
  24. data/ext/rj_schema/rapidjson/example/schemavalidator/schemavalidator.cpp +118 -0
  25. data/ext/rj_schema/rapidjson/example/sortkeys/sortkeys.cpp +62 -0
  26. data/ext/rj_schema/rapidjson/example/tutorial/tutorial.cpp +1 -1
  27. data/ext/rj_schema/rapidjson/include/rapidjson/allocators.h +6 -6
  28. data/ext/rj_schema/rapidjson/include/rapidjson/cursorstreamwrapper.h +1 -1
  29. data/ext/rj_schema/rapidjson/include/rapidjson/document.h +124 -35
  30. data/ext/rj_schema/rapidjson/include/rapidjson/encodedstream.h +1 -1
  31. data/ext/rj_schema/rapidjson/include/rapidjson/encodings.h +1 -1
  32. data/ext/rj_schema/rapidjson/include/rapidjson/error/en.h +49 -1
  33. data/ext/rj_schema/rapidjson/include/rapidjson/error/error.h +56 -1
  34. data/ext/rj_schema/rapidjson/include/rapidjson/filereadstream.h +2 -2
  35. data/ext/rj_schema/rapidjson/include/rapidjson/filewritestream.h +1 -1
  36. data/ext/rj_schema/rapidjson/include/rapidjson/fwd.h +2 -2
  37. data/ext/rj_schema/rapidjson/include/rapidjson/internal/biginteger.h +2 -2
  38. data/ext/rj_schema/rapidjson/include/rapidjson/internal/clzll.h +71 -0
  39. data/ext/rj_schema/rapidjson/include/rapidjson/internal/diyfp.h +3 -17
  40. data/ext/rj_schema/rapidjson/include/rapidjson/internal/dtoa.h +1 -1
  41. data/ext/rj_schema/rapidjson/include/rapidjson/internal/ieee754.h +1 -1
  42. data/ext/rj_schema/rapidjson/include/rapidjson/internal/itoa.h +1 -1
  43. data/ext/rj_schema/rapidjson/include/rapidjson/internal/meta.h +1 -1
  44. data/ext/rj_schema/rapidjson/include/rapidjson/internal/pow10.h +1 -1
  45. data/ext/rj_schema/rapidjson/include/rapidjson/internal/regex.h +20 -13
  46. data/ext/rj_schema/rapidjson/include/rapidjson/internal/stack.h +4 -3
  47. data/ext/rj_schema/rapidjson/include/rapidjson/internal/strfunc.h +1 -1
  48. data/ext/rj_schema/rapidjson/include/rapidjson/internal/strtod.h +1 -1
  49. data/ext/rj_schema/rapidjson/include/rapidjson/internal/swap.h +1 -1
  50. data/ext/rj_schema/rapidjson/include/rapidjson/istreamwrapper.h +50 -35
  51. data/ext/rj_schema/rapidjson/include/rapidjson/memorybuffer.h +1 -1
  52. data/ext/rj_schema/rapidjson/include/rapidjson/memorystream.h +1 -1
  53. data/ext/rj_schema/rapidjson/include/rapidjson/ostreamwrapper.h +1 -1
  54. data/ext/rj_schema/rapidjson/include/rapidjson/pointer.h +63 -5
  55. data/ext/rj_schema/rapidjson/include/rapidjson/prettywriter.h +2 -2
  56. data/ext/rj_schema/rapidjson/include/rapidjson/rapidjson.h +63 -1
  57. data/ext/rj_schema/rapidjson/include/rapidjson/reader.h +67 -53
  58. data/ext/rj_schema/rapidjson/include/rapidjson/schema.h +318 -164
  59. data/ext/rj_schema/rapidjson/include/rapidjson/stream.h +1 -1
  60. data/ext/rj_schema/rapidjson/include/rapidjson/stringbuffer.h +1 -1
  61. data/ext/rj_schema/rapidjson/include/rapidjson/writer.h +10 -10
  62. data/ext/rj_schema/rapidjson/readme.md +51 -1
  63. data/ext/rj_schema/rapidjson/readme.zh-cn.md +2 -2
  64. data/ext/rj_schema/rapidjson/test/perftest/misctest.cpp +1 -1
  65. data/ext/rj_schema/rapidjson/test/perftest/perftest.cpp +1 -1
  66. data/ext/rj_schema/rapidjson/test/perftest/perftest.h +1 -1
  67. data/ext/rj_schema/rapidjson/test/perftest/platformtest.cpp +2 -2
  68. data/ext/rj_schema/rapidjson/test/perftest/rapidjsontest.cpp +75 -1
  69. data/ext/rj_schema/rapidjson/test/unittest/CMakeLists.txt +1 -0
  70. data/ext/rj_schema/rapidjson/test/unittest/allocatorstest.cpp +1 -1
  71. data/ext/rj_schema/rapidjson/test/unittest/bigintegertest.cpp +1 -1
  72. data/ext/rj_schema/rapidjson/test/unittest/clzlltest.cpp +34 -0
  73. data/ext/rj_schema/rapidjson/test/unittest/cursorstreamwrappertest.cpp +19 -19
  74. data/ext/rj_schema/rapidjson/test/unittest/documenttest.cpp +1 -1
  75. data/ext/rj_schema/rapidjson/test/unittest/dtoatest.cpp +1 -1
  76. data/ext/rj_schema/rapidjson/test/unittest/encodedstreamtest.cpp +1 -1
  77. data/ext/rj_schema/rapidjson/test/unittest/encodingstest.cpp +1 -1
  78. data/ext/rj_schema/rapidjson/test/unittest/filestreamtest.cpp +45 -2
  79. data/ext/rj_schema/rapidjson/test/unittest/fwdtest.cpp +1 -1
  80. data/ext/rj_schema/rapidjson/test/unittest/istreamwrappertest.cpp +10 -10
  81. data/ext/rj_schema/rapidjson/test/unittest/itoatest.cpp +8 -8
  82. data/ext/rj_schema/rapidjson/test/unittest/jsoncheckertest.cpp +1 -1
  83. data/ext/rj_schema/rapidjson/test/unittest/namespacetest.cpp +1 -1
  84. data/ext/rj_schema/rapidjson/test/unittest/ostreamwrappertest.cpp +1 -1
  85. data/ext/rj_schema/rapidjson/test/unittest/pointertest.cpp +157 -16
  86. data/ext/rj_schema/rapidjson/test/unittest/prettywritertest.cpp +1 -1
  87. data/ext/rj_schema/rapidjson/test/unittest/readertest.cpp +113 -75
  88. data/ext/rj_schema/rapidjson/test/unittest/regextest.cpp +2 -1
  89. data/ext/rj_schema/rapidjson/test/unittest/schematest.cpp +593 -78
  90. data/ext/rj_schema/rapidjson/test/unittest/simdtest.cpp +1 -1
  91. data/ext/rj_schema/rapidjson/test/unittest/strfunctest.cpp +1 -1
  92. data/ext/rj_schema/rapidjson/test/unittest/stringbuffertest.cpp +5 -5
  93. data/ext/rj_schema/rapidjson/test/unittest/strtodtest.cpp +1 -1
  94. data/ext/rj_schema/rapidjson/test/unittest/unittest.cpp +1 -1
  95. data/ext/rj_schema/rapidjson/test/unittest/unittest.h +4 -1
  96. data/ext/rj_schema/rapidjson/test/unittest/valuetest.cpp +12 -12
  97. data/ext/rj_schema/rapidjson/test/unittest/writertest.cpp +1 -1
  98. data/ext/rj_schema/rapidjson/thirdparty/gtest/BUILD.bazel +175 -0
  99. data/ext/rj_schema/rapidjson/thirdparty/gtest/CMakeLists.txt +18 -1
  100. data/ext/rj_schema/rapidjson/thirdparty/gtest/CONTRIBUTING.md +160 -0
  101. data/ext/rj_schema/rapidjson/thirdparty/gtest/LICENSE +28 -0
  102. data/ext/rj_schema/rapidjson/thirdparty/gtest/Makefile.am +14 -0
  103. data/ext/rj_schema/rapidjson/thirdparty/gtest/README.md +16 -35
  104. data/ext/rj_schema/rapidjson/thirdparty/gtest/WORKSPACE +8 -0
  105. data/ext/rj_schema/rapidjson/thirdparty/gtest/appveyor.yml +104 -0
  106. data/ext/rj_schema/rapidjson/thirdparty/gtest/ci/build-linux-autotools.sh +44 -0
  107. data/ext/rj_schema/rapidjson/thirdparty/gtest/ci/build-linux-bazel.sh +36 -0
  108. data/ext/rj_schema/rapidjson/thirdparty/gtest/ci/env-linux.sh +41 -0
  109. data/ext/rj_schema/rapidjson/thirdparty/gtest/ci/env-osx.sh +40 -0
  110. data/ext/rj_schema/rapidjson/thirdparty/gtest/ci/get-nprocessors.sh +48 -0
  111. data/ext/rj_schema/rapidjson/thirdparty/gtest/ci/install-linux.sh +49 -0
  112. data/ext/rj_schema/rapidjson/thirdparty/gtest/ci/install-osx.sh +39 -0
  113. data/ext/rj_schema/rapidjson/thirdparty/gtest/ci/log-config.sh +51 -0
  114. data/ext/rj_schema/rapidjson/thirdparty/gtest/ci/travis.sh +44 -0
  115. data/ext/rj_schema/rapidjson/thirdparty/gtest/configure.ac +16 -0
  116. data/ext/rj_schema/rapidjson/thirdparty/gtest/googlemock/CHANGES +1 -1
  117. data/ext/rj_schema/rapidjson/thirdparty/gtest/googlemock/CMakeLists.txt +72 -32
  118. data/ext/rj_schema/rapidjson/thirdparty/gtest/googlemock/README.md +53 -42
  119. data/ext/rj_schema/rapidjson/thirdparty/gtest/googlemock/cmake/gmock.pc.in +9 -0
  120. data/ext/rj_schema/rapidjson/thirdparty/gtest/googlemock/cmake/gmock_main.pc.in +9 -0
  121. data/ext/rj_schema/rapidjson/thirdparty/gtest/googlemock/configure.ac +4 -4
  122. data/ext/rj_schema/rapidjson/thirdparty/gtest/googlemock/docs/CheatSheet.md +6 -4
  123. data/ext/rj_schema/rapidjson/thirdparty/gtest/googlemock/docs/CookBook.md +117 -132
  124. data/ext/rj_schema/rapidjson/thirdparty/gtest/googlemock/docs/Documentation.md +7 -4
  125. data/ext/rj_schema/rapidjson/thirdparty/gtest/googlemock/docs/ForDummies.md +20 -12
  126. data/ext/rj_schema/rapidjson/thirdparty/gtest/googlemock/docs/FrequentlyAskedQuestions.md +1 -2
  127. data/ext/rj_schema/rapidjson/thirdparty/gtest/googlemock/include/gmock/gmock-actions.h +83 -26
  128. data/ext/rj_schema/rapidjson/thirdparty/gtest/googlemock/include/gmock/gmock-generated-actions.h +262 -68
  129. data/ext/rj_schema/rapidjson/thirdparty/gtest/googlemock/include/gmock/gmock-generated-actions.h.pump +45 -6
  130. data/ext/rj_schema/rapidjson/thirdparty/gtest/googlemock/include/gmock/gmock-generated-function-mockers.h +650 -366
  131. data/ext/rj_schema/rapidjson/thirdparty/gtest/googlemock/include/gmock/gmock-generated-function-mockers.h.pump +76 -20
  132. data/ext/rj_schema/rapidjson/thirdparty/gtest/googlemock/include/gmock/gmock-generated-matchers.h +308 -229
  133. data/ext/rj_schema/rapidjson/thirdparty/gtest/googlemock/include/gmock/gmock-generated-matchers.h.pump +18 -15
  134. data/ext/rj_schema/rapidjson/thirdparty/gtest/googlemock/include/gmock/gmock-generated-nice-strict.h +87 -26
  135. data/ext/rj_schema/rapidjson/thirdparty/gtest/googlemock/include/gmock/gmock-generated-nice-strict.h.pump +33 -16
  136. data/ext/rj_schema/rapidjson/thirdparty/gtest/googlemock/include/gmock/gmock-matchers.h +1209 -353
  137. data/ext/rj_schema/rapidjson/thirdparty/gtest/googlemock/include/gmock/gmock-more-matchers.h +33 -0
  138. data/ext/rj_schema/rapidjson/thirdparty/gtest/googlemock/include/gmock/gmock-spec-builders.h +159 -88
  139. data/ext/rj_schema/rapidjson/thirdparty/gtest/googlemock/include/gmock/gmock.h +2 -1
  140. data/ext/rj_schema/rapidjson/thirdparty/gtest/googlemock/include/gmock/internal/custom/gmock-generated-actions.h.pump +1 -1
  141. data/ext/rj_schema/rapidjson/thirdparty/gtest/googlemock/include/gmock/internal/custom/gmock-matchers.h +3 -4
  142. data/ext/rj_schema/rapidjson/thirdparty/gtest/googlemock/include/gmock/internal/gmock-generated-internal-utils.h +16 -9
  143. data/ext/rj_schema/rapidjson/thirdparty/gtest/googlemock/include/gmock/internal/gmock-internal-utils.h +71 -8
  144. data/ext/rj_schema/rapidjson/thirdparty/gtest/googlemock/include/gmock/internal/gmock-port.h +7 -11
  145. data/ext/rj_schema/rapidjson/thirdparty/gtest/googlemock/msvc/2010/gmock.sln +14 -0
  146. data/ext/rj_schema/rapidjson/thirdparty/gtest/googlemock/msvc/2010/gmock.vcxproj +69 -6
  147. data/ext/rj_schema/rapidjson/thirdparty/gtest/googlemock/msvc/2010/gmock_config.props +2 -2
  148. data/ext/rj_schema/rapidjson/thirdparty/gtest/googlemock/msvc/2010/gmock_main.vcxproj +69 -6
  149. data/ext/rj_schema/rapidjson/thirdparty/gtest/googlemock/msvc/2010/gmock_test.vcxproj +83 -8
  150. data/ext/rj_schema/rapidjson/thirdparty/gtest/googlemock/msvc/2015/gmock.sln +14 -0
  151. data/ext/rj_schema/rapidjson/thirdparty/gtest/googlemock/msvc/2015/gmock.vcxproj +63 -2
  152. data/ext/rj_schema/rapidjson/thirdparty/gtest/googlemock/msvc/2015/gmock_main.vcxproj +63 -2
  153. data/ext/rj_schema/rapidjson/thirdparty/gtest/googlemock/msvc/2015/gmock_test.vcxproj +76 -3
  154. data/ext/rj_schema/rapidjson/thirdparty/gtest/googlemock/scripts/fuse_gmock_files.py +1 -1
  155. data/ext/rj_schema/rapidjson/thirdparty/gtest/googlemock/scripts/generator/README +4 -5
  156. data/ext/rj_schema/rapidjson/thirdparty/gtest/googlemock/scripts/generator/cpp/ast.py +3 -3
  157. data/ext/rj_schema/rapidjson/thirdparty/gtest/googlemock/src/gmock-cardinalities.cc +1 -1
  158. data/ext/rj_schema/rapidjson/thirdparty/gtest/googlemock/src/gmock-internal-utils.cc +36 -6
  159. data/ext/rj_schema/rapidjson/thirdparty/gtest/googlemock/src/gmock-matchers.cc +210 -135
  160. data/ext/rj_schema/rapidjson/thirdparty/gtest/googlemock/src/gmock-spec-builders.cc +108 -48
  161. data/ext/rj_schema/rapidjson/thirdparty/gtest/googlemock/src/gmock.cc +23 -1
  162. data/ext/rj_schema/rapidjson/thirdparty/gtest/googlemock/test/BUILD.bazel +123 -0
  163. data/ext/rj_schema/rapidjson/thirdparty/gtest/googlemock/test/gmock-actions_test.cc +166 -2
  164. data/ext/rj_schema/rapidjson/thirdparty/gtest/googlemock/test/gmock-cardinalities_test.cc +1 -1
  165. data/ext/rj_schema/rapidjson/thirdparty/gtest/googlemock/test/gmock-generated-actions_test.cc +64 -62
  166. data/ext/rj_schema/rapidjson/thirdparty/gtest/googlemock/test/gmock-generated-function-mockers_test.cc +43 -18
  167. data/ext/rj_schema/rapidjson/thirdparty/gtest/googlemock/test/gmock-generated-internal-utils_test.cc +11 -9
  168. data/ext/rj_schema/rapidjson/thirdparty/gtest/googlemock/test/gmock-generated-matchers_test.cc +91 -36
  169. data/ext/rj_schema/rapidjson/thirdparty/gtest/googlemock/test/gmock-internal-utils_test.cc +33 -14
  170. data/ext/rj_schema/rapidjson/thirdparty/gtest/googlemock/test/gmock-matchers_test.cc +1286 -167
  171. data/ext/rj_schema/rapidjson/thirdparty/gtest/googlemock/test/gmock-more-actions_test.cc +85 -83
  172. data/ext/rj_schema/rapidjson/thirdparty/gtest/googlemock/test/gmock-nice-strict_test.cc +102 -15
  173. data/ext/rj_schema/rapidjson/thirdparty/gtest/googlemock/test/gmock-spec-builders_test.cc +136 -9
  174. data/ext/rj_schema/rapidjson/thirdparty/gtest/googlemock/test/gmock_link2_test.cc +1 -1
  175. data/ext/rj_schema/rapidjson/thirdparty/gtest/googlemock/test/gmock_link_test.cc +1 -1
  176. data/ext/rj_schema/rapidjson/thirdparty/gtest/googlemock/test/gmock_link_test.h +24 -2
  177. data/ext/rj_schema/rapidjson/thirdparty/gtest/googlemock/test/gmock_output_test.py +8 -5
  178. data/ext/rj_schema/rapidjson/thirdparty/gtest/googlemock/test/gmock_output_test_.cc +20 -1
  179. data/ext/rj_schema/rapidjson/thirdparty/gtest/googlemock/test/gmock_output_test_golden.txt +8 -1
  180. data/ext/rj_schema/rapidjson/thirdparty/gtest/googlemock/test/gmock_stress_test.cc +3 -2
  181. data/ext/rj_schema/rapidjson/thirdparty/gtest/googlemock/test/gmock_test.cc +44 -2
  182. data/ext/rj_schema/rapidjson/thirdparty/gtest/googlemock/test/gmock_test_utils.py +5 -7
  183. data/ext/rj_schema/rapidjson/thirdparty/gtest/googletest/CMakeLists.txt +40 -14
  184. data/ext/rj_schema/rapidjson/thirdparty/gtest/googletest/Makefile.am +60 -31
  185. data/ext/rj_schema/rapidjson/thirdparty/gtest/googletest/README.md +232 -171
  186. data/ext/rj_schema/rapidjson/thirdparty/gtest/googletest/cmake/gtest.pc.in +9 -0
  187. data/ext/rj_schema/rapidjson/thirdparty/gtest/googletest/cmake/gtest_main.pc.in +10 -0
  188. data/ext/rj_schema/rapidjson/thirdparty/gtest/googletest/cmake/internal_utils.cmake +54 -16
  189. data/ext/rj_schema/rapidjson/thirdparty/gtest/googletest/configure.ac +1 -1
  190. data/ext/rj_schema/rapidjson/thirdparty/gtest/googletest/docs/Pkgconfig.md +146 -0
  191. data/ext/rj_schema/rapidjson/thirdparty/gtest/googletest/docs/PumpManual.md +2 -2
  192. data/ext/rj_schema/rapidjson/thirdparty/gtest/googletest/docs/XcodeGuide.md +6 -6
  193. data/ext/rj_schema/rapidjson/thirdparty/gtest/googletest/docs/{AdvancedGuide.md → advanced.md} +260 -26
  194. data/ext/rj_schema/rapidjson/thirdparty/gtest/googletest/docs/{FAQ.md → faq.md} +62 -57
  195. data/ext/rj_schema/rapidjson/thirdparty/gtest/googletest/docs/{Primer.md → primer.md} +43 -9
  196. data/ext/rj_schema/rapidjson/thirdparty/gtest/googletest/docs/{Samples.md → samples.md} +0 -0
  197. data/ext/rj_schema/rapidjson/thirdparty/gtest/googletest/include/gtest/gtest-death-test.h +53 -5
  198. data/ext/rj_schema/rapidjson/thirdparty/gtest/googletest/include/gtest/gtest-message.h +1 -2
  199. data/ext/rj_schema/rapidjson/thirdparty/gtest/googletest/include/gtest/gtest-param-test.h +30 -36
  200. data/ext/rj_schema/rapidjson/thirdparty/gtest/googletest/include/gtest/gtest-param-test.h.pump +8 -17
  201. data/ext/rj_schema/rapidjson/thirdparty/gtest/googletest/include/gtest/gtest-printers.h +140 -51
  202. data/ext/rj_schema/rapidjson/thirdparty/gtest/googletest/include/gtest/gtest-spi.h +2 -3
  203. data/ext/rj_schema/rapidjson/thirdparty/gtest/googletest/include/gtest/gtest-typed-test.h +4 -3
  204. data/ext/rj_schema/rapidjson/thirdparty/gtest/googletest/include/gtest/gtest.h +126 -30
  205. data/ext/rj_schema/rapidjson/thirdparty/gtest/googletest/include/gtest/gtest_pred_impl.h +6 -7
  206. data/ext/rj_schema/rapidjson/thirdparty/gtest/googletest/include/gtest/gtest_prod.h +8 -5
  207. data/ext/rj_schema/rapidjson/thirdparty/gtest/googletest/include/gtest/internal/custom/gtest-port.h +6 -5
  208. data/ext/rj_schema/rapidjson/thirdparty/gtest/googletest/include/gtest/internal/custom/gtest.h +4 -0
  209. data/ext/rj_schema/rapidjson/thirdparty/gtest/googletest/include/gtest/internal/gtest-death-test-internal.h +13 -57
  210. data/ext/rj_schema/rapidjson/thirdparty/gtest/googletest/include/gtest/internal/gtest-filepath.h +1 -2
  211. data/ext/rj_schema/rapidjson/thirdparty/gtest/googletest/include/gtest/internal/gtest-internal.h +98 -59
  212. data/ext/rj_schema/rapidjson/thirdparty/gtest/googletest/include/gtest/internal/gtest-param-util-generated.h +34 -41
  213. data/ext/rj_schema/rapidjson/thirdparty/gtest/googletest/include/gtest/internal/gtest-param-util-generated.h.pump +3 -10
  214. data/ext/rj_schema/rapidjson/thirdparty/gtest/googletest/include/gtest/internal/gtest-param-util.h +9 -17
  215. data/ext/rj_schema/rapidjson/thirdparty/gtest/googletest/include/gtest/internal/gtest-port-arch.h +8 -1
  216. data/ext/rj_schema/rapidjson/thirdparty/gtest/googletest/include/gtest/internal/gtest-port.h +232 -99
  217. data/ext/rj_schema/rapidjson/thirdparty/gtest/googletest/include/gtest/internal/gtest-string.h +3 -3
  218. data/ext/rj_schema/rapidjson/thirdparty/gtest/googletest/include/gtest/internal/gtest-type-util.h +17 -1
  219. data/ext/rj_schema/rapidjson/thirdparty/gtest/googletest/include/gtest/internal/gtest-type-util.h.pump +17 -1
  220. data/ext/rj_schema/rapidjson/thirdparty/gtest/googletest/msvc/2010/gtest-md.sln +55 -0
  221. data/ext/rj_schema/rapidjson/thirdparty/gtest/googletest/msvc/2010/gtest-md.vcxproj +149 -0
  222. data/ext/rj_schema/rapidjson/thirdparty/gtest/googletest/msvc/2010/gtest-md.vcxproj.filters +18 -0
  223. data/ext/rj_schema/rapidjson/thirdparty/gtest/googletest/msvc/2010/gtest.sln +55 -0
  224. data/ext/rj_schema/rapidjson/thirdparty/gtest/googletest/msvc/2010/gtest.vcxproj +149 -0
  225. data/ext/rj_schema/rapidjson/thirdparty/gtest/googletest/msvc/2010/gtest.vcxproj.filters +18 -0
  226. data/ext/rj_schema/rapidjson/thirdparty/gtest/googletest/msvc/2010/gtest_main-md.vcxproj +154 -0
  227. data/ext/rj_schema/rapidjson/thirdparty/gtest/googletest/msvc/2010/gtest_main-md.vcxproj.filters +18 -0
  228. data/ext/rj_schema/rapidjson/thirdparty/gtest/googletest/msvc/2010/gtest_main.vcxproj +162 -0
  229. data/ext/rj_schema/rapidjson/thirdparty/gtest/googletest/msvc/2010/gtest_main.vcxproj.filters +18 -0
  230. data/ext/rj_schema/rapidjson/thirdparty/gtest/googletest/msvc/2010/gtest_prod_test-md.vcxproj +199 -0
  231. data/ext/rj_schema/rapidjson/thirdparty/gtest/googletest/msvc/2010/gtest_prod_test-md.vcxproj.filters +26 -0
  232. data/ext/rj_schema/rapidjson/thirdparty/gtest/googletest/msvc/2010/gtest_prod_test.vcxproj +191 -0
  233. data/ext/rj_schema/rapidjson/thirdparty/gtest/googletest/msvc/2010/gtest_prod_test.vcxproj.filters +26 -0
  234. data/ext/rj_schema/rapidjson/thirdparty/gtest/googletest/msvc/2010/gtest_unittest-md.vcxproj +188 -0
  235. data/ext/rj_schema/rapidjson/thirdparty/gtest/googletest/msvc/2010/gtest_unittest-md.vcxproj.filters +18 -0
  236. data/ext/rj_schema/rapidjson/thirdparty/gtest/googletest/msvc/2010/gtest_unittest.vcxproj +180 -0
  237. data/ext/rj_schema/rapidjson/thirdparty/gtest/googletest/msvc/2010/gtest_unittest.vcxproj.filters +18 -0
  238. data/ext/rj_schema/rapidjson/thirdparty/gtest/googletest/samples/prime_tables.h +6 -2
  239. data/ext/rj_schema/rapidjson/thirdparty/gtest/googletest/samples/sample1.cc +1 -1
  240. data/ext/rj_schema/rapidjson/thirdparty/gtest/googletest/samples/sample10_unittest.cc +0 -4
  241. data/ext/rj_schema/rapidjson/thirdparty/gtest/googletest/samples/sample1_unittest.cc +2 -1
  242. data/ext/rj_schema/rapidjson/thirdparty/gtest/googletest/samples/sample2_unittest.cc +2 -1
  243. data/ext/rj_schema/rapidjson/thirdparty/gtest/googletest/samples/sample3_unittest.cc +7 -6
  244. data/ext/rj_schema/rapidjson/thirdparty/gtest/googletest/samples/sample4_unittest.cc +5 -1
  245. data/ext/rj_schema/rapidjson/thirdparty/gtest/googletest/samples/sample5_unittest.cc +3 -3
  246. data/ext/rj_schema/rapidjson/thirdparty/gtest/googletest/samples/sample6_unittest.cc +2 -1
  247. data/ext/rj_schema/rapidjson/thirdparty/gtest/googletest/samples/sample7_unittest.cc +10 -22
  248. data/ext/rj_schema/rapidjson/thirdparty/gtest/googletest/samples/sample8_unittest.cc +2 -1
  249. data/ext/rj_schema/rapidjson/thirdparty/gtest/googletest/samples/sample9_unittest.cc +0 -3
  250. data/ext/rj_schema/rapidjson/thirdparty/gtest/googletest/scripts/fuse_gtest_files.py +1 -1
  251. data/ext/rj_schema/rapidjson/thirdparty/gtest/googletest/scripts/gen_gtest_pred_impl.py +10 -10
  252. data/ext/rj_schema/rapidjson/thirdparty/gtest/googletest/scripts/upload.py +1 -1
  253. data/ext/rj_schema/rapidjson/thirdparty/gtest/googletest/src/gtest-all.cc +1 -1
  254. data/ext/rj_schema/rapidjson/thirdparty/gtest/googletest/src/gtest-death-test.cc +226 -32
  255. data/ext/rj_schema/rapidjson/thirdparty/gtest/googletest/src/gtest-filepath.cc +5 -7
  256. data/ext/rj_schema/rapidjson/thirdparty/gtest/googletest/src/gtest-internal-inl.h +21 -29
  257. data/ext/rj_schema/rapidjson/thirdparty/gtest/googletest/src/gtest-port.cc +85 -67
  258. data/ext/rj_schema/rapidjson/thirdparty/gtest/googletest/src/gtest-printers.cc +93 -8
  259. data/ext/rj_schema/rapidjson/thirdparty/gtest/googletest/src/gtest-test-part.cc +1 -9
  260. data/ext/rj_schema/rapidjson/thirdparty/gtest/googletest/src/gtest-typed-test.cc +1 -0
  261. data/ext/rj_schema/rapidjson/thirdparty/gtest/googletest/src/gtest.cc +622 -164
  262. data/ext/rj_schema/rapidjson/thirdparty/gtest/googletest/src/gtest_main.cc +1 -1
  263. data/ext/rj_schema/rapidjson/thirdparty/gtest/googletest/test/BUILD.bazel +396 -0
  264. data/ext/rj_schema/rapidjson/thirdparty/gtest/googletest/test/gtest-death-test_test.cc +12 -15
  265. data/ext/rj_schema/rapidjson/thirdparty/gtest/googletest/test/gtest-filepath_test.cc +2 -12
  266. data/ext/rj_schema/rapidjson/thirdparty/gtest/googletest/test/gtest-listener_test.cc +1 -1
  267. data/ext/rj_schema/rapidjson/thirdparty/gtest/googletest/test/gtest-options_test.cc +6 -8
  268. data/ext/rj_schema/rapidjson/thirdparty/gtest/googletest/test/gtest-param-test2_test.cc +1 -5
  269. data/ext/rj_schema/rapidjson/thirdparty/gtest/googletest/test/gtest-param-test_test.cc +84 -29
  270. data/ext/rj_schema/rapidjson/thirdparty/gtest/googletest/test/gtest-param-test_test.h +1 -5
  271. data/ext/rj_schema/rapidjson/thirdparty/gtest/googletest/test/gtest-port_test.cc +11 -12
  272. data/ext/rj_schema/rapidjson/thirdparty/gtest/googletest/test/gtest-printers_test.cc +165 -63
  273. data/ext/rj_schema/rapidjson/thirdparty/gtest/googletest/test/gtest-typed-test2_test.cc +1 -1
  274. data/ext/rj_schema/rapidjson/thirdparty/gtest/googletest/test/gtest-typed-test_test.cc +1 -1
  275. data/ext/rj_schema/rapidjson/thirdparty/gtest/googletest/test/gtest-unittest-api_test.cc +1 -1
  276. data/ext/rj_schema/rapidjson/thirdparty/gtest/googletest/test/gtest_all_test.cc +13 -13
  277. data/ext/rj_schema/rapidjson/thirdparty/gtest/googletest/test/gtest_assert_by_exception_test.cc +119 -0
  278. data/ext/rj_schema/rapidjson/thirdparty/gtest/googletest/test/gtest_break_on_failure_unittest.py +1 -3
  279. data/ext/rj_schema/rapidjson/thirdparty/gtest/googletest/test/gtest_break_on_failure_unittest_.cc +1 -2
  280. data/ext/rj_schema/rapidjson/thirdparty/gtest/googletest/test/gtest_catch_exceptions_test.py +0 -2
  281. data/ext/rj_schema/rapidjson/thirdparty/gtest/googletest/test/gtest_catch_exceptions_test_.cc +1 -1
  282. data/ext/rj_schema/rapidjson/thirdparty/gtest/googletest/test/gtest_color_test.py +1 -2
  283. data/ext/rj_schema/rapidjson/thirdparty/gtest/googletest/test/gtest_color_test_.cc +0 -8
  284. data/ext/rj_schema/rapidjson/thirdparty/gtest/googletest/test/gtest_env_var_test.py +6 -4
  285. data/ext/rj_schema/rapidjson/thirdparty/gtest/googletest/test/gtest_env_var_test_.cc +0 -2
  286. data/ext/rj_schema/rapidjson/thirdparty/gtest/googletest/test/gtest_environment_test.cc +0 -3
  287. data/ext/rj_schema/rapidjson/thirdparty/gtest/googletest/test/gtest_filter_unittest.py +20 -18
  288. data/ext/rj_schema/rapidjson/thirdparty/gtest/googletest/test/gtest_filter_unittest_.cc +0 -2
  289. data/ext/rj_schema/rapidjson/thirdparty/gtest/googletest/test/gtest_help_test.py +1 -1
  290. data/ext/rj_schema/rapidjson/thirdparty/gtest/googletest/test/gtest_json_outfiles_test.py +162 -0
  291. data/ext/rj_schema/rapidjson/thirdparty/gtest/googletest/test/gtest_json_output_unittest.py +611 -0
  292. data/ext/rj_schema/rapidjson/thirdparty/gtest/googletest/test/gtest_json_test_utils.py +60 -0
  293. data/ext/rj_schema/rapidjson/thirdparty/gtest/googletest/test/gtest_list_tests_unittest.py +4 -4
  294. data/ext/rj_schema/rapidjson/thirdparty/gtest/googletest/test/gtest_main_unittest.cc +2 -2
  295. data/ext/rj_schema/rapidjson/thirdparty/gtest/googletest/test/gtest_output_test.py +11 -7
  296. data/ext/rj_schema/rapidjson/thirdparty/gtest/googletest/test/gtest_output_test_.cc +17 -12
  297. data/ext/rj_schema/rapidjson/thirdparty/gtest/googletest/test/gtest_output_test_golden_lin.txt +104 -66
  298. data/ext/rj_schema/rapidjson/thirdparty/gtest/googletest/test/gtest_pred_impl_unittest.cc +1 -1
  299. data/ext/rj_schema/rapidjson/thirdparty/gtest/googletest/test/gtest_prod_test.cc +2 -2
  300. data/ext/rj_schema/rapidjson/thirdparty/gtest/googletest/test/gtest_repeat_test.cc +2 -19
  301. data/ext/rj_schema/rapidjson/thirdparty/gtest/googletest/test/gtest_stress_test.cc +0 -6
  302. data/ext/rj_schema/rapidjson/thirdparty/gtest/googletest/test/gtest_test_utils.py +12 -14
  303. data/ext/rj_schema/rapidjson/thirdparty/gtest/googletest/test/gtest_testbridge_test.py +65 -0
  304. data/ext/rj_schema/rapidjson/thirdparty/gtest/googletest/test/gtest_testbridge_test_.cc +44 -0
  305. data/ext/rj_schema/rapidjson/thirdparty/gtest/googletest/test/gtest_throw_on_failure_test.py +1 -1
  306. data/ext/rj_schema/rapidjson/thirdparty/gtest/googletest/test/gtest_uninitialized_test.py +4 -5
  307. data/ext/rj_schema/rapidjson/thirdparty/gtest/googletest/test/gtest_uninitialized_test_.cc +2 -2
  308. data/ext/rj_schema/rapidjson/thirdparty/gtest/googletest/test/gtest_unittest.cc +240 -149
  309. data/ext/rj_schema/rapidjson/thirdparty/gtest/googletest/test/gtest_xml_outfile1_test_.cc +0 -1
  310. data/ext/rj_schema/rapidjson/thirdparty/gtest/googletest/test/gtest_xml_outfile2_test_.cc +0 -1
  311. data/ext/rj_schema/rapidjson/thirdparty/gtest/googletest/test/gtest_xml_outfiles_test.py +15 -7
  312. data/ext/rj_schema/rapidjson/thirdparty/gtest/googletest/test/gtest_xml_output_unittest.py +100 -30
  313. data/ext/rj_schema/rapidjson/thirdparty/gtest/googletest/test/gtest_xml_output_unittest_.cc +0 -2
  314. data/ext/rj_schema/rapidjson/thirdparty/gtest/googletest/test/gtest_xml_test_utils.py +25 -23
  315. data/ext/rj_schema/rapidjson/thirdparty/gtest/googletest/test/production.cc +1 -1
  316. data/ext/rj_schema/rapidjson/thirdparty/gtest/googletest/test/production.h +1 -1
  317. data/ext/rj_schema/rapidjson/thirdparty/gtest/googletest/xcode/Scripts/versiongenerate.py +4 -4
  318. data/ext/rj_schema/rapidjson/thirdparty/gtest/googletest/xcode/gtest.xcodeproj/project.pbxproj +47 -0
  319. data/ext/rj_schema/rapidjson/travis-doxygen.sh +13 -6
  320. data/ext/rj_schema/rj_schema.cpp +161 -17
  321. data/lib/rj_schema.rb +1 -1
  322. metadata +63 -58
  323. data/ext/rj_schema/rapidjson/thirdparty/gtest/googlemock/docs/DevGuide.md +0 -132
  324. data/ext/rj_schema/rapidjson/thirdparty/gtest/googlemock/docs/v1_5/CheatSheet.md +0 -525
  325. data/ext/rj_schema/rapidjson/thirdparty/gtest/googlemock/docs/v1_5/CookBook.md +0 -3250
  326. data/ext/rj_schema/rapidjson/thirdparty/gtest/googlemock/docs/v1_5/Documentation.md +0 -11
  327. data/ext/rj_schema/rapidjson/thirdparty/gtest/googlemock/docs/v1_5/ForDummies.md +0 -439
  328. data/ext/rj_schema/rapidjson/thirdparty/gtest/googlemock/docs/v1_5/FrequentlyAskedQuestions.md +0 -624
  329. data/ext/rj_schema/rapidjson/thirdparty/gtest/googlemock/docs/v1_6/CheatSheet.md +0 -534
  330. data/ext/rj_schema/rapidjson/thirdparty/gtest/googlemock/docs/v1_6/CookBook.md +0 -3342
  331. data/ext/rj_schema/rapidjson/thirdparty/gtest/googlemock/docs/v1_6/Documentation.md +0 -12
  332. data/ext/rj_schema/rapidjson/thirdparty/gtest/googlemock/docs/v1_6/ForDummies.md +0 -439
  333. data/ext/rj_schema/rapidjson/thirdparty/gtest/googlemock/docs/v1_6/FrequentlyAskedQuestions.md +0 -628
  334. data/ext/rj_schema/rapidjson/thirdparty/gtest/googlemock/docs/v1_7/CheatSheet.md +0 -556
  335. data/ext/rj_schema/rapidjson/thirdparty/gtest/googlemock/docs/v1_7/CookBook.md +0 -3432
  336. data/ext/rj_schema/rapidjson/thirdparty/gtest/googlemock/docs/v1_7/Documentation.md +0 -12
  337. data/ext/rj_schema/rapidjson/thirdparty/gtest/googlemock/docs/v1_7/ForDummies.md +0 -439
  338. data/ext/rj_schema/rapidjson/thirdparty/gtest/googlemock/docs/v1_7/FrequentlyAskedQuestions.md +0 -628
  339. data/ext/rj_schema/rapidjson/thirdparty/gtest/googletest/docs/DevGuide.md +0 -126
  340. data/ext/rj_schema/rapidjson/thirdparty/gtest/googletest/docs/Documentation.md +0 -14
  341. data/ext/rj_schema/rapidjson/thirdparty/gtest/googletest/docs/V1_5_AdvancedGuide.md +0 -2096
  342. data/ext/rj_schema/rapidjson/thirdparty/gtest/googletest/docs/V1_5_Documentation.md +0 -12
  343. data/ext/rj_schema/rapidjson/thirdparty/gtest/googletest/docs/V1_5_FAQ.md +0 -886
  344. data/ext/rj_schema/rapidjson/thirdparty/gtest/googletest/docs/V1_5_Primer.md +0 -497
  345. data/ext/rj_schema/rapidjson/thirdparty/gtest/googletest/docs/V1_5_PumpManual.md +0 -177
  346. data/ext/rj_schema/rapidjson/thirdparty/gtest/googletest/docs/V1_5_XcodeGuide.md +0 -93
  347. data/ext/rj_schema/rapidjson/thirdparty/gtest/googletest/docs/V1_6_AdvancedGuide.md +0 -2178
  348. data/ext/rj_schema/rapidjson/thirdparty/gtest/googletest/docs/V1_6_Documentation.md +0 -14
  349. data/ext/rj_schema/rapidjson/thirdparty/gtest/googletest/docs/V1_6_FAQ.md +0 -1038
  350. data/ext/rj_schema/rapidjson/thirdparty/gtest/googletest/docs/V1_6_Primer.md +0 -501
  351. data/ext/rj_schema/rapidjson/thirdparty/gtest/googletest/docs/V1_6_PumpManual.md +0 -177
  352. data/ext/rj_schema/rapidjson/thirdparty/gtest/googletest/docs/V1_6_Samples.md +0 -14
  353. data/ext/rj_schema/rapidjson/thirdparty/gtest/googletest/docs/V1_6_XcodeGuide.md +0 -93
  354. data/ext/rj_schema/rapidjson/thirdparty/gtest/googletest/docs/V1_7_AdvancedGuide.md +0 -2181
  355. data/ext/rj_schema/rapidjson/thirdparty/gtest/googletest/docs/V1_7_Documentation.md +0 -14
  356. data/ext/rj_schema/rapidjson/thirdparty/gtest/googletest/docs/V1_7_FAQ.md +0 -1082
  357. data/ext/rj_schema/rapidjson/thirdparty/gtest/googletest/docs/V1_7_Primer.md +0 -501
  358. data/ext/rj_schema/rapidjson/thirdparty/gtest/googletest/docs/V1_7_PumpManual.md +0 -177
  359. data/ext/rj_schema/rapidjson/thirdparty/gtest/googletest/docs/V1_7_Samples.md +0 -14
  360. data/ext/rj_schema/rapidjson/thirdparty/gtest/googletest/docs/V1_7_XcodeGuide.md +0 -93
  361. data/ext/rj_schema/rapidjson/thirdparty/gtest/googletest/msvc/gtest-md.sln +0 -45
  362. data/ext/rj_schema/rapidjson/thirdparty/gtest/googletest/msvc/gtest-md.vcproj +0 -126
  363. data/ext/rj_schema/rapidjson/thirdparty/gtest/googletest/msvc/gtest.sln +0 -45
  364. data/ext/rj_schema/rapidjson/thirdparty/gtest/googletest/msvc/gtest.vcproj +0 -126
  365. data/ext/rj_schema/rapidjson/thirdparty/gtest/googletest/msvc/gtest_main-md.vcproj +0 -129
  366. data/ext/rj_schema/rapidjson/thirdparty/gtest/googletest/msvc/gtest_main.vcproj +0 -129
  367. data/ext/rj_schema/rapidjson/thirdparty/gtest/googletest/msvc/gtest_prod_test-md.vcproj +0 -164
  368. data/ext/rj_schema/rapidjson/thirdparty/gtest/googletest/msvc/gtest_prod_test.vcproj +0 -164
  369. data/ext/rj_schema/rapidjson/thirdparty/gtest/googletest/msvc/gtest_unittest-md.vcproj +0 -147
  370. data/ext/rj_schema/rapidjson/thirdparty/gtest/googletest/msvc/gtest_unittest.vcproj +0 -147
  371. data/ext/rj_schema/rapidjson/thirdparty/gtest/travis.sh +0 -15
@@ -5,10 +5,18 @@
5
5
  <Configuration>Debug</Configuration>
6
6
  <Platform>Win32</Platform>
7
7
  </ProjectConfiguration>
8
+ <ProjectConfiguration Include="Debug|x64">
9
+ <Configuration>Debug</Configuration>
10
+ <Platform>x64</Platform>
11
+ </ProjectConfiguration>
8
12
  <ProjectConfiguration Include="Release|Win32">
9
13
  <Configuration>Release</Configuration>
10
14
  <Platform>Win32</Platform>
11
15
  </ProjectConfiguration>
16
+ <ProjectConfiguration Include="Release|x64">
17
+ <Configuration>Release</Configuration>
18
+ <Platform>x64</Platform>
19
+ </ProjectConfiguration>
12
20
  </ItemGroup>
13
21
  <PropertyGroup Label="Globals">
14
22
  <ProjectGuid>{E4EF614B-30DF-4954-8C53-580A0BF6B589}</ProjectGuid>
@@ -22,11 +30,22 @@
22
30
  <WholeProgramOptimization>true</WholeProgramOptimization>
23
31
  <PlatformToolset>v140</PlatformToolset>
24
32
  </PropertyGroup>
33
+ <PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Release|x64'" Label="Configuration">
34
+ <ConfigurationType>StaticLibrary</ConfigurationType>
35
+ <CharacterSet>Unicode</CharacterSet>
36
+ <WholeProgramOptimization>true</WholeProgramOptimization>
37
+ <PlatformToolset>v140</PlatformToolset>
38
+ </PropertyGroup>
25
39
  <PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Debug|Win32'" Label="Configuration">
26
40
  <ConfigurationType>StaticLibrary</ConfigurationType>
27
41
  <CharacterSet>Unicode</CharacterSet>
28
42
  <PlatformToolset>v140</PlatformToolset>
29
43
  </PropertyGroup>
44
+ <PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Debug|x64'" Label="Configuration">
45
+ <ConfigurationType>StaticLibrary</ConfigurationType>
46
+ <CharacterSet>Unicode</CharacterSet>
47
+ <PlatformToolset>v140</PlatformToolset>
48
+ </PropertyGroup>
30
49
  <Import Project="$(VCTargetsPath)\Microsoft.Cpp.props" />
31
50
  <ImportGroup Label="ExtensionSettings">
32
51
  </ImportGroup>
@@ -34,18 +53,34 @@
34
53
  <Import Project="$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props" Condition="exists('$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props')" Label="LocalAppDataPlatform" />
35
54
  <Import Project="gmock_config.props" />
36
55
  </ImportGroup>
56
+ <ImportGroup Condition="'$(Configuration)|$(Platform)'=='Release|x64'" Label="PropertySheets">
57
+ <Import Project="$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props" Condition="exists('$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props')" Label="LocalAppDataPlatform" />
58
+ <Import Project="gmock_config.props" />
59
+ </ImportGroup>
37
60
  <ImportGroup Condition="'$(Configuration)|$(Platform)'=='Debug|Win32'" Label="PropertySheets">
38
61
  <Import Project="$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props" Condition="exists('$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props')" Label="LocalAppDataPlatform" />
39
62
  <Import Project="gmock_config.props" />
40
63
  </ImportGroup>
64
+ <ImportGroup Condition="'$(Configuration)|$(Platform)'=='Debug|x64'" Label="PropertySheets">
65
+ <Import Project="$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props" Condition="exists('$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props')" Label="LocalAppDataPlatform" />
66
+ <Import Project="gmock_config.props" />
67
+ </ImportGroup>
41
68
  <PropertyGroup Label="UserMacros" />
42
69
  <PropertyGroup>
43
70
  <_ProjectFileVersion>10.0.30319.1</_ProjectFileVersion>
44
- <OutDir Condition="'$(Configuration)|$(Platform)'=='Debug|Win32'">$(SolutionDir)$(Configuration)\</OutDir>
71
+ <OutDir Condition="'$(Configuration)|$(Platform)'=='Debug|Win32'">$(SolutionDir)$(Platform)-$(Configuration)\</OutDir>
45
72
  <IntDir Condition="'$(Configuration)|$(Platform)'=='Debug|Win32'">$(OutDir)$(ProjectName)\</IntDir>
46
- <OutDir Condition="'$(Configuration)|$(Platform)'=='Release|Win32'">$(SolutionDir)$(Configuration)\</OutDir>
73
+ <OutDir Condition="'$(Configuration)|$(Platform)'=='Release|Win32'">$(SolutionDir)$(Platform)-$(Configuration)\</OutDir>
47
74
  <IntDir Condition="'$(Configuration)|$(Platform)'=='Release|Win32'">$(OutDir)$(ProjectName)\</IntDir>
48
75
  </PropertyGroup>
76
+ <PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Debug|x64'">
77
+ <OutDir>$(SolutionDir)$(Platform)-$(Configuration)\</OutDir>
78
+ <IntDir>$(OutDir)$(ProjectName)\</IntDir>
79
+ </PropertyGroup>
80
+ <PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Release|x64'">
81
+ <OutDir>$(SolutionDir)$(Platform)-$(Configuration)\</OutDir>
82
+ <IntDir>$(OutDir)$(ProjectName)\</IntDir>
83
+ </PropertyGroup>
49
84
  <ItemDefinitionGroup Condition="'$(Configuration)|$(Platform)'=='Debug|Win32'">
50
85
  <ClCompile>
51
86
  <Optimization>Disabled</Optimization>
@@ -60,6 +95,19 @@
60
95
  <DebugInformationFormat>ProgramDatabase</DebugInformationFormat>
61
96
  </ClCompile>
62
97
  </ItemDefinitionGroup>
98
+ <ItemDefinitionGroup Condition="'$(Configuration)|$(Platform)'=='Debug|x64'">
99
+ <ClCompile>
100
+ <Optimization>Disabled</Optimization>
101
+ <AdditionalIncludeDirectories>../../include;%(AdditionalIncludeDirectories)</AdditionalIncludeDirectories>
102
+ <PreprocessorDefinitions>WIN32;_DEBUG;_LIB;%(PreprocessorDefinitions)</PreprocessorDefinitions>
103
+ <BasicRuntimeChecks>EnableFastChecks</BasicRuntimeChecks>
104
+ <RuntimeLibrary>MultiThreadedDebug</RuntimeLibrary>
105
+ <PrecompiledHeader>
106
+ </PrecompiledHeader>
107
+ <WarningLevel>Level3</WarningLevel>
108
+ <DebugInformationFormat>ProgramDatabase</DebugInformationFormat>
109
+ </ClCompile>
110
+ </ItemDefinitionGroup>
63
111
  <ItemDefinitionGroup Condition="'$(Configuration)|$(Platform)'=='Release|Win32'">
64
112
  <ClCompile>
65
113
  <AdditionalIncludeDirectories>../../include;%(AdditionalIncludeDirectories)</AdditionalIncludeDirectories>
@@ -71,6 +119,17 @@
71
119
  <DebugInformationFormat>ProgramDatabase</DebugInformationFormat>
72
120
  </ClCompile>
73
121
  </ItemDefinitionGroup>
122
+ <ItemDefinitionGroup Condition="'$(Configuration)|$(Platform)'=='Release|x64'">
123
+ <ClCompile>
124
+ <AdditionalIncludeDirectories>../../include;%(AdditionalIncludeDirectories)</AdditionalIncludeDirectories>
125
+ <PreprocessorDefinitions>WIN32;NDEBUG;_LIB;%(PreprocessorDefinitions)</PreprocessorDefinitions>
126
+ <RuntimeLibrary>MultiThreaded</RuntimeLibrary>
127
+ <PrecompiledHeader>
128
+ </PrecompiledHeader>
129
+ <WarningLevel>Level3</WarningLevel>
130
+ <DebugInformationFormat>ProgramDatabase</DebugInformationFormat>
131
+ </ClCompile>
132
+ </ItemDefinitionGroup>
74
133
  <ItemGroup>
75
134
  <ProjectReference Include="gmock.vcxproj">
76
135
  <Project>{34681f0d-ce45-415d-b5f2-5c662dfe3bd5}</Project>
@@ -81,7 +140,9 @@
81
140
  <ItemGroup>
82
141
  <ClCompile Include="..\..\src\gmock_main.cc">
83
142
  <AdditionalIncludeDirectories Condition="'$(Configuration)|$(Platform)'=='Debug|Win32'">../../include;%(AdditionalIncludeDirectories)</AdditionalIncludeDirectories>
143
+ <AdditionalIncludeDirectories Condition="'$(Configuration)|$(Platform)'=='Debug|x64'">../../include;%(AdditionalIncludeDirectories)</AdditionalIncludeDirectories>
84
144
  <AdditionalIncludeDirectories Condition="'$(Configuration)|$(Platform)'=='Release|Win32'">../../include;%(AdditionalIncludeDirectories)</AdditionalIncludeDirectories>
145
+ <AdditionalIncludeDirectories Condition="'$(Configuration)|$(Platform)'=='Release|x64'">../../include;%(AdditionalIncludeDirectories)</AdditionalIncludeDirectories>
85
146
  </ClCompile>
86
147
  </ItemGroup>
87
148
  <Import Project="$(VCTargetsPath)\Microsoft.Cpp.targets" />
@@ -5,10 +5,18 @@
5
5
  <Configuration>Debug</Configuration>
6
6
  <Platform>Win32</Platform>
7
7
  </ProjectConfiguration>
8
+ <ProjectConfiguration Include="Debug|x64">
9
+ <Configuration>Debug</Configuration>
10
+ <Platform>x64</Platform>
11
+ </ProjectConfiguration>
8
12
  <ProjectConfiguration Include="Release|Win32">
9
13
  <Configuration>Release</Configuration>
10
14
  <Platform>Win32</Platform>
11
15
  </ProjectConfiguration>
16
+ <ProjectConfiguration Include="Release|x64">
17
+ <Configuration>Release</Configuration>
18
+ <Platform>x64</Platform>
19
+ </ProjectConfiguration>
12
20
  </ItemGroup>
13
21
  <PropertyGroup Label="Globals">
14
22
  <ProjectGuid>{F10D22F8-AC7B-4213-8720-608E7D878CD2}</ProjectGuid>
@@ -22,11 +30,22 @@
22
30
  <WholeProgramOptimization>true</WholeProgramOptimization>
23
31
  <PlatformToolset>v140</PlatformToolset>
24
32
  </PropertyGroup>
33
+ <PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Release|x64'" Label="Configuration">
34
+ <ConfigurationType>Application</ConfigurationType>
35
+ <CharacterSet>Unicode</CharacterSet>
36
+ <WholeProgramOptimization>true</WholeProgramOptimization>
37
+ <PlatformToolset>v140</PlatformToolset>
38
+ </PropertyGroup>
25
39
  <PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Debug|Win32'" Label="Configuration">
26
40
  <ConfigurationType>Application</ConfigurationType>
27
41
  <CharacterSet>Unicode</CharacterSet>
28
42
  <PlatformToolset>v140</PlatformToolset>
29
43
  </PropertyGroup>
44
+ <PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Debug|x64'" Label="Configuration">
45
+ <ConfigurationType>Application</ConfigurationType>
46
+ <CharacterSet>Unicode</CharacterSet>
47
+ <PlatformToolset>v140</PlatformToolset>
48
+ </PropertyGroup>
30
49
  <Import Project="$(VCTargetsPath)\Microsoft.Cpp.props" />
31
50
  <ImportGroup Label="ExtensionSettings">
32
51
  </ImportGroup>
@@ -34,19 +53,37 @@
34
53
  <Import Project="$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props" Condition="exists('$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props')" Label="LocalAppDataPlatform" />
35
54
  <Import Project="gmock_config.props" />
36
55
  </ImportGroup>
56
+ <ImportGroup Condition="'$(Configuration)|$(Platform)'=='Release|x64'" Label="PropertySheets">
57
+ <Import Project="$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props" Condition="exists('$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props')" Label="LocalAppDataPlatform" />
58
+ <Import Project="gmock_config.props" />
59
+ </ImportGroup>
37
60
  <ImportGroup Condition="'$(Configuration)|$(Platform)'=='Debug|Win32'" Label="PropertySheets">
38
61
  <Import Project="$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props" Condition="exists('$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props')" Label="LocalAppDataPlatform" />
39
62
  <Import Project="gmock_config.props" />
40
63
  </ImportGroup>
64
+ <ImportGroup Condition="'$(Configuration)|$(Platform)'=='Debug|x64'" Label="PropertySheets">
65
+ <Import Project="$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props" Condition="exists('$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props')" Label="LocalAppDataPlatform" />
66
+ <Import Project="gmock_config.props" />
67
+ </ImportGroup>
41
68
  <PropertyGroup Label="UserMacros" />
42
69
  <PropertyGroup>
43
70
  <_ProjectFileVersion>10.0.30319.1</_ProjectFileVersion>
44
- <OutDir Condition="'$(Configuration)|$(Platform)'=='Debug|Win32'">$(SolutionDir)$(Configuration)\</OutDir>
71
+ <OutDir Condition="'$(Configuration)|$(Platform)'=='Debug|Win32'">$(SolutionDir)$(Platform)-$(Configuration)\</OutDir>
45
72
  <IntDir Condition="'$(Configuration)|$(Platform)'=='Debug|Win32'">$(OutDir)$(ProjectName)\</IntDir>
46
73
  <LinkIncremental Condition="'$(Configuration)|$(Platform)'=='Debug|Win32'">true</LinkIncremental>
47
- <OutDir Condition="'$(Configuration)|$(Platform)'=='Release|Win32'">$(SolutionDir)$(Configuration)\</OutDir>
74
+ <LinkIncremental Condition="'$(Configuration)|$(Platform)'=='Debug|x64'">true</LinkIncremental>
75
+ <OutDir Condition="'$(Configuration)|$(Platform)'=='Release|Win32'">$(SolutionDir)$(Platform)-$(Configuration)\</OutDir>
48
76
  <IntDir Condition="'$(Configuration)|$(Platform)'=='Release|Win32'">$(OutDir)$(ProjectName)\</IntDir>
49
77
  <LinkIncremental Condition="'$(Configuration)|$(Platform)'=='Release|Win32'">false</LinkIncremental>
78
+ <LinkIncremental Condition="'$(Configuration)|$(Platform)'=='Release|x64'">false</LinkIncremental>
79
+ </PropertyGroup>
80
+ <PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Debug|x64'">
81
+ <OutDir>$(SolutionDir)$(Platform)-$(Configuration)\</OutDir>
82
+ <IntDir>$(OutDir)$(ProjectName)\</IntDir>
83
+ </PropertyGroup>
84
+ <PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Release|x64'">
85
+ <OutDir>$(SolutionDir)$(Platform)-$(Configuration)\</OutDir>
86
+ <IntDir>$(OutDir)$(ProjectName)\</IntDir>
50
87
  </PropertyGroup>
51
88
  <ItemDefinitionGroup Condition="'$(Configuration)|$(Platform)'=='Debug|Win32'">
52
89
  <ClCompile>
@@ -68,10 +105,28 @@
68
105
  <TargetMachine>MachineX86</TargetMachine>
69
106
  </Link>
70
107
  </ItemDefinitionGroup>
108
+ <ItemDefinitionGroup Condition="'$(Configuration)|$(Platform)'=='Debug|x64'">
109
+ <ClCompile>
110
+ <AdditionalOptions>/bigobj %(AdditionalOptions)</AdditionalOptions>
111
+ <Optimization>Disabled</Optimization>
112
+ <AdditionalIncludeDirectories>..\..\include;..\..;$(GTestDir);%(AdditionalIncludeDirectories)</AdditionalIncludeDirectories>
113
+ <PreprocessorDefinitions>WIN32;_DEBUG;_CONSOLE;%(PreprocessorDefinitions)</PreprocessorDefinitions>
114
+ <BasicRuntimeChecks>EnableFastChecks</BasicRuntimeChecks>
115
+ <RuntimeLibrary>MultiThreadedDebug</RuntimeLibrary>
116
+ <PrecompiledHeader>
117
+ </PrecompiledHeader>
118
+ <WarningLevel>Level3</WarningLevel>
119
+ <DebugInformationFormat>ProgramDatabase</DebugInformationFormat>
120
+ </ClCompile>
121
+ <Link>
122
+ <GenerateDebugInformation>true</GenerateDebugInformation>
123
+ <SubSystem>Console</SubSystem>
124
+ </Link>
125
+ </ItemDefinitionGroup>
71
126
  <ItemDefinitionGroup Condition="'$(Configuration)|$(Platform)'=='Release|Win32'">
72
127
  <ClCompile>
73
128
  <AdditionalOptions>/bigobj %(AdditionalOptions)</AdditionalOptions>
74
- <AdditionalIncludeDirectories>..\..\include;..\..;%(AdditionalIncludeDirectories)</AdditionalIncludeDirectories>
129
+ <AdditionalIncludeDirectories>..\..\include;..\..;$(GTestDir);%(AdditionalIncludeDirectories)</AdditionalIncludeDirectories>
75
130
  <PreprocessorDefinitions>WIN32;NDEBUG;_CONSOLE;%(PreprocessorDefinitions)</PreprocessorDefinitions>
76
131
  <RuntimeLibrary>MultiThreaded</RuntimeLibrary>
77
132
  <PrecompiledHeader>
@@ -87,6 +142,24 @@
87
142
  <TargetMachine>MachineX86</TargetMachine>
88
143
  </Link>
89
144
  </ItemDefinitionGroup>
145
+ <ItemDefinitionGroup Condition="'$(Configuration)|$(Platform)'=='Release|x64'">
146
+ <ClCompile>
147
+ <AdditionalOptions>/bigobj %(AdditionalOptions)</AdditionalOptions>
148
+ <AdditionalIncludeDirectories>..\..\include;..\..;$(GTestDir);%(AdditionalIncludeDirectories)</AdditionalIncludeDirectories>
149
+ <PreprocessorDefinitions>WIN32;NDEBUG;_CONSOLE;%(PreprocessorDefinitions)</PreprocessorDefinitions>
150
+ <RuntimeLibrary>MultiThreaded</RuntimeLibrary>
151
+ <PrecompiledHeader>
152
+ </PrecompiledHeader>
153
+ <WarningLevel>Level3</WarningLevel>
154
+ <DebugInformationFormat>ProgramDatabase</DebugInformationFormat>
155
+ </ClCompile>
156
+ <Link>
157
+ <GenerateDebugInformation>true</GenerateDebugInformation>
158
+ <SubSystem>Console</SubSystem>
159
+ <OptimizeReferences>true</OptimizeReferences>
160
+ <EnableCOMDATFolding>true</EnableCOMDATFolding>
161
+ </Link>
162
+ </ItemDefinitionGroup>
90
163
  <ItemGroup>
91
164
  <ProjectReference Include="gmock_main.vcxproj">
92
165
  <Project>{e4ef614b-30df-4954-8c53-580a0bf6b589}</Project>
@@ -55,7 +55,7 @@ EXAMPLES
55
55
  This tool is experimental. In particular, it assumes that there is no
56
56
  conditional inclusion of Google Mock or Google Test headers. Please
57
57
  report any problems to googlemock@googlegroups.com. You can read
58
- http://code.google.com/p/googlemock/wiki/CookBook for more
58
+ https://github.com/google/googletest/blob/master/googlemock/docs/CookBook.md for more
59
59
  information.
60
60
  """
61
61
 
@@ -1,11 +1,10 @@
1
1
 
2
2
  The Google Mock class generator is an application that is part of cppclean.
3
- For more information about cppclean, see the README.cppclean file or
4
- visit http://code.google.com/p/cppclean/
3
+ For more information about cppclean, visit http://code.google.com/p/cppclean/
5
4
 
6
- cppclean requires Python 2.3.5 or later. If you don't have Python installed
7
- on your system, you will also need to install it. You can download Python
8
- from: http://www.python.org/download/releases/
5
+ The mock generator requires Python 2.3.5 or later. If you don't have Python
6
+ installed on your system, you will also need to install it. You can download
7
+ Python from: http://www.python.org/download/releases/
9
8
 
10
9
  To use the Google Mock class generator, you need to call it
11
10
  on the command line passing the header file and class for which you want
@@ -338,7 +338,7 @@ class Class(_GenericDeclaration):
338
338
  # TODO(nnorwitz): handle namespaces, etc.
339
339
  if self.bases:
340
340
  for token_list in self.bases:
341
- # TODO(nnorwitz): bases are tokens, do name comparision.
341
+ # TODO(nnorwitz): bases are tokens, do name comparison.
342
342
  for token in token_list:
343
343
  if token.name == node.name:
344
344
  return True
@@ -381,7 +381,7 @@ class Function(_GenericDeclaration):
381
381
 
382
382
  def Requires(self, node):
383
383
  if self.parameters:
384
- # TODO(nnorwitz): parameters are tokens, do name comparision.
384
+ # TODO(nnorwitz): parameters are tokens, do name comparison.
385
385
  for p in self.parameters:
386
386
  if p.name == node.name:
387
387
  return True
@@ -858,7 +858,7 @@ class AstBuilder(object):
858
858
  last_token = self._GetNextToken()
859
859
  return tokens, last_token
860
860
 
861
- # TODO(nnorwitz): remove _IgnoreUpTo() it shouldn't be necesary.
861
+ # TODO(nnorwitz): remove _IgnoreUpTo() it shouldn't be necessary.
862
862
  def _IgnoreUpTo(self, token_type, token):
863
863
  unused_tokens = self._GetTokensUpTo(token_type, token)
864
864
 
@@ -92,7 +92,7 @@ class BetweenCardinalityImpl : public CardinalityInterface {
92
92
  };
93
93
 
94
94
  // Formats "n times" in a human-friendly way.
95
- inline internal::string FormatTimes(int n) {
95
+ inline std::string FormatTimes(int n) {
96
96
  if (n == 1) {
97
97
  return "once";
98
98
  } else if (n == 2) {
@@ -47,12 +47,31 @@
47
47
  namespace testing {
48
48
  namespace internal {
49
49
 
50
+ // Joins a vector of strings as if they are fields of a tuple; returns
51
+ // the joined string.
52
+ GTEST_API_ std::string JoinAsTuple(const Strings& fields) {
53
+ switch (fields.size()) {
54
+ case 0:
55
+ return "";
56
+ case 1:
57
+ return fields[0];
58
+ default:
59
+ std::string result = "(" + fields[0];
60
+ for (size_t i = 1; i < fields.size(); i++) {
61
+ result += ", ";
62
+ result += fields[i];
63
+ }
64
+ result += ")";
65
+ return result;
66
+ }
67
+ }
68
+
50
69
  // Converts an identifier name to a space-separated list of lower-case
51
70
  // words. Each maximum substring of the form [A-Za-z][a-z]*|\d+ is
52
71
  // treated as one word. For example, both "FooBar123" and
53
72
  // "foo_bar_123" are converted to "foo bar 123".
54
- GTEST_API_ string ConvertIdentifierNameToWords(const char* id_name) {
55
- string result;
73
+ GTEST_API_ std::string ConvertIdentifierNameToWords(const char* id_name) {
74
+ std::string result;
56
75
  char prev_char = '\0';
57
76
  for (const char* p = id_name; *p != '\0'; prev_char = *(p++)) {
58
77
  // We don't care about the current locale as the input is
@@ -71,12 +90,12 @@ GTEST_API_ string ConvertIdentifierNameToWords(const char* id_name) {
71
90
  }
72
91
 
73
92
  // This class reports Google Mock failures as Google Test failures. A
74
- // user can define another class in a similar fashion if he intends to
93
+ // user can define another class in a similar fashion if they intend to
75
94
  // use Google Mock with a testing framework other than Google Test.
76
95
  class GoogleTestFailureReporter : public FailureReporterInterface {
77
96
  public:
78
97
  virtual void ReportFailure(FailureType type, const char* file, int line,
79
- const string& message) {
98
+ const std::string& message) {
80
99
  AssertHelper(type == kFatal ?
81
100
  TestPartResult::kFatalFailure :
82
101
  TestPartResult::kNonFatalFailure,
@@ -128,8 +147,7 @@ GTEST_API_ bool LogIsVisible(LogSeverity severity) {
128
147
  // stack_frames_to_skip is treated as 0, since we don't know which
129
148
  // function calls will be inlined by the compiler and need to be
130
149
  // conservative.
131
- GTEST_API_ void Log(LogSeverity severity,
132
- const string& message,
150
+ GTEST_API_ void Log(LogSeverity severity, const std::string& message,
133
151
  int stack_frames_to_skip) {
134
152
  if (!LogIsVisible(severity))
135
153
  return;
@@ -170,5 +188,17 @@ GTEST_API_ void Log(LogSeverity severity,
170
188
  std::cout << ::std::flush;
171
189
  }
172
190
 
191
+ GTEST_API_ WithoutMatchers GetWithoutMatchers() { return WithoutMatchers(); }
192
+
193
+ GTEST_API_ void IllegalDoDefault(const char* file, int line) {
194
+ internal::Assert(
195
+ false, file, line,
196
+ "You are using DoDefault() inside a composite action like "
197
+ "DoAll() or WithArgs(). This is not supported for technical "
198
+ "reasons. Please instead spell out the default action, or "
199
+ "assign the default action to an Action variable and use "
200
+ "the variable in various places.");
201
+ }
202
+
173
203
  } // namespace internal
174
204
  } // namespace testing
@@ -38,98 +38,133 @@
38
38
  #include "gmock/gmock-generated-matchers.h"
39
39
 
40
40
  #include <string.h>
41
+ #include <iostream>
41
42
  #include <sstream>
42
43
  #include <string>
43
44
 
44
45
  namespace testing {
45
46
 
46
- // Constructs a matcher that matches a const string& whose value is
47
+ // Constructs a matcher that matches a const std::string& whose value is
47
48
  // equal to s.
48
- Matcher<const internal::string&>::Matcher(const internal::string& s) {
49
- *this = Eq(s);
49
+ Matcher<const std::string&>::Matcher(const std::string& s) { *this = Eq(s); }
50
+
51
+ #if GTEST_HAS_GLOBAL_STRING
52
+ // Constructs a matcher that matches a const std::string& whose value is
53
+ // equal to s.
54
+ Matcher<const std::string&>::Matcher(const ::string& s) {
55
+ *this = Eq(static_cast<std::string>(s));
50
56
  }
57
+ #endif // GTEST_HAS_GLOBAL_STRING
51
58
 
52
- // Constructs a matcher that matches a const string& whose value is
59
+ // Constructs a matcher that matches a const std::string& whose value is
53
60
  // equal to s.
54
- Matcher<const internal::string&>::Matcher(const char* s) {
55
- *this = Eq(internal::string(s));
61
+ Matcher<const std::string&>::Matcher(const char* s) {
62
+ *this = Eq(std::string(s));
56
63
  }
57
64
 
58
- // Constructs a matcher that matches a string whose value is equal to s.
59
- Matcher<internal::string>::Matcher(const internal::string& s) { *this = Eq(s); }
65
+ // Constructs a matcher that matches a std::string whose value is equal to
66
+ // s.
67
+ Matcher<std::string>::Matcher(const std::string& s) { *this = Eq(s); }
60
68
 
61
- // Constructs a matcher that matches a string whose value is equal to s.
62
- Matcher<internal::string>::Matcher(const char* s) {
63
- *this = Eq(internal::string(s));
69
+ #if GTEST_HAS_GLOBAL_STRING
70
+ // Constructs a matcher that matches a std::string whose value is equal to
71
+ // s.
72
+ Matcher<std::string>::Matcher(const ::string& s) {
73
+ *this = Eq(static_cast<std::string>(s));
64
74
  }
75
+ #endif // GTEST_HAS_GLOBAL_STRING
76
+
77
+ // Constructs a matcher that matches a std::string whose value is equal to
78
+ // s.
79
+ Matcher<std::string>::Matcher(const char* s) { *this = Eq(std::string(s)); }
65
80
 
66
- #if GTEST_HAS_STRING_PIECE_
67
- // Constructs a matcher that matches a const StringPiece& whose value is
81
+ #if GTEST_HAS_GLOBAL_STRING
82
+ // Constructs a matcher that matches a const ::string& whose value is
68
83
  // equal to s.
69
- Matcher<const StringPiece&>::Matcher(const internal::string& s) {
70
- *this = Eq(s);
84
+ Matcher<const ::string&>::Matcher(const std::string& s) {
85
+ *this = Eq(static_cast<::string>(s));
71
86
  }
72
87
 
73
- // Constructs a matcher that matches a const StringPiece& whose value is
88
+ // Constructs a matcher that matches a const ::string& whose value is
74
89
  // equal to s.
75
- Matcher<const StringPiece&>::Matcher(const char* s) {
76
- *this = Eq(internal::string(s));
77
- }
90
+ Matcher<const ::string&>::Matcher(const ::string& s) { *this = Eq(s); }
78
91
 
79
- // Constructs a matcher that matches a const StringPiece& whose value is
92
+ // Constructs a matcher that matches a const ::string& whose value is
80
93
  // equal to s.
81
- Matcher<const StringPiece&>::Matcher(StringPiece s) {
82
- *this = Eq(s.ToString());
94
+ Matcher<const ::string&>::Matcher(const char* s) { *this = Eq(::string(s)); }
95
+
96
+ // Constructs a matcher that matches a ::string whose value is equal to s.
97
+ Matcher<::string>::Matcher(const std::string& s) {
98
+ *this = Eq(static_cast<::string>(s));
83
99
  }
84
100
 
85
- // Constructs a matcher that matches a StringPiece whose value is equal to s.
86
- Matcher<StringPiece>::Matcher(const internal::string& s) {
101
+ // Constructs a matcher that matches a ::string whose value is equal to s.
102
+ Matcher<::string>::Matcher(const ::string& s) { *this = Eq(s); }
103
+
104
+ // Constructs a matcher that matches a string whose value is equal to s.
105
+ Matcher<::string>::Matcher(const char* s) { *this = Eq(::string(s)); }
106
+ #endif // GTEST_HAS_GLOBAL_STRING
107
+
108
+ #if GTEST_HAS_ABSL
109
+ // Constructs a matcher that matches a const absl::string_view& whose value is
110
+ // equal to s.
111
+ Matcher<const absl::string_view&>::Matcher(const std::string& s) {
87
112
  *this = Eq(s);
88
113
  }
89
114
 
90
- // Constructs a matcher that matches a StringPiece whose value is equal to s.
91
- Matcher<StringPiece>::Matcher(const char* s) {
92
- *this = Eq(internal::string(s));
115
+ #if GTEST_HAS_GLOBAL_STRING
116
+ // Constructs a matcher that matches a const absl::string_view& whose value is
117
+ // equal to s.
118
+ Matcher<const absl::string_view&>::Matcher(const ::string& s) { *this = Eq(s); }
119
+ #endif // GTEST_HAS_GLOBAL_STRING
120
+
121
+ // Constructs a matcher that matches a const absl::string_view& whose value is
122
+ // equal to s.
123
+ Matcher<const absl::string_view&>::Matcher(const char* s) {
124
+ *this = Eq(std::string(s));
93
125
  }
94
126
 
95
- // Constructs a matcher that matches a StringPiece whose value is equal to s.
96
- Matcher<StringPiece>::Matcher(StringPiece s) {
97
- *this = Eq(s.ToString());
127
+ // Constructs a matcher that matches a const absl::string_view& whose value is
128
+ // equal to s.
129
+ Matcher<const absl::string_view&>::Matcher(absl::string_view s) {
130
+ *this = Eq(std::string(s));
98
131
  }
99
- #endif // GTEST_HAS_STRING_PIECE_
100
132
 
101
- namespace internal {
133
+ // Constructs a matcher that matches a absl::string_view whose value is equal to
134
+ // s.
135
+ Matcher<absl::string_view>::Matcher(const std::string& s) { *this = Eq(s); }
102
136
 
103
- // Joins a vector of strings as if they are fields of a tuple; returns
104
- // the joined string.
105
- GTEST_API_ string JoinAsTuple(const Strings& fields) {
106
- switch (fields.size()) {
107
- case 0:
108
- return "";
109
- case 1:
110
- return fields[0];
111
- default:
112
- string result = "(" + fields[0];
113
- for (size_t i = 1; i < fields.size(); i++) {
114
- result += ", ";
115
- result += fields[i];
116
- }
117
- result += ")";
118
- return result;
119
- }
137
+ #if GTEST_HAS_GLOBAL_STRING
138
+ // Constructs a matcher that matches a absl::string_view whose value is equal to
139
+ // s.
140
+ Matcher<absl::string_view>::Matcher(const ::string& s) { *this = Eq(s); }
141
+ #endif // GTEST_HAS_GLOBAL_STRING
142
+
143
+ // Constructs a matcher that matches a absl::string_view whose value is equal to
144
+ // s.
145
+ Matcher<absl::string_view>::Matcher(const char* s) {
146
+ *this = Eq(std::string(s));
147
+ }
148
+
149
+ // Constructs a matcher that matches a absl::string_view whose value is equal to
150
+ // s.
151
+ Matcher<absl::string_view>::Matcher(absl::string_view s) {
152
+ *this = Eq(std::string(s));
120
153
  }
154
+ #endif // GTEST_HAS_ABSL
155
+
156
+ namespace internal {
121
157
 
122
158
  // Returns the description for a matcher defined using the MATCHER*()
123
159
  // macro where the user-supplied description string is "", if
124
160
  // 'negation' is false; otherwise returns the description of the
125
161
  // negation of the matcher. 'param_values' contains a list of strings
126
162
  // that are the print-out of the matcher's parameters.
127
- GTEST_API_ string FormatMatcherDescription(bool negation,
128
- const char* matcher_name,
129
- const Strings& param_values) {
130
- string result = ConvertIdentifierNameToWords(matcher_name);
131
- if (param_values.size() >= 1)
132
- result += " " + JoinAsTuple(param_values);
163
+ GTEST_API_ std::string FormatMatcherDescription(bool negation,
164
+ const char* matcher_name,
165
+ const Strings& param_values) {
166
+ std::string result = ConvertIdentifierNameToWords(matcher_name);
167
+ if (param_values.size() >= 1) result += " " + JoinAsTuple(param_values);
133
168
  return negation ? "not (" + result + ")" : result;
134
169
  }
135
170
 
@@ -200,8 +235,7 @@ class MaxBipartiteMatchState {
200
235
  explicit MaxBipartiteMatchState(const MatchMatrix& graph)
201
236
  : graph_(&graph),
202
237
  left_(graph_->LhsSize(), kUnused),
203
- right_(graph_->RhsSize(), kUnused) {
204
- }
238
+ right_(graph_->RhsSize(), kUnused) {}
205
239
 
206
240
  // Returns the edges of a maximal match, each in the form {left, right}.
207
241
  ElementMatcherPairs Compute() {
@@ -258,10 +292,8 @@ class MaxBipartiteMatchState {
258
292
  //
259
293
  bool TryAugment(size_t ilhs, ::std::vector<char>* seen) {
260
294
  for (size_t irhs = 0; irhs < graph_->RhsSize(); ++irhs) {
261
- if ((*seen)[irhs])
262
- continue;
263
- if (!graph_->HasEdge(ilhs, irhs))
264
- continue;
295
+ if ((*seen)[irhs]) continue;
296
+ if (!graph_->HasEdge(ilhs, irhs)) continue;
265
297
  // There's an available edge from ilhs to irhs.
266
298
  (*seen)[irhs] = 1;
267
299
  // Next a search is performed to determine whether
@@ -288,7 +320,7 @@ class MaxBipartiteMatchState {
288
320
  // Each element of the left_ vector represents a left hand side node
289
321
  // (i.e. an element) and each element of right_ is a right hand side
290
322
  // node (i.e. a matcher). The values in the left_ vector indicate
291
- // outflow from that node to a node on the the right_ side. The values
323
+ // outflow from that node to a node on the right_ side. The values
292
324
  // in the right_ indicate inflow, and specify which left_ node is
293
325
  // feeding that right_ node, if any. For example, left_[3] == 1 means
294
326
  // there's a flow from element #3 to matcher #1. Such a flow would also
@@ -304,8 +336,7 @@ class MaxBipartiteMatchState {
304
336
 
305
337
  const size_t MaxBipartiteMatchState::kUnused;
306
338
 
307
- GTEST_API_ ElementMatcherPairs
308
- FindMaxBipartiteMatching(const MatchMatrix& g) {
339
+ GTEST_API_ ElementMatcherPairs FindMaxBipartiteMatching(const MatchMatrix& g) {
309
340
  return MaxBipartiteMatchState(g).Compute();
310
341
  }
311
342
 
@@ -314,7 +345,7 @@ static void LogElementMatcherPairVec(const ElementMatcherPairs& pairs,
314
345
  typedef ElementMatcherPairs::const_iterator Iter;
315
346
  ::std::ostream& os = *stream;
316
347
  os << "{";
317
- const char *sep = "";
348
+ const char* sep = "";
318
349
  for (Iter it = pairs.begin(); it != pairs.end(); ++it) {
319
350
  os << sep << "\n ("
320
351
  << "element #" << it->first << ", "
@@ -324,38 +355,6 @@ static void LogElementMatcherPairVec(const ElementMatcherPairs& pairs,
324
355
  os << "\n}";
325
356
  }
326
357
 
327
- // Tries to find a pairing, and explains the result.
328
- GTEST_API_ bool FindPairing(const MatchMatrix& matrix,
329
- MatchResultListener* listener) {
330
- ElementMatcherPairs matches = FindMaxBipartiteMatching(matrix);
331
-
332
- size_t max_flow = matches.size();
333
- bool result = (max_flow == matrix.RhsSize());
334
-
335
- if (!result) {
336
- if (listener->IsInterested()) {
337
- *listener << "where no permutation of the elements can "
338
- "satisfy all matchers, and the closest match is "
339
- << max_flow << " of " << matrix.RhsSize()
340
- << " matchers with the pairings:\n";
341
- LogElementMatcherPairVec(matches, listener->stream());
342
- }
343
- return false;
344
- }
345
-
346
- if (matches.size() > 1) {
347
- if (listener->IsInterested()) {
348
- const char *sep = "where:\n";
349
- for (size_t mi = 0; mi < matches.size(); ++mi) {
350
- *listener << sep << " - element #" << matches[mi].first
351
- << " is matched by matcher #" << matches[mi].second;
352
- sep = ",\n";
353
- }
354
- }
355
- }
356
- return true;
357
- }
358
-
359
358
  bool MatchMatrix::NextGraph() {
360
359
  for (size_t ilhs = 0; ilhs < LhsSize(); ++ilhs) {
361
360
  for (size_t irhs = 0; irhs < RhsSize(); ++irhs) {
@@ -379,9 +378,9 @@ void MatchMatrix::Randomize() {
379
378
  }
380
379
  }
381
380
 
382
- string MatchMatrix::DebugString() const {
381
+ std::string MatchMatrix::DebugString() const {
383
382
  ::std::stringstream ss;
384
- const char *sep = "";
383
+ const char* sep = "";
385
384
  for (size_t i = 0; i < LhsSize(); ++i) {
386
385
  ss << sep;
387
386
  for (size_t j = 0; j < RhsSize(); ++j) {
@@ -394,44 +393,83 @@ string MatchMatrix::DebugString() const {
394
393
 
395
394
  void UnorderedElementsAreMatcherImplBase::DescribeToImpl(
396
395
  ::std::ostream* os) const {
397
- if (matcher_describers_.empty()) {
398
- *os << "is empty";
399
- return;
400
- }
401
- if (matcher_describers_.size() == 1) {
402
- *os << "has " << Elements(1) << " and that element ";
403
- matcher_describers_[0]->DescribeTo(os);
404
- return;
396
+ switch (match_flags()) {
397
+ case UnorderedMatcherRequire::ExactMatch:
398
+ if (matcher_describers_.empty()) {
399
+ *os << "is empty";
400
+ return;
401
+ }
402
+ if (matcher_describers_.size() == 1) {
403
+ *os << "has " << Elements(1) << " and that element ";
404
+ matcher_describers_[0]->DescribeTo(os);
405
+ return;
406
+ }
407
+ *os << "has " << Elements(matcher_describers_.size())
408
+ << " and there exists some permutation of elements such that:\n";
409
+ break;
410
+ case UnorderedMatcherRequire::Superset:
411
+ *os << "a surjection from elements to requirements exists such that:\n";
412
+ break;
413
+ case UnorderedMatcherRequire::Subset:
414
+ *os << "an injection from elements to requirements exists such that:\n";
415
+ break;
405
416
  }
406
- *os << "has " << Elements(matcher_describers_.size())
407
- << " and there exists some permutation of elements such that:\n";
417
+
408
418
  const char* sep = "";
409
419
  for (size_t i = 0; i != matcher_describers_.size(); ++i) {
410
- *os << sep << " - element #" << i << " ";
420
+ *os << sep;
421
+ if (match_flags() == UnorderedMatcherRequire::ExactMatch) {
422
+ *os << " - element #" << i << " ";
423
+ } else {
424
+ *os << " - an element ";
425
+ }
411
426
  matcher_describers_[i]->DescribeTo(os);
412
- sep = ", and\n";
427
+ if (match_flags() == UnorderedMatcherRequire::ExactMatch) {
428
+ sep = ", and\n";
429
+ } else {
430
+ sep = "\n";
431
+ }
413
432
  }
414
433
  }
415
434
 
416
435
  void UnorderedElementsAreMatcherImplBase::DescribeNegationToImpl(
417
436
  ::std::ostream* os) const {
418
- if (matcher_describers_.empty()) {
419
- *os << "isn't empty";
420
- return;
421
- }
422
- if (matcher_describers_.size() == 1) {
423
- *os << "doesn't have " << Elements(1)
424
- << ", or has " << Elements(1) << " that ";
425
- matcher_describers_[0]->DescribeNegationTo(os);
426
- return;
437
+ switch (match_flags()) {
438
+ case UnorderedMatcherRequire::ExactMatch:
439
+ if (matcher_describers_.empty()) {
440
+ *os << "isn't empty";
441
+ return;
442
+ }
443
+ if (matcher_describers_.size() == 1) {
444
+ *os << "doesn't have " << Elements(1) << ", or has " << Elements(1)
445
+ << " that ";
446
+ matcher_describers_[0]->DescribeNegationTo(os);
447
+ return;
448
+ }
449
+ *os << "doesn't have " << Elements(matcher_describers_.size())
450
+ << ", or there exists no permutation of elements such that:\n";
451
+ break;
452
+ case UnorderedMatcherRequire::Superset:
453
+ *os << "no surjection from elements to requirements exists such that:\n";
454
+ break;
455
+ case UnorderedMatcherRequire::Subset:
456
+ *os << "no injection from elements to requirements exists such that:\n";
457
+ break;
427
458
  }
428
- *os << "doesn't have " << Elements(matcher_describers_.size())
429
- << ", or there exists no permutation of elements such that:\n";
430
459
  const char* sep = "";
431
460
  for (size_t i = 0; i != matcher_describers_.size(); ++i) {
432
- *os << sep << " - element #" << i << " ";
461
+ *os << sep;
462
+ if (match_flags() == UnorderedMatcherRequire::ExactMatch) {
463
+ *os << " - element #" << i << " ";
464
+ } else {
465
+ *os << " - an element ";
466
+ }
433
467
  matcher_describers_[i]->DescribeTo(os);
434
- sep = ", and\n";
468
+ if (match_flags() == UnorderedMatcherRequire::ExactMatch) {
469
+ sep = ", and\n";
470
+ } else {
471
+ sep = "\n";
472
+ }
435
473
  }
436
474
  }
437
475
 
@@ -440,11 +478,9 @@ void UnorderedElementsAreMatcherImplBase::DescribeNegationToImpl(
440
478
  // and better error reporting.
441
479
  // Returns false, writing an explanation to 'listener', if and only
442
480
  // if the success criteria are not met.
443
- bool UnorderedElementsAreMatcherImplBase::
444
- VerifyAllElementsAndMatchersAreMatched(
445
- const ::std::vector<string>& element_printouts,
446
- const MatchMatrix& matrix,
447
- MatchResultListener* listener) const {
481
+ bool UnorderedElementsAreMatcherImplBase::VerifyMatchMatrix(
482
+ const ::std::vector<std::string>& element_printouts,
483
+ const MatchMatrix& matrix, MatchResultListener* listener) const {
448
484
  bool result = true;
449
485
  ::std::vector<char> element_matched(matrix.LhsSize(), 0);
450
486
  ::std::vector<char> matcher_matched(matrix.RhsSize(), 0);
@@ -457,12 +493,11 @@ VerifyAllElementsAndMatchersAreMatched(
457
493
  }
458
494
  }
459
495
 
460
- {
496
+ if (match_flags() & UnorderedMatcherRequire::Superset) {
461
497
  const char* sep =
462
498
  "where the following matchers don't match any elements:\n";
463
499
  for (size_t mi = 0; mi < matcher_matched.size(); ++mi) {
464
- if (matcher_matched[mi])
465
- continue;
500
+ if (matcher_matched[mi]) continue;
466
501
  result = false;
467
502
  if (listener->IsInterested()) {
468
503
  *listener << sep << "matcher #" << mi << ": ";
@@ -472,7 +507,7 @@ VerifyAllElementsAndMatchersAreMatched(
472
507
  }
473
508
  }
474
509
 
475
- {
510
+ if (match_flags() & UnorderedMatcherRequire::Subset) {
476
511
  const char* sep =
477
512
  "where the following elements don't match any matchers:\n";
478
513
  const char* outer_sep = "";
@@ -480,8 +515,7 @@ VerifyAllElementsAndMatchersAreMatched(
480
515
  outer_sep = "\nand ";
481
516
  }
482
517
  for (size_t ei = 0; ei < element_matched.size(); ++ei) {
483
- if (element_matched[ei])
484
- continue;
518
+ if (element_matched[ei]) continue;
485
519
  result = false;
486
520
  if (listener->IsInterested()) {
487
521
  *listener << outer_sep << sep << "element #" << ei << ": "
@@ -494,5 +528,46 @@ VerifyAllElementsAndMatchersAreMatched(
494
528
  return result;
495
529
  }
496
530
 
531
+ bool UnorderedElementsAreMatcherImplBase::FindPairing(
532
+ const MatchMatrix& matrix, MatchResultListener* listener) const {
533
+ ElementMatcherPairs matches = FindMaxBipartiteMatching(matrix);
534
+
535
+ size_t max_flow = matches.size();
536
+ if ((match_flags() & UnorderedMatcherRequire::Superset) &&
537
+ max_flow < matrix.RhsSize()) {
538
+ if (listener->IsInterested()) {
539
+ *listener << "where no permutation of the elements can satisfy all "
540
+ "matchers, and the closest match is "
541
+ << max_flow << " of " << matrix.RhsSize()
542
+ << " matchers with the pairings:\n";
543
+ LogElementMatcherPairVec(matches, listener->stream());
544
+ }
545
+ return false;
546
+ }
547
+ if ((match_flags() & UnorderedMatcherRequire::Subset) &&
548
+ max_flow < matrix.LhsSize()) {
549
+ if (listener->IsInterested()) {
550
+ *listener
551
+ << "where not all elements can be matched, and the closest match is "
552
+ << max_flow << " of " << matrix.RhsSize()
553
+ << " matchers with the pairings:\n";
554
+ LogElementMatcherPairVec(matches, listener->stream());
555
+ }
556
+ return false;
557
+ }
558
+
559
+ if (matches.size() > 1) {
560
+ if (listener->IsInterested()) {
561
+ const char* sep = "where:\n";
562
+ for (size_t mi = 0; mi < matches.size(); ++mi) {
563
+ *listener << sep << " - element #" << matches[mi].first
564
+ << " is matched by matcher #" << matches[mi].second;
565
+ sep = ",\n";
566
+ }
567
+ }
568
+ }
569
+ return true;
570
+ }
571
+
497
572
  } // namespace internal
498
573
  } // namespace testing