# testx-yaml-parser

> Simple YAML file parser for use with the testx library. Converts a YAML file to testx test script (JSON)

Latest version **2.0.0** (published 2017-08-12) · ISC license · 0 weekly downloads

## Install

```sh
npm install testx-yaml-parser
pnpm add testx-yaml-parser
yarn add testx-yaml-parser
bun add testx-yaml-parser
```

## Health

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

Positive: no vulnerabilities.

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

Negative: abandoned.

## Facts

| | |
|---|---|
| Version | 2.0.0 |
| Published | 2017-08-12 |
| First published | 2016-09-13 |
| Weekly downloads | 0 |
| License | ISC |
| TypeScript types | none |
| Module format | CommonJS |
| Dependencies | 1 |
| Known vulnerabilities | 0 |
| Install scripts | no |
| GitHub stars | 0 |
| Author | Greyarch BV |
| Maintainers | greyarch |
| Keywords | yaml, test, testx |

## Links

- npm: https://www.npmjs.com/package/testx-yaml-parser
- Repository: http://www.github.com/testxio/yaml-parser
- npm.io page: https://npm.io/package/testx-yaml-parser

## Dependencies (1)

- [js-yaml](https://npm.io/package/js-yaml.md) ^3.6.1

## Alternatives

- [monaco-yaml](https://npm.io/package/monaco-yaml.md) — 420.1K weekly downloads
- [@crewx/workflow](https://npm.io/package/@crewx/workflow.md) — 3.1K weekly downloads
- [yaml-cat](https://npm.io/package/yaml-cat.md) — 38 weekly downloads
- [nunjucks-in-yaml](https://npm.io/package/nunjucks-in-yaml.md) — 9 weekly downloads
- [shopify-symlinks](https://npm.io/package/shopify-symlinks.md) — 3 weekly downloads

## Recent versions

- 2.0.0 (latest) — 2017-08-12
- 1.2.0 — 2016-10-25
- 1.1.1 — 2016-09-30
- 1.1.0 — 2016-09-24
- 1.0.0 — 2016-09-22
- 0.1.2 — 2016-09-21
- 0.1.1 — 2016-09-21
- 0.1.0 — 2016-09-13

## README

# Usage

In your test file (*mytests/test.yaml*):

```YAML
- go to:
    url: /

# fill in the search box and press search
- set:
    searchBox: sample pdf files

- set:
    searchBtn: ''

# check the content of the pdf file
- check in pdf:
    link: pdfLink
    expect1: D e n t i s t s
    expect2: P o l i t i c i a n s
```

In your spec file (CoffeeScript):

``` CoffeeScript
testx = require 'testx'
yamlParser = require 'testx-yaml-parser'

describe 'Some page', ->
  it 'should work in a certain way', ->
    testx.runScript yamlParser.parseFile 'mytests/test.yaml'
```

Alternatively you can pass the YAML as a literal string. In CoffeeScript:

``` CoffeeScript
testx = require 'testx'
yamlParser = require 'testx-yaml-parser'

describe 'Some page', ->
  it 'should work in a certain way', ->
    testx.runScript yamlParser.parse """

- go to:
    url: /

# fill in the search box and press search
- set:
    searchBox: sample pdf files

- set:
    searchBtn: ''

# check the content of the pdf file
- check in pdf:
    link: pdfLink
    expect1: D e n t i s t s
    expect2: P o l i t i c i a n s    
"""
```

---
_Source: https://npm.io/package/testx-yaml-parser · Machine-readable twin of the npm.io package page. Health data is recomputed on every publish._
