Skip to content
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

[master] Support enums in OpenAPI to Ballerina client and types generation #1328

Merged
merged 9 commits into from
May 8, 2023

Conversation

aneeshafedo
Copy link
Contributor

@aneeshafedo aneeshafedo commented Apr 21, 2023

Purpose

$subject
Resolves ballerina-platform/ballerina-library#5479

Check List

Enum Generation in parameters in Client generation

  • Query parameter
  • Header parameter
  • Path parameter

Enum generation in schema

  • Reusable enums
  • Inline enums in properties
  • Nullable enums

Security checks

Test environment

JAVA JDK 11

@aneeshafedo aneeshafedo force-pushed the enum-1.5.x branch 2 times, most recently from 7d74b59 to 74a9b3e Compare April 24, 2023 05:25
@aneeshafedo aneeshafedo force-pushed the enum-1.5.x branch 2 times, most recently from 16ead48 to 8223164 Compare April 24, 2023 07:35
@aneeshafedo aneeshafedo changed the base branch from 1.5.x to master April 24, 2023 11:13
@aneeshafedo aneeshafedo changed the title [1.5.x] Support enums in client and schemaOpenAPI to Ballerina generation [master] Support enums in client and schemaOpenAPI to Ballerina generation Apr 24, 2023
@aneeshafedo aneeshafedo marked this pull request as ready for review April 24, 2023 12:08
@aneeshafedo aneeshafedo changed the title [master] Support enums in client and schemaOpenAPI to Ballerina generation [master] Support enums in OpenAPI to Ballerina generation Apr 27, 2023
@aneeshafedo aneeshafedo changed the title [master] Support enums in OpenAPI to Ballerina generation [master] Support enums in OpenAPI to Ballerina client and types generation Apr 27, 2023
@codecov
Copy link

codecov bot commented May 1, 2023

Codecov Report

Patch coverage: 76.82% and project coverage change: -0.04 ⚠️

Comparison is base (20d1639) 78.95% compared to head (f7147c2) 78.91%.

Additional details and impacted files
@@             Coverage Diff              @@
##             master    ballerina-platform/openapi-tools#1328      +/-   ##
============================================
- Coverage     78.95%   78.91%   -0.04%     
- Complexity     1636     1656      +20     
============================================
  Files           123      124       +1     
  Lines          9641     9690      +49     
  Branches       1554     1569      +15     
============================================
+ Hits           7612     7647      +35     
- Misses         1463     1470       +7     
- Partials        566      573       +7     
Impacted Files Coverage Δ
...ma/ballerinatypegenerators/ArrayTypeGenerator.java 94.11% <0.00%> (-1.97%) ⬇️
...i/core/generators/service/ParametersGenerator.java 85.65% <ø> (ø)
.../schema/ballerinatypegenerators/EnumGenerator.java 73.07% <73.07%> (ø)
.../generators/client/FunctionSignatureGenerator.java 91.89% <75.00%> (-1.22%) ⬇️
...allerinatypegenerators/PrimitiveTypeGenerator.java 94.11% <83.33%> (-5.89%) ⬇️
...java/io/ballerina/openapi/core/GeneratorUtils.java 88.14% <84.61%> (-0.14%) ⬇️
...api/core/generators/schema/TypeGeneratorUtils.java 90.73% <100.00%> (ø)

... and 1 file with indirect coverage changes

☔ View full report in Codecov by Sentry.
📢 Do you have feedback about the report comment? Let us know in this issue.

…i-tools into enum-1.5.x

# Conflicts:
#	openapi-core/src/main/java/io/ballerina/openapi/core/generators/service/ParametersGenerator.java
@sonarcloud
Copy link

sonarcloud bot commented May 8, 2023

Kudos, SonarCloud Quality Gate passed!    Quality Gate passed

Bug A 0 Bugs
Vulnerability A 0 Vulnerabilities
Security Hotspot A 0 Security Hotspots
Code Smell A 10 Code Smells

No Coverage information No Coverage information
0.0% 0.0% Duplication

Copy link
Contributor

@NipunaRanasinghe NipunaRanasinghe left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM

Copy link
Member

@lnash94 lnash94 left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM

@lnash94 lnash94 merged commit 7872aeb into ballerina-platform:master May 8, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Support Enums in connector generation
3 participants