summaryrefslogtreecommitdiffstats
path: root/googlemock/test/gmock-matchers_test.cc
diff options
context:
space:
mode:
authorGennadiy Civil <misterg@google.com>2018-07-20 15:28:58 (GMT)
committerGennadiy Civil <misterg@google.com>2018-07-20 15:28:58 (GMT)
commita02af2f689426aa9622b06643f53ed27fa6dc8a5 (patch)
tree0fae2f56aba6c1275fdca61d4ef6f2131f2e7f12 /googlemock/test/gmock-matchers_test.cc
parentc62c79432bd23762a99a6658380fd202f858d7a9 (diff)
downloadgoogletest-a02af2f689426aa9622b06643f53ed27fa6dc8a5.zip
googletest-a02af2f689426aa9622b06643f53ed27fa6dc8a5.tar.gz
googletest-a02af2f689426aa9622b06643f53ed27fa6dc8a5.tar.bz2
Diffstat (limited to 'googlemock/test/gmock-matchers_test.cc')
-rw-r--r--googlemock/test/gmock-matchers_test.cc5
1 files changed, 4 insertions, 1 deletions
diff --git a/googlemock/test/gmock-matchers_test.cc b/googlemock/test/gmock-matchers_test.cc
index f9dfd3c..9f1a547 100644
--- a/googlemock/test/gmock-matchers_test.cc
+++ b/googlemock/test/gmock-matchers_test.cc
@@ -2795,7 +2795,6 @@ TEST(ElementsAreTest, HugeMatcherUnordered) {
#endif // GTEST_LANG_CXX11
-
// Tests that AnyOf(m1, ..., mn) describes itself properly.
TEST(AnyOfTest, CanDescribeSelf) {
Matcher<int> m;
@@ -4239,13 +4238,17 @@ TEST(PropertyTest, WorksForReferenceToConstProperty) {
// ref-qualified.
TEST(PropertyTest, WorksForRefQualifiedProperty) {
Matcher<const AClass&> m = Property(&AClass::s_ref, StartsWith("hi"));
+ Matcher<const AClass&> m_with_name =
+ Property("s", &AClass::s_ref, StartsWith("hi"));
AClass a;
a.set_s("hill");
EXPECT_TRUE(m.Matches(a));
+ EXPECT_TRUE(m_with_name.Matches(a));
a.set_s("hole");
EXPECT_FALSE(m.Matches(a));
+ EXPECT_FALSE(m_with_name.Matches(a));
}
#endif