Skip to content

Commit 24c026a

Browse files
committed
test: 更新单元测试
1 parent e52c8e2 commit 24c026a

File tree

1 file changed

+1
-2
lines changed

1 file changed

+1
-2
lines changed

test/UnitTest/Extensions/JSModuleExtensionsTest.cs

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -19,8 +19,7 @@ public async Task LoadModule_Ok()
1919
public async Task LoadModule_Exception()
2020
{
2121
var jsRuntime = new MockJSRuntime();
22-
var module = await jsRuntime.LoadModule("./mock.js", "test");
23-
Assert.NotNull(module);
22+
await Assert.ThrowsAsync<TaskCanceledException>(() => jsRuntime.LoadModule("./mock.js", "test"));
2423
}
2524

2625
[Fact]

0 commit comments

Comments
 (0)