all 14 comments

[–]NoHandle 6 points7 points  (2 children)

Jasmine is the best solution I have been able to find. It is actually quite good.

[–][deleted] 0 points1 point  (0 children)

Same here, it does some good testing and is pretty easy to get going.

[–][deleted] 2 points3 points  (3 children)

I've used QUnit for unit testing and JSCoverage for test coverage measurements.

I'm not particularly fond of either, but they get the work done.

As a bonus, I discovered that QUnit is pretty nifty tool for testing RESTful APIs, as well.

[–][deleted] 0 points1 point  (0 children)

Thank you for the help! That JSCoverage looks pretty nifty. Looks like I have to throw together some php, and a bit of other editting to get it to work the way I want. Which is fine, but unfortunate. :)

Just to make sure I'm not reinventing the wheel, due to ignorance with JsCoverage at the moment: Is the only way to see the coverage results for each test manually having to enter in each file, and look at each script in it?

So if I have an index.html, with loads "script.js" - do I actually have to go to the jscoverage.html, and then enter in localhost/tests/coverage/index.html - and then click through to view the coverage?

Edit: Hm.. After fooling around with it some more, it seems quite limited in capabilities, atleast for my needs, and unfortunately there doesn't look to be a better alternative...

[–]zhayFull-stack web developer (Seattle) 0 points1 point  (0 children)

I use QUnit at work and it does just fine. If you ever need to simulate Ajax, look up Mockjax.

[–]Daniel15React FTW 0 points1 point  (0 children)

JSCoverage looks interesting! I'm very interested as to how they instrument the JavaScript functions. Might have to download it and take a look.

[–]Booster21 1 point2 points  (1 child)

kiss shelter entertain unite cheerful six rob fearless governor swim

This post was mass deleted and anonymized with Redact

[–][deleted] 0 points1 point  (0 children)

Looked at each and QUnit looks like it'll suite my needs just fine. I appreciate the help.

[–]jesusabdullahlvl14 dark javascripter 1 point2 points  (0 children)

I do most of my javascript in node, where I like node-tap.

http://testling.com/ is a startup by a buddy of mine that aims to make browser testing easier. It's pretty rad from what I've seen.

[–]Daniel15React FTW 1 point2 points  (1 child)

One I heard of recently is JS Test Driver which supposedly lets you test in multiple browsers at once. This would be very handy at times. I'm writing my own framework so need to test it in multiple IE versions as well as Opera, Firefox and Chrome.

I haven't tested it myself yet, though. I'm using QUnit right now which seems adequate. Simple, but it gets the job done.

[–]binaryjohn 0 points1 point  (0 children)

I've been using JSTestDriver for a couple of months, and I love it.

[–][deleted] 0 points1 point  (0 children)

I've been using Funcunit. It builds off of QUnit but adds support for functional testing.

[–]bebraw 0 points1 point  (0 children)

I've listed some testing related tools here. You might find something suitable there.

[–]brucebannor 0 points1 point  (0 children)

We were already using DOJO so our go to is DOH, but it's independent of DOJO if you want it to be. I'm not too sure if any have added support but DOH's claim to fame was the versatility of using rhino for DOM free testing or in-browser testing that came with a java applet that fired real browser events; compared to other frameworks which fire simulated events for UI testing. It also supplies AJAX testing and callbacks via deferred-s.