mirror of
https://github.com/osukey/osukey.git
synced 2025-08-07 16:43:52 +09:00
Take IWorkingBeatmap
instead of WorkingBeatmap
This makes testing much easier, and allows for checking of any class deriving from that interface, including `WorkingBeatmap`.
This commit is contained in:
@ -31,7 +31,7 @@ namespace osu.Game.Rulesets.Osu.Edit.Checks
|
|||||||
new IssueTemplateOffscreenSlider(this)
|
new IssueTemplateOffscreenSlider(this)
|
||||||
};
|
};
|
||||||
|
|
||||||
public IEnumerable<Issue> Run(WorkingBeatmap workingBeatmap)
|
public IEnumerable<Issue> Run(IWorkingBeatmap workingBeatmap)
|
||||||
{
|
{
|
||||||
foreach (var hitobject in workingBeatmap.Beatmap.HitObjects)
|
foreach (var hitobject in workingBeatmap.Beatmap.HitObjects)
|
||||||
{
|
{
|
||||||
|
@ -17,7 +17,7 @@ namespace osu.Game.Rulesets.Edit.Checks
|
|||||||
new IssueTemplateDoesNotExist(this)
|
new IssueTemplateDoesNotExist(this)
|
||||||
};
|
};
|
||||||
|
|
||||||
public IEnumerable<Issue> Run(WorkingBeatmap workingBeatmap)
|
public IEnumerable<Issue> Run(IWorkingBeatmap workingBeatmap)
|
||||||
{
|
{
|
||||||
string backgroundFile = workingBeatmap.Beatmap.Metadata?.BackgroundFile;
|
string backgroundFile = workingBeatmap.Beatmap.Metadata?.BackgroundFile;
|
||||||
|
|
||||||
|
@ -30,7 +30,7 @@ namespace osu.Game.Rulesets.Edit.Checks
|
|||||||
new IssueTemplateTooUncompressed(this)
|
new IssueTemplateTooUncompressed(this)
|
||||||
};
|
};
|
||||||
|
|
||||||
public IEnumerable<Issue> Run(WorkingBeatmap workingBeatmap)
|
public IEnumerable<Issue> Run(IWorkingBeatmap workingBeatmap)
|
||||||
{
|
{
|
||||||
var backgroundFile = workingBeatmap.Beatmap.Metadata?.BackgroundFile;
|
var backgroundFile = workingBeatmap.Beatmap.Metadata?.BackgroundFile;
|
||||||
if (backgroundFile == null)
|
if (backgroundFile == null)
|
||||||
|
@ -25,6 +25,6 @@ namespace osu.Game.Rulesets.Edit.Checks.Components
|
|||||||
/// Runs this check and returns any issues detected for the provided beatmap.
|
/// Runs this check and returns any issues detected for the provided beatmap.
|
||||||
/// </summary>
|
/// </summary>
|
||||||
/// <param name="workingBeatmap">The beatmap to run the check on.</param>
|
/// <param name="workingBeatmap">The beatmap to run the check on.</param>
|
||||||
public IEnumerable<Issue> Run(WorkingBeatmap workingBeatmap);
|
public IEnumerable<Issue> Run(IWorkingBeatmap workingBeatmap);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
Reference in New Issue
Block a user