Last modified: 2012-04-16 14:18:37 UTC
keep em consistent :)
Then add a layer of BDD on top of QUnit ? =)
Pavlov? https://github.com/mmonteleone/pavlov No idea how stable that is.
(In reply to comment #1) > Then add a layer of BDD on top of QUnit ? =) Not sure how serious I should take the wink, but I'll ask.. Why would we want to maintain two separate unit test frameworks for MediaWiki JavaScript? Would you welcome someone adding the PHP SimpleTest framework to MediaWiki and start writing unit tests in it and then having to bridge that to PHPUnit for continuous integration? Assuming no, lets just stick to converting it to QUnit.
btw, although QUnit may not be marked as BDD officially, its practically the same - QUnit: module( '..', { setup: fn(), tearDown: fn (), } ); test( '..', function () { /* assertions: equal(), deepEqual, strictEqual, QUnit.ltOrEq, .. */ }); test( '..', function () { /* assertions: .. */ }); - Jasmine: describe( '..', function () { beforeEach( fn () ); it( '..', function () { /* assertions: expect.toEqual(), .. / }); });
https://gerrit.wikimedia.org/r/#q,Id7b498888e22576e8ff0636725191624add470d6,n,z
(In reply to comment #3) > (In reply to comment #1) > > Then add a layer of BDD on top of QUnit ? =) > > Not sure how serious I should take the wink, but I'll ask.. Why would we want > to maintain two separate unit test frameworks for MediaWiki JavaScript? It is not a separated framework. Pavlov is build on top of QUnit, it is merely extending it just like PHPUnit_Extensions_Story_TestCase extends PHPUnit :-]