Skip to content

Commit da5e16e

Browse files
committed
Simplify test for Task nullable custom type schema
Removed conditional InlineData and hardcoded shouldBeRequired to false in GetReturnSchema_TaskNullableCustomType_UnwrapsToCustomTypeSchemaWithoutRequired test for consistency across frameworks.
1 parent 94ad953 commit da5e16e

1 file changed

Lines changed: 2 additions & 7 deletions

File tree

ReflectorNet.Tests/SchemaTests/ReturnSchemaTests.cs

Lines changed: 2 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -255,15 +255,10 @@ public void GetReturnSchema_TaskNullablePrimitive_UnwrapsWithoutRequired(string
255255
}
256256

257257
[Theory]
258-
#if NET5_0_OR_GREATER
259-
[InlineData(false)]
260-
#else
261-
[InlineData(true)]
262-
#endif
263-
public void GetReturnSchema_TaskNullableCustomType_UnwrapsToCustomTypeSchemaWithoutRequired(bool shouldBeRequired)
258+
public void GetReturnSchema_TaskNullableCustomType_UnwrapsToCustomTypeSchemaWithoutRequired()
264259
{
265260
var schema = GetReturnSchemaForMethod(nameof(TaskNullableCustomTypeMethod));
266-
AssertCustomTypeReturnSchema(schema!, new[] { "Name", "Value" }, shouldBeRequired: shouldBeRequired);
261+
AssertCustomTypeReturnSchema(schema!, new[] { "Name", "Value" }, shouldBeRequired: false);
267262
AssertAllRefsDefined(schema!);
268263
}
269264

0 commit comments

Comments
 (0)