add command test. Refactor comments.