FreeListTester

Free list tester base class. Tests all methods of IFreeList.

Constructors

this
this(FL fl)

Constructor.

Members

Aliases

Item
alias Item = I

Alias for type of item stored in free list.

Functions

checkItem
void checkItem(Item item, size_t i)

Checks the value of the passed item against the value which can be deterministically derived from the passed integer. The method should throw TestException on failure.

lengthCheck
void lengthCheck(size_t expected_busy, size_t expected_idle)

Checks that the contents of the free list match the expected values. Derived classes can add additional checks by overriding.

newItem
Item newItem()
setItem
void setItem(Item item, size_t i)

Sets the value of the passed item, using the passed integer to deterministically decide its contents.

test
void test()

Unittest for internal free list.

Static variables

num_items
auto num_items;

Number of items to use in tests.

Parameters

I

type of item stored in free list

Meta