mirror of
https://github.com/valitydev/osquery-1.git
synced 2024-11-07 18:08:53 +00:00
status default constructor
This commit is contained in:
parent
e23e7bdab8
commit
7d387ec605
@ -14,6 +14,12 @@ TEST_F(StatusTests, test_constructor) {
|
||||
EXPECT_EQ(s.getMessage(), "message");
|
||||
}
|
||||
|
||||
TEST_F(StatusTests, test_constructor_2) {
|
||||
Status s;
|
||||
EXPECT_EQ(s.getCode(), 0);
|
||||
EXPECT_EQ(s.getMessage(), "OK");
|
||||
}
|
||||
|
||||
TEST_F(StatusTests, test_ok) {
|
||||
auto s1 = Status(5, "message");
|
||||
EXPECT_FALSE(s1.ok());
|
||||
|
@ -9,6 +9,7 @@ namespace osquery {
|
||||
|
||||
class Status {
|
||||
public:
|
||||
Status() : code_(0), message_("OK") {}
|
||||
Status(int c, std::string m) : code_(c), message_(m) {}
|
||||
|
||||
public:
|
||||
|
Loading…
Reference in New Issue
Block a user