• Home
  • History
  • Annotate
  • Raw
  • Download
  • only in /freebsd-13-stable/contrib/googletest/googlemock/test/

Lines Matching refs:Action

57 using testing::Action;
396 Action<MyGlobalFunction> action = MakeAction(new MyActionImpl);
398 // When exercising the Perform() method of Action<F>, we must pass
406 // Tests that Action<F> can be contructed from a pointer to
409 Action<MyGlobalFunction> action(new MyActionImpl);
412 // Tests that Action<F> delegates actual work to ActionInterface<F>.
414 const Action<MyGlobalFunction> action(new MyActionImpl);
420 // Tests that Action<F> can be copied.
422 Action<MyGlobalFunction> a1(new MyActionImpl);
423 Action<MyGlobalFunction> a2(a1); // Tests the copy constructor.
444 // Tests that an Action<From> object can be converted to a
445 // compatible Action<To> object.
461 const Action<bool(int)> a1(new IsNotZero); // NOLINT
462 const Action<int(char)> a2 = Action<int(char)>(a1); // NOLINT
511 Action<int(bool, int, double)> a1 = ReturnSecondArgument(); // NOLINT
518 Action<int()> a1 = ReturnZeroFromNullaryFunction();
521 Action<void*()> a2 = ReturnZeroFromNullaryFunction();
528 const Action<void(int)> ret = Return(); // NOLINT
534 Action<int()> ret = Return(1); // NOLINT
543 Action<const char*()> a1 = Return("Hello");
546 Action<std::string()> a2 = Return("world");
563 // Return() called with 'v' as argument. The Action will return the same data
565 Action<IntegerVectorWrapper()> a = Return(v);
583 Action<Base*()> ret = Return(&base);
591 // when the action is cast to Action<T(...)> rather than when the action is
614 Action<ToType()> action(Return(x));
619 EXPECT_FALSE(converted) << "Action must NOT convert its argument "
633 Action<DestinationType()> action(Return(s));
638 const Action<int*()> a1 = ReturnNull();
641 const Action<const char*(bool)> a2 = ReturnNull(); // NOLINT
649 const Action<std::unique_ptr<const int>()> a1 = ReturnNull();
652 const Action<std::shared_ptr<int>(std::string)> a2 = ReturnNull();
660 const Action<const int&(bool)> ret = ReturnRef(n); // NOLINT
669 Action<Base&()> a = ReturnRef(base);
679 const Action<const int&()> ret = ReturnRefOfCopy(n);
693 Action<Base&()> a = ReturnRefOfCopy(base);
799 Action<MyFunction> a = SetArgPointee<1>(2);
820 Action<MyFunction> a = SetArgPointee<0>("hi");
836 Action<MyFunction> a = SetArgPointee<0>(L"world");
844 Action<MyStringFunction> a2 = SetArgPointee<0>(L"world");
857 Action<MyFunction> a = SetArgPointee<1>(hi);
876 Action<MyFunction> a = SetArgPointee<1>(hi);
886 Action<MyStringFunction> a2 = SetArgPointee<1>(world);
897 Action<MyFunction> a = SetArgumentPointee<1>(2);
942 Action<int(int)> a = InvokeWithoutArgs(Nullary); // NOLINT
946 Action<int(int, double)> a2 = InvokeWithoutArgs(Nullary); // NOLINT
950 Action<void(int)> a3 = InvokeWithoutArgs(VoidNullary); // NOLINT
959 Action<int()> a = InvokeWithoutArgs(NullaryFunctor()); // NOLINT
963 Action<int(int, double, char)> a2 = // NOLINT
968 Action<void()> a3 = InvokeWithoutArgs(VoidNullaryFunctor());
977 Action<int(bool, char)> a = // NOLINT
984 Action<void(int)> a = IgnoreResult(Return(5)); // NOLINT
997 Action<void()> a = IgnoreResult(Invoke(ReturnOne));
1011 Action<void(int)> a =
1019 Action<void(int)> a = Assign(&x, 5);
1026 Action<void(void)> a = Assign(&x, "Hello, world");
1033 Action<void(int)> a = Assign(&x, 5);
1047 Action<int(void)> a = SetErrnoAndReturn(ENOTTY, -5);
1054 Action<int*(void)> a = SetErrnoAndReturn(ENOTTY, &x);
1060 Action<double()> a = SetErrnoAndReturn(EINVAL, 5);
1289 Action<int(int, int&, int*)> a = &Add;
1295 Action<int(std::unique_ptr<int>)> a1 = &Deref;
1300 Action<int(bool, int)> a1 = [](bool b, int i) { return b ? i : 0; };
1305 Action<void(std::unique_ptr<int>)> a2 = [&saved](std::unique_ptr<int> p) {
1313 Action<int(int)> ai = Double();
1315 Action<double(double)> ad = Double(); // Double? Double double!
1321 const Action<bool(int)> a1 = [](int i) { return i > 1; };
1322 const Action<int(bool)> a2 = Action<int(bool)>(a1);
1327 const Action<bool(std::string)> s1 = [](std::string s) { return !s.empty(); };
1328 const Action<int(const char*)> s2 = Action<int(const char*)>(s1);
1333 const Action<bool(std::string)> x = [](Unused) { return 42; };
1339 Action<int(int, double y, double z)> a =
1351 Action<int(std::unique_ptr<int>)> a = Return(1);
1357 Action<void(std::unique_ptr<int>, int*)> a2 = testing::SetArgPointee<1>(3);