Skip to content

Commit

Permalink
Documentation updates
Browse files Browse the repository at this point in the history
  • Loading branch information
molovo committed Feb 13, 2017
1 parent 55f0c5a commit fb9f7bf
Showing 1 changed file with 30 additions and 0 deletions.
30 changes: 30 additions & 0 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -256,6 +256,27 @@ directories:
To set up ZUnit for a new project, just run `zunit init` in the project's root directory. This will create the `.zunit.yml` config file and relevant directories, including an example test.

### [Travis CI](https://travis-ci.org) config

ZUnit can generate a `.travis.yml` file for you, which contains the build steps needed to install ZUnit's dependencies and then run tests. Just run `zunit init --travis` when initialising your project.

An example `.travis.yml` is below:

```yaml
addons:
apt:
packages:
zsh
before_script:
- mkdir .bin
- curl -L https://raw.githubusercontent.com/molovo/revolver/master/revolver > .bin/revolver
- curl -L https://raw.githubusercontent.com/molovo/color/master/color.zsh > .bin/color
- curl -L https://raw.githubusercontent.com/molovo/zunit/master/zunit > .bin/zunit
- chmod u+x .bin/{color,revolver,zunit}
- export PATH="$PWD/.bin:$PATH"
script: zunit
```

## Running Tests

The CLI program `zunit` is used to run tests.
Expand Down Expand Up @@ -286,6 +307,15 @@ zunit --tap
zunit --output-text
```

### HTML Reports

ZUnit is capable of producing a detail HTML report, which you can view in your browser.

```sh
# Prints HTML report to the _output directory
zunit --output-html
```

### Risky Tests

By default, risky tests (those that make no assertions) raise a warning in the test output. To supress this behaviour, and allow risky tests to pass without warning, use the `--allow-risky` option.
Expand Down

0 comments on commit fb9f7bf

Please sign in to comment.