mirror of
https://github.com/aria2/aria2.git
synced 2025-04-05 21:47:37 +03:00
Add test when instance-length is 0
This commit is contained in:
parent
38fc5de154
commit
67fa274578
1 changed files with 7 additions and 0 deletions
|
@ -683,10 +683,17 @@ void HttpRequestTest::testIsRangeSatisfied()
|
||||||
|
|
||||||
CPPUNIT_ASSERT(httpRequest.isRangeSatisfied(range));
|
CPPUNIT_ASSERT(httpRequest.isRangeSatisfied(range));
|
||||||
|
|
||||||
|
range = Range(segment->getPosition(),
|
||||||
|
segment->getPosition()+segment->getLength()-1,
|
||||||
|
0);
|
||||||
|
|
||||||
|
CPPUNIT_ASSERT(!httpRequest.isRangeSatisfied(range));
|
||||||
|
|
||||||
range = Range(0, segment->getPosition()+segment->getLength()-1,
|
range = Range(0, segment->getPosition()+segment->getLength()-1,
|
||||||
entityLength);
|
entityLength);
|
||||||
|
|
||||||
CPPUNIT_ASSERT(!httpRequest.isRangeSatisfied(range));
|
CPPUNIT_ASSERT(!httpRequest.isRangeSatisfied(range));
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
void HttpRequestTest::testUserAgent()
|
void HttpRequestTest::testUserAgent()
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue