sngular / scc-multiapi-converter

SCC Verifier MultiApi Converter allows us to use Spring Cloud Contract to generate contracts from an OpenApi yaml or AsyncApi yaml document

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

Failed to execute goal 'generateTests' while trying to generate contracts from an OpenApi yaml document

ingogriebsch opened this issue · comments

Hello,

I would like to understand how this library works. So I created a Spring-Boot project based on Spring-Boot 2.7.3 and Spring-Cloud 2021.0.3. As build tool I use Maven 3.8 and to configure the project properly I followed the instructions on your website. As API definition I used the OpenApi example from your website.

When I run the build I get the following error message:

Failed to execute goal org.springframework.cloud:spring-cloud-contract-maven-plugin:3.1.3:generateTests (default-generateTests) on project openapi-scc: Execution default-generateTests of goal org. springframework.cloud:spring-cloud-contract-maven-plugin:3.1.3:generateTests failed: Failed to convert file [C:\opt\ws\work\_openapi-scc\src\main\resources\api\openapi.yml]: Cannot invoke "io.swagger.v3.oas.models.media.Schema.getExample()" because "schema" is null -> [Help 1].

Am I doing something wrong? Is the example missing some things? Is the library having a bug?

The project where I had the problem can be found here:
https://github.com/ingogriebsch/_openapi-scc

Thank you for collaborating with the project by giving us feedback!!

Hi @ingogriebsch,

sorry for the delay answering, we got a bit of internal miss communication.

I’ll take a look into it,

Cheeers

Hi @ingogriebsch ,

You can now check the changes we have made in this branch.

Cheers.