Adds timing info to Concordion specifications
Java JavaScript CSS
Fetching latest commit…
Cannot retrieve the latest commit at this time.
Permalink
Failed to load latest commit information.
gradle/wrapper
images
src
.gitignore
.travis.yml
LICENSE.txt
README.md
build.gradle
gradle.properties
gradlew
gradlew.bat
settings.gradle

README.md

Build Status

This Concordion extension provides the capability to embed the processing time of each specification example at runtime.

The demo project demonstrates this extension.

Introduction

Often it is useful to know how long a given example takes to run. This extension provides this by printing the timing to screen for each example. The functionality can be toggled on or off via a toggle button located at the top right of the results screen.

How to install

Add to dependencies

 testCompile 'org.concordion:concordion-timing-extension:0.2.0'

How to use

For the timings to show on examples, you must be using the example command in your specification (Markdown format, HTML format).

Add to your test fixture one of these options

With no configuration

@Extensions(value = TimerExtension.class)

With comprehensive configuration

@Extension
ConcordionExtension TimingExtension = new TimerExtension()
    .withShowByDefault(true)
    .withIcon("/path/to/icon.png")
    .withTimeFormat(new SimpleTimeFormatter(" hours", " minutes", " seconds", " milliseconds"));

Features

Timings per example

Example timing

Customisable timing format and toggle icon

Customised Example

Toggle display of timings

Customised Example

Further info