# testcafe-reporter-slack-errors-only

> slack-errors-only TestCafe reporter plugin.

Latest version **1.6.1** (published 2018-11-11) · MIT license · 0 weekly downloads

## Install

```sh
npm install testcafe-reporter-slack-errors-only
pnpm add testcafe-reporter-slack-errors-only
yarn add testcafe-reporter-slack-errors-only
bun add testcafe-reporter-slack-errors-only
```

## Health

**Score 15/100 (F)** — status: abandoned.

Positive: no vulnerabilities.

Warnings: low downloads; no types; no esm support.

Negative: abandoned; low maintenance score.

## Facts

| | |
|---|---|
| Version | 1.6.1 |
| Published | 2018-11-11 |
| First published | 2018-08-05 |
| Weekly downloads | 0 |
| License | MIT |
| TypeScript types | none |
| Module format | CommonJS |
| Dependencies | 2 |
| Unpacked size | 6.8 KB |
| Known vulnerabilities | 0 |
| Install scripts | no |
| GitHub stars | 0 |
| Author | Eden Adler |
| Maintainers | edenadler |
| Keywords | testcafe, reporter, plugin |

## Links

- npm: https://www.npmjs.com/package/testcafe-reporter-slack-errors-only
- Repository: https://github.com/edenadler/testcafe-reporter-slack-errors-only
- Homepage: https://github.com/edenadler/testcafe-reporter-slack-errors-only#readme
- Issues: https://github.com/edenadler/testcafe-reporter-slack-errors-only/issues
- npm.io page: https://npm.io/package/testcafe-reporter-slack-errors-only

## Dependencies (2)

- [dotenv](https://npm.io/package/dotenv.md) ^6.0.0
- [slack-node](https://npm.io/package/slack-node.md) ^0.1.8

## Recent versions

- 1.6.1 (latest) — 2018-11-11
- 1.6.0 — 2018-11-08
- 1.5.1 — 2018-10-25
- 1.5.0 — 2018-08-22
- 1.0.0 — 2018-08-05

## README

# testcafe-reporter-slack-errors-only
[![Build Status](https://travis-ci.org/edenadler/testcafe-reporter-slack-errors-only.svg)](https://travis-ci.org/edenadler/testcafe-reporter-slack-errors-only)

This is the **slack-errors-only** reporter plugin for [TestCafe](http://devexpress.github.io/testcafe).

<p align="center">
    <img src="https://raw.github.com/edenadler/testcafe-reporter-slack-errors-only/master/media/preview.png" alt="preview" />
</p>

## Install

```
npm install testcafe-reporter-slack-errors-only
```

## Usage

When you run tests from the command line, specify the reporter name by using the `--reporter` option:

```
testcafe chrome 'path/to/test/file.js' --reporter slack-errors-only
```


When you use API, pass the reporter name to the `reporter()` method:

```js
testCafe
    .createRunner()
    .src('path/to/test/file.js')
    .browsers('chrome')
    .reporter('slack-errors-only') // <-
    .run();
```

## Important Note

If you are looping over your test fixtures, each test fixture **must** have a unique name (otherwise error reports will be all grouped together under the same name, making it difficult to attribute the source of the error for each test)  

For example:  

```js
//test.js  

function testFlow(config) {

    fixture(`${config.testName}`)
        .page `http://example.com`

        test('Example', async t => {
            await config.testing();
        });
}

const testSuite = getTestSuite();

for (const config of testSuite) {
    testFlow(config);
}
```

## Author
Eden Adler

---
_Source: https://npm.io/package/testcafe-reporter-slack-errors-only · Machine-readable twin of the npm.io package page. Health data is recomputed on every publish._
