Skip to content

Commit

Permalink
Fix tests for net48, net6.0, net 7.0
Browse files Browse the repository at this point in the history
  • Loading branch information
TonEnfer committed Dec 8, 2024
1 parent c9c8845 commit fdcd206
Show file tree
Hide file tree
Showing 3 changed files with 17 additions and 0 deletions.
2 changes: 2 additions & 0 deletions test/Riok.Mapperly.IntegrationTests/Mapper/TestMapper.cs
Original file line number Diff line number Diff line change
Expand Up @@ -51,7 +51,9 @@ public TestMapper()

public partial DateTime DirectDateTime(DateTime dateTime);

#if NET5_0_OR_GREATER
public partial byte[] ConvertWithInstanceMethod(Guid id);
#endif

public partial IEnumerable<TestObjectDto> MapAllDtos(IEnumerable<TestObject> objects);

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -50,6 +50,7 @@
EnumName: Value30,
EnumStringValue: 0,
EnumReverseStringValue: DtoValue3,
ToByteArrayWithInstanceMethod: AAAAAAAAAAAAAAAAAAAAAA==,
FormattedIntValue: CHF 0.00,
FormattedDateValue: Monday, January 1, 0001,
ExposePrivateValue: 26
Expand Down Expand Up @@ -194,6 +195,14 @@
},
DateTimeValueTargetDateOnly: 2020-01-03,
DateTimeValueTargetTimeOnly: 3:10 PM,
ToByteArrayWithInstanceMethod: AQAAAAIAAwAEBQYHCAkKCw==,
WithCreateMethod: 10,
WithCreateFromMethod: 20,
WithFromSingleMethod: 30.0,
WithCreateParamsMethod: 40.0,
WithCreateFromParamsMethod: 50,
WithFromShortParamsMethod: 60,
WithToDecimalMethod: 70.0,
FormattedIntValue: CHF 10.00,
FormattedDateValue: Friday, January 3, 2020,
ExposePrivateValue: 28,
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -46,6 +46,12 @@ public partial int ParseableInt(string value)
return dateTime;
}

[global::System.CodeDom.Compiler.GeneratedCode("Riok.Mapperly", "0.0.1.0")]
public partial byte[] ConvertWithInstanceMethod(global::System.Guid id)
{
return id.ToByteArray();
}

[global::System.CodeDom.Compiler.GeneratedCode("Riok.Mapperly", "0.0.1.0")]
public partial global::System.Collections.Generic.IEnumerable<global::Riok.Mapperly.IntegrationTests.Dto.TestObjectDto> MapAllDtos(global::System.Collections.Generic.IEnumerable<global::Riok.Mapperly.IntegrationTests.Models.TestObject> objects)
{
Expand Down

0 comments on commit fdcd206

Please sign in to comment.