OpenAPITools / OpenAPITools/openapi-generator
[REQ] [typescript-fetch] Add unit test for required nullable datetimes
Nobody has claimed this yet.
- Dominant language
- Java
- Stars
- 26.8k
- Forks
- 7.7k
- PR merge metrics
- PR metrics pending
Description
New test for required nullable datetimes
A bug was recently introduced where required nullable datetimes would cause an issue (runtime crash) for clients when generating the code.
Describe the solution you'd like
A new test could be created that could catch this in the future if any other changes are made to the template.
Additional context
OpenAPI Specification:
{
"type": "object",
"properties": {
"startedAt": {
"type": "string",
"format": "date-time",
"nullable": true
}
},
"required": [
"startedAt"
]
See issue #21820
Contributor guide
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
Research direction
Start by locating the existing typescript-fetch generator tests and the template or test entry point for generated clients. Use the provided OpenAPI schema with a required nullable date-time property, and consider the work done when generation and the generated client complete without the runtime crash described in issue #21820.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- typescript
- Domain
- testing-qa
- Issue type
- Bug
- Difficulty
- 3/5
- Estimated time
- Half a day
- Activity status
- Stale
- Clarity
- Mostly clear
- Newbie friendliness
- 48/100