Skip to content

Instantly share code, notes, and snippets.

@zhaofeng-shu33
Created November 16, 2019 02:40
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save zhaofeng-shu33/be6720ad833061d0b1b107da57a8de8a to your computer and use it in GitHub Desktop.
Save zhaofeng-shu33/be6720ad833061d0b1b107da57a8de8a to your computer and use it in GitHub Desktop.
#include <gtest/gtest.h>
class A : public testing::Test {
protected:
int a;
void SetUp() override {
a = 2;
}
};
TEST_F(A, power) {
EXPECT_EQ(a * a, 4);
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment