From: Wolfram Schneider Date: Fri, 31 Jan 2014 09:34:17 +0000 (+0000) Subject: extract and display number of tests, and duration X-Git-Tag: 1.0.0~1550 X-Git-Url: http://lists.indexdata.dk/?a=commitdiff_plain;h=dbf249f204487107f43e90783dcc243ecd94eae7;p=mkws-moved-to-github.git extract and display number of tests, and duration --- diff --git a/test/phantom/evaluate.js b/test/phantom/evaluate.js index be26202..e4f7934 100644 --- a/test/phantom/evaluate.js +++ b/test/phantom/evaluate.js @@ -1,7 +1,7 @@ /* Fetch a mkws/jasmine based page into node.js, evaluate the page and check if test status This should make it possible to run the test on the command line in jenkins. e.g.: - + phantomjs evaluate.js https://mkws-dev.indexdata.com/jasmine-local-popup.html */ @@ -31,13 +31,16 @@ page.open(url, function (status) { // return document.querySelector(s).innerText; return { mkws: window.mkws, - string: "foo" + duration: window.$(".duration").text(), + passing: window.$(".passingAlert").text() }; }, 'title'); console.log("."); if (result.mkws.jasmine_done) { console.log("MKWS tests are successfully done. Hooray!"); + console.log("duration: " + result.duration); + console.log("passing: " + result.passing); phantom.exit(0); } r = result;