Skip to main content

This plugin is used to load yaml output to your test using pytest framework.

Project description

# pytest_yaml

This plugin is used to load yaml output to your test using pytest framework.

## How to install

```bash
pip install pytest_yaml
```

## How to use

#### Example code

```yaml
param: "value"
```

```python
def test_hello(yaml_content):
assert yaml_content['param'] == 'value', 'your message'
```

#### Command line

```bash
pytest ./tests/sample/ --yaml-file ./yaml/sample.yml
```


Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

pytest_yaml-1.2.1.tar.gz (1.7 kB view hashes)

Uploaded source

Built Distribution

pytest_yaml-1.2.1-py3-none-any.whl (2.7 kB view hashes)

Uploaded py3

Supported by

AWS AWS Cloud computing Datadog Datadog Monitoring Facebook / Instagram Facebook / Instagram PSF Sponsor Fastly Fastly CDN Google Google Object Storage and Download Analytics Huawei Huawei PSF Sponsor Microsoft Microsoft PSF Sponsor NVIDIA NVIDIA PSF Sponsor Pingdom Pingdom Monitoring Salesforce Salesforce PSF Sponsor Sentry Sentry Error logging StatusPage StatusPage Status page