add test for command watch
support command ignore and corresponding test