-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
test: add unit tesing for schema builder
Signed-off-by: ktro2828 <[email protected]>
- Loading branch information
Showing
1 changed file
with
71 additions
and
0 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,71 @@ | ||
from t4_devkit.schema import SchemaName, build_schema | ||
|
||
|
||
def test_build_attribute(attribute_json) -> None: | ||
"""Test building attribute.""" | ||
_ = build_schema(SchemaName.ATTRIBUTE, attribute_json) | ||
|
||
|
||
def test_build_calibrated_sensor(calibrated_sensor_json) -> None: | ||
"""Test building calibrated sensor.""" | ||
_ = build_schema(SchemaName.CALIBRATED_SENSOR, calibrated_sensor_json) | ||
|
||
|
||
def test_build_category(category_json) -> None: | ||
"""Test building category.""" | ||
_ = build_schema(SchemaName.CATEGORY, category_json) | ||
|
||
|
||
def test_build_ego_pose(ego_pose_json) -> None: | ||
"""Test building ego pose.""" | ||
_ = build_schema(SchemaName.EGO_POSE, ego_pose_json) | ||
|
||
|
||
def test_build_instance(instance_json) -> None: | ||
"""Test building instance.""" | ||
_ = build_schema(SchemaName.INSTANCE, instance_json) | ||
|
||
|
||
def test_build_log(log_json) -> None: | ||
"""Test building log.""" | ||
_ = build_schema(SchemaName.LOG, log_json) | ||
|
||
|
||
def test_build_map(map_json) -> None: | ||
"""Test building map.""" | ||
_ = build_schema(SchemaName.MAP, map_json) | ||
|
||
|
||
def test_build_object_ann(object_ann_json) -> None: | ||
"""Test building object ann.""" | ||
_ = build_schema(SchemaName.OBJECT_ANN, object_ann_json) | ||
|
||
|
||
def test_build_sample_annotation(sample_annotation_json) -> None: | ||
"""Test building sample annotation.""" | ||
_ = build_schema(SchemaName.SAMPLE_ANNOTATION, sample_annotation_json) | ||
|
||
|
||
def test_build_sample_data(sample_data_json) -> None: | ||
"""Test building sample data.""" | ||
_ = build_schema(SchemaName.SAMPLE_DATA, sample_data_json) | ||
|
||
|
||
def test_build_sample(sample_json) -> None: | ||
"""Test building sample.""" | ||
_ = build_schema(SchemaName.SAMPLE, sample_json) | ||
|
||
|
||
def test_build_sensor(sensor_json) -> None: | ||
"""Test building sensor.""" | ||
_ = build_schema(SchemaName.SENSOR, sensor_json) | ||
|
||
|
||
def test_build_surface_ann(surface_ann_json) -> None: | ||
"""Test building surface ann.""" | ||
_ = build_schema(SchemaName.SURFACE_ANN, surface_ann_json) | ||
|
||
|
||
def test_build_visibility(visibility_json) -> None: | ||
"""Test building visibility.""" | ||
_ = build_schema(SchemaName.VISIBILITY, visibility_json) |