Skip to content

Conversation

gslaszlo
Copy link

Add support for generated enum types, as in orval docs.

@gslaszlo gslaszlo requested a review from a team as a code owner July 25, 2025 08:14
@CLAassistant
Copy link

CLAassistant commented Jul 25, 2025

CLA assistant check
All committers have signed the CLA.

@DefCon-007
Copy link
Collaborator

@gslaszlo Thanks a lot for the changes. The changes look good. I will try to test it locally once, meanwhile, can you add some unit tests for this? We can add some functional tests like this, https://github.com/grafana/openapi-to-k6/blob/main/tests/functional-tests/test-generator/generator.test.ts, we could take a single schema and test it out for all the supported enum types.

@gslaszlo
Copy link
Author

gslaszlo commented Aug 7, 2025

@DefCon-007 Thanks for pointing it out, I've added tests for all 3 cases. I didn't want to do a lot of edits in the generator.test.ts so I added 3 fixtures with different expected_sdk params, but if you prefer to add more code instead of fixtures, I can do that as well.

@DefCon-007
Copy link
Collaborator

@gslaszlo Could you fix the conflicts? We are good to merge once they are fixed.

@gslaszlo
Copy link
Author

gslaszlo commented Sep 3, 2025

@DefCon-007 Sorry for the delay, fixed the conflicts.

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.

3 participants