rj_schema 0.0.1 → 0.0.2

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (323) hide show
  1. checksums.yaml +5 -5
  2. data/Rakefile +4 -0
  3. data/ext/rj_schema/rapidjson/thirdparty/gtest/CMakeLists.txt +16 -0
  4. data/ext/rj_schema/rapidjson/thirdparty/gtest/README.md +141 -0
  5. data/ext/rj_schema/rapidjson/thirdparty/gtest/googlemock/CHANGES +126 -0
  6. data/ext/rj_schema/rapidjson/thirdparty/gtest/googlemock/CMakeLists.txt +202 -0
  7. data/ext/rj_schema/rapidjson/thirdparty/gtest/googlemock/CONTRIBUTORS +40 -0
  8. data/ext/rj_schema/rapidjson/thirdparty/gtest/googlemock/LICENSE +28 -0
  9. data/ext/rj_schema/rapidjson/thirdparty/gtest/googlemock/Makefile.am +224 -0
  10. data/ext/rj_schema/rapidjson/thirdparty/gtest/googlemock/README.md +333 -0
  11. data/ext/rj_schema/rapidjson/thirdparty/gtest/googlemock/configure.ac +146 -0
  12. data/ext/rj_schema/rapidjson/thirdparty/gtest/googlemock/docs/CheatSheet.md +562 -0
  13. data/ext/rj_schema/rapidjson/thirdparty/gtest/googlemock/docs/CookBook.md +3675 -0
  14. data/ext/rj_schema/rapidjson/thirdparty/gtest/googlemock/docs/DesignDoc.md +280 -0
  15. data/ext/rj_schema/rapidjson/thirdparty/gtest/googlemock/docs/DevGuide.md +132 -0
  16. data/ext/rj_schema/rapidjson/thirdparty/gtest/googlemock/docs/Documentation.md +12 -0
  17. data/ext/rj_schema/rapidjson/thirdparty/gtest/googlemock/docs/ForDummies.md +439 -0
  18. data/ext/rj_schema/rapidjson/thirdparty/gtest/googlemock/docs/FrequentlyAskedQuestions.md +628 -0
  19. data/ext/rj_schema/rapidjson/thirdparty/gtest/googlemock/docs/KnownIssues.md +19 -0
  20. data/ext/rj_schema/rapidjson/thirdparty/gtest/googlemock/docs/v1_5/CheatSheet.md +525 -0
  21. data/ext/rj_schema/rapidjson/thirdparty/gtest/googlemock/docs/v1_5/CookBook.md +3250 -0
  22. data/ext/rj_schema/rapidjson/thirdparty/gtest/googlemock/docs/v1_5/Documentation.md +11 -0
  23. data/ext/rj_schema/rapidjson/thirdparty/gtest/googlemock/docs/v1_5/ForDummies.md +439 -0
  24. data/ext/rj_schema/rapidjson/thirdparty/gtest/googlemock/docs/v1_5/FrequentlyAskedQuestions.md +624 -0
  25. data/ext/rj_schema/rapidjson/thirdparty/gtest/googlemock/docs/v1_6/CheatSheet.md +534 -0
  26. data/ext/rj_schema/rapidjson/thirdparty/gtest/googlemock/docs/v1_6/CookBook.md +3342 -0
  27. data/ext/rj_schema/rapidjson/thirdparty/gtest/googlemock/docs/v1_6/Documentation.md +12 -0
  28. data/ext/rj_schema/rapidjson/thirdparty/gtest/googlemock/docs/v1_6/ForDummies.md +439 -0
  29. data/ext/rj_schema/rapidjson/thirdparty/gtest/googlemock/docs/v1_6/FrequentlyAskedQuestions.md +628 -0
  30. data/ext/rj_schema/rapidjson/thirdparty/gtest/googlemock/docs/v1_7/CheatSheet.md +556 -0
  31. data/ext/rj_schema/rapidjson/thirdparty/gtest/googlemock/docs/v1_7/CookBook.md +3432 -0
  32. data/ext/rj_schema/rapidjson/thirdparty/gtest/googlemock/docs/v1_7/Documentation.md +12 -0
  33. data/ext/rj_schema/rapidjson/thirdparty/gtest/googlemock/docs/v1_7/ForDummies.md +439 -0
  34. data/ext/rj_schema/rapidjson/thirdparty/gtest/googlemock/docs/v1_7/FrequentlyAskedQuestions.md +628 -0
  35. data/ext/rj_schema/rapidjson/thirdparty/gtest/googlemock/include/gmock/gmock-actions.h +1205 -0
  36. data/ext/rj_schema/rapidjson/thirdparty/gtest/googlemock/include/gmock/gmock-cardinalities.h +147 -0
  37. data/ext/rj_schema/rapidjson/thirdparty/gtest/googlemock/include/gmock/gmock-generated-actions.h +2377 -0
  38. data/ext/rj_schema/rapidjson/thirdparty/gtest/googlemock/include/gmock/gmock-generated-actions.h.pump +794 -0
  39. data/ext/rj_schema/rapidjson/thirdparty/gtest/googlemock/include/gmock/gmock-generated-function-mockers.h +1095 -0
  40. data/ext/rj_schema/rapidjson/thirdparty/gtest/googlemock/include/gmock/gmock-generated-function-mockers.h.pump +291 -0
  41. data/ext/rj_schema/rapidjson/thirdparty/gtest/googlemock/include/gmock/gmock-generated-matchers.h +2179 -0
  42. data/ext/rj_schema/rapidjson/thirdparty/gtest/googlemock/include/gmock/gmock-generated-matchers.h.pump +672 -0
  43. data/ext/rj_schema/rapidjson/thirdparty/gtest/googlemock/include/gmock/gmock-generated-nice-strict.h +397 -0
  44. data/ext/rj_schema/rapidjson/thirdparty/gtest/googlemock/include/gmock/gmock-generated-nice-strict.h.pump +161 -0
  45. data/ext/rj_schema/rapidjson/thirdparty/gtest/googlemock/include/gmock/gmock-matchers.h +4399 -0
  46. data/ext/rj_schema/rapidjson/thirdparty/gtest/googlemock/include/gmock/gmock-more-actions.h +246 -0
  47. data/ext/rj_schema/rapidjson/thirdparty/gtest/googlemock/include/gmock/gmock-more-matchers.h +58 -0
  48. data/ext/rj_schema/rapidjson/thirdparty/gtest/googlemock/include/gmock/gmock-spec-builders.h +1847 -0
  49. data/ext/rj_schema/rapidjson/thirdparty/gtest/googlemock/include/gmock/gmock.h +94 -0
  50. data/ext/rj_schema/rapidjson/thirdparty/gtest/googlemock/include/gmock/internal/custom/gmock-generated-actions.h +8 -0
  51. data/ext/rj_schema/rapidjson/thirdparty/gtest/googlemock/include/gmock/internal/custom/gmock-generated-actions.h.pump +10 -0
  52. data/ext/rj_schema/rapidjson/thirdparty/gtest/googlemock/include/gmock/internal/custom/gmock-matchers.h +39 -0
  53. data/ext/rj_schema/rapidjson/thirdparty/gtest/googlemock/include/gmock/internal/custom/gmock-port.h +46 -0
  54. data/ext/rj_schema/rapidjson/thirdparty/gtest/googlemock/include/gmock/internal/gmock-generated-internal-utils.h +279 -0
  55. data/ext/rj_schema/rapidjson/thirdparty/gtest/googlemock/include/gmock/internal/gmock-generated-internal-utils.h.pump +136 -0
  56. data/ext/rj_schema/rapidjson/thirdparty/gtest/googlemock/include/gmock/internal/gmock-internal-utils.h +511 -0
  57. data/ext/rj_schema/rapidjson/thirdparty/gtest/googlemock/include/gmock/internal/gmock-port.h +91 -0
  58. data/ext/rj_schema/rapidjson/thirdparty/gtest/googlemock/make/Makefile +101 -0
  59. data/ext/rj_schema/rapidjson/thirdparty/gtest/googlemock/msvc/2005/gmock.sln +32 -0
  60. data/ext/rj_schema/rapidjson/thirdparty/gtest/googlemock/msvc/2005/gmock.vcproj +191 -0
  61. data/ext/rj_schema/rapidjson/thirdparty/gtest/googlemock/msvc/2005/gmock_config.vsprops +15 -0
  62. data/ext/rj_schema/rapidjson/thirdparty/gtest/googlemock/msvc/2005/gmock_main.vcproj +187 -0
  63. data/ext/rj_schema/rapidjson/thirdparty/gtest/googlemock/msvc/2005/gmock_test.vcproj +201 -0
  64. data/ext/rj_schema/rapidjson/thirdparty/gtest/googlemock/msvc/2010/gmock.sln +32 -0
  65. data/ext/rj_schema/rapidjson/thirdparty/gtest/googlemock/msvc/2010/gmock.vcxproj +82 -0
  66. data/ext/rj_schema/rapidjson/thirdparty/gtest/googlemock/msvc/2010/gmock_config.props +19 -0
  67. data/ext/rj_schema/rapidjson/thirdparty/gtest/googlemock/msvc/2010/gmock_main.vcxproj +88 -0
  68. data/ext/rj_schema/rapidjson/thirdparty/gtest/googlemock/msvc/2010/gmock_test.vcxproj +101 -0
  69. data/ext/rj_schema/rapidjson/thirdparty/gtest/googlemock/msvc/2015/gmock.sln +32 -0
  70. data/ext/rj_schema/rapidjson/thirdparty/gtest/googlemock/msvc/2015/gmock.vcxproj +84 -0
  71. data/ext/rj_schema/rapidjson/thirdparty/gtest/googlemock/msvc/2015/gmock_config.props +19 -0
  72. data/ext/rj_schema/rapidjson/thirdparty/gtest/googlemock/msvc/2015/gmock_main.vcxproj +90 -0
  73. data/ext/rj_schema/rapidjson/thirdparty/gtest/googlemock/msvc/2015/gmock_test.vcxproj +103 -0
  74. data/ext/rj_schema/rapidjson/thirdparty/gtest/googlemock/scripts/fuse_gmock_files.py +240 -0
  75. data/ext/rj_schema/rapidjson/thirdparty/gtest/googlemock/scripts/generator/LICENSE +203 -0
  76. data/ext/rj_schema/rapidjson/thirdparty/gtest/googlemock/scripts/generator/README +35 -0
  77. data/ext/rj_schema/rapidjson/thirdparty/gtest/googlemock/scripts/generator/README.cppclean +115 -0
  78. data/ext/rj_schema/rapidjson/thirdparty/gtest/googlemock/scripts/generator/cpp/__init__.py +0 -0
  79. data/ext/rj_schema/rapidjson/thirdparty/gtest/googlemock/scripts/generator/cpp/ast.py +1733 -0
  80. data/ext/rj_schema/rapidjson/thirdparty/gtest/googlemock/scripts/generator/cpp/gmock_class.py +227 -0
  81. data/ext/rj_schema/rapidjson/thirdparty/gtest/googlemock/scripts/generator/cpp/gmock_class_test.py +448 -0
  82. data/ext/rj_schema/rapidjson/thirdparty/gtest/googlemock/scripts/generator/cpp/keywords.py +59 -0
  83. data/ext/rj_schema/rapidjson/thirdparty/gtest/googlemock/scripts/generator/cpp/tokenize.py +287 -0
  84. data/ext/rj_schema/rapidjson/thirdparty/gtest/googlemock/scripts/generator/cpp/utils.py +41 -0
  85. data/ext/rj_schema/rapidjson/thirdparty/gtest/googlemock/scripts/generator/gmock_gen.py +31 -0
  86. data/ext/rj_schema/rapidjson/thirdparty/gtest/googlemock/scripts/gmock-config.in +303 -0
  87. data/ext/rj_schema/rapidjson/thirdparty/gtest/googlemock/scripts/gmock_doctor.py +640 -0
  88. data/ext/rj_schema/rapidjson/thirdparty/gtest/googlemock/scripts/upload.py +1387 -0
  89. data/ext/rj_schema/rapidjson/thirdparty/gtest/googlemock/scripts/upload_gmock.py +78 -0
  90. data/ext/rj_schema/rapidjson/thirdparty/gtest/googlemock/src/gmock-all.cc +47 -0
  91. data/ext/rj_schema/rapidjson/thirdparty/gtest/googlemock/src/gmock-cardinalities.cc +156 -0
  92. data/ext/rj_schema/rapidjson/thirdparty/gtest/googlemock/src/gmock-internal-utils.cc +174 -0
  93. data/ext/rj_schema/rapidjson/thirdparty/gtest/googlemock/src/gmock-matchers.cc +498 -0
  94. data/ext/rj_schema/rapidjson/thirdparty/gtest/googlemock/src/gmock-spec-builders.cc +823 -0
  95. data/ext/rj_schema/rapidjson/thirdparty/gtest/googlemock/src/gmock.cc +183 -0
  96. data/ext/rj_schema/rapidjson/thirdparty/gtest/googlemock/src/gmock_main.cc +54 -0
  97. data/ext/rj_schema/rapidjson/thirdparty/gtest/googlemock/test/gmock-actions_test.cc +1411 -0
  98. data/ext/rj_schema/rapidjson/thirdparty/gtest/googlemock/test/gmock-cardinalities_test.cc +428 -0
  99. data/ext/rj_schema/rapidjson/thirdparty/gtest/googlemock/test/gmock-generated-actions_test.cc +1228 -0
  100. data/ext/rj_schema/rapidjson/thirdparty/gtest/googlemock/test/gmock-generated-function-mockers_test.cc +622 -0
  101. data/ext/rj_schema/rapidjson/thirdparty/gtest/googlemock/test/gmock-generated-internal-utils_test.cc +127 -0
  102. data/ext/rj_schema/rapidjson/thirdparty/gtest/googlemock/test/gmock-generated-matchers_test.cc +1286 -0
  103. data/ext/rj_schema/rapidjson/thirdparty/gtest/googlemock/test/gmock-internal-utils_test.cc +699 -0
  104. data/ext/rj_schema/rapidjson/thirdparty/gtest/googlemock/test/gmock-matchers_test.cc +5648 -0
  105. data/ext/rj_schema/rapidjson/thirdparty/gtest/googlemock/test/gmock-more-actions_test.cc +708 -0
  106. data/ext/rj_schema/rapidjson/thirdparty/gtest/googlemock/test/gmock-nice-strict_test.cc +424 -0
  107. data/ext/rj_schema/rapidjson/thirdparty/gtest/googlemock/test/gmock-port_test.cc +43 -0
  108. data/ext/rj_schema/rapidjson/thirdparty/gtest/googlemock/test/gmock-spec-builders_test.cc +2644 -0
  109. data/ext/rj_schema/rapidjson/thirdparty/gtest/googlemock/test/gmock_all_test.cc +51 -0
  110. data/ext/rj_schema/rapidjson/thirdparty/gtest/googlemock/test/gmock_ex_test.cc +81 -0
  111. data/ext/rj_schema/rapidjson/thirdparty/gtest/googlemock/test/gmock_leak_test.py +108 -0
  112. data/ext/rj_schema/rapidjson/thirdparty/gtest/googlemock/test/gmock_leak_test_.cc +100 -0
  113. data/ext/rj_schema/rapidjson/thirdparty/gtest/googlemock/test/gmock_link2_test.cc +40 -0
  114. data/ext/rj_schema/rapidjson/thirdparty/gtest/googlemock/test/gmock_link_test.cc +40 -0
  115. data/ext/rj_schema/rapidjson/thirdparty/gtest/googlemock/test/gmock_link_test.h +669 -0
  116. data/ext/rj_schema/rapidjson/thirdparty/gtest/googlemock/test/gmock_output_test.py +180 -0
  117. data/ext/rj_schema/rapidjson/thirdparty/gtest/googlemock/test/gmock_output_test_.cc +291 -0
  118. data/ext/rj_schema/rapidjson/thirdparty/gtest/googlemock/test/gmock_output_test_golden.txt +310 -0
  119. data/ext/rj_schema/rapidjson/thirdparty/gtest/googlemock/test/gmock_stress_test.cc +322 -0
  120. data/ext/rj_schema/rapidjson/thirdparty/gtest/googlemock/test/gmock_test.cc +220 -0
  121. data/ext/rj_schema/rapidjson/thirdparty/gtest/googlemock/test/gmock_test_utils.py +112 -0
  122. data/ext/rj_schema/rapidjson/thirdparty/gtest/googletest/CHANGES +157 -0
  123. data/ext/rj_schema/rapidjson/thirdparty/gtest/googletest/CMakeLists.txt +286 -0
  124. data/ext/rj_schema/rapidjson/thirdparty/gtest/googletest/CONTRIBUTORS +37 -0
  125. data/ext/rj_schema/rapidjson/thirdparty/gtest/googletest/LICENSE +28 -0
  126. data/ext/rj_schema/rapidjson/thirdparty/gtest/googletest/Makefile.am +310 -0
  127. data/ext/rj_schema/rapidjson/thirdparty/gtest/googletest/README.md +280 -0
  128. data/ext/rj_schema/rapidjson/thirdparty/gtest/googletest/cmake/internal_utils.cmake +242 -0
  129. data/ext/rj_schema/rapidjson/thirdparty/gtest/googletest/codegear/gtest.cbproj +138 -0
  130. data/ext/rj_schema/rapidjson/thirdparty/gtest/googletest/codegear/gtest.groupproj +54 -0
  131. data/ext/rj_schema/rapidjson/thirdparty/gtest/googletest/codegear/gtest_all.cc +38 -0
  132. data/ext/rj_schema/rapidjson/thirdparty/gtest/googletest/codegear/gtest_link.cc +40 -0
  133. data/ext/rj_schema/rapidjson/thirdparty/gtest/googletest/codegear/gtest_main.cbproj +82 -0
  134. data/ext/rj_schema/rapidjson/thirdparty/gtest/googletest/codegear/gtest_unittest.cbproj +88 -0
  135. data/ext/rj_schema/rapidjson/thirdparty/gtest/googletest/configure.ac +68 -0
  136. data/ext/rj_schema/rapidjson/thirdparty/gtest/googletest/docs/AdvancedGuide.md +2182 -0
  137. data/ext/rj_schema/rapidjson/thirdparty/gtest/googletest/docs/DevGuide.md +126 -0
  138. data/ext/rj_schema/rapidjson/thirdparty/gtest/googletest/docs/Documentation.md +14 -0
  139. data/ext/rj_schema/rapidjson/thirdparty/gtest/googletest/docs/FAQ.md +1087 -0
  140. data/ext/rj_schema/rapidjson/thirdparty/gtest/googletest/docs/Primer.md +502 -0
  141. data/ext/rj_schema/rapidjson/thirdparty/gtest/googletest/docs/PumpManual.md +177 -0
  142. data/ext/rj_schema/rapidjson/thirdparty/gtest/googletest/docs/Samples.md +14 -0
  143. data/ext/rj_schema/rapidjson/thirdparty/gtest/googletest/docs/V1_5_AdvancedGuide.md +2096 -0
  144. data/ext/rj_schema/rapidjson/thirdparty/gtest/googletest/docs/V1_5_Documentation.md +12 -0
  145. data/ext/rj_schema/rapidjson/thirdparty/gtest/googletest/docs/V1_5_FAQ.md +886 -0
  146. data/ext/rj_schema/rapidjson/thirdparty/gtest/googletest/docs/V1_5_Primer.md +497 -0
  147. data/ext/rj_schema/rapidjson/thirdparty/gtest/googletest/docs/V1_5_PumpManual.md +177 -0
  148. data/ext/rj_schema/rapidjson/thirdparty/gtest/googletest/docs/V1_5_XcodeGuide.md +93 -0
  149. data/ext/rj_schema/rapidjson/thirdparty/gtest/googletest/docs/V1_6_AdvancedGuide.md +2178 -0
  150. data/ext/rj_schema/rapidjson/thirdparty/gtest/googletest/docs/V1_6_Documentation.md +14 -0
  151. data/ext/rj_schema/rapidjson/thirdparty/gtest/googletest/docs/V1_6_FAQ.md +1038 -0
  152. data/ext/rj_schema/rapidjson/thirdparty/gtest/googletest/docs/V1_6_Primer.md +501 -0
  153. data/ext/rj_schema/rapidjson/thirdparty/gtest/googletest/docs/V1_6_PumpManual.md +177 -0
  154. data/ext/rj_schema/rapidjson/thirdparty/gtest/googletest/docs/V1_6_Samples.md +14 -0
  155. data/ext/rj_schema/rapidjson/thirdparty/gtest/googletest/docs/V1_6_XcodeGuide.md +93 -0
  156. data/ext/rj_schema/rapidjson/thirdparty/gtest/googletest/docs/V1_7_AdvancedGuide.md +2181 -0
  157. data/ext/rj_schema/rapidjson/thirdparty/gtest/googletest/docs/V1_7_Documentation.md +14 -0
  158. data/ext/rj_schema/rapidjson/thirdparty/gtest/googletest/docs/V1_7_FAQ.md +1082 -0
  159. data/ext/rj_schema/rapidjson/thirdparty/gtest/googletest/docs/V1_7_Primer.md +501 -0
  160. data/ext/rj_schema/rapidjson/thirdparty/gtest/googletest/docs/V1_7_PumpManual.md +177 -0
  161. data/ext/rj_schema/rapidjson/thirdparty/gtest/googletest/docs/V1_7_Samples.md +14 -0
  162. data/ext/rj_schema/rapidjson/thirdparty/gtest/googletest/docs/V1_7_XcodeGuide.md +93 -0
  163. data/ext/rj_schema/rapidjson/thirdparty/gtest/googletest/docs/XcodeGuide.md +93 -0
  164. data/ext/rj_schema/rapidjson/thirdparty/gtest/googletest/include/gtest/gtest-death-test.h +294 -0
  165. data/ext/rj_schema/rapidjson/thirdparty/gtest/googletest/include/gtest/gtest-message.h +250 -0
  166. data/ext/rj_schema/rapidjson/thirdparty/gtest/googletest/include/gtest/gtest-param-test.h +1444 -0
  167. data/ext/rj_schema/rapidjson/thirdparty/gtest/googletest/include/gtest/gtest-param-test.h.pump +510 -0
  168. data/ext/rj_schema/rapidjson/thirdparty/gtest/googletest/include/gtest/gtest-printers.h +993 -0
  169. data/ext/rj_schema/rapidjson/thirdparty/gtest/googletest/include/gtest/gtest-spi.h +232 -0
  170. data/ext/rj_schema/rapidjson/thirdparty/gtest/googletest/include/gtest/gtest-test-part.h +179 -0
  171. data/ext/rj_schema/rapidjson/thirdparty/gtest/googletest/include/gtest/gtest-typed-test.h +263 -0
  172. data/ext/rj_schema/rapidjson/thirdparty/gtest/googletest/include/gtest/gtest.h +2236 -0
  173. data/ext/rj_schema/rapidjson/thirdparty/gtest/googletest/include/gtest/gtest_pred_impl.h +358 -0
  174. data/ext/rj_schema/rapidjson/thirdparty/gtest/googletest/include/gtest/gtest_prod.h +58 -0
  175. data/ext/rj_schema/rapidjson/thirdparty/gtest/googletest/include/gtest/internal/custom/gtest-port.h +69 -0
  176. data/ext/rj_schema/rapidjson/thirdparty/gtest/googletest/include/gtest/internal/custom/gtest-printers.h +42 -0
  177. data/ext/rj_schema/rapidjson/thirdparty/gtest/googletest/include/gtest/internal/custom/gtest.h +41 -0
  178. data/ext/rj_schema/rapidjson/thirdparty/gtest/googletest/include/gtest/internal/gtest-death-test-internal.h +319 -0
  179. data/ext/rj_schema/rapidjson/thirdparty/gtest/googletest/include/gtest/internal/gtest-filepath.h +206 -0
  180. data/ext/rj_schema/rapidjson/thirdparty/gtest/googletest/include/gtest/internal/gtest-internal.h +1238 -0
  181. data/ext/rj_schema/rapidjson/thirdparty/gtest/googletest/include/gtest/internal/gtest-linked_ptr.h +243 -0
  182. data/ext/rj_schema/rapidjson/thirdparty/gtest/googletest/include/gtest/internal/gtest-param-util-generated.h +5146 -0
  183. data/ext/rj_schema/rapidjson/thirdparty/gtest/googletest/include/gtest/internal/gtest-param-util-generated.h.pump +286 -0
  184. data/ext/rj_schema/rapidjson/thirdparty/gtest/googletest/include/gtest/internal/gtest-param-util.h +731 -0
  185. data/ext/rj_schema/rapidjson/thirdparty/gtest/googletest/include/gtest/internal/gtest-port-arch.h +93 -0
  186. data/ext/rj_schema/rapidjson/thirdparty/gtest/googletest/include/gtest/internal/gtest-port.h +2554 -0
  187. data/ext/rj_schema/rapidjson/thirdparty/gtest/googletest/include/gtest/internal/gtest-string.h +167 -0
  188. data/ext/rj_schema/rapidjson/thirdparty/gtest/googletest/include/gtest/internal/gtest-tuple.h +1020 -0
  189. data/ext/rj_schema/rapidjson/thirdparty/gtest/googletest/include/gtest/internal/gtest-tuple.h.pump +347 -0
  190. data/ext/rj_schema/rapidjson/thirdparty/gtest/googletest/include/gtest/internal/gtest-type-util.h +3331 -0
  191. data/ext/rj_schema/rapidjson/thirdparty/gtest/googletest/include/gtest/internal/gtest-type-util.h.pump +297 -0
  192. data/ext/rj_schema/rapidjson/thirdparty/gtest/googletest/m4/acx_pthread.m4 +363 -0
  193. data/ext/rj_schema/rapidjson/thirdparty/gtest/googletest/m4/gtest.m4 +74 -0
  194. data/ext/rj_schema/rapidjson/thirdparty/gtest/googletest/make/Makefile +82 -0
  195. data/ext/rj_schema/rapidjson/thirdparty/gtest/googletest/msvc/gtest-md.sln +45 -0
  196. data/ext/rj_schema/rapidjson/thirdparty/gtest/googletest/msvc/gtest-md.vcproj +126 -0
  197. data/ext/rj_schema/rapidjson/thirdparty/gtest/googletest/msvc/gtest.sln +45 -0
  198. data/ext/rj_schema/rapidjson/thirdparty/gtest/googletest/msvc/gtest.vcproj +126 -0
  199. data/ext/rj_schema/rapidjson/thirdparty/gtest/googletest/msvc/gtest_main-md.vcproj +129 -0
  200. data/ext/rj_schema/rapidjson/thirdparty/gtest/googletest/msvc/gtest_main.vcproj +129 -0
  201. data/ext/rj_schema/rapidjson/thirdparty/gtest/googletest/msvc/gtest_prod_test-md.vcproj +164 -0
  202. data/ext/rj_schema/rapidjson/thirdparty/gtest/googletest/msvc/gtest_prod_test.vcproj +164 -0
  203. data/ext/rj_schema/rapidjson/thirdparty/gtest/googletest/msvc/gtest_unittest-md.vcproj +147 -0
  204. data/ext/rj_schema/rapidjson/thirdparty/gtest/googletest/msvc/gtest_unittest.vcproj +147 -0
  205. data/ext/rj_schema/rapidjson/thirdparty/gtest/googletest/samples/prime_tables.h +123 -0
  206. data/ext/rj_schema/rapidjson/thirdparty/gtest/googletest/samples/sample1.cc +68 -0
  207. data/ext/rj_schema/rapidjson/thirdparty/gtest/googletest/samples/sample1.h +43 -0
  208. data/ext/rj_schema/rapidjson/thirdparty/gtest/googletest/samples/sample10_unittest.cc +144 -0
  209. data/ext/rj_schema/rapidjson/thirdparty/gtest/googletest/samples/sample1_unittest.cc +153 -0
  210. data/ext/rj_schema/rapidjson/thirdparty/gtest/googletest/samples/sample2.cc +56 -0
  211. data/ext/rj_schema/rapidjson/thirdparty/gtest/googletest/samples/sample2.h +85 -0
  212. data/ext/rj_schema/rapidjson/thirdparty/gtest/googletest/samples/sample2_unittest.cc +109 -0
  213. data/ext/rj_schema/rapidjson/thirdparty/gtest/googletest/samples/sample3-inl.h +172 -0
  214. data/ext/rj_schema/rapidjson/thirdparty/gtest/googletest/samples/sample3_unittest.cc +151 -0
  215. data/ext/rj_schema/rapidjson/thirdparty/gtest/googletest/samples/sample4.cc +46 -0
  216. data/ext/rj_schema/rapidjson/thirdparty/gtest/googletest/samples/sample4.h +53 -0
  217. data/ext/rj_schema/rapidjson/thirdparty/gtest/googletest/samples/sample4_unittest.cc +45 -0
  218. data/ext/rj_schema/rapidjson/thirdparty/gtest/googletest/samples/sample5_unittest.cc +199 -0
  219. data/ext/rj_schema/rapidjson/thirdparty/gtest/googletest/samples/sample6_unittest.cc +224 -0
  220. data/ext/rj_schema/rapidjson/thirdparty/gtest/googletest/samples/sample7_unittest.cc +130 -0
  221. data/ext/rj_schema/rapidjson/thirdparty/gtest/googletest/samples/sample8_unittest.cc +173 -0
  222. data/ext/rj_schema/rapidjson/thirdparty/gtest/googletest/samples/sample9_unittest.cc +160 -0
  223. data/ext/rj_schema/rapidjson/thirdparty/gtest/googletest/scripts/common.py +83 -0
  224. data/ext/rj_schema/rapidjson/thirdparty/gtest/googletest/scripts/fuse_gtest_files.py +253 -0
  225. data/ext/rj_schema/rapidjson/thirdparty/gtest/googletest/scripts/gen_gtest_pred_impl.py +730 -0
  226. data/ext/rj_schema/rapidjson/thirdparty/gtest/googletest/scripts/gtest-config.in +274 -0
  227. data/ext/rj_schema/rapidjson/thirdparty/gtest/googletest/scripts/pump.py +855 -0
  228. data/ext/rj_schema/rapidjson/thirdparty/gtest/googletest/scripts/release_docs.py +158 -0
  229. data/ext/rj_schema/rapidjson/thirdparty/gtest/googletest/scripts/test/Makefile +59 -0
  230. data/ext/rj_schema/rapidjson/thirdparty/gtest/googletest/scripts/upload.py +1387 -0
  231. data/ext/rj_schema/rapidjson/thirdparty/gtest/googletest/scripts/upload_gtest.py +78 -0
  232. data/ext/rj_schema/rapidjson/thirdparty/gtest/googletest/src/gtest-all.cc +48 -0
  233. data/ext/rj_schema/rapidjson/thirdparty/gtest/googletest/src/gtest-death-test.cc +1342 -0
  234. data/ext/rj_schema/rapidjson/thirdparty/gtest/googletest/src/gtest-filepath.cc +387 -0
  235. data/ext/rj_schema/rapidjson/thirdparty/gtest/googletest/src/gtest-internal-inl.h +1183 -0
  236. data/ext/rj_schema/rapidjson/thirdparty/gtest/googletest/src/gtest-port.cc +1259 -0
  237. data/ext/rj_schema/rapidjson/thirdparty/gtest/googletest/src/gtest-printers.cc +373 -0
  238. data/ext/rj_schema/rapidjson/thirdparty/gtest/googletest/src/gtest-test-part.cc +110 -0
  239. data/ext/rj_schema/rapidjson/thirdparty/gtest/googletest/src/gtest-typed-test.cc +118 -0
  240. data/ext/rj_schema/rapidjson/thirdparty/gtest/googletest/src/gtest.cc +5388 -0
  241. data/ext/rj_schema/rapidjson/thirdparty/gtest/googletest/src/gtest_main.cc +38 -0
  242. data/ext/rj_schema/rapidjson/thirdparty/gtest/googletest/test/gtest-death-test_ex_test.cc +93 -0
  243. data/ext/rj_schema/rapidjson/thirdparty/gtest/googletest/test/gtest-death-test_test.cc +1427 -0
  244. data/ext/rj_schema/rapidjson/thirdparty/gtest/googletest/test/gtest-filepath_test.cc +662 -0
  245. data/ext/rj_schema/rapidjson/thirdparty/gtest/googletest/test/gtest-linked_ptr_test.cc +154 -0
  246. data/ext/rj_schema/rapidjson/thirdparty/gtest/googletest/test/gtest-listener_test.cc +311 -0
  247. data/ext/rj_schema/rapidjson/thirdparty/gtest/googletest/test/gtest-message_test.cc +159 -0
  248. data/ext/rj_schema/rapidjson/thirdparty/gtest/googletest/test/gtest-options_test.cc +215 -0
  249. data/ext/rj_schema/rapidjson/thirdparty/gtest/googletest/test/gtest-param-test2_test.cc +65 -0
  250. data/ext/rj_schema/rapidjson/thirdparty/gtest/googletest/test/gtest-param-test_test.cc +1055 -0
  251. data/ext/rj_schema/rapidjson/thirdparty/gtest/googletest/test/gtest-param-test_test.h +57 -0
  252. data/ext/rj_schema/rapidjson/thirdparty/gtest/googletest/test/gtest-port_test.cc +1304 -0
  253. data/ext/rj_schema/rapidjson/thirdparty/gtest/googletest/test/gtest-printers_test.cc +1635 -0
  254. data/ext/rj_schema/rapidjson/thirdparty/gtest/googletest/test/gtest-test-part_test.cc +208 -0
  255. data/ext/rj_schema/rapidjson/thirdparty/gtest/googletest/test/gtest-tuple_test.cc +320 -0
  256. data/ext/rj_schema/rapidjson/thirdparty/gtest/googletest/test/gtest-typed-test2_test.cc +45 -0
  257. data/ext/rj_schema/rapidjson/thirdparty/gtest/googletest/test/gtest-typed-test_test.cc +380 -0
  258. data/ext/rj_schema/rapidjson/thirdparty/gtest/googletest/test/gtest-typed-test_test.h +66 -0
  259. data/ext/rj_schema/rapidjson/thirdparty/gtest/googletest/test/gtest-unittest-api_test.cc +341 -0
  260. data/ext/rj_schema/rapidjson/thirdparty/gtest/googletest/test/gtest_all_test.cc +47 -0
  261. data/ext/rj_schema/rapidjson/thirdparty/gtest/googletest/test/gtest_break_on_failure_unittest.py +212 -0
  262. data/ext/rj_schema/rapidjson/thirdparty/gtest/googletest/test/gtest_break_on_failure_unittest_.cc +88 -0
  263. data/ext/rj_schema/rapidjson/thirdparty/gtest/googletest/test/gtest_catch_exceptions_test.py +237 -0
  264. data/ext/rj_schema/rapidjson/thirdparty/gtest/googletest/test/gtest_catch_exceptions_test_.cc +311 -0
  265. data/ext/rj_schema/rapidjson/thirdparty/gtest/googletest/test/gtest_color_test.py +130 -0
  266. data/ext/rj_schema/rapidjson/thirdparty/gtest/googletest/test/gtest_color_test_.cc +71 -0
  267. data/ext/rj_schema/rapidjson/thirdparty/gtest/googletest/test/gtest_env_var_test.py +117 -0
  268. data/ext/rj_schema/rapidjson/thirdparty/gtest/googletest/test/gtest_env_var_test_.cc +126 -0
  269. data/ext/rj_schema/rapidjson/thirdparty/gtest/googletest/test/gtest_environment_test.cc +192 -0
  270. data/ext/rj_schema/rapidjson/thirdparty/gtest/googletest/test/gtest_filter_unittest.py +636 -0
  271. data/ext/rj_schema/rapidjson/thirdparty/gtest/googletest/test/gtest_filter_unittest_.cc +140 -0
  272. data/ext/rj_schema/rapidjson/thirdparty/gtest/googletest/test/gtest_help_test.py +172 -0
  273. data/ext/rj_schema/rapidjson/thirdparty/gtest/googletest/test/gtest_help_test_.cc +46 -0
  274. data/ext/rj_schema/rapidjson/thirdparty/gtest/googletest/test/gtest_list_tests_unittest.py +207 -0
  275. data/ext/rj_schema/rapidjson/thirdparty/gtest/googletest/test/gtest_list_tests_unittest_.cc +157 -0
  276. data/ext/rj_schema/rapidjson/thirdparty/gtest/googletest/test/gtest_main_unittest.cc +45 -0
  277. data/ext/rj_schema/rapidjson/thirdparty/gtest/googletest/test/gtest_no_test_unittest.cc +56 -0
  278. data/ext/rj_schema/rapidjson/thirdparty/gtest/googletest/test/gtest_output_test.py +340 -0
  279. data/ext/rj_schema/rapidjson/thirdparty/gtest/googletest/test/gtest_output_test_.cc +1062 -0
  280. data/ext/rj_schema/rapidjson/thirdparty/gtest/googletest/test/gtest_output_test_golden_lin.txt +743 -0
  281. data/ext/rj_schema/rapidjson/thirdparty/gtest/googletest/test/gtest_pred_impl_unittest.cc +2427 -0
  282. data/ext/rj_schema/rapidjson/thirdparty/gtest/googletest/test/gtest_premature_exit_test.cc +127 -0
  283. data/ext/rj_schema/rapidjson/thirdparty/gtest/googletest/test/gtest_prod_test.cc +57 -0
  284. data/ext/rj_schema/rapidjson/thirdparty/gtest/googletest/test/gtest_repeat_test.cc +253 -0
  285. data/ext/rj_schema/rapidjson/thirdparty/gtest/googletest/test/gtest_shuffle_test.py +325 -0
  286. data/ext/rj_schema/rapidjson/thirdparty/gtest/googletest/test/gtest_shuffle_test_.cc +103 -0
  287. data/ext/rj_schema/rapidjson/thirdparty/gtest/googletest/test/gtest_sole_header_test.cc +57 -0
  288. data/ext/rj_schema/rapidjson/thirdparty/gtest/googletest/test/gtest_stress_test.cc +256 -0
  289. data/ext/rj_schema/rapidjson/thirdparty/gtest/googletest/test/gtest_test_utils.py +320 -0
  290. data/ext/rj_schema/rapidjson/thirdparty/gtest/googletest/test/gtest_throw_on_failure_ex_test.cc +92 -0
  291. data/ext/rj_schema/rapidjson/thirdparty/gtest/googletest/test/gtest_throw_on_failure_test.py +171 -0
  292. data/ext/rj_schema/rapidjson/thirdparty/gtest/googletest/test/gtest_throw_on_failure_test_.cc +72 -0
  293. data/ext/rj_schema/rapidjson/thirdparty/gtest/googletest/test/gtest_uninitialized_test.py +70 -0
  294. data/ext/rj_schema/rapidjson/thirdparty/gtest/googletest/test/gtest_uninitialized_test_.cc +43 -0
  295. data/ext/rj_schema/rapidjson/thirdparty/gtest/googletest/test/gtest_unittest.cc +7706 -0
  296. data/ext/rj_schema/rapidjson/thirdparty/gtest/googletest/test/gtest_xml_outfile1_test_.cc +49 -0
  297. data/ext/rj_schema/rapidjson/thirdparty/gtest/googletest/test/gtest_xml_outfile2_test_.cc +49 -0
  298. data/ext/rj_schema/rapidjson/thirdparty/gtest/googletest/test/gtest_xml_outfiles_test.py +132 -0
  299. data/ext/rj_schema/rapidjson/thirdparty/gtest/googletest/test/gtest_xml_output_unittest.py +308 -0
  300. data/ext/rj_schema/rapidjson/thirdparty/gtest/googletest/test/gtest_xml_output_unittest_.cc +181 -0
  301. data/ext/rj_schema/rapidjson/thirdparty/gtest/googletest/test/gtest_xml_test_utils.py +194 -0
  302. data/ext/rj_schema/rapidjson/thirdparty/gtest/googletest/test/production.cc +36 -0
  303. data/ext/rj_schema/rapidjson/thirdparty/gtest/googletest/test/production.h +55 -0
  304. data/ext/rj_schema/rapidjson/thirdparty/gtest/googletest/xcode/Config/DebugProject.xcconfig +30 -0
  305. data/ext/rj_schema/rapidjson/thirdparty/gtest/googletest/xcode/Config/FrameworkTarget.xcconfig +17 -0
  306. data/ext/rj_schema/rapidjson/thirdparty/gtest/googletest/xcode/Config/General.xcconfig +41 -0
  307. data/ext/rj_schema/rapidjson/thirdparty/gtest/googletest/xcode/Config/ReleaseProject.xcconfig +32 -0
  308. data/ext/rj_schema/rapidjson/thirdparty/gtest/googletest/xcode/Config/StaticLibraryTarget.xcconfig +18 -0
  309. data/ext/rj_schema/rapidjson/thirdparty/gtest/googletest/xcode/Config/TestTarget.xcconfig +8 -0
  310. data/ext/rj_schema/rapidjson/thirdparty/gtest/googletest/xcode/Resources/Info.plist +30 -0
  311. data/ext/rj_schema/rapidjson/thirdparty/gtest/googletest/xcode/Samples/FrameworkSample/Info.plist +28 -0
  312. data/ext/rj_schema/rapidjson/thirdparty/gtest/googletest/xcode/Samples/FrameworkSample/WidgetFramework.xcodeproj/project.pbxproj +457 -0
  313. data/ext/rj_schema/rapidjson/thirdparty/gtest/googletest/xcode/Samples/FrameworkSample/runtests.sh +62 -0
  314. data/ext/rj_schema/rapidjson/thirdparty/gtest/googletest/xcode/Samples/FrameworkSample/widget.cc +63 -0
  315. data/ext/rj_schema/rapidjson/thirdparty/gtest/googletest/xcode/Samples/FrameworkSample/widget.h +59 -0
  316. data/ext/rj_schema/rapidjson/thirdparty/gtest/googletest/xcode/Samples/FrameworkSample/widget_test.cc +68 -0
  317. data/ext/rj_schema/rapidjson/thirdparty/gtest/googletest/xcode/Scripts/runtests.sh +65 -0
  318. data/ext/rj_schema/rapidjson/thirdparty/gtest/googletest/xcode/Scripts/versiongenerate.py +100 -0
  319. data/ext/rj_schema/rapidjson/thirdparty/gtest/googletest/xcode/gtest.xcodeproj/project.pbxproj +1135 -0
  320. data/ext/rj_schema/rapidjson/thirdparty/gtest/travis.sh +15 -0
  321. data/ext/rj_schema/rj_schema.cpp +64 -41
  322. data/lib/rj_schema.rb +1 -1
  323. metadata +378 -5
@@ -0,0 +1,672 @@
1
+ $$ -*- mode: c++; -*-
2
+ $$ This is a Pump source file. Please use Pump to convert it to
3
+ $$ gmock-generated-actions.h.
4
+ $$
5
+ $var n = 10 $$ The maximum arity we support.
6
+ $$ }} This line fixes auto-indentation of the following code in Emacs.
7
+ // Copyright 2008, Google Inc.
8
+ // All rights reserved.
9
+ //
10
+ // Redistribution and use in source and binary forms, with or without
11
+ // modification, are permitted provided that the following conditions are
12
+ // met:
13
+ //
14
+ // * Redistributions of source code must retain the above copyright
15
+ // notice, this list of conditions and the following disclaimer.
16
+ // * Redistributions in binary form must reproduce the above
17
+ // copyright notice, this list of conditions and the following disclaimer
18
+ // in the documentation and/or other materials provided with the
19
+ // distribution.
20
+ // * Neither the name of Google Inc. nor the names of its
21
+ // contributors may be used to endorse or promote products derived from
22
+ // this software without specific prior written permission.
23
+ //
24
+ // THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS
25
+ // "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT
26
+ // LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR
27
+ // A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT
28
+ // OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
29
+ // SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
30
+ // LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
31
+ // DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY
32
+ // THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
33
+ // (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
34
+ // OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
35
+
36
+ // Google Mock - a framework for writing C++ mock classes.
37
+ //
38
+ // This file implements some commonly used variadic matchers.
39
+
40
+ #ifndef GMOCK_INCLUDE_GMOCK_GMOCK_GENERATED_MATCHERS_H_
41
+ #define GMOCK_INCLUDE_GMOCK_GMOCK_GENERATED_MATCHERS_H_
42
+
43
+ #include <iterator>
44
+ #include <sstream>
45
+ #include <string>
46
+ #include <vector>
47
+ #include "gmock/gmock-matchers.h"
48
+
49
+ namespace testing {
50
+ namespace internal {
51
+
52
+ $range i 0..n-1
53
+
54
+ // The type of the i-th (0-based) field of Tuple.
55
+ #define GMOCK_FIELD_TYPE_(Tuple, i) \
56
+ typename ::testing::tuple_element<i, Tuple>::type
57
+
58
+ // TupleFields<Tuple, k0, ..., kn> is for selecting fields from a
59
+ // tuple of type Tuple. It has two members:
60
+ //
61
+ // type: a tuple type whose i-th field is the ki-th field of Tuple.
62
+ // GetSelectedFields(t): returns fields k0, ..., and kn of t as a tuple.
63
+ //
64
+ // For example, in class TupleFields<tuple<bool, char, int>, 2, 0>, we have:
65
+ //
66
+ // type is tuple<int, bool>, and
67
+ // GetSelectedFields(make_tuple(true, 'a', 42)) is (42, true).
68
+
69
+ template <class Tuple$for i [[, int k$i = -1]]>
70
+ class TupleFields;
71
+
72
+ // This generic version is used when there are $n selectors.
73
+ template <class Tuple$for i [[, int k$i]]>
74
+ class TupleFields {
75
+ public:
76
+ typedef ::testing::tuple<$for i, [[GMOCK_FIELD_TYPE_(Tuple, k$i)]]> type;
77
+ static type GetSelectedFields(const Tuple& t) {
78
+ return type($for i, [[get<k$i>(t)]]);
79
+ }
80
+ };
81
+
82
+ // The following specialization is used for 0 ~ $(n-1) selectors.
83
+
84
+ $for i [[
85
+ $$ }}}
86
+ $range j 0..i-1
87
+ $range k 0..n-1
88
+
89
+ template <class Tuple$for j [[, int k$j]]>
90
+ class TupleFields<Tuple, $for k, [[$if k < i [[k$k]] $else [[-1]]]]> {
91
+ public:
92
+ typedef ::testing::tuple<$for j, [[GMOCK_FIELD_TYPE_(Tuple, k$j)]]> type;
93
+ static type GetSelectedFields(const Tuple& $if i==0 [[/* t */]] $else [[t]]) {
94
+ return type($for j, [[get<k$j>(t)]]);
95
+ }
96
+ };
97
+
98
+ ]]
99
+
100
+ #undef GMOCK_FIELD_TYPE_
101
+
102
+ // Implements the Args() matcher.
103
+
104
+ $var ks = [[$for i, [[k$i]]]]
105
+ template <class ArgsTuple$for i [[, int k$i = -1]]>
106
+ class ArgsMatcherImpl : public MatcherInterface<ArgsTuple> {
107
+ public:
108
+ // ArgsTuple may have top-level const or reference modifiers.
109
+ typedef GTEST_REMOVE_REFERENCE_AND_CONST_(ArgsTuple) RawArgsTuple;
110
+ typedef typename internal::TupleFields<RawArgsTuple, $ks>::type SelectedArgs;
111
+ typedef Matcher<const SelectedArgs&> MonomorphicInnerMatcher;
112
+
113
+ template <typename InnerMatcher>
114
+ explicit ArgsMatcherImpl(const InnerMatcher& inner_matcher)
115
+ : inner_matcher_(SafeMatcherCast<const SelectedArgs&>(inner_matcher)) {}
116
+
117
+ virtual bool MatchAndExplain(ArgsTuple args,
118
+ MatchResultListener* listener) const {
119
+ const SelectedArgs& selected_args = GetSelectedArgs(args);
120
+ if (!listener->IsInterested())
121
+ return inner_matcher_.Matches(selected_args);
122
+
123
+ PrintIndices(listener->stream());
124
+ *listener << "are " << PrintToString(selected_args);
125
+
126
+ StringMatchResultListener inner_listener;
127
+ const bool match = inner_matcher_.MatchAndExplain(selected_args,
128
+ &inner_listener);
129
+ PrintIfNotEmpty(inner_listener.str(), listener->stream());
130
+ return match;
131
+ }
132
+
133
+ virtual void DescribeTo(::std::ostream* os) const {
134
+ *os << "are a tuple ";
135
+ PrintIndices(os);
136
+ inner_matcher_.DescribeTo(os);
137
+ }
138
+
139
+ virtual void DescribeNegationTo(::std::ostream* os) const {
140
+ *os << "are a tuple ";
141
+ PrintIndices(os);
142
+ inner_matcher_.DescribeNegationTo(os);
143
+ }
144
+
145
+ private:
146
+ static SelectedArgs GetSelectedArgs(ArgsTuple args) {
147
+ return TupleFields<RawArgsTuple, $ks>::GetSelectedFields(args);
148
+ }
149
+
150
+ // Prints the indices of the selected fields.
151
+ static void PrintIndices(::std::ostream* os) {
152
+ *os << "whose fields (";
153
+ const int indices[$n] = { $ks };
154
+ for (int i = 0; i < $n; i++) {
155
+ if (indices[i] < 0)
156
+ break;
157
+
158
+ if (i >= 1)
159
+ *os << ", ";
160
+
161
+ *os << "#" << indices[i];
162
+ }
163
+ *os << ") ";
164
+ }
165
+
166
+ const MonomorphicInnerMatcher inner_matcher_;
167
+
168
+ GTEST_DISALLOW_ASSIGN_(ArgsMatcherImpl);
169
+ };
170
+
171
+ template <class InnerMatcher$for i [[, int k$i = -1]]>
172
+ class ArgsMatcher {
173
+ public:
174
+ explicit ArgsMatcher(const InnerMatcher& inner_matcher)
175
+ : inner_matcher_(inner_matcher) {}
176
+
177
+ template <typename ArgsTuple>
178
+ operator Matcher<ArgsTuple>() const {
179
+ return MakeMatcher(new ArgsMatcherImpl<ArgsTuple, $ks>(inner_matcher_));
180
+ }
181
+
182
+ private:
183
+ const InnerMatcher inner_matcher_;
184
+
185
+ GTEST_DISALLOW_ASSIGN_(ArgsMatcher);
186
+ };
187
+
188
+ // A set of metafunctions for computing the result type of AllOf.
189
+ // AllOf(m1, ..., mN) returns
190
+ // AllOfResultN<decltype(m1), ..., decltype(mN)>::type.
191
+
192
+ // Although AllOf isn't defined for one argument, AllOfResult1 is defined
193
+ // to simplify the implementation.
194
+ template <typename M1>
195
+ struct AllOfResult1 {
196
+ typedef M1 type;
197
+ };
198
+
199
+ $range i 1..n
200
+
201
+ $range i 2..n
202
+ $for i [[
203
+ $range j 2..i
204
+ $var m = i/2
205
+ $range k 1..m
206
+ $range t m+1..i
207
+
208
+ template <typename M1$for j [[, typename M$j]]>
209
+ struct AllOfResult$i {
210
+ typedef BothOfMatcher<
211
+ typename AllOfResult$m<$for k, [[M$k]]>::type,
212
+ typename AllOfResult$(i-m)<$for t, [[M$t]]>::type
213
+ > type;
214
+ };
215
+
216
+ ]]
217
+
218
+ // A set of metafunctions for computing the result type of AnyOf.
219
+ // AnyOf(m1, ..., mN) returns
220
+ // AnyOfResultN<decltype(m1), ..., decltype(mN)>::type.
221
+
222
+ // Although AnyOf isn't defined for one argument, AnyOfResult1 is defined
223
+ // to simplify the implementation.
224
+ template <typename M1>
225
+ struct AnyOfResult1 {
226
+ typedef M1 type;
227
+ };
228
+
229
+ $range i 1..n
230
+
231
+ $range i 2..n
232
+ $for i [[
233
+ $range j 2..i
234
+ $var m = i/2
235
+ $range k 1..m
236
+ $range t m+1..i
237
+
238
+ template <typename M1$for j [[, typename M$j]]>
239
+ struct AnyOfResult$i {
240
+ typedef EitherOfMatcher<
241
+ typename AnyOfResult$m<$for k, [[M$k]]>::type,
242
+ typename AnyOfResult$(i-m)<$for t, [[M$t]]>::type
243
+ > type;
244
+ };
245
+
246
+ ]]
247
+
248
+ } // namespace internal
249
+
250
+ // Args<N1, N2, ..., Nk>(a_matcher) matches a tuple if the selected
251
+ // fields of it matches a_matcher. C++ doesn't support default
252
+ // arguments for function templates, so we have to overload it.
253
+
254
+ $range i 0..n
255
+ $for i [[
256
+ $range j 1..i
257
+ template <$for j [[int k$j, ]]typename InnerMatcher>
258
+ inline internal::ArgsMatcher<InnerMatcher$for j [[, k$j]]>
259
+ Args(const InnerMatcher& matcher) {
260
+ return internal::ArgsMatcher<InnerMatcher$for j [[, k$j]]>(matcher);
261
+ }
262
+
263
+
264
+ ]]
265
+ // ElementsAre(e_1, e_2, ... e_n) matches an STL-style container with
266
+ // n elements, where the i-th element in the container must
267
+ // match the i-th argument in the list. Each argument of
268
+ // ElementsAre() can be either a value or a matcher. We support up to
269
+ // $n arguments.
270
+ //
271
+ // The use of DecayArray in the implementation allows ElementsAre()
272
+ // to accept string literals, whose type is const char[N], but we
273
+ // want to treat them as const char*.
274
+ //
275
+ // NOTE: Since ElementsAre() cares about the order of the elements, it
276
+ // must not be used with containers whose elements's order is
277
+ // undefined (e.g. hash_map).
278
+
279
+ $range i 0..n
280
+ $for i [[
281
+
282
+ $range j 1..i
283
+
284
+ $if i>0 [[
285
+
286
+ template <$for j, [[typename T$j]]>
287
+ ]]
288
+
289
+ inline internal::ElementsAreMatcher<
290
+ ::testing::tuple<
291
+ $for j, [[
292
+
293
+ typename internal::DecayArray<T$j[[]]>::type]]> >
294
+ ElementsAre($for j, [[const T$j& e$j]]) {
295
+ typedef ::testing::tuple<
296
+ $for j, [[
297
+
298
+ typename internal::DecayArray<T$j[[]]>::type]]> Args;
299
+ return internal::ElementsAreMatcher<Args>(Args($for j, [[e$j]]));
300
+ }
301
+
302
+ ]]
303
+
304
+ // UnorderedElementsAre(e_1, e_2, ..., e_n) is an ElementsAre extension
305
+ // that matches n elements in any order. We support up to n=$n arguments.
306
+
307
+ $range i 0..n
308
+ $for i [[
309
+
310
+ $range j 1..i
311
+
312
+ $if i>0 [[
313
+
314
+ template <$for j, [[typename T$j]]>
315
+ ]]
316
+
317
+ inline internal::UnorderedElementsAreMatcher<
318
+ ::testing::tuple<
319
+ $for j, [[
320
+
321
+ typename internal::DecayArray<T$j[[]]>::type]]> >
322
+ UnorderedElementsAre($for j, [[const T$j& e$j]]) {
323
+ typedef ::testing::tuple<
324
+ $for j, [[
325
+
326
+ typename internal::DecayArray<T$j[[]]>::type]]> Args;
327
+ return internal::UnorderedElementsAreMatcher<Args>(Args($for j, [[e$j]]));
328
+ }
329
+
330
+ ]]
331
+
332
+ // AllOf(m1, m2, ..., mk) matches any value that matches all of the given
333
+ // sub-matchers. AllOf is called fully qualified to prevent ADL from firing.
334
+
335
+ $range i 2..n
336
+ $for i [[
337
+ $range j 1..i
338
+ $var m = i/2
339
+ $range k 1..m
340
+ $range t m+1..i
341
+
342
+ template <$for j, [[typename M$j]]>
343
+ inline typename internal::AllOfResult$i<$for j, [[M$j]]>::type
344
+ AllOf($for j, [[M$j m$j]]) {
345
+ return typename internal::AllOfResult$i<$for j, [[M$j]]>::type(
346
+ $if m == 1 [[m1]] $else [[::testing::AllOf($for k, [[m$k]])]],
347
+ $if m+1 == i [[m$i]] $else [[::testing::AllOf($for t, [[m$t]])]]);
348
+ }
349
+
350
+ ]]
351
+
352
+ // AnyOf(m1, m2, ..., mk) matches any value that matches any of the given
353
+ // sub-matchers. AnyOf is called fully qualified to prevent ADL from firing.
354
+
355
+ $range i 2..n
356
+ $for i [[
357
+ $range j 1..i
358
+ $var m = i/2
359
+ $range k 1..m
360
+ $range t m+1..i
361
+
362
+ template <$for j, [[typename M$j]]>
363
+ inline typename internal::AnyOfResult$i<$for j, [[M$j]]>::type
364
+ AnyOf($for j, [[M$j m$j]]) {
365
+ return typename internal::AnyOfResult$i<$for j, [[M$j]]>::type(
366
+ $if m == 1 [[m1]] $else [[::testing::AnyOf($for k, [[m$k]])]],
367
+ $if m+1 == i [[m$i]] $else [[::testing::AnyOf($for t, [[m$t]])]]);
368
+ }
369
+
370
+ ]]
371
+
372
+ } // namespace testing
373
+ $$ } // This Pump meta comment fixes auto-indentation in Emacs. It will not
374
+ $$ // show up in the generated code.
375
+
376
+
377
+ // The MATCHER* family of macros can be used in a namespace scope to
378
+ // define custom matchers easily.
379
+ //
380
+ // Basic Usage
381
+ // ===========
382
+ //
383
+ // The syntax
384
+ //
385
+ // MATCHER(name, description_string) { statements; }
386
+ //
387
+ // defines a matcher with the given name that executes the statements,
388
+ // which must return a bool to indicate if the match succeeds. Inside
389
+ // the statements, you can refer to the value being matched by 'arg',
390
+ // and refer to its type by 'arg_type'.
391
+ //
392
+ // The description string documents what the matcher does, and is used
393
+ // to generate the failure message when the match fails. Since a
394
+ // MATCHER() is usually defined in a header file shared by multiple
395
+ // C++ source files, we require the description to be a C-string
396
+ // literal to avoid possible side effects. It can be empty, in which
397
+ // case we'll use the sequence of words in the matcher name as the
398
+ // description.
399
+ //
400
+ // For example:
401
+ //
402
+ // MATCHER(IsEven, "") { return (arg % 2) == 0; }
403
+ //
404
+ // allows you to write
405
+ //
406
+ // // Expects mock_foo.Bar(n) to be called where n is even.
407
+ // EXPECT_CALL(mock_foo, Bar(IsEven()));
408
+ //
409
+ // or,
410
+ //
411
+ // // Verifies that the value of some_expression is even.
412
+ // EXPECT_THAT(some_expression, IsEven());
413
+ //
414
+ // If the above assertion fails, it will print something like:
415
+ //
416
+ // Value of: some_expression
417
+ // Expected: is even
418
+ // Actual: 7
419
+ //
420
+ // where the description "is even" is automatically calculated from the
421
+ // matcher name IsEven.
422
+ //
423
+ // Argument Type
424
+ // =============
425
+ //
426
+ // Note that the type of the value being matched (arg_type) is
427
+ // determined by the context in which you use the matcher and is
428
+ // supplied to you by the compiler, so you don't need to worry about
429
+ // declaring it (nor can you). This allows the matcher to be
430
+ // polymorphic. For example, IsEven() can be used to match any type
431
+ // where the value of "(arg % 2) == 0" can be implicitly converted to
432
+ // a bool. In the "Bar(IsEven())" example above, if method Bar()
433
+ // takes an int, 'arg_type' will be int; if it takes an unsigned long,
434
+ // 'arg_type' will be unsigned long; and so on.
435
+ //
436
+ // Parameterizing Matchers
437
+ // =======================
438
+ //
439
+ // Sometimes you'll want to parameterize the matcher. For that you
440
+ // can use another macro:
441
+ //
442
+ // MATCHER_P(name, param_name, description_string) { statements; }
443
+ //
444
+ // For example:
445
+ //
446
+ // MATCHER_P(HasAbsoluteValue, value, "") { return abs(arg) == value; }
447
+ //
448
+ // will allow you to write:
449
+ //
450
+ // EXPECT_THAT(Blah("a"), HasAbsoluteValue(n));
451
+ //
452
+ // which may lead to this message (assuming n is 10):
453
+ //
454
+ // Value of: Blah("a")
455
+ // Expected: has absolute value 10
456
+ // Actual: -9
457
+ //
458
+ // Note that both the matcher description and its parameter are
459
+ // printed, making the message human-friendly.
460
+ //
461
+ // In the matcher definition body, you can write 'foo_type' to
462
+ // reference the type of a parameter named 'foo'. For example, in the
463
+ // body of MATCHER_P(HasAbsoluteValue, value) above, you can write
464
+ // 'value_type' to refer to the type of 'value'.
465
+ //
466
+ // We also provide MATCHER_P2, MATCHER_P3, ..., up to MATCHER_P$n to
467
+ // support multi-parameter matchers.
468
+ //
469
+ // Describing Parameterized Matchers
470
+ // =================================
471
+ //
472
+ // The last argument to MATCHER*() is a string-typed expression. The
473
+ // expression can reference all of the matcher's parameters and a
474
+ // special bool-typed variable named 'negation'. When 'negation' is
475
+ // false, the expression should evaluate to the matcher's description;
476
+ // otherwise it should evaluate to the description of the negation of
477
+ // the matcher. For example,
478
+ //
479
+ // using testing::PrintToString;
480
+ //
481
+ // MATCHER_P2(InClosedRange, low, hi,
482
+ // string(negation ? "is not" : "is") + " in range [" +
483
+ // PrintToString(low) + ", " + PrintToString(hi) + "]") {
484
+ // return low <= arg && arg <= hi;
485
+ // }
486
+ // ...
487
+ // EXPECT_THAT(3, InClosedRange(4, 6));
488
+ // EXPECT_THAT(3, Not(InClosedRange(2, 4)));
489
+ //
490
+ // would generate two failures that contain the text:
491
+ //
492
+ // Expected: is in range [4, 6]
493
+ // ...
494
+ // Expected: is not in range [2, 4]
495
+ //
496
+ // If you specify "" as the description, the failure message will
497
+ // contain the sequence of words in the matcher name followed by the
498
+ // parameter values printed as a tuple. For example,
499
+ //
500
+ // MATCHER_P2(InClosedRange, low, hi, "") { ... }
501
+ // ...
502
+ // EXPECT_THAT(3, InClosedRange(4, 6));
503
+ // EXPECT_THAT(3, Not(InClosedRange(2, 4)));
504
+ //
505
+ // would generate two failures that contain the text:
506
+ //
507
+ // Expected: in closed range (4, 6)
508
+ // ...
509
+ // Expected: not (in closed range (2, 4))
510
+ //
511
+ // Types of Matcher Parameters
512
+ // ===========================
513
+ //
514
+ // For the purpose of typing, you can view
515
+ //
516
+ // MATCHER_Pk(Foo, p1, ..., pk, description_string) { ... }
517
+ //
518
+ // as shorthand for
519
+ //
520
+ // template <typename p1_type, ..., typename pk_type>
521
+ // FooMatcherPk<p1_type, ..., pk_type>
522
+ // Foo(p1_type p1, ..., pk_type pk) { ... }
523
+ //
524
+ // When you write Foo(v1, ..., vk), the compiler infers the types of
525
+ // the parameters v1, ..., and vk for you. If you are not happy with
526
+ // the result of the type inference, you can specify the types by
527
+ // explicitly instantiating the template, as in Foo<long, bool>(5,
528
+ // false). As said earlier, you don't get to (or need to) specify
529
+ // 'arg_type' as that's determined by the context in which the matcher
530
+ // is used. You can assign the result of expression Foo(p1, ..., pk)
531
+ // to a variable of type FooMatcherPk<p1_type, ..., pk_type>. This
532
+ // can be useful when composing matchers.
533
+ //
534
+ // While you can instantiate a matcher template with reference types,
535
+ // passing the parameters by pointer usually makes your code more
536
+ // readable. If, however, you still want to pass a parameter by
537
+ // reference, be aware that in the failure message generated by the
538
+ // matcher you will see the value of the referenced object but not its
539
+ // address.
540
+ //
541
+ // Explaining Match Results
542
+ // ========================
543
+ //
544
+ // Sometimes the matcher description alone isn't enough to explain why
545
+ // the match has failed or succeeded. For example, when expecting a
546
+ // long string, it can be very helpful to also print the diff between
547
+ // the expected string and the actual one. To achieve that, you can
548
+ // optionally stream additional information to a special variable
549
+ // named result_listener, whose type is a pointer to class
550
+ // MatchResultListener:
551
+ //
552
+ // MATCHER_P(EqualsLongString, str, "") {
553
+ // if (arg == str) return true;
554
+ //
555
+ // *result_listener << "the difference: "
556
+ /// << DiffStrings(str, arg);
557
+ // return false;
558
+ // }
559
+ //
560
+ // Overloading Matchers
561
+ // ====================
562
+ //
563
+ // You can overload matchers with different numbers of parameters:
564
+ //
565
+ // MATCHER_P(Blah, a, description_string1) { ... }
566
+ // MATCHER_P2(Blah, a, b, description_string2) { ... }
567
+ //
568
+ // Caveats
569
+ // =======
570
+ //
571
+ // When defining a new matcher, you should also consider implementing
572
+ // MatcherInterface or using MakePolymorphicMatcher(). These
573
+ // approaches require more work than the MATCHER* macros, but also
574
+ // give you more control on the types of the value being matched and
575
+ // the matcher parameters, which may leads to better compiler error
576
+ // messages when the matcher is used wrong. They also allow
577
+ // overloading matchers based on parameter types (as opposed to just
578
+ // based on the number of parameters).
579
+ //
580
+ // MATCHER*() can only be used in a namespace scope. The reason is
581
+ // that C++ doesn't yet allow function-local types to be used to
582
+ // instantiate templates. The up-coming C++0x standard will fix this.
583
+ // Once that's done, we'll consider supporting using MATCHER*() inside
584
+ // a function.
585
+ //
586
+ // More Information
587
+ // ================
588
+ //
589
+ // To learn more about using these macros, please search for 'MATCHER'
590
+ // on http://code.google.com/p/googlemock/wiki/CookBook.
591
+
592
+ $range i 0..n
593
+ $for i
594
+
595
+ [[
596
+ $var macro_name = [[$if i==0 [[MATCHER]] $elif i==1 [[MATCHER_P]]
597
+ $else [[MATCHER_P$i]]]]
598
+ $var class_name = [[name##Matcher[[$if i==0 [[]] $elif i==1 [[P]]
599
+ $else [[P$i]]]]]]
600
+ $range j 0..i-1
601
+ $var template = [[$if i==0 [[]] $else [[
602
+
603
+ template <$for j, [[typename p$j##_type]]>\
604
+ ]]]]
605
+ $var ctor_param_list = [[$for j, [[p$j##_type gmock_p$j]]]]
606
+ $var impl_ctor_param_list = [[$for j, [[p$j##_type gmock_p$j]]]]
607
+ $var impl_inits = [[$if i==0 [[]] $else [[ : $for j, [[p$j(gmock_p$j)]]]]]]
608
+ $var inits = [[$if i==0 [[]] $else [[ : $for j, [[p$j(gmock_p$j)]]]]]]
609
+ $var params = [[$for j, [[p$j]]]]
610
+ $var param_types = [[$if i==0 [[]] $else [[<$for j, [[p$j##_type]]>]]]]
611
+ $var param_types_and_names = [[$for j, [[p$j##_type p$j]]]]
612
+ $var param_field_decls = [[$for j
613
+ [[
614
+
615
+ p$j##_type p$j;\
616
+ ]]]]
617
+ $var param_field_decls2 = [[$for j
618
+ [[
619
+
620
+ p$j##_type p$j;\
621
+ ]]]]
622
+
623
+ #define $macro_name(name$for j [[, p$j]], description)\$template
624
+ class $class_name {\
625
+ public:\
626
+ template <typename arg_type>\
627
+ class gmock_Impl : public ::testing::MatcherInterface<arg_type> {\
628
+ public:\
629
+ [[$if i==1 [[explicit ]]]]gmock_Impl($impl_ctor_param_list)\
630
+ $impl_inits {}\
631
+ virtual bool MatchAndExplain(\
632
+ arg_type arg, ::testing::MatchResultListener* result_listener) const;\
633
+ virtual void DescribeTo(::std::ostream* gmock_os) const {\
634
+ *gmock_os << FormatDescription(false);\
635
+ }\
636
+ virtual void DescribeNegationTo(::std::ostream* gmock_os) const {\
637
+ *gmock_os << FormatDescription(true);\
638
+ }\$param_field_decls
639
+ private:\
640
+ ::testing::internal::string FormatDescription(bool negation) const {\
641
+ const ::testing::internal::string gmock_description = (description);\
642
+ if (!gmock_description.empty())\
643
+ return gmock_description;\
644
+ return ::testing::internal::FormatMatcherDescription(\
645
+ negation, #name, \
646
+ ::testing::internal::UniversalTersePrintTupleFieldsToStrings(\
647
+ ::testing::tuple<$for j, [[p$j##_type]]>($for j, [[p$j]])));\
648
+ }\
649
+ GTEST_DISALLOW_ASSIGN_(gmock_Impl);\
650
+ };\
651
+ template <typename arg_type>\
652
+ operator ::testing::Matcher<arg_type>() const {\
653
+ return ::testing::Matcher<arg_type>(\
654
+ new gmock_Impl<arg_type>($params));\
655
+ }\
656
+ [[$if i==1 [[explicit ]]]]$class_name($ctor_param_list)$inits {\
657
+ }\$param_field_decls2
658
+ private:\
659
+ GTEST_DISALLOW_ASSIGN_($class_name);\
660
+ };\$template
661
+ inline $class_name$param_types name($param_types_and_names) {\
662
+ return $class_name$param_types($params);\
663
+ }\$template
664
+ template <typename arg_type>\
665
+ bool $class_name$param_types::gmock_Impl<arg_type>::MatchAndExplain(\
666
+ arg_type arg, \
667
+ ::testing::MatchResultListener* result_listener GTEST_ATTRIBUTE_UNUSED_)\
668
+ const
669
+ ]]
670
+
671
+
672
+ #endif // GMOCK_INCLUDE_GMOCK_GMOCK_GENERATED_MATCHERS_H_