Added queue and tests