Last modified: 2013-03-14 17:55:06 UTC

Wikimedia Bugzilla is closed!

Wikimedia migrated from Bugzilla to Phabricator. Bug reports are handled in Wikimedia Phabricator.
This static website is read-only and for historical purposes. It is not possible to log in and except for displaying bug reports and their history, links might be broken. See T46050, the corresponding Phabricator task for complete and up-to-date bug report information.
Bug 44050 - Implement QUnit support in continuous integration (via phantomjs)
Implement QUnit support in continuous integration (via phantomjs)
Status: RESOLVED FIXED
Product: Wikimedia
Classification: Unclassified
Continuous integration (Other open bugs)
unspecified
All All
: Normal enhancement (vote)
: ---
Assigned To: Krinkle
:
Depends on:
Blocks:
  Show dependency treegraph
 
Reported: 2013-01-16 23:08 UTC by Matthew Flaschen
Modified: 2013-03-14 17:55 UTC (History)
4 users (show)

See Also:
Web browser: ---
Mobile Platform: ---
Assignee Huggle Beta Tester: ---


Attachments

Description Matthew Flaschen 2013-01-16 23:08:45 UTC
Jenkins should run the QUnit tests for the project that is being committed to.
Comment 1 Antoine "hashar" Musso (WMF) 2013-01-17 18:23:49 UTC
This is being worked on by Timo as time allow (ccing him). The idea is to get a MediaWiki install to listen on http://localhost/change/patch (or similar) and run the QUnit tests under NodeJS.

https://gerrit.wikimedia.org/r/#/c/44164/ setup the virtual host
Comment 2 Krinkle 2013-01-18 01:00:14 UTC
(In reply to comment #1)
> This is being worked on by Timo as time allow (ccing him). The idea is to
> get a
> MediaWiki install to listen on http://localhost/change/patch (or similar) and
> run the QUnit tests under NodeJS.
>

PhantomJS, not NodeJS. In NodeJS tests would fail horribly as the DOM API doesn't exist.
Comment 3 Dan Andreescu 2013-01-18 13:03:57 UTC
I have this working in Limn (https://github.com/wikimedia/limn/blob/master/test/phantom.runner.js is the relevant file, along with some very light scripting that invokes it from the command line). I'll lend a hand on this soon.
Comment 4 Krinkle 2013-01-18 16:00:00 UTC
(In reply to comment #3)
> I have this working in Limn
> (https://github.com/wikimedia/limn/blob/master/test/phantom.runner.js is the
> relevant file, along with some very light scripting that invokes it from the
> command line). I'll lend a hand on this soon.

The running of phantomjs isn't a problem and we already have a script for that in place that does not involve a fixed timeout or polling of DOM (QUnit has an API, no need to poll anything). I recognise the script you linked and guess you didn't write this yourself, so I'm not reviewing the script you linked further.

What I'm working on is the procedure to install MediaWiki within Jenkins in a temporary Apache-served location and then pass the url to phantomjs/qunit. Using grunt as builder for these steps (instead of Ant).
Comment 5 Dan Andreescu 2013-01-18 17:57:44 UTC
> (QUnit has an API, no need to poll anything).  I recognise the script you
> linked and guess you didn't write this yourself, so I'm not reviewing the
> script you linked further.

Yep, borrowed this and didn't clean it up yet.  We're using the API to report results in more detail, if that's useful:

https://github.com/wikimedia/limn/blob/master/test/index.co

> What I'm working on is the procedure to install MediaWiki within Jenkins
> in a temporary Apache-served location and then pass the url to phantomjs/qunit.

Have you tried using Ori's Vagrant method?  https://github.com/atdt/wmf-vagrant
Comment 6 Krinkle 2013-01-18 21:02:38 UTC
(In reply to comment #5)
> > (QUnit has an API, no need to poll anything).  I recognise the script you
> > linked and guess you didn't write this yourself, so I'm not reviewing the
> > script you linked further.
> 
> Yep, borrowed this and didn't clean it up yet.  We're using the API to report
> results in more detail, if that's useful:
> 
> https://github.com/wikimedia/limn/blob/master/test/index.co
> 
> > What I'm working on is the procedure to install MediaWiki within Jenkins
> > in a temporary Apache-served location and then pass the url to phantomjs/qunit.
> 
> Have you tried using Ori's Vagrant method? 
> https://github.com/atdt/wmf-vagrant

We are going to run the builds themselves (as opposed to individual tasks) in a VM in the near future (likely using Vagrant), but I don't see how that is other wise relevant to running qunit tests.
Comment 7 Matthew Flaschen 2013-01-18 21:04:45 UTC
As long as there's a timeout on the tests being run, I don't think a VM is necessary.
Comment 8 Krinkle 2013-03-14 17:55:06 UTC
(In reply to comment #7)
> As long as there's a timeout on the tests being run, I don't think a VM is
> necessary.

Exactly.

http://lists.wikimedia.org/pipermail/wikitech-l/2013-March/067208.html

Note You need to log in before you can comment on or make changes to this bug.


Navigation
Links