public void add(E item) {
        if (!offer(item)) {
            throw new IllegalStateException("CircularQueue is full");
        }
    }
@Test(expected = NullPointerException.class)
    public void test_add_whenNull() {
        CircularQueue<Integer> queue = new CircularQueue<>(128);
        queue.add(null);
    }