Socket
Socket
Sign inDemoInstall

testx-yaml-parser

Package Overview
Dependencies
4
Maintainers
1
Versions
8
Alerts
File Explorer

Advanced tools

Install Socket

Detect and block malicious and high-risk dependencies

Install

testx-yaml-parser

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


Version published
Maintainers
1
Weekly downloads
193
decreased by-23.41%

Weekly downloads

Readme

Source

Usage

In your test file (mytests/test.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):

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:

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    
"""

Keywords

FAQs

Last updated on 12 Aug 2017

Did you know?

Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.

Install

Related posts

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc