new example test case for allocate