Updating MockPlugin to throw an exception if queue is empty