Skip to content

Commit

Permalink
[browser] Remove ValueTask interop test placeholders (#94560)
Browse files Browse the repository at this point in the history
  • Loading branch information
maraf authored Nov 10, 2023
1 parent 9137cb4 commit c07cb44
Show file tree
Hide file tree
Showing 2 changed files with 0 additions and 78 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -452,38 +452,6 @@ public static async Task FailedAsynchronousTask()
await Task.Yield();
throw new Exception();
}

public static async ValueTask AsynchronousValueTask()
{
await Task.Yield();
}

public static ValueTask SynchronousValueTask()
{
return ValueTask.CompletedTask;
}

public static ValueTask<int> SynchronousValueTaskInt(int i)
{
return ValueTask.FromResult(i);
}

public static async ValueTask<int> AsynchronousValueTaskInt(int i)
{
await Task.Yield();
return i;
}

public static ValueTask FailedSynchronousValueTask()
{
return ValueTask.FromException(new Exception());
}

public static async ValueTask FailedAsynchronousValueTask()
{
await Task.Yield();
throw new Exception();
}
}

public enum TestEnum : uint {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -787,51 +787,5 @@ public static async Task MarshalFailedAsynchronousTask()
bool success = await MarshalTask("FailedAsynchronousTask");
Assert.False(success, "FailedAsynchronousTask didn't failed.");
}

[Fact]
[ActiveIssue("https://github.com/dotnet/runtime/issues/61368")]
public static async Task MarshalSynchronousValueTaskDoesNotWorkYet()
{
bool success = await MarshalTask("SynchronousValueTask");
Assert.True(success, "SynchronousValueTask didn't succeeded.");
}

[Fact]
[ActiveIssue("https://github.com/dotnet/runtime/issues/61368")]
public static async Task MarshalAsynchronousValueTaskDoesNotWorkYet()
{
bool success = await MarshalTask("AsynchronousValueTask");
Assert.True(success, "AsynchronousValueTask didn't succeeded.");
}

[Fact]
[ActiveIssue("https://github.com/dotnet/runtime/issues/61368")]
public static Task MarshalSynchronousValueTaskIntDoesNotWorkYet()
{
return MarshalTaskReturningInt("SynchronousValueTaskInt");
}

[Fact]
[ActiveIssue("https://github.com/dotnet/runtime/issues/61368")]
public static Task MarshalAsynchronousValueTaskIntDoesNotWorkYet()
{
return MarshalTaskReturningInt("AsynchronousValueTaskInt");
}

[Fact]
[ActiveIssue("https://github.com/dotnet/runtime/issues/61368")]
public static async Task MarshalFailedSynchronousValueTaskDoesNotWorkYet()
{
bool success = await MarshalTask("FailedSynchronousValueTask");
Assert.False(success, "FailedSynchronousValueTask didn't failed.");
}

[Fact]
[ActiveIssue("https://github.com/dotnet/runtime/issues/61368")]
public static async Task MarshalFailedAsynchronousValueTaskDoesNotWorkYet()
{
bool success = await MarshalTask("FailedAsynchronousValueTask");
Assert.False(success, "FailedAsynchronousValueTask didn't failed.");
}
}
}

0 comments on commit c07cb44

Please sign in to comment.