Refactor test-noun-coverage.sh