File tree Expand file tree Collapse file tree 1 file changed +11
-0
lines changed
library/src/test/scala/za/co/absa/springdocopenapiscala Expand file tree Collapse file tree 1 file changed +11
-0
lines changed Original file line number Diff line number Diff line change @@ -56,6 +56,17 @@ class OpenAPIScalaCustomizerSpec extends AnyFlatSpec {
56
56
57
57
behavior of " customise"
58
58
59
+ it should " set `components` of its argument OpenAPI object to one injected via DI to the class" in {
60
+ val components = new Components ().addSchemas(" a" , new Schema )
61
+ val openAPIScalaCustomizer = new OpenAPIScalaCustomizer (components)
62
+
63
+ val openAPI = initializeOpenAPI
64
+
65
+ openAPIScalaCustomizer.customise(openAPI)
66
+
67
+ assert(openAPI.getComponents === components)
68
+ }
69
+
59
70
it should " convert all responses returning Unit (BoxedUnit reference) to empty response" in {
60
71
val components = new Components ()
61
72
val openAPIScalaCustomizer = new OpenAPIScalaCustomizer (components)
You can’t perform that action at this time.
0 commit comments