dragoonis/behat-html-formatter 问题修复 & 功能扩展

解决BUG、新增功能、兼容多环境部署,快速响应你的开发需求

邮箱:yvsm@zunyunkeji.com | QQ:316430983 | 微信:yvsm316

dragoonis/behat-html-formatter

Composer 安装命令:

composer require dragoonis/behat-html-formatter

包简介

This will create a html formatter for Behat.

README 文档

README

Suggestions are more than welcome !

This is a behat 3 extension to generate HTML reports from your test results.

Add this to your behat.yml file:

formatters:
    html:
        output_path: %paths.base%/build/html/behat
  extensions:
    emuse\BehatHTMLFormatter\BehatHTMLFormatterExtension:
        name: html
        renderer: Twig,Behat2
        file_name: Index
        print_args: true
        loop_break: true

The output parameter is relative to %paths.base% and, when omitted, will default to that same path.

The renderer is the renderer engine and the report format that you want to be generated.

The file_name is optional. When it is added, the report name will be fixed instead fo generated, and this file will be overwritten with every build.

Actually, there is 3 formats :

  • Twig : new report format based on Twig, requires Twig installed
  • Behat2 : like Behat 2 HTML report
  • Minimal : ultra minimal...

You must specify the format that you want to use in the renderer parameter.

You can combine formats to generate multiple reports with multiple formats at one time for one test suite : you just need to separate them by commas

File names have this format : "renderer name"_"date hour"

Twig renderer only parameters:

The print_args is optional. When it is added, the report will contain the arguments for each step if exists. (e.g. Tables)

The print_outp is optional. When it is added, the report will contain the output of each step if exists. (e.g. Exceptions)

The loop_break is optional. When it is added, Scenario Outlines printed to the report will have a break line separating the executions.

To be done:

  1. Add parameters for behat.yml file
  2. Add bootstrap as dependency
  3. clean up html report
  4. Add out parameter

Screenshots

Twig :

Behat2 :

统计信息

  • 总下载量: 895
  • 月度下载量: 0
  • 日度下载量: 0
  • 收藏数: 0
  • 点击次数: 1
  • 依赖项目数: 0
  • 推荐数: 0

GitHub 信息

  • Stars: 0
  • Watchers: 1
  • Forks: 117
  • 开发语言: PHP

其他信息

  • 授权协议: Unknown
  • 更新时间: 2016-03-23

承接程序开发

PHP开发

VUE

Vue开发

前端开发

小程序开发

公众号开发

系统定制

数据库设计

云部署

网站建设

安全加固