{"id":15605732,"url":"https://github.com/ajitsing/data_verifier","last_synced_at":"2026-01-20T07:02:07.634Z","repository":{"id":51207557,"uuid":"192169684","full_name":"ajitsing/data_verifier","owner":"ajitsing","description":"Ruby gem to verify data","archived":false,"fork":false,"pushed_at":"2021-05-20T07:12:59.000Z","size":18,"stargazers_count":1,"open_issues_count":1,"forks_count":0,"subscribers_count":0,"default_branch":"master","last_synced_at":"2025-11-30T22:17:20.795Z","etag":null,"topics":["data-sanity","data-verification","data-verifier","ruby","ruby-gem","testing","testing-tools"],"latest_commit_sha":null,"homepage":"","language":"Ruby","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"mit","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/ajitsing.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":"LICENSE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null}},"created_at":"2019-06-16T08:52:20.000Z","updated_at":"2019-06-23T13:41:06.000Z","dependencies_parsed_at":"2022-08-26T08:00:59.085Z","dependency_job_id":null,"html_url":"https://github.com/ajitsing/data_verifier","commit_stats":null,"previous_names":[],"tags_count":1,"template":false,"template_full_name":null,"purl":"pkg:github/ajitsing/data_verifier","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/ajitsing%2Fdata_verifier","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/ajitsing%2Fdata_verifier/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/ajitsing%2Fdata_verifier/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/ajitsing%2Fdata_verifier/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/ajitsing","download_url":"https://codeload.github.com/ajitsing/data_verifier/tar.gz/refs/heads/master","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/ajitsing%2Fdata_verifier/sbom","scorecard":null,"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":286080680,"owners_count":28597985,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2026-01-20T02:08:49.799Z","status":"ssl_error","status_checked_at":"2026-01-20T02:08:44.148Z","response_time":117,"last_error":"SSL_read: unexpected eof while reading","robots_txt_status":"success","robots_txt_updated_at":"2025-07-24T06:49:26.215Z","robots_txt_url":"https://github.com/robots.txt","online":false,"can_crawl_api":true,"host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["data-sanity","data-verification","data-verifier","ruby","ruby-gem","testing","testing-tools"],"created_at":"2024-10-03T04:14:04.127Z","updated_at":"2026-01-20T07:02:07.620Z","avatar_url":"https://github.com/ajitsing.png","language":"Ruby","funding_links":[],"categories":[],"sub_categories":[],"readme":"# data_verifier\n\n[![Maintenance](https://img.shields.io/badge/Maintained%3F-yes-green.svg)](https://GitHub.com/ajitsing/data_verifier/graphs/commit-activity)\n[![Open Source Love](https://badges.frapsoft.com/os/v1/open-source.svg?v=102)](https://opensource.org/licenses/MIT)\n[![Gem Version](https://badge.fury.io/rb/data_verifier.svg)](https://badge.fury.io/rb/data_verifier)\n[![HitCount](http://hits.dwyl.io/ajitsing/data_verifier.svg)](http://hits.dwyl.io/ajitsing/data_verifier)\n![Gem Downloads](http://ruby-gem-downloads-badge.herokuapp.com/data_verifier?type=total)\n[![Build Status](https://travis-ci.org/ajitsing/data_verifier.svg?branch=master)](https://travis-ci.org/ajitsing/data_verifier)\n[![Twitter Follow](https://img.shields.io/twitter/follow/Ajit5ingh.svg?style=social)](https://twitter.com/Ajit5ingh)\n\nThere are times when we change the approach of modifying data and want to verify\nthat the data modified by the new approach is same as the old approach.\nThis gem is build for such verifications.\n\n## Motivation\n\nIn my project, we replicate the data from other systems. There was a requirement where we changed the source of the data\nand code to replicate the data to our system. In testing phase we wanted to create a validation sheet,\nwhich can show the difference b/w the data in our system before and after the new source.\n\n## Installation\nAdd this line to your application's Gemfile:\n```ruby\ngem 'data_verifier'\n```\n\n## Usage\nThis gem has to be used in two phases:\n\n1. Build Phase: Use this phase to build the baseline of the data before changing the code/approach\n2. Verification Phase: Use this phase to verify the new data against the baseline data\n\n#### Config:\n\n```ruby\nrequire 'data_verifier'\n\nQUERIES = {\n    users_table: \"select * from users where id=100\",\n    phones_table: \"select * from phones where user_id=100\",\n    addresses_table: \"select * from addresses where user_id=100\",\n}\n\nconfig = DataVerifier::Config.new do |c|\n  c.db_adapter = :oracle\n  c.db_user = 'my_db_user'\n  c.db_password = 'my_pass'\n  c.db_host = 'localhost'\n  c.db_name = 'test_db'\n  c.db_port = '1521'\n  c.data_identifier = 'user_id_100'\n  c.queries = QUERIES\nend\n```\n\n#### Inspector\nCreate an inspector to run in both build and verify mode.\n\n```ruby\nconfigs = [config1, config2, config3]\ninspector = DataVerifier::Inspector.new(configs, report_name: 'my_awesome_report')\n```\n\n#### Building Baseline Data:\n\nThe below code will execute all the queries and store their result in json files.\n\n```ruby\ninspector.inspect(phase: :BUILD)\n```\n\n#### Verification:\n\nBelow code will again execute the queries and will compare it with the baseline data.\nAfter comparision it will create an excel file of the result.\n\n```ruby\ninspector.inspect(phase: :VERIFY)\n```\n\n#### Result:\n\n\u003cimg src=\"https://github.com/ajitsing/ScreenShots/blob/master/data_verifier/data_verifier_result.png\"/\u003e\n\n## License\n```license\nMIT License\n\nCopyright (c) 2019 Ajit Singh\n\nPermission is hereby granted, free of charge, to any person obtaining a copy\nof this software and associated documentation files (the \"Software\"), to deal\nin the Software without restriction, including without limitation the rights\nto use, copy, modify, merge, publish, distribute, sublicense, and/or sell\ncopies of the Software, and to permit persons to whom the Software is\nfurnished to do so, subject to the following conditions:\n\nThe above copyright notice and this permission notice shall be included in all\ncopies or substantial portions of the Software.\n\nTHE SOFTWARE IS PROVIDED \"AS IS\", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR\nIMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,\nFITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE\nAUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER\nLIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,\nOUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE\nSOFTWARE.\n```\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fajitsing%2Fdata_verifier","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fajitsing%2Fdata_verifier","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fajitsing%2Fdata_verifier/lists"}