@Override
@Test(expected = IllegalStateException.class)
public void testCannotInsertInFrozenChunk() {

    Text locator = Variables.register("locator", getLocator());
    Value value = Variables.register("value", getStringValue());
    PrimaryKey record = Variables.register("record", getRecord());
    ((CorpusChunk) chunk).insert(locator, value, record, Time.now(),
            Action.ADD);
    if(chunk.size() <= 0) {
        value = Variables.register("value", getStringValue());
        ((CorpusChunk) chunk).insert(locator, value, record, Time.now(),
                Action.ADD);
    }
    chunk.freeze(file);
    ((CorpusChunk) chunk).insert(locator, value, record, Time.now(),
            Action.ADD);
}