prototypejs / prototype

Prototype JavaScript framework
http://prototypejs.org/
Other
3.54k stars 639 forks source link

Switch to Mocha for testing. #283

Closed savetheclocktower closed 9 years ago

savetheclocktower commented 9 years ago

Doing this as a PR so that we have one final place to review this and see if we missed anything. See #194 for more information.

Requires Sinatra. rake test:start starts the test server, and from there you can either (a) visit the test page in a browser of your choice, or (b) use rake test:run with the same BROWSERS and TESTS options you're used to from the old test system. All tests have been ported over.

jwestbrook commented 9 years ago

Can you reduce the verbosity level of Sinatra by default? it dumps all the webserver access log entries to the console and are really only needed if you want to debug the ajax requests

savetheclocktower commented 9 years ago

That should take care of it.

jwestbrook commented 9 years ago

you also need

set :server_settings, {:AccessLog => []}

so that WEBrick shuts up as well

savetheclocktower commented 9 years ago

OK, anything else? We should land this before I get distracted again.

jwestbrook commented 9 years ago

We need to figure out how to run the tests via console without having to run 2 separate processess, but I think this is a huge improvement, and I'm good with it.

Are you aiming for another April release? I know there is not too much that has changed in the last 12 months, but consistent releases would help the community :-)

savetheclocktower commented 9 years ago

I bet I can figure out how to write a third task that handles starting the server, starting the runner, then stopping the server, but it's not a high priority.

Once this is landed I'll start thinking about a bugfix release. The RequireJS problem, in particular, warrants a release.

jwestbrook commented 9 years ago

reminder to update http://prototypejs.org/contribute to reflect new steps for testing

savetheclocktower commented 9 years ago

Done.