1
0
mirror of https://github.com/ppy/osu.git synced 2025-02-13 15:03:13 +08:00

Fix unsafe config fetching

This commit is contained in:
Dean Herbert 2022-05-29 22:55:53 +09:00
parent 186999c4eb
commit c078c06902

View File

@ -150,10 +150,14 @@ namespace osu.Game.Tests.Visual.Online
public void TestChatHeight()
{
BindableFloat configChatHeight = new BindableFloat();
config.BindWith(OsuSetting.ChatDisplayHeight, configChatHeight);
float newHeight = 0;
AddStep("Reset config chat height", () => configChatHeight.SetDefault());
AddStep("Reset config chat height", () =>
{
config.BindWith(OsuSetting.ChatDisplayHeight, configChatHeight);
configChatHeight.SetDefault();
});
AddStep("Show overlay", () => chatOverlay.Show());
AddAssert("Overlay uses config height", () => chatOverlay.Height == configChatHeight.Default);
AddStep("Click top bar", () =>