Added the "output" option
Written tests