jasmine-maven-plugin

Redirect calls to console.log() to standard output in Jasmine tests

蓝咒 提交于 2019-12-31 10:06:43
问题 I'm using Jasmine via the jasmine-maven-plugin, and I would like to see console.log() messages in the Maven build output. Is there a way to achieve this? If console.log() cannot be redirected, is there any other way to log from my tests so that they show up on the Maven build output? I'm running these tests on Jenkins in a headless fashion, and would like a means to get some debug output from the tests. 回答1: Try console.info('foo') From the test javascripts. 回答2: You can use: jasmine.log("I

How to set up JASMINE using MAVEN-PLUGIN?

让人想犯罪 __ 提交于 2019-12-10 20:28:37
问题 I have a folder structure like -root -pom.xml -service -web -pom.xml -src -main -test -java -javascript -lib -specRunner.js -runner.html -spec -model -view -collection I have written JASMINE test cases in the "spec" folder containing "model","views","collections". I'm able to see my test results in runner.html. Now i'm trying to integrate with MAVEN build. SO followed steps given in http://searls.github.io/jasmine-maven-plugin But i'm getting build failure when doing mvn clean install and

Redirect calls to console.log() to standard output in Jasmine tests

有些话、适合烂在心里 提交于 2019-12-02 19:55:19
I'm using Jasmine via the jasmine-maven-plugin, and I would like to see console.log() messages in the Maven build output. Is there a way to achieve this? If console.log() cannot be redirected, is there any other way to log from my tests so that they show up on the Maven build output? I'm running these tests on Jenkins in a headless fashion, and would like a means to get some debug output from the tests. Try console.info('foo') From the test javascripts. You can use: jasmine.log("I've got a big log."); NB: See douglas-treadwell's comment below. This refers to Jasmine 1.x. With Jasmine 2.0 just