Conversation
There was a problem hiding this comment.
Pull request overview
This PR refactors the NodaTime scalar surface by replacing the former OffsetDateTime scalar implementation with a new DateTime scalar backed by NodaTime’s OffsetDateTime, introducing precision options and related resource strings.
Changes:
- Remove
OffsetDateTimeType(and its tests) and add a newDateTimeTypescalar +DateTimeOptionsfor input/output fractional-second precision. - Update the NodaTime test schema registration helper to register
DateTimeType. - Add new localized resource strings and expose internals to the
HotChocolate.Types.NodaTimeassembly.
Reviewed changes
Copilot reviewed 8 out of 9 changed files in this pull request and generated 3 comments.
Show a summary per file
| File | Description |
|---|---|
| src/HotChocolate/Core/test/Types.NodaTime.Tests/OffsetDateTimeTypeTests.cs | Removes tests for the old OffsetDateTimeType. |
| src/HotChocolate/Core/test/Types.NodaTime.Tests/NodaTimeRequestExecutorBuilderExtensions.cs | Updates the default test registration list to use DateTimeType instead of OffsetDateTimeType. |
| src/HotChocolate/Core/test/Types.NodaTime.Tests/DateTimeTypeTests.cs | Adds test coverage for the new DateTimeType scalar behavior and precision handling. |
| src/HotChocolate/Core/src/Types/HotChocolate.Types.csproj | Grants InternalsVisibleTo to HotChocolate.Types.NodaTime. |
| src/HotChocolate/Core/src/Types.NodaTime/Properties/NodaTimeResources.resx | Adds resource strings for DateTimeOptions validation and DateTimeType description. |
| src/HotChocolate/Core/src/Types.NodaTime/Properties/NodaTimeResources.Designer.cs | Regenerates strongly-typed resources to include the new strings. |
| src/HotChocolate/Core/src/Types.NodaTime/OffsetDateTimeType.cs | Removes the old OffsetDateTimeType scalar implementation. |
| src/HotChocolate/Core/src/Types.NodaTime/DateTimeType.cs | Introduces the new DateTimeType scalar mapping to NodaTime OffsetDateTime. |
| src/HotChocolate/Core/src/Types.NodaTime/DateTimeOptions.cs | Introduces precision configuration for parsing/serializing the new scalar. |
Files not reviewed (1)
- src/HotChocolate/Core/src/Types.NodaTime/Properties/NodaTimeResources.Designer.cs: Language not supported
💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.
src/HotChocolate/Core/test/Types.NodaTime.Tests/NodaTimeRequestExecutorBuilderExtensions.cs
Outdated
Show resolved
Hide resolved
There was a problem hiding this comment.
Pull request overview
Copilot reviewed 61 out of 66 changed files in this pull request and generated 4 comments.
Files not reviewed (1)
- src/HotChocolate/Core/src/Types.NodaTime/Properties/NodaTimeResources.Designer.cs: Language not supported
💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.
src/HotChocolate/Core/src/Types.NodaTime/Iso8601DurationParser.cs
Outdated
Show resolved
Hide resolved
src/HotChocolate/Core/src/Types.NodaTime/Iso8601DurationParser.cs
Outdated
Show resolved
Hide resolved
There was a problem hiding this comment.
Pull request overview
Copilot reviewed 61 out of 66 changed files in this pull request and generated 2 comments.
Files not reviewed (1)
- src/HotChocolate/Core/src/Types.NodaTime/Properties/NodaTimeResources.Designer.cs: Language not supported
💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.
Summary of the changes (Less than 80 chars)