Skip to content

Commit 09d917e

Browse files
committed
Cleanup new test case
1 parent 40e24a5 commit 09d917e

File tree

1 file changed

+11
-16
lines changed

1 file changed

+11
-16
lines changed

components/MarkdownTextBlock/tests/ExampleMarkdownTextBlockTestClass.cs

Lines changed: 11 additions & 16 deletions
Original file line numberDiff line numberDiff line change
@@ -132,26 +132,21 @@ public async Task ComplexAsyncLoadUIExampleWithoutDispatcherTest()
132132
Assert.IsFalse(component.IsLoaded);
133133
}
134134

135-
// You can still use the UIThreadTestMethod to remove the extra layer for the dispatcher as well:
136-
[TestMethod]
137-
public async Task ComplexAsyncLoadUIExampleWithCustomConfigTest()
135+
[UIThreadTestMethod]
136+
public async Task MarkdownTextBlockEmptyTextValueTest()
138137
{
139-
await EnqueueAsync(async () =>
138+
var component = new MarkdownTextBlock
140139
{
141-
var component = new MarkdownTextBlock
142-
{
143-
Config = new MarkdownConfig()
144-
};
145-
Assert.IsNotNull(component);
146-
Assert.IsFalse(component.IsLoaded);
147-
148-
await LoadTestContentAsync(component);
140+
Config = new()
141+
};
149142

150-
Assert.IsTrue(component.IsLoaded);
143+
Assert.IsNotNull(component);
144+
Assert.IsFalse(component.IsLoaded);
151145

152-
await UnloadTestContentAsync(component);
146+
await LoadTestContentAsync(component);
147+
Assert.IsTrue(component.IsLoaded);
153148

154-
Assert.IsFalse(component.IsLoaded);
155-
});
149+
await UnloadTestContentAsync(component);
150+
Assert.IsFalse(component.IsLoaded);
156151
}
157152
}

0 commit comments

Comments
 (0)