Adds options, improve tests