markdown C ++ Google Test

Posted

tags:

篇首语:本文由小常识网(cha138.com)小编为大家整理,主要介绍了markdown C ++ Google Test相关的知识,希望对你有一定的参考价值。

## Organization:
+ project_folder
   - my_component.h
   - my_component.cpp
   - project.mk
   + unit_tests
      - my_component.t.cpp
      - unit_tests.mk
   + integration tests
      - my_component.t.cpp
      -integration_tests.mk

## Features
```
EXPECT_TRUE(valueToTest);
EXPECT_FALSE(valueToTest);
EXPECT_EQ(expected, valueToTest);
EXPECT_LT(value1, value2);
EXPECT_LE(value1, value2);
EXPECT_GT(value1, value2);
EXPECT_GE(value1, value2);
EXPECT_STREQ(expected, valueToTest);

EXPECT_THROW(statement, typeOfException);
EXPECT_NO_THROW(statement);

EXPECT_DOUBLE_EQ(expectedValue, valueToTest);
EXPECT_NEAR(value1, value2, allowedError);
```

以上是关于markdown C ++ Google Test的主要内容,如果未能解决你的问题,请参考以下文章

ubuntu安装google test

Linux 下使用Google Test

Google Test 安装

Google Test 安装

Markdown - Test

Blog Test - MarkDown Test