예제 #1
0
BOOST_FIXTURE_TEST_CASE(checkAttrId, AttrIdTestFixture)
{
    checkIdList();

    appendIdList("123");
    appendIdList("");
    appendIdList("456 789");
    appendIdList("2147483647"); // 2^31-1
    appendIdList("2147483647 2147483646 2147483645");
    appendIdList("1 2 3 4 5 6 7 8 9");
    appendIdList("");
    appendIdList("");
    appendIdList("");
    appendIdList("9 7 5 3 1 2 4 6 8");

    checkIdList();

    checkOverFlow();

    appendIdList("1000000000 100000000 10000000 1000000 100000 10000 1000 100 10 1");

    checkIdList();
}
예제 #2
0
void ArrayStack::push(int value)
{
    checkOverFlow();
    array[elementsCounter++] = value;
}