Skip to content

Commit

Permalink
Verify the value of "annotation.event()" property in the unit test
Browse files Browse the repository at this point in the history
  • Loading branch information
przemekwitek committed Jun 10, 2020
1 parent 2a4841c commit 4328be7
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 1 deletion.
2 changes: 1 addition & 1 deletion include/api/CAnnotationJsonWriter.h
Expand Up @@ -38,7 +38,7 @@ class API_EXPORT CAnnotationJsonWriter final : private core::CNonCopyable {
private:
void populateAnnotationObject(const std::string& jobId,
const model::CAnnotation& annotation,
rapidjson::Value& doc);
rapidjson::Value& obj);

private:
//! JSON line writer
Expand Down
2 changes: 2 additions & 0 deletions lib/api/unittest/CAnnotationJsonWriterTest.cc
Expand Up @@ -68,6 +68,8 @@ BOOST_AUTO_TEST_CASE(testWrite) {
BOOST_TEST_REQUIRE(annotation.HasMember("annotation"));
BOOST_REQUIRE_EQUAL(std::string("annotation text"),
std::string(annotation["annotation"].GetString()));
BOOST_REQUIRE_EQUAL(std::string("model_change"),
std::string(annotation["event"].GetString()));
}

BOOST_AUTO_TEST_SUITE_END()

0 comments on commit 4328be7

Please sign in to comment.