标签: jasmine-spec-reporter

在量角器测试中定制Jasmine记者

我找不到如何使用jasmine框架改变protractors runner中的记者风格.

我现在拥有的是:

在此输入图像描述

但我想要更像的东西:

在此输入图像描述

有没有办法为茉莉花添加自定义报告器,显示当前测试运行而不是DOTS和Fs?

jasmine protractor jasmine-spec-reporter

17
推荐指数
1
解决办法
1万
查看次数

我怎么能有mocha记者的量角器?

我正在使用量角器(0.22.0)测试我的应用程序.这可能是一个摩卡风格的记者而不是基本的茉莉花吗?它的当前情况如下:

(....F...)
Run Code Online (Sandbox Code Playgroud)

我正在寻找更像的东西:

my set of tests 1
  my test 1-1
  my test 1-2
my set of tests 2
  my test 2-1
  my test 2-2
Run Code Online (Sandbox Code Playgroud)

javascript mocha.js protractor jasmine-spec-reporter

6
推荐指数
1
解决办法
3527
查看次数

AngularJS量角器:逐步进度日志

在(现已弃用)角度场景测试运行器中,有一个选项可以创建一个runner.html页面,该页面将在iFrame中运行测试,同时在主页面中逐步报告进度.

场景转轮的截图

有没有办法为量角器测试获得类似的逐步日志?它不需要在一个html页面(控制台或日志文件就可以了).

angularjs angularjs-e2e protractor jasmine-spec-reporter

6
推荐指数
2
解决办法
1727
查看次数

有没有人找到一种方法来向Protractor Describe块添加列表编号?

我的量角器测试中有很多Describe块.我得到的测试输出的页面和页面都正确缩进,但是很难看出哪个测试是哪个以及测试进展到了多远.

有没有人试图在Describe中添加列表编号.像这样的东西:

1.   Main Page test
   1.1  Test xxx
   1.2  Test yyy
      1.2.1 Describe in describe in describe test
2.   XXX Page test
   2.1  Test abc
Run Code Online (Sandbox Code Playgroud)

注意,这里点之后的第一个和第二个数字将是描述的结果.

angularjs protractor jasmine-spec-reporter

6
推荐指数
1
解决办法
519
查看次数

我可以将jasmine-spec-reporter的输出写入文件吗?

我目前正在使用jasmine-spec-reporter为我的量角器测试用例创建一个规格报告。

终端上的输出看起来很棒!有什么方法可以将此输出保存到文件中,或以某种方式使用protractor-jasmine2-screenshot-reporter创建摘要,但禁用屏幕截图?

我尝试过在网上寻找解决方案,但到目前为止还没有成功。

var SpecReporter = require('jasmine-spec-reporter');
jasmine.getEnv().addReporter(new SpecReporter({displayStacktrace: 'none'}));
Run Code Online (Sandbox Code Playgroud)

https://github.com/jintoppy/protractor-html-screenshot-reporter

https://github.com/bcaudan/jasmine-spec-reporter

我当前的解决方法是使用protractor-jasmine2-screenshot-reporter生成报告。这也会生成屏幕截图(由于创建了卷,因此不太实用)。

如果有人可以禁用屏幕截图,甚至不允许保存.png文件,请分享。

javascript automation protractor jasmine-spec-reporter

5
推荐指数
1
解决办法
5390
查看次数

SpecReporter 不是茉莉花上的构造函数错误

我尝试使用 node.js 在 jasmine 上配置简单的项目。我得到以下文件:

/*global jasmine */
 var SpecReporter = require('jasmine-spec-reporter');

exports.config = {
    allScriptsTimeout: 11000,
    specs: [
        '**/*.testdev.ts'
     ],
    capabilities: {
        'browserName': 'chrome'
    },
    directConnect: true,
    baseUrl: 'foo',
    framework: 'jasmine',
    jasmineNodeOpts: {
        showColors: true,
        defaultTimeoutInterval: 60000,
        print: function() {}
    },
    useAllAngular2AppRoots: true,
     beforeLaunch: function() {
         require('ts-node').register({
            project: 'e2e'
             });
        },
    onPrepare: function() {
    jasmine.getEnv().addReporter(new SpecReporter());
    }
};
Run Code Online (Sandbox Code Playgroud)

然后是一个测试文件:

import {} from 'jasmine';
describe ("test", function() {
  it ("should work", function() {
      console.log('============ Main Workflow file starts');
  });
}); …
Run Code Online (Sandbox Code Playgroud)

node.js jasmine jasmine-spec-reporter

2
推荐指数
1
解决办法
2233
查看次数