mirror of
https://github.com/ppy/osu.git
synced 2024-12-14 18:42:56 +08:00
Simplify fetching of DrawableChannel
This commit is contained in:
parent
642e006267
commit
5f3bea846b
@ -365,7 +365,7 @@ namespace osu.Game.Tests.Visual.Online
|
||||
AddAssert("TextBox is focused", () => InputManager.FocusedDrawable == chatOverlayTextBox);
|
||||
AddStep("Click listing", () => clickDrawable(chatOverlay.ChildrenOfType<ChannelListing>().Single()));
|
||||
AddAssert("TextBox is focused", () => InputManager.FocusedDrawable == chatOverlayTextBox);
|
||||
AddStep("Click drawable channel", () => clickDrawable(chatOverlay.ChildrenOfType<DrawableChannel>().Single()));
|
||||
AddStep("Click drawable channel", () => clickDrawable(currentDrawableChannel));
|
||||
AddAssert("TextBox is focused", () => InputManager.FocusedDrawable == chatOverlayTextBox);
|
||||
AddStep("Click channel list", () => clickDrawable(chatOverlay.ChildrenOfType<ChannelList>().Single()));
|
||||
AddAssert("TextBox is focused", () => InputManager.FocusedDrawable == chatOverlayTextBox);
|
||||
@ -382,7 +382,7 @@ namespace osu.Game.Tests.Visual.Online
|
||||
chatOverlay.ChildrenOfType<LoadingLayer>().Single().State.Value;
|
||||
|
||||
private DrawableChannel currentDrawableChannel =>
|
||||
chatOverlay.ChildrenOfType<Container<DrawableChannel>>().Single().Child;
|
||||
chatOverlay.ChildrenOfType<DrawableChannel>().Single();
|
||||
|
||||
private ChannelListItem getChannelListItem(Channel channel) =>
|
||||
chatOverlay.ChildrenOfType<ChannelListItem>().Single(item => item.Channel == channel);
|
||||
|
Loading…
Reference in New Issue
Block a user