From dbf249f204487107f43e90783dcc243ecd94eae7 Mon Sep 17 00:00:00 2001 From: Wolfram Schneider Date: Fri, 31 Jan 2014 09:34:17 +0000 Subject: [PATCH] extract and display number of tests, and duration --- test/phantom/evaluate.js | 7 +++++-- 1 file changed, 5 insertions(+), 2 deletions(-) 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; -- 1.7.10.4