summaryrefslogtreecommitdiff
path: root/test/BtAllowedFastMessageTest.cc
diff options
context:
space:
mode:
authorTatsuhiro Tsujikawa <tatsuhiro.t@gmail.com>2015-06-21 18:04:30 +0900
committerTatsuhiro Tsujikawa <tatsuhiro.t@gmail.com>2015-06-21 19:29:54 +0900
commit318c804504e32b7a0bbdbb35336d2e918000d80a (patch)
treefad396aee04c44a29ee79b33e1675db2275146c0 /test/BtAllowedFastMessageTest.cc
parent8ba9b0474747185708a25943fb6d2f97b3d9b17f (diff)
Use user-defined literal for k, m, and g (powers of 1024)
Diffstat (limited to 'test/BtAllowedFastMessageTest.cc')
-rw-r--r--test/BtAllowedFastMessageTest.cc4
1 files changed, 2 insertions, 2 deletions
diff --git a/test/BtAllowedFastMessageTest.cc b/test/BtAllowedFastMessageTest.cc
index a1065997..ab4f9a26 100644
--- a/test/BtAllowedFastMessageTest.cc
+++ b/test/BtAllowedFastMessageTest.cc
@@ -77,7 +77,7 @@ void BtAllowedFastMessageTest::testDoReceivedAction() {
BtAllowedFastMessage msg;
msg.setIndex(1);
std::shared_ptr<Peer> peer(new Peer("localhost", 6969));
- peer->allocateSessionResource(1024, 1024*1024);
+ peer->allocateSessionResource(1_k, 1_m);
peer->setFastExtensionEnabled(true);
msg.setPeer(peer);
CPPUNIT_ASSERT(!peer->isInPeerAllowedIndexSet(1));
@@ -95,7 +95,7 @@ void BtAllowedFastMessageTest::testOnSendComplete() {
BtAllowedFastMessage msg;
msg.setIndex(1);
std::shared_ptr<Peer> peer(new Peer("localhost", 6969));
- peer->allocateSessionResource(1024, 1024*1024);
+ peer->allocateSessionResource(1_k, 1_m);
peer->setFastExtensionEnabled(true);
msg.setPeer(peer);
CPPUNIT_ASSERT(!peer->isInAmAllowedIndexSet(1));