GTest support

Overview

Test API for run Google Test binaries

Copyright (C) 2019-2022 OKTET Labs Ltd. More…

// typedefs

typedef struct tapi_gtest_impl tapi_gtest_impl;
typedef struct tapi_gtest tapi_gtest;

// structs

struct tapi_gtest;
struct tapi_gtest_impl;

// global functions

te_errno tapi_gtest_init(tapi_gtest* gtest, tapi_job_factory_t* factory);
te_errno tapi_gtest_start(tapi_gtest* gtest);
te_errno tapi_gtest_stop(tapi_gtest* gtest);
te_errno tapi_gtest_wait(tapi_gtest* gtest, int timeout_ms);
te_errno tapi_gtest_fini(tapi_gtest* gtest);

// macros

#define TAPI_GTEST_DEFAULTS
#define TAPI_GTEST_IMPL_DEFAULTS
#define TEST_GET_GTEST_PARAM(_gtest)
#define TEST_GTEST_PARAM(_gtest)

Detailed Documentation

Test API for run Google Test binaries

Copyright (C) 2019-2022 OKTET Labs Ltd. All rights reserved.

Typedefs

typedef struct tapi_gtest_impl tapi_gtest_impl

Internal implementation struct

typedef struct tapi_gtest tapi_gtest

GTest handler

Global Functions

te_errno tapi_gtest_init(tapi_gtest* gtest, tapi_job_factory_t* factory)

Create GTest

Parameters:

gtest

GTest handler

factory

Job factory

Returns:

Status code

te_errno tapi_gtest_start(tapi_gtest* gtest)

Start GTest

Parameters:

gtest

GTest handler

Returns:

Status code

te_errno tapi_gtest_stop(tapi_gtest* gtest)

Stop GTest

Parameters:

gtest

GTest handler

Returns:

Status code

te_errno tapi_gtest_wait(tapi_gtest* gtest, int timeout_ms)

Wait GTest and get result

Parameters:

gtest

GTest handler

timeout_ms

Timeout for wait

Returns:

Status code

te_errno tapi_gtest_fini(tapi_gtest* gtest)

Cleanup GTest

Parameters:

gtest

GTest handler

Returns:

Status code

Macros

#define TAPI_GTEST_DEFAULTS

Defaults for implementation for GTest handler

#define TAPI_GTEST_IMPL_DEFAULTS

Defaults for implementation struct

#define TEST_GET_GTEST_PARAM(_gtest)

A way for read gtest option from test arguments

#define TEST_GTEST_PARAM(_gtest)

A way for read gtest option from test arguments