summaryrefslogtreecommitdiff
path: root/qpid/cpp/src/tests/qpid_send.cpp
diff options
context:
space:
mode:
authorAlan Conway <aconway@apache.org>2010-04-21 14:48:58 +0000
committerAlan Conway <aconway@apache.org>2010-04-21 14:48:58 +0000
commitc0d39fa7f5075054e598e61bbea140d08648c40d (patch)
tree45098bd3bbfdd83e88131426c77437c8613fd8d4 /qpid/cpp/src/tests/qpid_send.cpp
parente9c27048f9538d7484f9537e43f357df5f20b4e1 (diff)
downloadqpid-python-c0d39fa7f5075054e598e61bbea140d08648c40d.tar.gz
Consistent use of string constants for message property keys in sender/receiver tests.
git-svn-id: https://svn.apache.org/repos/asf/qpid/trunk@936337 13f79535-47bb-0310-9956-ffa450edef68
Diffstat (limited to 'qpid/cpp/src/tests/qpid_send.cpp')
-rw-r--r--qpid/cpp/src/tests/qpid_send.cpp8
1 files changed, 5 insertions, 3 deletions
diff --git a/qpid/cpp/src/tests/qpid_send.cpp b/qpid/cpp/src/tests/qpid_send.cpp
index ec6586323f..27f9b667c6 100644
--- a/qpid/cpp/src/tests/qpid_send.cpp
+++ b/qpid/cpp/src/tests/qpid_send.cpp
@@ -192,6 +192,8 @@ struct Options : public qpid::Options
};
const string EOS("eos");
+const string SN("sn");
+const string TS("ts");
}} // namespace qpid::tests
@@ -278,8 +280,8 @@ int main(int argc, char ** argv)
if (opts.rate) interval = qpid::sys::TIME_SEC/opts.rate;
while (contentGen->setContent(msg)) {
- msg.getProperties()["sn"] = ++sent;
- msg.getProperties()["ts"] = int64_t(
+ msg.getProperties()[SN] = ++sent;
+ msg.getProperties()[TS] = int64_t(
qpid::sys::Duration(qpid::sys::EPOCH, qpid::sys::now()));
sender.send(msg);
reporter.message(msg);
@@ -300,7 +302,7 @@ int main(int argc, char ** argv)
}
if (opts.reportTotal) reporter.report();
for (uint i = opts.sendEos; i > 0; --i) {
- msg.getProperties()["sn"] = ++sent;
+ msg.getProperties()[SN] = ++sent;
msg.setContent(EOS);//TODO: add in ability to send digest or similar
sender.send(msg);
}