24 lines
612 B
Markdown
24 lines
612 B
Markdown
# JSON Schema Validator Artifact
|
|
|
|
## Overview
|
|
This artifact contains a JSON Schema Validator implementation that validates JSON files against JSON schemas.
|
|
|
|
## Files
|
|
- `json_schema_cli.py` - Command-line JSON validator
|
|
- `test_validator.py` - Test runner for the validator
|
|
- `test_schema.json` - JSON schema for testing
|
|
- `valid_test_data.json` - Valid test data
|
|
- `invalid_test_data.json` - Invalid test data (type mismatch)
|
|
|
|
## Usage
|
|
```bash
|
|
python3 json_schema_cli.py <json_file> <schema_file>
|
|
```
|
|
|
|
## Verification
|
|
Run tests with:
|
|
```bash
|
|
python3 test_validator.py
|
|
```
|
|
|
|
All tests should pass with exit code 0. |