Add unit tests for which command.