From 3517f7a869710e52a2b37927fd89eb2cb14f744a Mon Sep 17 00:00:00 2001 From: Sterchi Daniel Date: Mon, 15 Jul 2024 15:52:58 +0200 Subject: [PATCH] remove bug related todos created issues for that: - https://github.com/citrusframework/citrus/issues/1190 - https://github.com/citrusframework/citrus/issues/1189 --- .../openapi/integration/OpenApiClientIT.java | 113 ------------------ 1 file changed, 113 deletions(-) diff --git a/connectors/citrus-openapi/src/test/java/org/citrusframework/openapi/integration/OpenApiClientIT.java b/connectors/citrus-openapi/src/test/java/org/citrusframework/openapi/integration/OpenApiClientIT.java index 97c58b45c6..f9831727b6 100644 --- a/connectors/citrus-openapi/src/test/java/org/citrusframework/openapi/integration/OpenApiClientIT.java +++ b/connectors/citrus-openapi/src/test/java/org/citrusframework/openapi/integration/OpenApiClientIT.java @@ -188,119 +188,6 @@ public void getPetById_generated() { .receive("getPetById", HttpStatus.OK)); } - // TODO TAT-1291 create issues for Bugs - @CitrusTest - public void BUG_getPetById_paramsCanAlsoBeSetWithMessageBuilder() { - variable("petId", "1001"); - - when(openapi(petstoreSpec) - .client(httpClient) - .send("getPetById") - .fork(true) - .message() - // TODO Bug - if the params are already set on the message, they get overwritten - .queryParam("verbose", "false") - .header("correlationIds", "1234F5gXW") - ); - - then(http().server(httpServer) - .receive() - .get("/pet/1001") - .queryParam("verbose", "true") - .message() - .header("correlationIds", "1234F5gXW") - ); - - then(http().server(httpServer) - .send() - .response(HttpStatus.OK) - .message() - .body(Resources.create("classpath:org/citrusframework/openapi/petstore/pet.json")) - .contentType("application/json")); - - then(openapi(petstoreSpec) - .client(httpClient) - .receive("getPetById", HttpStatus.OK)); - } - - @CitrusTest - public void BUG_should_be_possible_to_switch_content_type__to_xml() { - variable("petId", "1001"); - - when(openapi(petstoreSpec) - .client(httpClient) - .send("getPetById") - .message() - .accept("application/xml") - .fork(true)); - - then(http().server(httpServer) - .receive() - .get("/pet/${petId}") - .message() - .accept("@contains('application/xml')@")); - - then(http().server(httpServer) - .send() - .response(HttpStatus.OK) - .message() - .body(Resources.create("classpath:org/citrusframework/openapi/petstore/pet.xml")) - .contentType("application/xml")); - - then(openapi(petstoreSpec) - .client(httpClient) - .receive("getPetById", HttpStatus.OK) - .message() - // TODO BUG XML bodies do not seem to work, even if there is just XML as "produces" in the spec - .body(Resources.create("classpath:org/citrusframework/openapi/petstore/pet.xml")) - // TODO BUG the type/contentType statements are useless, if there is another type in the spec. - // even if there are two. i.E: - // # this will always use JSON as type - // produces: - // - application/json - // - application/xml - .contentType("application/xml") - .type(XML)); - } - - @CitrusTest - public void BUG_should_only_validate_the_presence_of_required_properties() { - variable("petId", "1001"); - - when(openapi(petstoreSpec) - .client(httpClient) - .send("getPetById") - .message() - .accept("application/json") - .fork(true)); - - then(http().server(httpServer) - .receive() - .get("/pet/${petId}") - .message() - .accept("@contains('application/json')@")); - - then(http().server(httpServer) - .send() - .response(HttpStatus.OK) - .message() - // TODO BUG this should be valid, according to the spec-file - .body(""" - { - "category": {}, - "name": "", - "status": "sold" - } - """) - .contentType("application/json")); - - then(openapi(petstoreSpec) - .client(httpClient) - .receive("getPetById", HttpStatus.OK) - .message() - ); - } - @CitrusTest public void postAddPet() { variable("petId", "1001");