mirror of
https://github.com/ppy/osu.git
synced 2025-01-15 09:22:54 +08:00
Move all TestCases to Testing project
This allows tests to successfully retrieve rulesets, as they are referenced.
This commit is contained in:
parent
59d908861e
commit
dc9c474033
@ -233,6 +233,10 @@
|
|||||||
<Project>{f167e17a-7de6-4af5-b920-a5112296c695}</Project>
|
<Project>{f167e17a-7de6-4af5-b920-a5112296c695}</Project>
|
||||||
<Name>osu.Game.Rulesets.Taiko</Name>
|
<Name>osu.Game.Rulesets.Taiko</Name>
|
||||||
</ProjectReference>
|
</ProjectReference>
|
||||||
|
<ProjectReference Include="..\osu.Game.Tests\osu.Game.Tests.csproj">
|
||||||
|
<Project>{54377672-20b1-40af-8087-5cf73bf3953a}</Project>
|
||||||
|
<Name>osu.Game.Tests</Name>
|
||||||
|
</ProjectReference>
|
||||||
<ProjectReference Include="..\osu.Game\osu.Game.csproj">
|
<ProjectReference Include="..\osu.Game\osu.Game.csproj">
|
||||||
<Project>{2a66dd92-adb1-4994-89e2-c94e04acda0d}</Project>
|
<Project>{2a66dd92-adb1-4994-89e2-c94e04acda0d}</Project>
|
||||||
<Name>osu.Game</Name>
|
<Name>osu.Game</Name>
|
||||||
|
10
osu.Game.Tests/Visual/TestCaseAllPlayers.cs
Normal file
10
osu.Game.Tests/Visual/TestCaseAllPlayers.cs
Normal file
@ -0,0 +1,10 @@
|
|||||||
|
// Copyright (c) 2007-2017 ppy Pty Ltd <contact@ppy.sh>.
|
||||||
|
// Licensed under the MIT Licence - https://raw.githubusercontent.com/ppy/osu/master/LICENCE
|
||||||
|
|
||||||
|
namespace osu.Game.Tests.Visual
|
||||||
|
{
|
||||||
|
public class TestCaseAllPlayers : TestCasePlayer
|
||||||
|
{
|
||||||
|
public override string Description => @"Showing everything to play the game.";
|
||||||
|
}
|
||||||
|
}
|
@ -4,7 +4,6 @@
|
|||||||
using System;
|
using System;
|
||||||
using System.Collections.Generic;
|
using System.Collections.Generic;
|
||||||
using System.Linq;
|
using System.Linq;
|
||||||
using Microsoft.EntityFrameworkCore;
|
|
||||||
using osu.Framework.Allocation;
|
using osu.Framework.Allocation;
|
||||||
using osu.Framework.MathUtils;
|
using osu.Framework.MathUtils;
|
||||||
using osu.Game.Beatmaps;
|
using osu.Game.Beatmaps;
|
||||||
@ -38,8 +37,7 @@ namespace osu.Game.Tests.Visual
|
|||||||
var storage = new TestStorage(@"TestCasePlaySongSelect");
|
var storage = new TestStorage(@"TestCasePlaySongSelect");
|
||||||
|
|
||||||
// this is by no means clean. should be replacing inside of OsuGameBase somehow.
|
// this is by no means clean. should be replacing inside of OsuGameBase somehow.
|
||||||
var context = new OsuDbContext(storage.GetDatabaseConnectionString(@"client"));
|
var context = new OsuDbContext();
|
||||||
context.Database.Migrate();
|
|
||||||
|
|
||||||
Func<OsuDbContext> contextFactory = () => context;
|
Func<OsuDbContext> contextFactory = () => context;
|
||||||
|
|
@ -90,6 +90,56 @@
|
|||||||
<Compile Include="Beatmaps\IO\ImportBeatmapTest.cs" />
|
<Compile Include="Beatmaps\IO\ImportBeatmapTest.cs" />
|
||||||
<Compile Include="Resources\Resource.cs" />
|
<Compile Include="Resources\Resource.cs" />
|
||||||
<Compile Include="Beatmaps\Formats\OsuLegacyDecoderTest.cs" />
|
<Compile Include="Beatmaps\Formats\OsuLegacyDecoderTest.cs" />
|
||||||
|
<Compile Include="Visual\TestCaseBeatmapDetailArea.cs" />
|
||||||
|
<Compile Include="Visual\TestCaseBeatmapDetails.cs" />
|
||||||
|
<Compile Include="Visual\TestCaseBeatmapOptionsOverlay.cs" />
|
||||||
|
<Compile Include="Visual\TestCaseBeatmapSetOverlay.cs" />
|
||||||
|
<Compile Include="Visual\TestCaseBeatSyncedContainer.cs" />
|
||||||
|
<Compile Include="Visual\TestCaseBreadcrumbs.cs" />
|
||||||
|
<Compile Include="Visual\TestCaseBreakOverlay.cs" />
|
||||||
|
<Compile Include="Visual\TestCaseChatDisplay.cs" />
|
||||||
|
<Compile Include="Visual\TestCaseContextMenu.cs" />
|
||||||
|
<Compile Include="Visual\TestCaseDialogOverlay.cs" />
|
||||||
|
<Compile Include="Visual\TestCaseDirect.cs" />
|
||||||
|
<Compile Include="Visual\TestCaseDrawableRoom.cs" />
|
||||||
|
<Compile Include="Visual\TestCaseDrawings.cs" />
|
||||||
|
<Compile Include="Visual\TestCaseEditor.cs" />
|
||||||
|
<Compile Include="Visual\TestCaseEditorComposeTimeline.cs" />
|
||||||
|
<Compile Include="Visual\TestCaseEditorMenuBar.cs" />
|
||||||
|
<Compile Include="Visual\TestCaseEditorSummaryTimeline.cs" />
|
||||||
|
<Compile Include="Visual\TestCaseGamefield.cs" />
|
||||||
|
<Compile Include="Visual\TestCaseGraph.cs" />
|
||||||
|
<Compile Include="Visual\TestCaseIconButton.cs" />
|
||||||
|
<Compile Include="Visual\TestCaseKeyConfiguration.cs" />
|
||||||
|
<Compile Include="Visual\TestCaseKeyCounter.cs" />
|
||||||
|
<Compile Include="Visual\TestCaseLeaderboard.cs" />
|
||||||
|
<Compile Include="Visual\TestCaseMedalOverlay.cs" />
|
||||||
|
<Compile Include="Visual\TestCaseMenuButtonSystem.cs" />
|
||||||
|
<Compile Include="Visual\TestCaseMenuOverlays.cs" />
|
||||||
|
<Compile Include="Visual\TestCaseMods.cs" />
|
||||||
|
<Compile Include="Visual\TestCaseMusicController.cs" />
|
||||||
|
<Compile Include="Visual\TestCaseNotificationOverlay.cs" />
|
||||||
|
<Compile Include="Visual\TestCaseOnScreenDisplay.cs" />
|
||||||
|
<Compile Include="Visual\TestCaseAllPlayers.cs" />
|
||||||
|
<Compile Include="Visual\TestCasePlaySongSelect.cs" />
|
||||||
|
<Compile Include="Visual\TestCaseReplay.cs" />
|
||||||
|
<Compile Include="Visual\TestCaseReplaySettingsOverlay.cs" />
|
||||||
|
<Compile Include="Visual\TestCaseResults.cs" />
|
||||||
|
<Compile Include="Visual\TestCaseRoomInspector.cs" />
|
||||||
|
<Compile Include="Visual\TestCaseScoreCounter.cs" />
|
||||||
|
<Compile Include="Visual\TestCaseScrollingPlayfield.cs" />
|
||||||
|
<Compile Include="Visual\TestCaseSettings.cs" />
|
||||||
|
<Compile Include="Visual\TestCaseSkipButton.cs" />
|
||||||
|
<Compile Include="Visual\TestCaseSocial.cs" />
|
||||||
|
<Compile Include="Visual\TestCaseSongProgress.cs" />
|
||||||
|
<Compile Include="Visual\TestCaseStoryboard.cs" />
|
||||||
|
<Compile Include="Visual\TestCaseTabControl.cs" />
|
||||||
|
<Compile Include="Visual\TestCaseTextAwesome.cs" />
|
||||||
|
<Compile Include="Visual\TestCaseTwoLayerButton.cs" />
|
||||||
|
<Compile Include="Visual\TestCaseUserPanel.cs" />
|
||||||
|
<Compile Include="Visual\TestCaseUserProfile.cs" />
|
||||||
|
<Compile Include="Visual\TestCaseUserRanks.cs" />
|
||||||
|
<Compile Include="Visual\TestCaseWaveform.cs" />
|
||||||
</ItemGroup>
|
</ItemGroup>
|
||||||
<ItemGroup>
|
<ItemGroup>
|
||||||
<EmbeddedResource Include="Resources\Soleily - Renatus %28Gamu%29 [Insane].osu" />
|
<EmbeddedResource Include="Resources\Soleily - Renatus %28Gamu%29 [Insane].osu" />
|
||||||
|
@ -40,6 +40,8 @@ namespace osu.Game.Database
|
|||||||
: this("DataSource=:memory:")
|
: this("DataSource=:memory:")
|
||||||
{
|
{
|
||||||
// required for tooling (see https://wildermuth.com/2017/07/06/Program-cs-in-ASP-NET-Core-2-0).
|
// required for tooling (see https://wildermuth.com/2017/07/06/Program-cs-in-ASP-NET-Core-2-0).
|
||||||
|
|
||||||
|
Migrate();
|
||||||
}
|
}
|
||||||
|
|
||||||
/// <summary>
|
/// <summary>
|
||||||
|
@ -20,7 +20,7 @@ using osu.Game.Screens.Edit.Screens.Design;
|
|||||||
|
|
||||||
namespace osu.Game.Screens.Edit
|
namespace osu.Game.Screens.Edit
|
||||||
{
|
{
|
||||||
internal class Editor : OsuScreen
|
public class Editor : OsuScreen
|
||||||
{
|
{
|
||||||
protected override BackgroundScreen CreateBackground() => new BackgroundScreenCustom(@"Backgrounds/bg4");
|
protected override BackgroundScreen CreateBackground() => new BackgroundScreenCustom(@"Backgrounds/bg4");
|
||||||
|
|
||||||
|
@ -12,7 +12,7 @@ using osu.Game.Graphics;
|
|||||||
|
|
||||||
namespace osu.Game.Screens.Edit.Screens.Compose.Timeline
|
namespace osu.Game.Screens.Edit.Screens.Compose.Timeline
|
||||||
{
|
{
|
||||||
internal class ScrollingTimelineContainer : ScrollContainer
|
public class ScrollingTimelineContainer : ScrollContainer
|
||||||
{
|
{
|
||||||
public readonly Bindable<bool> HitObjectsVisible = new Bindable<bool>();
|
public readonly Bindable<bool> HitObjectsVisible = new Bindable<bool>();
|
||||||
public readonly Bindable<bool> HitSoundsVisible = new Bindable<bool>();
|
public readonly Bindable<bool> HitSoundsVisible = new Bindable<bool>();
|
||||||
|
@ -17,7 +17,7 @@ using OpenTK.Graphics;
|
|||||||
|
|
||||||
namespace osu.Game.Tests.Visual
|
namespace osu.Game.Tests.Visual
|
||||||
{
|
{
|
||||||
public class TestCasePlayer : OsuTestCase
|
public abstract class TestCasePlayer : OsuTestCase
|
||||||
{
|
{
|
||||||
private readonly Type ruleset;
|
private readonly Type ruleset;
|
||||||
|
|
||||||
@ -34,7 +34,7 @@ namespace osu.Game.Tests.Visual
|
|||||||
this.ruleset = ruleset;
|
this.ruleset = ruleset;
|
||||||
}
|
}
|
||||||
|
|
||||||
public TestCasePlayer()
|
protected TestCasePlayer()
|
||||||
{
|
{
|
||||||
|
|
||||||
}
|
}
|
||||||
|
@ -768,55 +768,7 @@
|
|||||||
<Compile Include="Tests\Beatmaps\TestWorkingBeatmap.cs" />
|
<Compile Include="Tests\Beatmaps\TestWorkingBeatmap.cs" />
|
||||||
<Compile Include="Tests\Platform\TestStorage.cs" />
|
<Compile Include="Tests\Platform\TestStorage.cs" />
|
||||||
<Compile Include="Tests\Visual\OsuTestCase.cs" />
|
<Compile Include="Tests\Visual\OsuTestCase.cs" />
|
||||||
<Compile Include="Tests\Visual\TestCaseBeatmapDetailArea.cs" />
|
|
||||||
<Compile Include="Tests\Visual\TestCaseBeatmapDetails.cs" />
|
|
||||||
<Compile Include="Tests\Visual\TestCaseBeatmapOptionsOverlay.cs" />
|
|
||||||
<Compile Include="Tests\Visual\TestCaseBeatSyncedContainer.cs" />
|
|
||||||
<Compile Include="Tests\Visual\TestCaseBreadcrumbs.cs" />
|
|
||||||
<Compile Include="Tests\Visual\TestCaseBreakOverlay.cs" />
|
|
||||||
<Compile Include="Tests\Visual\TestCaseChatDisplay.cs" />
|
|
||||||
<Compile Include="Tests\Visual\TestCaseContextMenu.cs" />
|
|
||||||
<Compile Include="Tests\Visual\TestCaseDialogOverlay.cs" />
|
|
||||||
<Compile Include="Tests\Visual\TestCaseDirect.cs" />
|
|
||||||
<Compile Include="Tests\Visual\TestCaseDrawableRoom.cs" />
|
|
||||||
<Compile Include="Tests\Visual\TestCaseDrawings.cs" />
|
|
||||||
<Compile Include="Tests\Visual\TestCaseEditor.cs" />
|
|
||||||
<Compile Include="Tests\Visual\TestCaseEditorComposeTimeline.cs" />
|
|
||||||
<Compile Include="Tests\Visual\TestCaseEditorMenuBar.cs" />
|
|
||||||
<Compile Include="Tests\Visual\TestCaseEditorSummaryTimeline.cs" />
|
|
||||||
<Compile Include="Tests\Visual\TestCaseGamefield.cs" />
|
|
||||||
<Compile Include="Tests\Visual\TestCaseGraph.cs" />
|
|
||||||
<Compile Include="Tests\Visual\TestCaseIconButton.cs" />
|
|
||||||
<Compile Include="Tests\Visual\TestCaseKeyConfiguration.cs" />
|
|
||||||
<Compile Include="Tests\Visual\TestCaseKeyCounter.cs" />
|
|
||||||
<Compile Include="Tests\Visual\TestCaseLeaderboard.cs" />
|
|
||||||
<Compile Include="Tests\Visual\TestCaseMedalOverlay.cs" />
|
|
||||||
<Compile Include="Tests\Visual\TestCaseMenuButtonSystem.cs" />
|
|
||||||
<Compile Include="Tests\Visual\TestCaseMenuOverlays.cs" />
|
|
||||||
<Compile Include="Tests\Visual\TestCaseMods.cs" />
|
|
||||||
<Compile Include="Tests\Visual\TestCaseMusicController.cs" />
|
|
||||||
<Compile Include="Tests\Visual\TestCaseNotificationOverlay.cs" />
|
|
||||||
<Compile Include="Tests\Visual\TestCaseOnScreenDisplay.cs" />
|
|
||||||
<Compile Include="Tests\Visual\TestCasePlayer.cs" />
|
<Compile Include="Tests\Visual\TestCasePlayer.cs" />
|
||||||
<Compile Include="Tests\Visual\TestCasePlaySongSelect.cs" />
|
|
||||||
<Compile Include="Tests\Visual\TestCaseReplay.cs" />
|
|
||||||
<Compile Include="Tests\Visual\TestCaseReplaySettingsOverlay.cs" />
|
|
||||||
<Compile Include="Tests\Visual\TestCaseResults.cs" />
|
|
||||||
<Compile Include="Tests\Visual\TestCaseRoomInspector.cs" />
|
|
||||||
<Compile Include="Tests\Visual\TestCaseScoreCounter.cs" />
|
|
||||||
<Compile Include="Tests\Visual\TestCaseScrollingPlayfield.cs" />
|
|
||||||
<Compile Include="Tests\Visual\TestCaseSettings.cs" />
|
|
||||||
<Compile Include="Tests\Visual\TestCaseSkipButton.cs" />
|
|
||||||
<Compile Include="Tests\Visual\TestCaseSocial.cs" />
|
|
||||||
<Compile Include="Tests\Visual\TestCaseSongProgress.cs" />
|
|
||||||
<Compile Include="Tests\Visual\TestCaseStoryboard.cs" />
|
|
||||||
<Compile Include="Tests\Visual\TestCaseTabControl.cs" />
|
|
||||||
<Compile Include="Tests\Visual\TestCaseTextAwesome.cs" />
|
|
||||||
<Compile Include="Tests\Visual\TestCaseTwoLayerButton.cs" />
|
|
||||||
<Compile Include="Tests\Visual\TestCaseUserPanel.cs" />
|
|
||||||
<Compile Include="Tests\Visual\TestCaseUserProfile.cs" />
|
|
||||||
<Compile Include="Tests\Visual\TestCaseUserRanks.cs" />
|
|
||||||
<Compile Include="Tests\Visual\TestCaseWaveform.cs" />
|
|
||||||
<Compile Include="Users\Avatar.cs" />
|
<Compile Include="Users\Avatar.cs" />
|
||||||
<Compile Include="Users\Country.cs" />
|
<Compile Include="Users\Country.cs" />
|
||||||
<Compile Include="Users\Medal.cs" />
|
<Compile Include="Users\Medal.cs" />
|
||||||
@ -839,9 +791,7 @@
|
|||||||
<Compile Include="Overlays\BeatmapSet\BasicStats.cs" />
|
<Compile Include="Overlays\BeatmapSet\BasicStats.cs" />
|
||||||
<Compile Include="Overlays\BeatmapSet\SuccessRate.cs" />
|
<Compile Include="Overlays\BeatmapSet\SuccessRate.cs" />
|
||||||
<Compile Include="Overlays\BeatmapSet\PreviewButton.cs" />
|
<Compile Include="Overlays\BeatmapSet\PreviewButton.cs" />
|
||||||
<Compile Include="Tests\Visual\TestCaseBeatmapSetOverlay.cs" />
|
|
||||||
</ItemGroup>
|
</ItemGroup>
|
||||||
<ItemGroup />
|
|
||||||
<Import Project="$(MSBuildBinPath)\Microsoft.CSharp.targets" />
|
<Import Project="$(MSBuildBinPath)\Microsoft.CSharp.targets" />
|
||||||
<!-- To modify your build process, add your task inside one of the targets below and uncomment it.
|
<!-- To modify your build process, add your task inside one of the targets below and uncomment it.
|
||||||
Other similar extension points exist, see Microsoft.Common.targets.
|
Other similar extension points exist, see Microsoft.Common.targets.
|
||||||
@ -865,4 +815,4 @@
|
|||||||
<Import Project="$(SolutionDir)\packages\SQLitePCLRaw.lib.e_sqlite3.osx.1.1.8\build\net35\SQLitePCLRaw.lib.e_sqlite3.osx.targets" Condition="Exists('$(SolutionDir)\packages\SQLitePCLRaw.lib.e_sqlite3.osx.1.1.8\build\net35\SQLitePCLRaw.lib.e_sqlite3.osx.targets')" />
|
<Import Project="$(SolutionDir)\packages\SQLitePCLRaw.lib.e_sqlite3.osx.1.1.8\build\net35\SQLitePCLRaw.lib.e_sqlite3.osx.targets" Condition="Exists('$(SolutionDir)\packages\SQLitePCLRaw.lib.e_sqlite3.osx.1.1.8\build\net35\SQLitePCLRaw.lib.e_sqlite3.osx.targets')" />
|
||||||
<Import Project="$(SolutionDir)\packages\SQLitePCLRaw.lib.e_sqlite3.linux.1.1.8\build\net35\SQLitePCLRaw.lib.e_sqlite3.linux.targets" Condition="Exists('$(SolutionDir)\packages\SQLitePCLRaw.lib.e_sqlite3.linux.1.1.8\build\net35\SQLitePCLRaw.lib.e_sqlite3.linux.targets')" />
|
<Import Project="$(SolutionDir)\packages\SQLitePCLRaw.lib.e_sqlite3.linux.1.1.8\build\net35\SQLitePCLRaw.lib.e_sqlite3.linux.targets" Condition="Exists('$(SolutionDir)\packages\SQLitePCLRaw.lib.e_sqlite3.linux.1.1.8\build\net35\SQLitePCLRaw.lib.e_sqlite3.linux.targets')" />
|
||||||
<Import Project="$(SolutionDir)\packages\SQLitePCLRaw.lib.e_sqlite3.v110_xp.1.1.8\build\net35\SQLitePCLRaw.lib.e_sqlite3.v110_xp.targets" Condition="Exists('$(SolutionDir)\packages\SQLitePCLRaw.lib.e_sqlite3.v110_xp.1.1.8\build\net35\SQLitePCLRaw.lib.e_sqlite3.v110_xp.targets')" />
|
<Import Project="$(SolutionDir)\packages\SQLitePCLRaw.lib.e_sqlite3.v110_xp.1.1.8\build\net35\SQLitePCLRaw.lib.e_sqlite3.v110_xp.targets" Condition="Exists('$(SolutionDir)\packages\SQLitePCLRaw.lib.e_sqlite3.v110_xp.1.1.8\build\net35\SQLitePCLRaw.lib.e_sqlite3.v110_xp.targets')" />
|
||||||
</Project>
|
</Project>
|
Loading…
Reference in New Issue
Block a user