DEV: adjust rake autospec to work with renamed es6 files

DEV: adjust rake autospec to work with renamed es6 files

We no longer use es6 files, update autospec

diff --git a/lib/autospec/qunit_runner.rb b/lib/autospec/qunit_runner.rb
index 37bc6d7..579e683 100644
--- a/lib/autospec/qunit_runner.rb
+++ b/lib/autospec/qunit_runner.rb
@@ -16,9 +16,9 @@ module Autospec
     end
 
     # Discourse specific
-    watch(%r{^app/assets/javascripts/discourse/(.+)\.js.es6$}) { |m| "test/javascripts/#{m[1]}-test.js.es6" }
-    watch(%r{^app/assets/javascripts/admin/(.+)\.js.es6$})     { |m| "test/javascripts/admin/#{m[1]}-test.js.es6" }
-    watch(%r{^test/javascripts/.+\.js.es6$})
+    watch(%r{^app/assets/javascripts/discourse/(.+)\.js$}) { |m| "test/javascripts/#{m[1]}-test.js" }
+    watch(%r{^app/assets/javascripts/admin/(.+)\.js$})     { |m| "test/javascripts/admin/#{m[1]}-test.js" }
+    watch(%r{^test/javascripts/.+\.js$})
 
     RELOADERS = Set.new
     def self.reload(pattern)
@@ -33,7 +33,7 @@ module Autospec
     reload(%r{^test/javascripts/(helpers|mixins)/.+\.js(\.es6)?$})
     reload("test/javascripts/test_helper.js")
 
-    watch(%r{^plugins/.*/test/.+\.js.es6$})
+    watch(%r{^plugins/.*/test/.+\.js(\.es6)?$})
 
     require "socket"
 

GitHub sha: 6d3d9ecf

Nice catch Sam, thanks!

1 Like