Metadata-Version: 2.1
Name: moveax-validation
Version: 2.0.0
Summary: Python implementation of our validation library
Home-page: https://github.com/moveaxlab/validation-py/
License: MIT
Keywords: schema,validation
Author: Mattias E. Mignone
Author-email: mattias.mignone@moveax.it
Requires-Python: >=3.5,<4.0
Classifier: License :: OSI Approved :: MIT License
Classifier: Programming Language :: Python :: 3
Classifier: Programming Language :: Python :: 3.5
Classifier: Programming Language :: Python :: 3.6
Classifier: Programming Language :: Python :: 3.7
Classifier: Programming Language :: Python :: 3.8
Requires-Dist: phonenumbers (>=8.10,<9.0)
Requires-Dist: python-dateutil (>=2.7.3,<3.0.0)
Project-URL: Repository, https://github.com/moveaxlab/validation-py/
Description-Content-Type: text/markdown

# Validation library
[![Build Status](https://travis-ci.com/moveaxlab/validation-py.svg?branch=master)](https://travis-ci.com/moveaxlab/validation-py)
[![Coverage Status](https://coveralls.io/repos/github/moveaxlab/validation-py/badge.svg?branch=master)](https://coveralls.io/github/moveaxlab/validation-py?branch=master)
![GitHub](https://img.shields.io/github/license/moveaxlab/validation-py.svg)
![PyPI](https://img.shields.io/pypi/v/moveax-validation.svg?style=popout)
![PyPI - Python Version](https://img.shields.io/pypi/pyversions/moveax-validation.svg)

## Installation
- Install from [Pypi](https://pypi.org/project/moveax-validation/):

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

## Usage
- Simple example:

    ```python
    >>> 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:

    ```console
    $ poetry run coverage run unit.py
    ```

