Skip to main content

Python implementation of our validation library

Project description

Validation library

Build Status Coverage Status GitHub PyPI PyPI - Python Version

Installation

  • Install from Pypi:

    $ pip install moveax-validation
            --- or ---
    $ poetry add moveax-validation
    

Usage

  • Simple example:

    >>> from validation import ValidatorFactory
    
    >>> data = ['foo', 'bar']
    >>> schema = {
        'elements': {
            'rules': ['minlen:3']
            'type': 'string'
        },
        'rules': ['maxlen:3'],
        'type': 'array'
    }
    >>> validator = ValidatorFactory.make(schema)
    >>> validator.validate(data)
    

Testing

  • Run the test suite with:

    $ poetry run coverage run unit.py
    

Project details


Download files

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

Files for moveax-validation, version 2.0.0
Filename, size File type Python version Upload date Hashes
Filename, size moveax_validation-2.0.0-py3-none-any.whl (34.0 kB) File type Wheel Python version py3 Upload date Hashes View
Filename, size moveax-validation-2.0.0.tar.gz (14.5 kB) File type Source Python version None Upload date Hashes View

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