@Test
    void verifyEmptyStringAsNull() {
        val json = """
              {
                  "@class" : "org.apereo.cas.services.CasRegisteredService",
                      "serviceId" : "^https://xyz.*",
                      "name" : "XYZ",
                      "id" : "20161214"
            "authenticationPolicy" : {
              "@class" : "org.apereo.cas.services.DefaultRegisteredServiceAuthenticationPolicy"}}""".indent(2);

        val serialized = serializer.from(json);
        assertNotNull(serialized);
        assertNotNull(serialized.getAuthenticationPolicy());
        assertNull(serialized.getAuthenticationPolicy().getCriteria());
    }
This is {@link RegisteredServiceJsonSerializerTests}.

@author Misagh Moayyed
@since 5.1.0
core/cas-server-core-services/src/test/java/org/apereo/cas/services/util/RegisteredServiceJsonSerializerTests.java