Skip to content

Commit

Permalink
Fix unconditional success in CLR tests (#100905)
Browse files Browse the repository at this point in the history
Test introduced in #100289 failed the build of CLR tests for e.g. RISC-V:
```
/runtime/src/tests/Loader/classloader/explicitlayout/Regressions/100220/Runtime_100220.cs(15,23): error XUW1002: Tests should not unconditionally return 100. Convert to a void return.
```
  • Loading branch information
tomeksowi authored Apr 11, 2024
1 parent f099172 commit a8158c1
Showing 1 changed file with 1 addition and 2 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,7 @@ public static class Runtime_100220
[Fact]
[ActiveIssue("https://github.com/dotnet/runtime/issues/100220", TestRuntimes.Mono)]
// Also, Mono needs RuntimeHelpers.GetRawObjectDataSize or equivalent to get an object size
public static int TestEntryPoint()
public static void TestEntryPoint()
{
if (IntPtr.Size == 8)
{
Expand Down Expand Up @@ -59,7 +59,6 @@ public static int TestEntryPoint()

// Field offsets:
Assert.Equal("(5, 3, 4, 1, 2, 6)", FieldOffsets(new SubclassSubclassSeq { A = 1, B = 2, C = 3, D = 4, E = 5, F = 6 }).ToString());
return 100;
}

[MethodImpl(MethodImplOptions.NoInlining)]
Expand Down

0 comments on commit a8158c1

Please sign in to comment.