Xmipp  v3.23.11-Nereus
Namespaces | Classes | Typedefs | Functions | Variables
testing Namespace Reference

Namespaces

 gmock_matchers_test
 
 internal
 

Classes

class  Action
 
class  Action< R(Args...)>
 
class  ActionInterface
 
class  DefaultValue
 
class  DefaultValue< T & >
 
class  DefaultValue< void >
 
class  EmptyTestEventListener
 
class  Environment
 
class  Matcher
 
class  Message
 
class  NaggyMock
 
class  NiceMock
 
class  OnceAction
 
class  OnceAction< Result(Args...)>
 
class  PolymorphicAction
 
struct  PrintToStringParamName
 
class  ScopedTrace
 
class  StrictMock
 
class  Test
 
class  TestEventListener
 
class  TestEventListeners
 
class  TestInfo
 
struct  TestParamInfo
 
class  TestProperty
 
class  TestResult
 
class  TestSuite
 
class  TestWithParam
 
class  UnitTest
 
class  WithParamInterface
 

Typedefs

typedef internal::IgnoredValue Unused
 
using TestCase = TestSuite
 
typedef internal::TimeInMillis TimeInMillis
 
template<typename... Ts>
using Types = internal::ProxyTypeList< Ts... >
 

Functions

template<typename F >
Action< F > MakeAction (ActionInterface< F > *impl)
 
template<typename Impl >
PolymorphicAction< Impl > MakePolymorphicAction (const Impl &impl)
 
template<typename... Action>
internal::DoAllAction< typename std::decay< Action >::type... > DoAll (Action &&... action)
 
template<size_t k, typename InnerAction >
internal::WithArgsAction< typename std::decay< InnerAction >::type, kWithArg (InnerAction &&action)
 
template<size_t k, size_t... ks, typename InnerAction >
internal::WithArgsAction< typename std::decay< InnerAction >::type, k, ks... > WithArgs (InnerAction &&action)
 
template<typename InnerAction >
internal::WithArgsAction< typename std::decay< InnerAction >::typeWithoutArgs (InnerAction &&action)
 
template<typename R >
internal::ReturnAction< R > Return (R value)
 
PolymorphicAction< internal::ReturnNullActionReturnNull ()
 
PolymorphicAction< internal::ReturnVoidActionReturn ()
 
template<typename R >
internal::ReturnRefAction< R > ReturnRef (R &x)
 
template<typename R , R * = nullptr>
internal::ReturnRefAction< R > ReturnRef (R &&)=delete
 
template<typename R >
internal::ReturnRefOfCopyAction< R > ReturnRefOfCopy (const R &x)
 
template<typename R >
internal::ByMoveWrapper< R > ByMove (R x)
 
template<typename T >
internal::ReturnRoundRobinAction< T > ReturnRoundRobin (std::vector< T > vals)
 
template<typename T >
internal::ReturnRoundRobinAction< T > ReturnRoundRobin (std::initializer_list< T > vals)
 
internal::DoDefaultAction DoDefault ()
 
template<size_t N, typename T >
internal::SetArgumentPointeeAction< N, T > SetArgPointee (T value)
 
template<size_t N, typename T >
internal::SetArgumentPointeeAction< N, T > SetArgumentPointee (T value)
 
template<typename T1 , typename T2 >
PolymorphicAction< internal::AssignAction< T1, T2 > > Assign (T1 *ptr, T2 val)
 
template<typename T >
PolymorphicAction< internal::SetErrnoAndReturnAction< T > > SetErrnoAndReturn (int errval, T result)
 
template<typename FunctionImpl >
std::decay< FunctionImpl >::type Invoke (FunctionImpl &&function_impl)
 
template<class Class , typename MethodPtr >
internal::InvokeMethodAction< Class, MethodPtr > Invoke (Class *obj_ptr, MethodPtr method_ptr)
 
template<typename FunctionImpl >
internal::InvokeWithoutArgsAction< typename std::decay< FunctionImpl >::typeInvokeWithoutArgs (FunctionImpl function_impl)
 
template<class Class , typename MethodPtr >
internal::InvokeMethodWithoutArgsAction< Class, MethodPtr > InvokeWithoutArgs (Class *obj_ptr, MethodPtr method_ptr)
 
template<typename A >
internal::IgnoreResultAction< A > IgnoreResult (const A &an_action)
 
template<typename T >
inline ::std::reference_wrapper< T > ByRef (T &l_value)
 
template<typename T , typename... Params>
internal::ReturnNewAction< T, typename std::decay< Params >::type... > ReturnNew (Params &&... params)
 
template<size_t k>
internal::ReturnArgAction< kReturnArg ()
 
template<size_t k, typename Ptr >
internal::SaveArgAction< k, Ptr > SaveArg (Ptr pointer)
 
template<size_t k, typename Ptr >
internal::SaveArgPointeeAction< k, Ptr > SaveArgPointee (Ptr pointer)
 
template<size_t k, typename T >
internal::SetArgRefereeAction< k, typename std::decay< T >::typeSetArgReferee (T &&value)
 
template<size_t k, typename I1 , typename I2 >
internal::SetArrayArgumentAction< k, I1, I2 > SetArrayArgument (I1 first, I2 last)
 
template<size_t k>
internal::DeleteArgAction< kDeleteArg ()
 
template<typename Ptr >
internal::ReturnPointeeAction< Ptr > ReturnPointee (Ptr pointer)
 
template<std::size_t index, typename... Params>
internal::InvokeArgumentAction< index, typename std::decay< Params >::type... > InvokeArgument (Params &&... params)
 
PolymorphicMatcher< internal::IsEmptyMatcherIsEmpty ()
 
 MATCHER (IsTrue, negation ? "is false" :"is true")
 
 MATCHER (IsFalse, negation ? "is true" :"is false")
 
GTEST_API_ void InitGoogleMock (int *argc, char **argv)
 
GTEST_API_ void InitGoogleMock (int *argc, wchar_t **argv)
 
GTEST_API_ void InitGoogleMock ()
 
std::ostream & operator<< (std::ostream &os, const Message &sb)
 
template<typename T , typename IncrementT >
internal::ParamGenerator< T > Range (T start, T end, IncrementT step)
 
template<typename T >
internal::ParamGenerator< T > Range (T start, T end)
 
template<typename ForwardIterator >
internal::ParamGenerator< typename std::iterator_traits< ForwardIterator >::value_type > ValuesIn (ForwardIterator begin, ForwardIterator end)
 
template<typename T , size_t N>
internal::ParamGenerator< T > ValuesIn (const T(&array)[N])
 
template<class Container >
internal::ParamGenerator< typename Container::value_type > ValuesIn (const Container &container)
 
template<typename... T>
internal::ValueArray< T... > Values (T... v)
 
internal::ParamGenerator< bool > Bool ()
 
template<typename... Generator>
internal::CartesianProductHolder< Generator... > Combine (const Generator &... g)
 
template<typename T >
internal::ParamConverterGenerator< T > ConvertGenerator (internal::ParamGenerator< T > gen)
 
template<typename T >
::std::string PrintToString (const T &value)
 
EnvironmentAddGlobalTestEnvironment (Environment *env)
 
GTEST_API_ void InitGoogleTest (int *argc, char **argv)
 
GTEST_API_ void InitGoogleTest (int *argc, wchar_t **argv)
 
GTEST_API_ void InitGoogleTest ()
 
GTEST_API_ AssertionResult IsSubstring (const char *needle_expr, const char *haystack_expr, const char *needle, const char *haystack)
 
GTEST_API_ AssertionResult IsSubstring (const char *needle_expr, const char *haystack_expr, const wchar_t *needle, const wchar_t *haystack)
 
GTEST_API_ AssertionResult IsNotSubstring (const char *needle_expr, const char *haystack_expr, const char *needle, const char *haystack)
 
GTEST_API_ AssertionResult IsNotSubstring (const char *needle_expr, const char *haystack_expr, const wchar_t *needle, const wchar_t *haystack)
 
GTEST_API_ AssertionResult IsSubstring (const char *needle_expr, const char *haystack_expr, const ::std::string &needle, const ::std::string &haystack)
 
GTEST_API_ AssertionResult IsNotSubstring (const char *needle_expr, const char *haystack_expr, const ::std::string &needle, const ::std::string &haystack)
 
GTEST_API_ AssertionResult FloatLE (const char *expr1, const char *expr2, float val1, float val2)
 
GTEST_API_ AssertionResult DoubleLE (const char *expr1, const char *expr2, double val1, double val2)
 
template<typename T1 , typename T2 >
constexpr bool StaticAssertTypeEq () noexcept
 
GTEST_API_ std::string TempDir ()
 
GTEST_API_ std::string SrcDir ()
 
template<int &... ExplicitParameterBarrier, typename Factory >
TestInfoRegisterTest (const char *test_suite_name, const char *test_name, const char *type_param, const char *value_param, const char *file, int line, Factory factory)
 
template<typename Pred , typename T1 >
AssertionResult AssertPred1Helper (const char *pred_text, const char *e1, Pred pred, const T1 &v1)
 
template<typename Pred , typename T1 , typename T2 >
AssertionResult AssertPred2Helper (const char *pred_text, const char *e1, const char *e2, Pred pred, const T1 &v1, const T2 &v2)
 
template<typename Pred , typename T1 , typename T2 , typename T3 >
AssertionResult AssertPred3Helper (const char *pred_text, const char *e1, const char *e2, const char *e3, Pred pred, const T1 &v1, const T2 &v2, const T3 &v3)
 
template<typename Pred , typename T1 , typename T2 , typename T3 , typename T4 >
AssertionResult AssertPred4Helper (const char *pred_text, const char *e1, const char *e2, const char *e3, const char *e4, Pred pred, const T1 &v1, const T2 &v2, const T3 &v3, const T4 &v4)
 
template<typename Pred , typename T1 , typename T2 , typename T3 , typename T4 , typename T5 >
AssertionResult AssertPred5Helper (const char *pred_text, const char *e1, const char *e2, const char *e3, const char *e4, const char *e5, Pred pred, const T1 &v1, const T2 &v2, const T3 &v3, const T4 &v4, const T5 &v5)
 

Variables

const int kMaxStackTraceDepth = 100
 

Typedef Documentation

◆ TestCase

using testing::TestCase = typedef TestSuite

Definition at line 219 of file gtest.h.

◆ TimeInMillis

Definition at line 362 of file gtest.h.

◆ Types

template<typename... Ts>
using testing::Types = typedef internal::ProxyTypeList<Ts...>

Definition at line 186 of file gtest-type-util.h.

◆ Unused

Definition at line 1780 of file gmock-actions.h.

Function Documentation

◆ AddGlobalTestEnvironment()

Environment* testing::AddGlobalTestEnvironment ( Environment env)
inline

Definition at line 1325 of file gtest.h.

1325  {
1326  return UnitTest::GetInstance()->AddEnvironment(env);
1327 }

◆ AssertPred1Helper()

template<typename Pred , typename T1 >
AssertionResult testing::AssertPred1Helper ( const char *  pred_text,
const char *  e1,
Pred  pred,
const T1 &  v1 
)

Definition at line 87 of file gtest_pred_impl.h.

88  {
89  if (pred(v1)) return AssertionSuccess();
90 
91  return AssertionFailure()
92  << pred_text << "(" << e1 << ") evaluates to false, where"
93  << "\n"
94  << e1 << " evaluates to " << ::testing::PrintToString(v1);
95 }
::std::string PrintToString(const T &value)
double v1

◆ AssertPred2Helper()

template<typename Pred , typename T1 , typename T2 >
AssertionResult testing::AssertPred2Helper ( const char *  pred_text,
const char *  e1,
const char *  e2,
Pred  pred,
const T1 &  v1,
const T2 &  v2 
)

Definition at line 118 of file gtest_pred_impl.h.

120  {
121  if (pred(v1, v2)) return AssertionSuccess();
122 
123  return AssertionFailure()
124  << pred_text << "(" << e1 << ", " << e2
125  << ") evaluates to false, where"
126  << "\n"
127  << e1 << " evaluates to " << ::testing::PrintToString(v1) << "\n"
128  << e2 << " evaluates to " << ::testing::PrintToString(v2);
129 }
::std::string PrintToString(const T &value)
double v1

◆ AssertPred3Helper()

template<typename Pred , typename T1 , typename T2 , typename T3 >
AssertionResult testing::AssertPred3Helper ( const char *  pred_text,
const char *  e1,
const char *  e2,
const char *  e3,
Pred  pred,
const T1 &  v1,
const T2 &  v2,
const T3 &  v3 
)

Definition at line 155 of file gtest_pred_impl.h.

157  {
158  if (pred(v1, v2, v3)) return AssertionSuccess();
159 
160  return AssertionFailure()
161  << pred_text << "(" << e1 << ", " << e2 << ", " << e3
162  << ") evaluates to false, where"
163  << "\n"
164  << e1 << " evaluates to " << ::testing::PrintToString(v1) << "\n"
165  << e2 << " evaluates to " << ::testing::PrintToString(v2) << "\n"
166  << e3 << " evaluates to " << ::testing::PrintToString(v3);
167 }
::std::string PrintToString(const T &value)
double v1

◆ AssertPred4Helper()

template<typename Pred , typename T1 , typename T2 , typename T3 , typename T4 >
AssertionResult testing::AssertPred4Helper ( const char *  pred_text,
const char *  e1,
const char *  e2,
const char *  e3,
const char *  e4,
Pred  pred,
const T1 &  v1,
const T2 &  v2,
const T3 &  v3,
const T4 &  v4 
)

Definition at line 194 of file gtest_pred_impl.h.

197  {
198  if (pred(v1, v2, v3, v4)) return AssertionSuccess();
199 
200  return AssertionFailure()
201  << pred_text << "(" << e1 << ", " << e2 << ", " << e3 << ", " << e4
202  << ") evaluates to false, where"
203  << "\n"
204  << e1 << " evaluates to " << ::testing::PrintToString(v1) << "\n"
205  << e2 << " evaluates to " << ::testing::PrintToString(v2) << "\n"
206  << e3 << " evaluates to " << ::testing::PrintToString(v3) << "\n"
207  << e4 << " evaluates to " << ::testing::PrintToString(v4);
208 }
::std::string PrintToString(const T &value)
double v1

◆ AssertPred5Helper()

template<typename Pred , typename T1 , typename T2 , typename T3 , typename T4 , typename T5 >
AssertionResult testing::AssertPred5Helper ( const char *  pred_text,
const char *  e1,
const char *  e2,
const char *  e3,
const char *  e4,
const char *  e5,
Pred  pred,
const T1 &  v1,
const T2 &  v2,
const T3 &  v3,
const T4 &  v4,
const T5 &  v5 
)

Definition at line 236 of file gtest_pred_impl.h.

240  {
241  if (pred(v1, v2, v3, v4, v5)) return AssertionSuccess();
242 
243  return AssertionFailure()
244  << pred_text << "(" << e1 << ", " << e2 << ", " << e3 << ", " << e4
245  << ", " << e5 << ") evaluates to false, where"
246  << "\n"
247  << e1 << " evaluates to " << ::testing::PrintToString(v1) << "\n"
248  << e2 << " evaluates to " << ::testing::PrintToString(v2) << "\n"
249  << e3 << " evaluates to " << ::testing::PrintToString(v3) << "\n"
250  << e4 << " evaluates to " << ::testing::PrintToString(v4) << "\n"
251  << e5 << " evaluates to " << ::testing::PrintToString(v5);
252 }
::std::string PrintToString(const T &value)
double v1

◆ Assign()

template<typename T1 , typename T2 >
PolymorphicAction<internal::AssignAction<T1, T2> > testing::Assign ( T1 *  ptr,
T2  val 
)

Definition at line 1928 of file gmock-actions.h.

1928  {
1929  return MakePolymorphicAction(internal::AssignAction<T1, T2>(ptr, val));
1930 }
PolymorphicAction< Impl > MakePolymorphicAction(const Impl &impl)

◆ Bool()

internal::ParamGenerator<bool> testing::Bool ( )
inline

Definition at line 359 of file gtest-param-test.h.

359 { return Values(false, true); }
internal::ValueArray< T... > Values(T... v)

◆ ByMove()

template<typename R >
internal::ByMoveWrapper<R> testing::ByMove ( x)

Definition at line 1887 of file gmock-actions.h.

1887  {
1888  return internal::ByMoveWrapper<R>(std::move(x));
1889 }
doublereal * x

◆ ByRef()

template<typename T >
inline ::std::reference_wrapper<T> testing::ByRef ( T &  l_value)

Definition at line 1997 of file gmock-actions.h.

1997  { // NOLINT
1998  return ::std::reference_wrapper<T>(l_value);
1999 }

◆ Combine()

template<typename... Generator>
internal::CartesianProductHolder<Generator...> testing::Combine ( const Generator &...  g)

Definition at line 406 of file gtest-param-test.h.

406  {
407  return internal::CartesianProductHolder<Generator...>(g...);
408 }
doublereal * g

◆ ConvertGenerator()

template<typename T >
internal::ParamConverterGenerator<T> testing::ConvertGenerator ( internal::ParamGenerator< T >  gen)

Definition at line 445 of file gtest-param-test.h.

446  {
447  return internal::ParamConverterGenerator<T>(gen);
448 }

◆ DeleteArg()

template<size_t k>
internal::DeleteArgAction<k> testing::DeleteArg ( )

Definition at line 2052 of file gmock-actions.h.

2052  {
2053  return {};
2054 }

◆ DoAll()

template<typename... Action>
internal::DoAllAction<typename std::decay<Action>::type...> testing::DoAll ( Action &&...  action)

Definition at line 1786 of file gmock-actions.h.

1787  {
1789  {}, std::forward<Action>(action)...);
1790 }
viol type

◆ DoDefault()

internal::DoDefaultAction testing::DoDefault ( )
inline

Definition at line 1909 of file gmock-actions.h.

1909  {
1910  return internal::DoDefaultAction();
1911 }

◆ DoubleLE()

GTEST_API_ AssertionResult testing::DoubleLE ( const char *  expr1,
const char *  expr2,
double  val1,
double  val2 
)

◆ FloatLE()

GTEST_API_ AssertionResult testing::FloatLE ( const char *  expr1,
const char *  expr2,
float  val1,
float  val2 
)

◆ IgnoreResult()

template<typename A >
internal::IgnoreResultAction<A> testing::IgnoreResult ( const A &  an_action)
inline

Definition at line 1982 of file gmock-actions.h.

1982  {
1983  return internal::IgnoreResultAction<A>(an_action);
1984 }

◆ InitGoogleMock() [1/3]

GTEST_API_ void testing::InitGoogleMock ( int *  argc,
char **  argv 
)

◆ InitGoogleMock() [2/3]

GTEST_API_ void testing::InitGoogleMock ( int *  argc,
wchar_t **  argv 
)

◆ InitGoogleMock() [3/3]

GTEST_API_ void testing::InitGoogleMock ( )

◆ InitGoogleTest() [1/3]

GTEST_API_ void testing::InitGoogleTest ( int *  argc,
char **  argv 
)

◆ InitGoogleTest() [2/3]

GTEST_API_ void testing::InitGoogleTest ( int *  argc,
wchar_t **  argv 
)

◆ InitGoogleTest() [3/3]

GTEST_API_ void testing::InitGoogleTest ( )

◆ Invoke() [1/2]

template<typename FunctionImpl >
std::decay<FunctionImpl>::type testing::Invoke ( FunctionImpl &&  function_impl)

Definition at line 1951 of file gmock-actions.h.

1951  {
1952  return std::forward<FunctionImpl>(function_impl);
1953 }

◆ Invoke() [2/2]

template<class Class , typename MethodPtr >
internal::InvokeMethodAction<Class, MethodPtr> testing::Invoke ( Class *  obj_ptr,
MethodPtr  method_ptr 
)

Definition at line 1958 of file gmock-actions.h.

1959  {
1960  return {obj_ptr, method_ptr};
1961 }

◆ InvokeArgument()

template<std::size_t index, typename... Params>
internal::InvokeArgumentAction<index, typename std::decay<Params>::type...> testing::InvokeArgument ( Params &&...  params)

Definition at line 651 of file gmock-more-actions.h.

651  {
653  internal::FlatTupleConstructTag{}, std::forward<Params>(params)...)};
654 }
viol type

◆ InvokeWithoutArgs() [1/2]

template<typename FunctionImpl >
internal::InvokeWithoutArgsAction<typename std::decay<FunctionImpl>::type> testing::InvokeWithoutArgs ( FunctionImpl  function_impl)

Definition at line 1966 of file gmock-actions.h.

1966  {
1967  return {std::move(function_impl)};
1968 }

◆ InvokeWithoutArgs() [2/2]

template<class Class , typename MethodPtr >
internal::InvokeMethodWithoutArgsAction<Class, MethodPtr> testing::InvokeWithoutArgs ( Class *  obj_ptr,
MethodPtr  method_ptr 
)

Definition at line 1973 of file gmock-actions.h.

1974  {
1975  return {obj_ptr, method_ptr};
1976 }

◆ IsEmpty()

PolymorphicMatcher<internal::IsEmptyMatcher> testing::IsEmpty ( )
inline

Definition at line 96 of file gmock-more-matchers.h.

96  {
97  return MakePolymorphicMatcher(internal::IsEmptyMatcher());
98 }

◆ IsNotSubstring() [1/3]

GTEST_API_ AssertionResult testing::IsNotSubstring ( const char *  needle_expr,
const char *  haystack_expr,
const char *  needle,
const char *  haystack 
)

◆ IsNotSubstring() [2/3]

GTEST_API_ AssertionResult testing::IsNotSubstring ( const char *  needle_expr,
const char *  haystack_expr,
const wchar_t *  needle,
const wchar_t *  haystack 
)

◆ IsNotSubstring() [3/3]

GTEST_API_ AssertionResult testing::IsNotSubstring ( const char *  needle_expr,
const char *  haystack_expr,
const ::std::string &  needle,
const ::std::string &  haystack 
)

◆ IsSubstring() [1/3]

GTEST_API_ AssertionResult testing::IsSubstring ( const char *  needle_expr,
const char *  haystack_expr,
const char *  needle,
const char *  haystack 
)

◆ IsSubstring() [2/3]

GTEST_API_ AssertionResult testing::IsSubstring ( const char *  needle_expr,
const char *  haystack_expr,
const wchar_t *  needle,
const wchar_t *  haystack 
)

◆ IsSubstring() [3/3]

GTEST_API_ AssertionResult testing::IsSubstring ( const char *  needle_expr,
const char *  haystack_expr,
const ::std::string &  needle,
const ::std::string &  haystack 
)

◆ MakeAction()

template<typename F >
Action<F> testing::MakeAction ( ActionInterface< F > *  impl)

Definition at line 896 of file gmock-actions.h.

896  {
897  return Action<F>(impl);
898 }

◆ MakePolymorphicAction()

template<typename Impl >
PolymorphicAction<Impl> testing::MakePolymorphicAction ( const Impl &  impl)
inline

Definition at line 908 of file gmock-actions.h.

908  {
909  return PolymorphicAction<Impl>(impl);
910 }

◆ MATCHER() [1/2]

testing::MATCHER ( IsTrue  ,
negation ? "is false" :"is true"   
)

Definition at line 104 of file gmock-more-matchers.h.

104  : "is true") {
105  return static_cast<bool>(arg);
106 }

◆ MATCHER() [2/2]

testing::MATCHER ( IsFalse  ,
negation ? "is true" :"is false"   
)

Definition at line 112 of file gmock-more-matchers.h.

112  : "is false") {
113  return !static_cast<bool>(arg);
114 }

◆ operator<<()

std::ostream& testing::operator<< ( std::ostream &  os,
const Message sb 
)
inline

Definition at line 200 of file gtest-message.h.

200  {
201  return os << sb.GetString();
202 }

◆ PrintToString()

template<typename T >
::std::string testing::PrintToString ( const T &  value)

Definition at line 1118 of file gtest-printers.h.

1118  {
1119  ::std::stringstream ss;
1120  internal::UniversalTersePrinter<T>::Print(value, &ss);
1121  return ss.str();
1122 }

◆ Range() [1/2]

template<typename T , typename IncrementT >
internal::ParamGenerator<T> testing::Range ( start,
end,
IncrementT  step 
)

Definition at line 229 of file gtest-param-test.h.

229  {
230  return internal::ParamGenerator<T>(
231  new internal::RangeGenerator<T, IncrementT>(start, end, step));
232 }

◆ Range() [2/2]

template<typename T >
internal::ParamGenerator<T> testing::Range ( start,
end 
)

Definition at line 235 of file gtest-param-test.h.

235  {
236  return Range(start, end, 1);
237 }
internal::ParamGenerator< T > Range(T start, T end)

◆ RegisterTest()

template<int &... ExplicitParameterBarrier, typename Factory >
TestInfo* testing::RegisterTest ( const char *  test_suite_name,
const char *  test_name,
const char *  type_param,
const char *  value_param,
const char *  file,
int  line,
Factory  factory 
)

Definition at line 2280 of file gtest.h.

2282  {
2283  using TestT = typename std::remove_pointer<decltype(factory())>::type;
2284 
2285  class FactoryImpl : public internal::TestFactoryBase {
2286  public:
2287  explicit FactoryImpl(Factory f) : factory_(std::move(f)) {}
2288  Test* CreateTest() override { return factory_(); }
2289 
2290  private:
2291  Factory factory_;
2292  };
2293 
2295  test_suite_name, test_name, type_param, value_param,
2296  internal::CodeLocation(file, line), internal::GetTypeId<TestT>(),
2297  internal::SuiteApiResolver<TestT>::GetSetUpCaseOrSuite(file, line),
2298  internal::SuiteApiResolver<TestT>::GetTearDownCaseOrSuite(file, line),
2299  new FactoryImpl{std::move(factory)});
2300 }
viol type
double * f
GTEST_API_ TestInfo * MakeAndRegisterTestInfo(const char *test_suite_name, const char *name, const char *type_param, const char *value_param, CodeLocation code_location, TypeId fixture_class_id, SetUpTestSuiteFunc set_up_tc, TearDownTestSuiteFunc tear_down_tc, TestFactoryBase *factory)

◆ Return() [1/2]

template<typename R >
internal::ReturnAction<R> testing::Return ( value)

Definition at line 1848 of file gmock-actions.h.

1848  {
1849  return internal::ReturnAction<R>(std::move(value));
1850 }

◆ Return() [2/2]

PolymorphicAction<internal::ReturnVoidAction> testing::Return ( )
inline

Definition at line 1858 of file gmock-actions.h.

1858  {
1859  return MakePolymorphicAction(internal::ReturnVoidAction());
1860 }
PolymorphicAction< Impl > MakePolymorphicAction(const Impl &impl)

◆ ReturnArg()

template<size_t k>
internal::ReturnArgAction<k> testing::ReturnArg ( )

Definition at line 2012 of file gmock-actions.h.

2012  {
2013  return {};
2014 }

◆ ReturnNew()

template<typename T , typename... Params>
internal::ReturnNewAction<T, typename std::decay<Params>::type...> testing::ReturnNew ( Params &&...  params)

Definition at line 2005 of file gmock-actions.h.

2006  {
2007  return {std::forward_as_tuple(std::forward<Params>(params)...)};
2008 }

◆ ReturnNull()

PolymorphicAction<internal::ReturnNullAction> testing::ReturnNull ( )
inline

Definition at line 1853 of file gmock-actions.h.

1853  {
1854  return MakePolymorphicAction(internal::ReturnNullAction());
1855 }
PolymorphicAction< Impl > MakePolymorphicAction(const Impl &impl)

◆ ReturnPointee()

template<typename Ptr >
internal::ReturnPointeeAction<Ptr> testing::ReturnPointee ( Ptr  pointer)

Definition at line 2058 of file gmock-actions.h.

2058  {
2059  return {pointer};
2060 }

◆ ReturnRef() [1/2]

template<typename R >
internal::ReturnRefAction<R> testing::ReturnRef ( R &  x)
inline

Definition at line 1864 of file gmock-actions.h.

1864  { // NOLINT
1865  return internal::ReturnRefAction<R>(x);
1866 }
doublereal * x

◆ ReturnRef() [2/2]

template<typename R , R * = nullptr>
internal::ReturnRefAction<R> testing::ReturnRef ( R &&  )
delete

◆ ReturnRefOfCopy()

template<typename R >
internal::ReturnRefOfCopyAction<R> testing::ReturnRefOfCopy ( const R &  x)
inline

Definition at line 1876 of file gmock-actions.h.

1876  {
1877  return internal::ReturnRefOfCopyAction<R>(x);
1878 }
doublereal * x

◆ ReturnRoundRobin() [1/2]

template<typename T >
internal::ReturnRoundRobinAction<T> testing::ReturnRoundRobin ( std::vector< T >  vals)

Definition at line 1895 of file gmock-actions.h.

1895  {
1896  return internal::ReturnRoundRobinAction<T>(std::move(vals));
1897 }

◆ ReturnRoundRobin() [2/2]

template<typename T >
internal::ReturnRoundRobinAction<T> testing::ReturnRoundRobin ( std::initializer_list< T >  vals)

Definition at line 1903 of file gmock-actions.h.

1904  {
1905  return internal::ReturnRoundRobinAction<T>(std::vector<T>(vals));
1906 }

◆ SaveArg()

template<size_t k, typename Ptr >
internal::SaveArgAction<k, Ptr> testing::SaveArg ( Ptr  pointer)

Definition at line 2019 of file gmock-actions.h.

2019  {
2020  return {pointer};
2021 }

◆ SaveArgPointee()

template<size_t k, typename Ptr >
internal::SaveArgPointeeAction<k, Ptr> testing::SaveArgPointee ( Ptr  pointer)

Definition at line 2026 of file gmock-actions.h.

2026  {
2027  return {pointer};
2028 }

◆ SetArgPointee()

template<size_t N, typename T >
internal::SetArgumentPointeeAction<N, T> testing::SetArgPointee ( value)

Definition at line 1916 of file gmock-actions.h.

1916  {
1917  return {std::move(value)};
1918 }

◆ SetArgReferee()

template<size_t k, typename T >
internal::SetArgRefereeAction<k, typename std::decay<T>::type> testing::SetArgReferee ( T &&  value)

Definition at line 2033 of file gmock-actions.h.

2034  {
2035  return {std::forward<T>(value)};
2036 }

◆ SetArgumentPointee()

template<size_t N, typename T >
internal::SetArgumentPointeeAction<N, T> testing::SetArgumentPointee ( value)

Definition at line 1922 of file gmock-actions.h.

1922  {
1923  return {std::move(value)};
1924 }

◆ SetArrayArgument()

template<size_t k, typename I1 , typename I2 >
internal::SetArrayArgumentAction<k, I1, I2> testing::SetArrayArgument ( I1  first,
I2  last 
)

Definition at line 2044 of file gmock-actions.h.

2045  {
2046  return {first, last};
2047 }
glob_log first

◆ SetErrnoAndReturn()

template<typename T >
PolymorphicAction<internal::SetErrnoAndReturnAction<T> > testing::SetErrnoAndReturn ( int  errval,
result 
)

Definition at line 1936 of file gmock-actions.h.

1937  {
1938  return MakePolymorphicAction(
1939  internal::SetErrnoAndReturnAction<T>(errval, result));
1940 }
PolymorphicAction< Impl > MakePolymorphicAction(const Impl &impl)

◆ SrcDir()

GTEST_API_ std::string testing::SrcDir ( )

◆ StaticAssertTypeEq()

template<typename T1 , typename T2 >
constexpr bool testing::StaticAssertTypeEq ( )
noexcept

Definition at line 2134 of file gtest.h.

2134  {
2135  static_assert(std::is_same<T1, T2>::value, "T1 and T2 are not the same type");
2136  return true;
2137 }

◆ TempDir()

GTEST_API_ std::string testing::TempDir ( )

◆ Values()

template<typename... T>
internal::ValueArray<T...> testing::Values ( T...  v)

Definition at line 335 of file gtest-param-test.h.

335  {
336  return internal::ValueArray<T...>(std::move(v)...);
337 }

◆ ValuesIn() [1/3]

template<typename ForwardIterator >
internal::ParamGenerator< typename std::iterator_traits<ForwardIterator>::value_type> testing::ValuesIn ( ForwardIterator  begin,
ForwardIterator  end 
)

Definition at line 297 of file gtest-param-test.h.

297  {
298  typedef typename std::iterator_traits<ForwardIterator>::value_type ParamType;
299  return internal::ParamGenerator<ParamType>(
300  new internal::ValuesInIteratorRangeGenerator<ParamType>(begin, end));
301 }

◆ ValuesIn() [2/3]

template<typename T , size_t N>
internal::ParamGenerator<T> testing::ValuesIn ( const T(&)  array[N])

Definition at line 304 of file gtest-param-test.h.

304  {
305  return ValuesIn(array, array + N);
306 }
internal::ParamGenerator< typename Container::value_type > ValuesIn(const Container &container)

◆ ValuesIn() [3/3]

template<class Container >
internal::ParamGenerator< typename Container::value_type > testing::ValuesIn ( const Container &  container)

Definition at line 309 of file gtest-param-test.h.

310  {
311  return ValuesIn(container.begin(), container.end());
312 }
internal::ParamGenerator< typename Container::value_type > ValuesIn(const Container &container)

◆ WithArg()

template<size_t k, typename InnerAction >
internal::WithArgsAction<typename std::decay<InnerAction>::type, k> testing::WithArg ( InnerAction &&  action)

Definition at line 1798 of file gmock-actions.h.

1799  {
1800  return {std::forward<InnerAction>(action)};
1801 }

◆ WithArgs()

template<size_t k, size_t... ks, typename InnerAction >
internal::WithArgsAction<typename std::decay<InnerAction>::type, k, ks...> testing::WithArgs ( InnerAction &&  action)

Definition at line 1809 of file gmock-actions.h.

1809  {
1810  return {std::forward<InnerAction>(action)};
1811 }

◆ WithoutArgs()

template<typename InnerAction >
internal::WithArgsAction<typename std::decay<InnerAction>::type> testing::WithoutArgs ( InnerAction &&  action)

Definition at line 1818 of file gmock-actions.h.

1819  {
1820  return {std::forward<InnerAction>(action)};
1821 }

Variable Documentation

◆ kMaxStackTraceDepth

const int testing::kMaxStackTraceDepth = 100

Definition at line 176 of file gtest.h.