0

I need some help in integrating protractor code with Jenkins. I am new to Jenkins so i am not sure if Jenkins or Cruise Control is right as currently we have builds in Cruise Control but we are okay to migrate to Jenkins if that is better. Can someone please help me with any tutorials to link my protractor task with Jenkins or Cruise Control? Currently we are using Gulp as a wrapper over Javascript code for execution. We are running it with command Gulp test --site folder name Should i just specify this command in Execute shell script option of Jenkins?

4

2 回答 2

1

是的,从任何 CI 工具运行 Protractor 测试并不复杂

第 1 步:只需使用“Execute Shell”作为构建步骤配置您的巡航控制/Jenkins 作业第 2 步:根据您选择的运行测试.. 创建一个 bat 文件

echo Protractor Execution
Protractor protractor.conf.js // In case running with protractor
npm run --e2etests // In case running with npm run config in package.json
Gulp test --site folder name // In your case
echo Over and out.

第 3 步:指向您的作业构建步骤以触发批处理文件

于 2016-09-07T15:01:03.093 回答
0

我把这个搞定了。当我直接在 Jenkins 中输入量角器命令时,它工作正常。我在 jenkins 中遇到了 gulp 命令的一些问题,但我会为此打开一个单独的线程。

于 2016-09-08T13:49:52.480 回答