Skip to content

Commit

Permalink
Cleanup new test case
Browse files Browse the repository at this point in the history
  • Loading branch information
Arlodotexe committed Nov 13, 2024
1 parent 40e24a5 commit 09d917e
Showing 1 changed file with 11 additions and 16 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -132,26 +132,21 @@ public async Task ComplexAsyncLoadUIExampleWithoutDispatcherTest()
Assert.IsFalse(component.IsLoaded);
}

// You can still use the UIThreadTestMethod to remove the extra layer for the dispatcher as well:
[TestMethod]
public async Task ComplexAsyncLoadUIExampleWithCustomConfigTest()
[UIThreadTestMethod]
public async Task MarkdownTextBlockEmptyTextValueTest()
{
await EnqueueAsync(async () =>
var component = new MarkdownTextBlock
{
var component = new MarkdownTextBlock
{
Config = new MarkdownConfig()
};
Assert.IsNotNull(component);
Assert.IsFalse(component.IsLoaded);
await LoadTestContentAsync(component);
Config = new()
};

Assert.IsTrue(component.IsLoaded);
Assert.IsNotNull(component);
Assert.IsFalse(component.IsLoaded);

await UnloadTestContentAsync(component);
await LoadTestContentAsync(component);
Assert.IsTrue(component.IsLoaded);

Assert.IsFalse(component.IsLoaded);
});
await UnloadTestContentAsync(component);
Assert.IsFalse(component.IsLoaded);
}
}

0 comments on commit 09d917e

Please sign in to comment.