diff --git a/watch.rb b/watch.rb index 935c4ca9..9f1d3eb4 100644 --- a/watch.rb +++ b/watch.rb @@ -1,12 +1,16 @@ #watch file -watch('lib/(.*)\.js') { |md| - system('echo "lib changed"') -} - -watch('test/(.*)\.js') { |md| - system("node #{md}") +def run_parser_tests + system("node test/parser-tests.js") puts "" puts("waiting...") puts "" +end + +watch('lib/(.*)\.js') { |md| + run_parser_tests +} + +watch('test/(.*)\.js') { |md| + run_parser_tests }