Code Monkey home page Code Monkey logo

data-validation's Introduction

CI CD workflow CodeQL workflow Quality Gate Status

Framework to help me as a QA Engineer to check the data quality of a dataset.

To practice this I used a data-driven approach to run the test class using a csv file with different data and also a structure of 5 data checks (type, constraint, structured, consistency and code)

Data Validation Test Suite

A Python unittest-based test suite for validating data quality in CSV datasets.

Overview

This test suite is designed to get fast feedback on data quality in CSV datasets. It performs various checks, including data type validation, constraint validation, structured validation, consistency validation and code validation.

Installation

To run the tests, you need Python 3.x and the following dependencies:

pip install pandas parameterized

Usage

Clone the repository. Run the tests using unittest:

python -m unittest -v test_data_validation.py

Tests

Data Type Validation

  • Checks that the data in each field, column, list, range or file corresponds to the correct type and format e.g.: int, str, bool, etc.

Constraint Validation

  • Checks that the data meets valid value ranges or expectations e.g.: age field has a valid age limit, not null, not empty, etc.

Structured Validation

  • Checks compliance with a data format, structure or schema e.g.: primary key, foreign key, data name, column name

Consistency Validation

  • Checks data style e.g.: date masks, currency, etc.

Code Validation

  • Checks that the classifications adhere to 'Yes' or 'No', '0' or '1', etc.

References

License

This project is licensed under the MIT License - see the LICENSE file for details.

data-validation's People

Contributors

rafaabc avatar

Watchers

 avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.