Move out test ongoing operation tracker to higher level

This commit is contained in:
Bartłomiej Dach 2021-01-08 22:28:21 +01:00
parent c2eeb822b8
commit ff60d652ed
2 changed files with 4 additions and 5 deletions

View File

@ -15,7 +15,6 @@ using osu.Game.Graphics.UserInterface;
using osu.Game.Online.Multiplayer;
using osu.Game.Online.Rooms;
using osu.Game.Rulesets;
using osu.Game.Screens.OnlinePlay;
using osu.Game.Screens.OnlinePlay.Multiplayer.Match;
using osu.Game.Tests.Resources;
using osu.Game.Users;
@ -31,9 +30,6 @@ namespace osu.Game.Tests.Visual.Multiplayer
private BeatmapManager beatmaps;
private RulesetStore rulesets;
[Cached]
private OngoingOperationTracker ongoingOperationTracker = new OngoingOperationTracker();
private IDisposable readyClickOperation;
[BackgroundDependencyLoader]
@ -66,7 +62,7 @@ namespace osu.Game.Tests.Visual.Multiplayer
},
OnReadyClick = async () =>
{
readyClickOperation = ongoingOperationTracker.BeginOperation();
readyClickOperation = OngoingOperationTracker.BeginOperation();
if (Client.IsHost && Client.LocalUser?.State == MultiplayerUserState.Ready)
{

View File

@ -23,6 +23,9 @@ namespace osu.Game.Tests.Visual.Multiplayer
[Cached]
public Bindable<FilterCriteria> Filter { get; }
[Cached]
public OngoingOperationTracker OngoingOperationTracker { get; } = new OngoingOperationTracker();
protected override Container<Drawable> Content => content;
private readonly TestMultiplayerRoomContainer content;