Skip to main content

A Robot Framework JSON Validator Library

Project description

Build Status

Short Description

Robot Framework library for JSON validation based on JSONSchema, JSONPath, JSONSelect.

Additional Information

Installation

Install the library from PyPI using pip:

pip install robotframework-jsonvalidator

Dependencies

Documentation

See keyword documentation for JsonValidator library on GitHub.

Example

json_example.json

{
  "store": {
    "book": [
      {
        "category": "reference",
        "author": "Nigel Rees",
        "title": "Sayings of the Century",
        "price": 8.95
      },
      {
        "category": "fiction",
        "author": "Evelyn Waugh",
        "title": "Sword of Honour",
        "price": 12.99
      },
      {
        "category": "fiction",
        "author": "Herman Melville",
        "title": "Moby Dick",
        "isbn": "0-553-21311-3",
        "price": 8.99
      },
      {
        "category": "fiction",
        "author": "J. R. R. Tolkien",
        "title": "The Lord of the Rings",
        "isbn": "0-395-19395-8",
        "price": 22.99
      }
    ],
    "bicycle": {
      "color": "red",
      "price": 19.95
    }
  }
}

Robot Framework test case:

*** Settings ***
Library    JsonValidator
Library    OperatingSystem

*** Test Cases ***
Check Element
    ${json_example}=    OperatingSystem.Get File   ${CURDIR}${/}json_example.json
    Element should exist    ${json_example}    .author:contains("Evelyn Waugh")

License

Apache License 2.0

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

robotframework-jsonvalidator-1.0.0.dev1.tar.gz (6.4 kB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

robotframework_jsonvalidator-1.0.0.dev1-py2.py3-none-any.whl (8.2 kB view details)

Uploaded Python 2Python 3

File details

Details for the file robotframework-jsonvalidator-1.0.0.dev1.tar.gz.

File metadata

File hashes

Hashes for robotframework-jsonvalidator-1.0.0.dev1.tar.gz
Algorithm Hash digest
SHA256 cd7099c4d40309e5209454a630cdd30fe16753235d7908a3208727d05a235d1f
MD5 330891dd5beeda6ec452732ad1a43be6
BLAKE2b-256 f0615e395d8eb4873f4525c2ba19c1e462ca1512c380de34df62967925375b16

See more details on using hashes here.

File details

Details for the file robotframework_jsonvalidator-1.0.0.dev1-py2.py3-none-any.whl.

File metadata

File hashes

Hashes for robotframework_jsonvalidator-1.0.0.dev1-py2.py3-none-any.whl
Algorithm Hash digest
SHA256 5922dbff7b13833ef1fc8799661b8731c5c48601bbcdf0f28b01cd2325b9f0c8
MD5 df0dc69b3811158a31f932265e01e88d
BLAKE2b-256 18a356e3f404276b649a9c324b43125d58f80d3cef81dea6e7e694eda0683d96

See more details on using hashes here.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Pingdom Monitoring Sentry Error logging StatusPage Status page