2023-09-01 03:56:21 +00:00
|
|
|
import pytest
|
2023-09-06 04:47:41 +00:00
|
|
|
from ..fixtures import nwb_core_fixture
|
2023-09-01 03:56:21 +00:00
|
|
|
|
|
|
|
from nwb_schema_language import Dataset, Group, Schema
|
|
|
|
|
2024-07-02 04:23:31 +00:00
|
|
|
|
|
|
|
@pytest.mark.parametrize(["schema_name"], [["core.nwb.file"]])
|
2023-09-01 03:56:21 +00:00
|
|
|
def test_schema_build(nwb_core_fixture, schema_name):
|
|
|
|
schema = [sch for sch in nwb_core_fixture.schemas if sch.name == schema_name][0]
|
2023-10-12 03:03:08 +00:00
|
|
|
res = schema.build()
|
|
|
|
|
|
|
|
|
|
|
|
def test_schema_repr(nwb_core_fixture):
|
|
|
|
"""
|
|
|
|
Doesn't really make sense to test the string repr matches any particular value because it's
|
|
|
|
strictly cosmetic, but we do test that it can be done
|
|
|
|
"""
|
|
|
|
sch = nwb_core_fixture.schemas[0]
|
|
|
|
repr_str = sch.__repr__()
|
|
|
|
assert isinstance(repr_str, str)
|