-
Notifications
You must be signed in to change notification settings - Fork 114
Json Patch e2e #1565
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Open
suarezrominajulieta
wants to merge
8
commits into
master
Choose a base branch
from
feature/jsonPatch_e2e
base: master
Could not load branches
Branch not found: {{ refName }}
Loading
Could not load tags
Nothing to show
Loading
Are you sure you want to change the base?
Some commits from the old base branch may be removed from the timeline,
and old review comments may become outdated.
+870
−4
Open
Json Patch e2e #1565
Changes from all commits
Commits
Show all changes
8 commits
Select commit
Hold shift + click to select a range
98ace44
Init approach
suarezrominajulieta 573dbc0
Merge branch 'master' into feature/jsonPatch_e2e
suarezrominajulieta 29f225c
Merge branch 'feature/jsonPatch' into feature/jsonPatch_e2e
suarezrominajulieta 9fdf0a6
Fix DTOtest, and add betters to e2e
suarezrominajulieta 78c7fed
Fix overhead of changes
suarezrominajulieta e9176b8
fix extra
suarezrominajulieta b162b83
tunning
suarezrominajulieta f319fca
Merge branch 'master' into feature/jsonPatch_e2e
suarezrominajulieta File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
There are no files selected for viewing
142 changes: 142 additions & 0 deletions
142
...ring-rest-bb/src/main/kotlin/com/foo/rest/examples/bb/jsonpatch/BBJsonPatchApplication.kt
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,142 @@ | ||
| package com.foo.rest.examples.bb.jsonpatch | ||
|
|
||
| import com.fasterxml.jackson.databind.JsonNode | ||
| import com.fasterxml.jackson.databind.ObjectMapper | ||
| import io.swagger.v3.oas.annotations.responses.ApiResponse | ||
| import io.swagger.v3.oas.annotations.responses.ApiResponses | ||
| import org.springframework.boot.SpringApplication | ||
| import org.springframework.boot.autoconfigure.SpringBootApplication | ||
| import org.springframework.boot.autoconfigure.security.servlet.SecurityAutoConfiguration | ||
| import org.evomaster.e2etests.utils.CoveredTargets | ||
| import org.springframework.http.ResponseEntity | ||
| import org.springframework.web.bind.annotation.* | ||
|
|
||
| @SpringBootApplication(exclude = [SecurityAutoConfiguration::class]) | ||
| @RestController | ||
| @RequestMapping("/pets") | ||
| open class BBJsonPatchApplication { | ||
|
|
||
| companion object { | ||
| @JvmStatic | ||
| fun main(args: Array<String>) { | ||
| SpringApplication.run(BBJsonPatchApplication::class.java, *args) | ||
| } | ||
| } | ||
|
|
||
| private val store: MutableMap<Long, BBJsonPatchDto> = mutableMapOf( | ||
| 1L to BBJsonPatchDto("Dog", 3), | ||
| 2L to BBJsonPatchDto("Cat", 5) | ||
| ) | ||
|
|
||
| private val mapper = ObjectMapper() | ||
|
|
||
| @ApiResponses(value = [ | ||
| ApiResponse(responseCode = "200", description = "Pet found"), | ||
| ApiResponse(responseCode = "400", description = "Invalid pet id") | ||
| ]) | ||
| @GetMapping("/{id}") | ||
| fun getPet(@PathVariable id: Long): ResponseEntity<BBJsonPatchDto> { | ||
| val pet = store[id] ?: return ResponseEntity.badRequest().build() | ||
| return ResponseEntity.ok(pet) | ||
| } | ||
|
|
||
| @ApiResponses(value = [ | ||
| ApiResponse(responseCode = "200", description = "Patch document processed successfully"), | ||
| ApiResponse(responseCode = "400", description = "Patch document is not a JSON array") | ||
| ]) | ||
| @PatchMapping("/{id}", consumes = ["application/json-patch+json"]) | ||
| fun patchPet(@PathVariable id: Long, @RequestBody body: String): ResponseEntity<String> { | ||
| if (parsePatchDocument(body) == null) | ||
| return ResponseEntity.badRequest().body("Patch document must be a JSON array") | ||
|
|
||
| CoveredTargets.cover("PATCHED") | ||
| return ResponseEntity.ok("patched") | ||
| } | ||
|
|
||
| @ApiResponses(value = [ | ||
| ApiResponse(responseCode = "200", description = "Add operation processed successfully"), | ||
| ApiResponse(responseCode = "400", description = "Patch document does not contain an add operation") | ||
| ]) | ||
| @PatchMapping("/{id}/add", consumes = ["application/json-patch+json"], produces = ["text/plain"]) | ||
| fun addPet(@PathVariable id: Long, @RequestBody body: String): ResponseEntity<String> = | ||
| patchOperation(body, "add", "JSON_PATCH_ADD") | ||
|
|
||
| @ApiResponses(value = [ | ||
| ApiResponse(responseCode = "200", description = "Remove operation processed successfully"), | ||
| ApiResponse(responseCode = "400", description = "Patch document does not contain a remove operation") | ||
| ]) | ||
| @PatchMapping("/{id}/remove", consumes = ["application/json-patch+json"], produces = ["text/plain"]) | ||
| fun removePet(@PathVariable id: Long, @RequestBody body: String): ResponseEntity<String> = | ||
| patchOperation(body, "remove", "JSON_PATCH_REMOVE") | ||
|
|
||
| @ApiResponses(value = [ | ||
| ApiResponse(responseCode = "200", description = "Replace operation processed successfully"), | ||
| ApiResponse(responseCode = "400", description = "Patch document does not contain a replace operation") | ||
| ]) | ||
| @PatchMapping("/{id}/replace", consumes = ["application/json-patch+json"], produces = ["text/plain"]) | ||
| fun replacePet(@PathVariable id: Long, @RequestBody body: String): ResponseEntity<String> = | ||
| patchOperation(body, "replace", "JSON_PATCH_REPLACE") | ||
|
|
||
| @ApiResponses(value = [ | ||
| ApiResponse(responseCode = "200", description = "Move operation processed successfully"), | ||
| ApiResponse(responseCode = "400", description = "Patch document does not contain a move operation") | ||
| ]) | ||
| @PatchMapping("/{id}/move", consumes = ["application/json-patch+json"], produces = ["text/plain"]) | ||
| fun movePet(@PathVariable id: Long, @RequestBody body: String): ResponseEntity<String> = | ||
| patchOperation(body, "move", "JSON_PATCH_MOVE") | ||
|
|
||
| @ApiResponses(value = [ | ||
| ApiResponse(responseCode = "200", description = "Copy operation processed successfully"), | ||
| ApiResponse(responseCode = "400", description = "Patch document does not contain a copy operation") | ||
| ]) | ||
| @PatchMapping("/{id}/copy", consumes = ["application/json-patch+json"], produces = ["text/plain"]) | ||
| fun copyPet(@PathVariable id: Long, @RequestBody body: String): ResponseEntity<String> = | ||
| patchOperation(body, "copy", "JSON_PATCH_COPY") | ||
|
|
||
| @ApiResponses(value = [ | ||
| ApiResponse(responseCode = "200", description = "Test operation processed successfully"), | ||
| ApiResponse(responseCode = "400", description = "Patch document does not contain a test operation") | ||
| ]) | ||
| @PatchMapping("/{id}/test", consumes = ["application/json-patch+json"], produces = ["text/plain"]) | ||
| fun testPet(@PathVariable id: Long, @RequestBody body: String): ResponseEntity<String> = | ||
| patchOperation(body, "test", "JSON_PATCH_TEST") | ||
|
|
||
| @ApiResponses(value = [ | ||
| ApiResponse(responseCode = "200", description = "Patch document has multiple operations"), | ||
| ApiResponse(responseCode = "400", description = "Patch document has fewer than two operations") | ||
| ]) | ||
| @PatchMapping("/{id}/sequence", consumes = ["application/json-patch+json"], produces = ["text/plain"]) | ||
| fun sequencePet(@PathVariable id: Long, @RequestBody body: String): ResponseEntity<String> { | ||
| if (!hasMultipleOperations(body)) | ||
| return ResponseEntity.badRequest().body("Patch document must contain at least two operations") | ||
|
|
||
| CoveredTargets.cover("JSON_PATCH_SEQUENCE") | ||
| return ResponseEntity.ok("sequence patched") | ||
| } | ||
|
|
||
| private fun patchOperation(body: String, operation: String, target: String): ResponseEntity<String> { | ||
| if (!hasOperation(body, operation)) | ||
| return ResponseEntity.badRequest().body("Patch document must contain a $operation operation") | ||
|
|
||
| CoveredTargets.cover(target) | ||
| return ResponseEntity.ok("$operation patched") | ||
| } | ||
|
|
||
| private fun hasOperation(body: String, operation: String): Boolean = | ||
| parsePatchDocument(body)?.any { it.path("op").asText() == operation } ?: false | ||
|
|
||
| private fun hasMultipleOperations(body: String): Boolean = | ||
| parsePatchDocument(body) | ||
| ?.takeIf { it.size() >= 2 } | ||
| ?.all { it.hasNonNull("op") } | ||
| ?: false | ||
|
|
||
| private fun parsePatchDocument(body: String): JsonNode? = | ||
| try { | ||
| mapper.readTree(body).takeIf { it.isArray } | ||
| } catch (e: Exception) { | ||
| null | ||
| } | ||
| } | ||
|
|
||
| data class BBJsonPatchDto(val name: String = "", val age: Int = 0) | ||
5 changes: 5 additions & 0 deletions
5
...pring-rest-bb/src/test/kotlin/com/foo/rest/examples/bb/jsonpatch/BBJsonPatchController.kt
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,5 @@ | ||
| package com.foo.rest.examples.bb.jsonpatch | ||
|
|
||
| import com.foo.rest.examples.bb.SpringController | ||
|
|
||
| class BBJsonPatchController : SpringController(BBJsonPatchApplication::class.java) |
72 changes: 72 additions & 0 deletions
72
...est-bb/src/test/kotlin/org/evomaster/e2etests/spring/rest/bb/jsonpatch/BBJsonPatchTest.kt
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,72 @@ | ||
| package org.evomaster.e2etests.spring.rest.bb.jsonpatch | ||
|
|
||
| import com.foo.rest.examples.bb.jsonpatch.BBJsonPatchController | ||
| import org.evomaster.core.EMConfig | ||
| import org.evomaster.core.output.OutputFormat | ||
| import org.evomaster.core.problem.rest.data.HttpVerb | ||
| import org.evomaster.e2etests.spring.rest.bb.SpringTestBase | ||
| import org.junit.jupiter.api.Assertions.assertTrue | ||
| import org.junit.jupiter.api.BeforeAll | ||
| import org.junit.jupiter.params.ParameterizedTest | ||
| import org.junit.jupiter.params.provider.EnumSource | ||
|
|
||
| class BBJsonPatchTest : SpringTestBase() { | ||
|
|
||
| companion object { | ||
| @BeforeAll | ||
| @JvmStatic | ||
| fun init() { | ||
| val config = EMConfig() | ||
| initClass(BBJsonPatchController(), config) | ||
| } | ||
| } | ||
|
|
||
| @ParameterizedTest | ||
| @EnumSource | ||
| fun testBlackBoxOutput(outputFormat: OutputFormat) { | ||
| executeAndEvaluateBBTest( | ||
| outputFormat, | ||
| "BBJsonPatchEM", | ||
| 1000, | ||
| 3, | ||
| listOf( | ||
| "PATCHED", | ||
| "JSON_PATCH_ADD", | ||
| "JSON_PATCH_REMOVE", | ||
| "JSON_PATCH_REPLACE", | ||
| "JSON_PATCH_MOVE", | ||
| "JSON_PATCH_COPY", | ||
| "JSON_PATCH_TEST", | ||
| "JSON_PATCH_SEQUENCE" | ||
| ) | ||
| ) { args: MutableList<String> -> | ||
|
|
||
| val solution = initAndRun(args) | ||
|
|
||
| assertTrue(solution.individuals.size >= 1) | ||
|
|
||
| assertHasAtLeastOne(solution, HttpVerb.PATCH, 200, "/pets/{id}", "patched") | ||
|
|
||
| assertHasAtLeastOne(solution, HttpVerb.PATCH, 200, "/pets/{id}/add", "add patched") | ||
| assertHasAtLeastOne(solution, HttpVerb.PATCH, 400, "/pets/{id}/add", null) | ||
|
|
||
| assertHasAtLeastOne(solution, HttpVerb.PATCH, 200, "/pets/{id}/remove", "remove patched") | ||
| assertHasAtLeastOne(solution, HttpVerb.PATCH, 400, "/pets/{id}/remove", null) | ||
|
|
||
| assertHasAtLeastOne(solution, HttpVerb.PATCH, 200, "/pets/{id}/replace", "replace patched") | ||
| assertHasAtLeastOne(solution, HttpVerb.PATCH, 400, "/pets/{id}/replace", null) | ||
|
|
||
| assertHasAtLeastOne(solution, HttpVerb.PATCH, 200, "/pets/{id}/move", "move patched") | ||
| assertHasAtLeastOne(solution, HttpVerb.PATCH, 400, "/pets/{id}/move", null) | ||
|
|
||
| assertHasAtLeastOne(solution, HttpVerb.PATCH, 200, "/pets/{id}/copy", "copy patched") | ||
| assertHasAtLeastOne(solution, HttpVerb.PATCH, 400, "/pets/{id}/copy", null) | ||
|
|
||
| assertHasAtLeastOne(solution, HttpVerb.PATCH, 200, "/pets/{id}/test", "test patched") | ||
| assertHasAtLeastOne(solution, HttpVerb.PATCH, 400, "/pets/{id}/test", null) | ||
|
|
||
| assertHasAtLeastOne(solution, HttpVerb.PATCH, 200, "/pets/{id}/sequence", "sequence patched") | ||
| assertHasAtLeastOne(solution, HttpVerb.PATCH, 400, "/pets/{id}/sequence", null) | ||
| } | ||
| } | ||
| } |
167 changes: 167 additions & 0 deletions
167
...src/main/kotlin/com/foo/rest/examples/spring/openapi/v3/jsonpatch/JsonPatchApplication.kt
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,167 @@ | ||
| package com.foo.rest.examples.spring.openapi.v3.jsonpatch | ||
|
|
||
| import com.fasterxml.jackson.databind.JsonNode | ||
| import com.fasterxml.jackson.databind.ObjectMapper | ||
| import io.swagger.v3.oas.annotations.responses.ApiResponse | ||
| import io.swagger.v3.oas.annotations.responses.ApiResponses | ||
| import org.springframework.boot.SpringApplication | ||
| import org.springframework.boot.autoconfigure.SpringBootApplication | ||
| import org.springframework.boot.autoconfigure.security.servlet.SecurityAutoConfiguration | ||
| import org.springframework.http.ResponseEntity | ||
| import org.springframework.web.bind.annotation.* | ||
|
|
||
| @SpringBootApplication(exclude = [SecurityAutoConfiguration::class]) | ||
| @RestController | ||
| @RequestMapping("/pets") | ||
| open class JsonPatchApplication { | ||
|
|
||
| companion object { | ||
| @JvmStatic | ||
| fun main(args: Array<String>) { | ||
| SpringApplication.run(JsonPatchApplication::class.java, *args) | ||
| } | ||
| } | ||
|
|
||
| private val store: MutableMap<Long, JsonPatchDto> = mutableMapOf( | ||
| 1L to JsonPatchDto("Dog", 3), | ||
| 2L to JsonPatchDto("Cat", 5) | ||
| ) | ||
|
|
||
| private val mapper = ObjectMapper() | ||
|
|
||
| @ApiResponses(value = [ | ||
| ApiResponse(responseCode = "200", description = "Pet found"), | ||
| ApiResponse(responseCode = "400", description = "Invalid pet id") | ||
| ]) | ||
| @GetMapping("/{id}") | ||
| fun getPet(@PathVariable id: Long): ResponseEntity<JsonPatchDto> { | ||
| val pet = store[id] ?: return ResponseEntity.badRequest().build() | ||
| return ResponseEntity.ok(pet) | ||
| } | ||
|
|
||
| @ApiResponses(value = [ | ||
| ApiResponse(responseCode = "200", description = "Patch document processed successfully"), | ||
| ApiResponse(responseCode = "400", description = "Pet id is invalid or patch document is not a JSON array") | ||
| ]) | ||
| @PatchMapping("/{id}", consumes = ["application/json-patch+json"]) | ||
| fun patchPet(@PathVariable id: Long, @RequestBody body: String): ResponseEntity<String> { | ||
| if (!store.containsKey(id)) return ResponseEntity.badRequest().body("Invalid pet id") | ||
|
|
||
| if (parsePatchDocument(body) == null) | ||
| return ResponseEntity.badRequest().body("Patch document must be a JSON array") | ||
|
|
||
| return ResponseEntity.ok("patched") | ||
| } | ||
|
|
||
| @ApiResponses(value = [ | ||
| ApiResponse(responseCode = "200", description = "Add operation processed successfully"), | ||
| ApiResponse(responseCode = "400", description = "Pet id is not positive or patch document does not contain an add operation for /a") | ||
| ]) | ||
| @PatchMapping("/{id}/add", consumes = ["application/json-patch+json"], produces = ["text/plain"]) | ||
| fun addPet(@PathVariable id: Long, @RequestBody body: String): ResponseEntity<String> = | ||
| patchOperation(id, body, "add") { it.path("path").asText() == "/a" } | ||
|
|
||
| @ApiResponses(value = [ | ||
| ApiResponse(responseCode = "200", description = "Remove operation processed successfully"), | ||
| ApiResponse(responseCode = "400", description = "Pet id is not positive or patch document does not contain a remove operation for /b") | ||
| ]) | ||
| @PatchMapping("/{id}/remove", consumes = ["application/json-patch+json"], produces = ["text/plain"]) | ||
| fun removePet(@PathVariable id: Long, @RequestBody body: String): ResponseEntity<String> = | ||
| patchOperation(id, body, "remove") { it.path("path").asText() == "/b" } | ||
|
|
||
| @ApiResponses(value = [ | ||
| ApiResponse(responseCode = "200", description = "Replace operation processed successfully"), | ||
| ApiResponse(responseCode = "400", description = "Pet id is not positive or patch document does not contain a replace operation for /c") | ||
| ]) | ||
| @PatchMapping("/{id}/replace", consumes = ["application/json-patch+json"], produces = ["text/plain"]) | ||
| fun replacePet(@PathVariable id: Long, @RequestBody body: String): ResponseEntity<String> = | ||
| patchOperation(id, body, "replace") { it.path("path").asText() == "/c" } | ||
|
|
||
| @ApiResponses(value = [ | ||
| ApiResponse(responseCode = "200", description = "Move operation processed successfully"), | ||
| ApiResponse(responseCode = "400", description = "Pet id is not positive or patch document does not contain a move operation from /a to /d") | ||
| ]) | ||
| @PatchMapping("/{id}/move", consumes = ["application/json-patch+json"], produces = ["text/plain"]) | ||
| fun movePet(@PathVariable id: Long, @RequestBody body: String): ResponseEntity<String> = | ||
| patchOperation(id, body, "move") { | ||
| it.path("from").asText() == "/a" && it.path("path").asText() == "/d" | ||
| } | ||
|
|
||
| @ApiResponses(value = [ | ||
| ApiResponse(responseCode = "200", description = "Copy operation processed successfully"), | ||
| ApiResponse(responseCode = "400", description = "Pet id is not positive or patch document does not contain a copy operation from /a to /d") | ||
| ]) | ||
| @PatchMapping("/{id}/copy", consumes = ["application/json-patch+json"], produces = ["text/plain"]) | ||
| fun copyPet(@PathVariable id: Long, @RequestBody body: String): ResponseEntity<String> = | ||
| patchOperation(id, body, "copy") { | ||
| it.path("from").asText() == "/a" && it.path("path").asText() == "/d" | ||
| } | ||
|
|
||
| @ApiResponses(value = [ | ||
| ApiResponse(responseCode = "200", description = "Test operation processed successfully"), | ||
| ApiResponse(responseCode = "400", description = "Pet id is not positive or patch document does not contain a test operation for /b") | ||
| ]) | ||
| @PatchMapping("/{id}/test", consumes = ["application/json-patch+json"], produces = ["text/plain"]) | ||
| fun testPet(@PathVariable id: Long, @RequestBody body: String): ResponseEntity<String> = | ||
| patchOperation(id, body, "test") { it.path("path").asText() == "/b" } | ||
|
|
||
| @ApiResponses(value = [ | ||
| ApiResponse(responseCode = "200", description = "Patch document has multiple operations"), | ||
| ApiResponse(responseCode = "400", description = "Pet id is not positive or patch document does not add /a before replacing /c") | ||
| ]) | ||
| @PatchMapping("/{id}/sequence", consumes = ["application/json-patch+json"], produces = ["text/plain"]) | ||
| fun sequencePet(@PathVariable id: Long, @RequestBody body: String): ResponseEntity<String> { | ||
| if (id <= 0) | ||
| return ResponseEntity.badRequest().body("Pet id must be positive") | ||
|
|
||
| if (!hasAddThenReplaceSequence(body)) | ||
| return ResponseEntity.badRequest().body("Patch document must contain add followed by replace") | ||
|
|
||
| return ResponseEntity.ok("sequence patched") | ||
| } | ||
|
|
||
| private fun patchOperation( | ||
| id: Long, | ||
| body: String, | ||
| operation: String, | ||
| extraCheck: (JsonNode) -> Boolean | ||
| ): ResponseEntity<String> { | ||
| if (id <= 0) | ||
| return ResponseEntity.badRequest().body("Pet id must be positive") | ||
|
|
||
| if (!hasOperation(body, operation, extraCheck)) | ||
| return ResponseEntity.badRequest().body("Patch document must contain a $operation operation") | ||
|
|
||
| return ResponseEntity.ok("$operation patched") | ||
| } | ||
|
|
||
| private fun hasOperation(body: String, operation: String, extraCheck: (JsonNode) -> Boolean): Boolean = | ||
| parsePatchDocument(body)?.any { it.path("op").asText() == operation && extraCheck(it) } ?: false | ||
|
|
||
| private fun hasAddThenReplaceSequence(body: String): Boolean { | ||
| val operations = parsePatchDocument(body) ?: return false | ||
| if (operations.size() < 2) | ||
| return false | ||
|
|
||
| var hasAdd = false | ||
| var hasReplace = false | ||
|
|
||
| for (operation in operations) { | ||
| if (operation.path("op").asText() == "add" && operation.path("path").asText() == "/a") | ||
| hasAdd = true | ||
| if (operation.path("op").asText() == "replace" && operation.path("path").asText() == "/c") | ||
| hasReplace = true | ||
| } | ||
|
|
||
| return hasAdd && hasReplace | ||
| } | ||
|
|
||
| private fun parsePatchDocument(body: String): JsonNode? = | ||
| try { | ||
| mapper.readTree(body).takeIf { it.isArray } | ||
| } catch (e: Exception) { | ||
| null | ||
| } | ||
| } | ||
|
|
||
| data class JsonPatchDto(val name: String = "", val age: Int = 0) |
5 changes: 5 additions & 0 deletions
5
.../src/test/kotlin/com/foo/rest/examples/spring/openapi/v3/jsonpatch/JsonPatchController.kt
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,5 @@ | ||
| package com.foo.rest.examples.spring.openapi.v3.jsonpatch | ||
|
|
||
| import com.foo.rest.examples.spring.openapi.v3.SpringController | ||
|
|
||
| class JsonPatchController : SpringController(JsonPatchApplication::class.java) |
Oops, something went wrong.
Oops, something went wrong.
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Why blackbox and whitebox, I think we need only one of them for testing this functionality.