public OpenAPI read(Class<?> cls) {
        return read(cls, resolveApplicationPath(), null, false, null, null, new LinkedHashSet<String>(), new ArrayList<Parameter>(), new HashSet<Class<?>>());
    }
@Test(description = "Optional handling")
    public void testTicket3624() {
        Reader reader = new Reader(new OpenAPI());

        OpenAPI openAPI = reader.read(Service.class);
        String yaml = "openapi: 3.0.1\n" +
                "paths:\n" +
                "  /example/model:\n" +
                "    get:\n" +
                "      tags:\n" +
                "      - ExampleService\n" +
                "      summary: ' Retrieve models for display to the user'\n" +
                "      operationId: getModels\n" +
                "      responses:\n" +
                "        default:\n" +
                "          description: default response\n" +
                "          content:\n" +
                "            application/json:\n" +
                "              schema:\n" +
                "                $ref: '#/components/schemas/Response'\n" +
                "  /example/model/by/ids:\n" +
                "    get:\n" +
                "      tags:\n" +
                "      - ExampleService\n" +
                "      summary: ' Retrieve models by their ids'\n" +
                "      operationId: getModelsById\n" +
                "      responses:\n" +
                "        default:\n" +
                "          description: default response\n" +
                "          content:\n" +
                "            application/json:\n" +
                "              schema:\n" +
                "                $ref: '#/components/schemas/ByIdResponse'\n" +
                "  /example/containerized/model:\n" +
                "    get:\n" +
                "      tags:\n" +
                "      - ExampleService\n" +
                "      summary: ' Retrieve review insights for a specific product'\n" +
                "      operationId: getContainerizedModels\n" +
                "      responses:\n" +
                "        default:\n" +
                "          description: default response\n" +
                "          content:\n" +
                "            application/json:\n" +
                "              schema:\n" +
                "                $ref: '#/components/schemas/ContainerizedResponse'\n" +
                "components:\n" +
                "  schemas:\n" +
                "    Model:\n" +
                "      type: object\n" +
                "      properties:\n" +
                "        text:\n" +
                "          type: string\n" +
                "        title:\n" +
                "          type: string\n" +
                "        active:\n" +
                "          type: boolean\n" +
                "        schemaParent:\n" +
                "          $ref: '#/components/schemas/Model'\n" +
                "        optionalString:\n" +
                "          type: string\n" +
                "        parent:\n" +
                "          $ref: '#/components/schemas/Model'\n" +
                "        id:\n" +
                "          type: integer\n" +
                "          format: int32\n" +
                "    Response:\n" +
                "      type: object\n" +
                "      properties:\n" +
                "        count:\n" +
                "          type: integer\n" +
                "          format: int32\n" +
                "        models:\n" +
                "          type: array\n" +
                "          items:\n" +
                "            $ref: '#/components/schemas/Model'\n" +
                "    ByIdResponse:\n" +
                "      type: object\n" +
                "      properties:\n" +
                "        modelsById:\n" +
                "          type: object\n" +
                "          additionalProperties:\n" +
                "            $ref: '#/components/schemas/Model'\n" +
                "    ContainerizedResponse:\n" +
                "      type: object\n" +
                "      properties:\n" +
                "        totalCount:\n" +
                "          type: integer\n" +
                "          format: int32\n" +
                "        containerizedModels:\n" +
                "          type: array\n" +
                "          items:\n" +
                "            $ref: '#/components/schemas/ModelContainer'\n" +
                "    ModelContainer:\n" +
                "      type: object\n" +
                "      properties:\n" +
                "        text:\n" +
                "          type: string\n" +
                "        model:\n" +
                "          $ref: '#/components/schemas/Model'\n" +
                "        id:\n" +
                "          type: integer\n" +
                "          format: int32";
        SerializationMatchers.assertEqualsToYaml(openAPI, yaml);
    }