@Override
    public E element() {
        final E e = peek();
        if (e == null) {
            throw new NoSuchElementException("Queue is empty");
        }
        return e;
    }
@Test(expected = NoSuchElementException.class)
    public void testElement_whenEmpty() {
        queue.element();
    }