Andrew Wong has posted comments on this change. ( 
http://gerrit.cloudera.org:8080/16525 )

Change subject: txn_participant-itest: deflake TestFrequentElections
......................................................................


Patch Set 2:

(2 comments)

http://gerrit.cloudera.org:8080/#/c/16525/2/src/kudu/integration-tests/txn_participant-itest.cc
File src/kudu/integration-tests/txn_participant-itest.cc:

http://gerrit.cloudera.org:8080/#/c/16525/2/src/kudu/integration-tests/txn_participant-itest.cc@98
PS2, Line 98: string TxnsAsString(const vector<TxnParticipant::TxnEntry>& txns) 
{
            :   return JoinMapped(txns,
            :       [](const TxnParticipant::TxnEntry& txn) {
            :         return Substitute("(txn_id=$0: $1, $2)",
            :             txn.txn_id, Txn::StateToString(txn.state), 
txn.commit_timestamp);
            :       },
            :       ",");
            : }
> Would
I find Substitute() and std::string a bit more flexible and easier to use than 
ostream, especially when printing multiple results.


http://gerrit.cloudera.org:8080/#/c/16525/2/src/kudu/integration-tests/txn_participant-itest.cc@349
PS2, Line 349:           << Substitute("Expected: $0,\nActual: $1",
             :                         TxnsAsString(expected_txns), 
TxnsAsString(actual_txns));
> Would you get this for free from the gtest framework if defining
I find Substitute() and std::string a bit more flexible and easier to use than 
ostream, especially when printing multiple results.



--
To view, visit http://gerrit.cloudera.org:8080/16525
To unsubscribe, visit http://gerrit.cloudera.org:8080/settings

Gerrit-Project: kudu
Gerrit-Branch: master
Gerrit-MessageType: comment
Gerrit-Change-Id: I71e168c79276ec2ebbb7561dccb7cef69723c544
Gerrit-Change-Number: 16525
Gerrit-PatchSet: 2
Gerrit-Owner: Andrew Wong <[email protected]>
Gerrit-Reviewer: Alexey Serbin <[email protected]>
Gerrit-Reviewer: Andrew Wong <[email protected]>
Gerrit-Reviewer: Grant Henke <[email protected]>
Gerrit-Reviewer: Kudu Jenkins (120)
Gerrit-Reviewer: Tidy Bot (241)
Gerrit-Comment-Date: Thu, 01 Oct 2020 23:24:06 +0000
Gerrit-HasComments: Yes

Reply via email to