def test_invalid_no_name(app):
    invalid = {
        "acronym": "TEST",
        "id": "aff-1",
        "identifiers": [
            {"identifier": "03yrm5c26", "scheme": "ror"}
        ],
        "title": {
            "en": "Test affiliation",
            "es": "Afiliacion de test"
        }
    }
    with pytest.raises(ValidationError):
        data = AffiliationSchema().load(invalid)
def test_valid_minimal(app):
    data = {
        "name": "Test affiliation",
    }
    loaded = AffiliationSchema().load(data)
    assert data == loaded
def test_valid_full(app, affiliation_full_data):
    loaded = AffiliationSchema().load(affiliation_full_data)
    assert affiliation_full_data == loaded