Task #3830
open
- Description updated (diff)
Changed GitHub link to point to exact commit hash, so that it stays relevant even if the master
branch changes in the future.
I've read the test case.
In its current logic, the same AsfStrategy
instance is used to make decisions for four batches of 30 Interests from a consumer, and the Interest counters on A-B and A-D links are asserted as follows:
batch |
A-B |
A-D |
0 |
>=24 |
<=6 |
1 |
<=30 |
>=30 |
2 |
>=50 |
<=40 |
3 |
<=60 |
>=60 |
These assertions are badly designed, because every assertion tests the accumulative packet counter since the beginning, while the behavior in each batch is independent from the counter value before processing this batch.
For example, batch2 A-B assertion will pass when A-B counter is either 50 or 58, but the former allows batch3 to increment this counter by up to 10 while the latter only permits an increment of no more than 2.
My suggestion is to reset the counters to zero before processing each batch, and change the assertions as follows:
batch |
A-B |
A-D |
0 |
>=24 |
<=6 |
1 |
<=6 |
>=24 |
2 |
>=20 |
<=10 |
3 |
<=10 |
>=20 |
- Description updated (diff)
- Category set to Forwarding
- Assignee set to Saurab Dulal
- Tags set to UnitTests
- Start date deleted (
10/27/2016)
- Tags changed from unit-tests to unit-tests, ASF
- Category changed from Forwarding to Unit Tests
- Assignee deleted (
Saurab Dulal)
Also available in: Atom
PDF