aboutsummaryrefslogtreecommitdiffstats
path: root/test/gmock-generated-function-mockers_test.cc
diff options
context:
space:
mode:
authorkosak <kosak@google.com>2014-01-13 22:28:01 +0000
committerkosak <kosak@google.com>2014-01-13 22:28:01 +0000
commitb93d0f10d5a1bab088223a57420ef599b26a5e0f (patch)
tree87ef35fe99962b8de504902528d8be44a58b1450 /test/gmock-generated-function-mockers_test.cc
parent04ce8521f481d857db1aa00a206278759b9b0381 (diff)
downloadgoogletest-b93d0f10d5a1bab088223a57420ef599b26a5e0f.tar.gz
googletest-b93d0f10d5a1bab088223a57420ef599b26a5e0f.tar.bz2
googletest-b93d0f10d5a1bab088223a57420ef599b26a5e0f.zip
Make Google Mock build cleanly on Visual Studio 2010, 2012, 2013.
Diffstat (limited to 'test/gmock-generated-function-mockers_test.cc')
-rw-r--r--test/gmock-generated-function-mockers_test.cc11
1 files changed, 11 insertions, 0 deletions
diff --git a/test/gmock-generated-function-mockers_test.cc b/test/gmock-generated-function-mockers_test.cc
index ea49b9c1..169ed5a2 100644
--- a/test/gmock-generated-function-mockers_test.cc
+++ b/test/gmock-generated-function-mockers_test.cc
@@ -112,6 +112,14 @@ class FooInterface {
#endif // GTEST_OS_WINDOWS
};
+// Const qualifiers on arguments were once (incorrectly) considered
+// significant in determining whether two virtual functions had the same
+// signature. This was fixed in Visual Studio 2008. However, the compiler
+// still emits a warning that alerts about this change in behavior.
+#ifdef _MSC_VER
+# pragma warning(push)
+# pragma warning(disable : 4373)
+#endif
class MockFoo : public FooInterface {
public:
MockFoo() {}
@@ -167,6 +175,9 @@ class MockFoo : public FooInterface {
private:
GTEST_DISALLOW_COPY_AND_ASSIGN_(MockFoo);
};
+#ifdef _MSC_VER
+# pragma warning(pop)
+#endif
class FunctionMockerTest : public testing::Test {
protected: