1
0
mirror of https://github.com/ppy/osu.git synced 2024-11-16 02:11:05 +08:00
Commit Graph

253 Commits

Author SHA1 Message Date
Dean Herbert
66b8b5192b Add test coverage of editor timestamp remembering 2023-06-06 15:25:19 +09:00
Bartłomiej Dach
5c1abdc704
Fix screen navigation test hijacking dummy request handler
In an upcoming change, I stumbled upon a test failure mode wherein tests
in `TestSceneScreenNavigation` would die on the following exception:

	2023-05-07 17:58:42 [error]: System.ObjectDisposedException: Cannot access a closed Realm.
	2023-05-07 17:58:42 [error]: Object name: 'Realms.Realm'.
	2023-05-07 17:58:42 [error]: at Realms.Realm.ThrowIfDisposed()
	2023-05-07 17:58:42 [error]: at Realms.Realm.All[T]()
	2023-05-07 17:58:42 [error]: at osu.Game.Beatmaps.BeatmapManager.<>c__DisplayClass25_0.<QueryBeatmap>b__0(Realm r) in D:\a\osu\osu\osu.Game\Beatmaps\BeatmapManager.cs:line 282
	2023-05-07 17:58:42 [error]: at osu.Game.Database.RealmAccess.Run[T](Func`2 action) in D:\a\osu\osu\osu.Game\Database\RealmAccess.cs:line 387
	2023-05-07 17:58:42 [error]: at osu.Game.Beatmaps.BeatmapManager.QueryBeatmap(Expression`1 query) in D:\a\osu\osu\osu.Game\Beatmaps\BeatmapManager.cs:line 282
	2023-05-07 17:58:42 [error]: at osu.Game.Tests.Visual.OnlinePlay.TestRoomRequestsHandler.<HandleRequest>g__createResponseBeatmaps|6_0(Int32[] beatmapIds, <>c__DisplayClass6_0& ) in D:\a\osu\osu\osu.Game\Tests\Visual\OnlinePlay\TestRoomRequestsHandler.cs:line 174
	2023-05-07 17:58:42 [error]: at osu.Game.Tests.Visual.OnlinePlay.TestRoomRequestsHandler.HandleRequest(APIRequest request, APIUser localUser, BeatmapManager beatmapManager) in D:\a\osu\osu\osu.Game\Tests\Visual\OnlinePlay\TestRoomRequestsHandler.cs:line 140
	2023-05-07 17:58:42 [error]: at osu.Game.Tests.Visual.TestMultiplayerComponents.<>c__DisplayClass18_0.<load>b__0(APIRequest request) in D:\a\osu\osu\osu.Game.Tests\Visual\TestMultiplayerComponents.cs:line 80
	2023-05-07 17:58:42 [error]: at osu.Game.Online.API.DummyAPIAccess.<>c__DisplayClass32_0.<Queue>b__0() in D:\a\osu\osu\osu.Game\Online\API\DummyAPIAccess.cs:line 74

Upon closer inspection, one of the tests in the scene instantiates a
`TestMultiplayerComponents` instance. `TestMultiplayerComponents`
registers a custom request handler onto `DummyAPIAccess`. Normally, this
is not an issue; however, because `TestSceneScreenNavigation` is an
`OsuGameTestScene`, and therefore has its storage recycled after every
test, this leads to the error above in the following scenario:

1. `TestPushMatchSubScreenAndPressBackButtonImmediately()` passes.
2. The test is cleaned up, and the test case's storage is recycled,
   including the test case's realm database.
3. In a subsequent test, a web request handled by the dummy API request
   handler is fired. The dummy API request handler subsequently attempts
   to access a realm that does not exist anymore.

As the usage of `TestMultiplayerComponents` is highly unorthodox in this
particular case, I'm opting for a localised fix which ensures that the
request handler is cleaned up appropriately.
2023-06-05 23:15:16 +02:00
Bartłomiej Dach
07b5874eee
Fix test step name 2023-05-24 20:18:36 +02:00
Dean Herbert
6044327181 Add test coverage for escape deselecting any active selection 2023-05-24 23:59:22 +09:00
Dean Herbert
663cec1ff6 Combine editor navigation test scenes 2023-05-24 23:51:28 +09:00
Bartłomiej Dach
8514b2758a
Fix rapid back button test failure 2023-05-07 21:07:38 +02:00
Dean Herbert
2643100644 Add xmldoc to new test mentioning failure rate and general purpose 2023-04-29 11:05:10 +09:00
Dean Herbert
32f8c674f4 Extract beatmap retrieval method for more legibility 2023-04-29 11:01:29 +09:00
Dean Herbert
a6f0186112 Improve legibility and code quality of new test 2023-04-29 10:51:56 +09:00
Dean Herbert
428b5fad3c Rename test scene to explicitly mention navigation testing 2023-04-29 10:51:56 +09:00
Cootz
d9b3c97179 Fix testing 2023-04-29 10:29:33 +09:00
Cootz
c5357d30ab Add test 2023-04-29 10:29:33 +09:00
Dean Herbert
28520414aa Move KeyCounter components to HUD namespace 2023-03-07 16:41:39 +09:00
Dean Herbert
8f6df5ea0f
Merge branch 'master' into gameplay/key-counter-abstraction 2023-03-07 16:09:45 +09:00
Bartłomiej Dach
9d4bb2ecf7
Add failing test coverage for clearing sidebar contents 2023-03-04 14:08:50 +01:00
Bartłomiej Dach
2f25fb4083
Move NonSkinnableScreenPlaceholder to outer scope 2023-03-04 13:22:43 +01:00
Bartłomiej Dach
3dd3b5e77a
Add failing test case 2023-03-04 13:17:54 +01:00
tsrk
ddd6c1a1c6
refactor(KeyCounter): address bindables issues
`IsCounting` is back being an auto-property.
`countPresses` is now encapsulated and being exposed as an
`IBindable<int>` via `CountPresses`
2023-02-16 22:20:34 +00:00
Susko3
364217829c Add test for ArchiveImportIPCChannel 2023-02-03 18:39:46 +01:00
Susko3
13fc649edf Refactor test to more closely match how OsuGameDesktop works 2023-02-03 18:22:51 +01:00
Dean Herbert
8dc2e6872e Move skin editor to overlays namespace 2023-02-02 14:00:31 +09:00
Joseph Madamba
845bbf55fe Add failing beatmap listing search on initial open test 2023-01-28 12:10:50 -08:00
Dean Herbert
1f47def3c4
Merge branch 'master' into skin-editor-loc 2023-01-17 11:53:08 +09:00
Dean Herbert
4cf448ec11 Use ToString() for test instead of linq skip 2023-01-17 11:51:17 +09:00
ansel
0ec608ec5d Select button using its index in test 2023-01-16 22:47:14 +03:00
Bartłomiej Dach
bf58fe21ce
Merge branch 'master' into beatmap-set-converted-beatmaps 2023-01-16 20:46:41 +01:00
Joseph Madamba
b733f46c6f Apply NRT to BeatmapPicker 2023-01-15 15:09:25 -08:00
Salman Ahmed
13c1b8f5a4 Fix intermittent failure in tests with restarting player instances 2023-01-15 16:06:06 +03:00
Joseph Madamba
5232588a1f Use PerformFromScreen to exit sub screens instead 2022-12-24 20:04:45 -08:00
Joseph Madamba
00ed5d6f92 Merge remote-tracking branch 'upstream/master' into fix-op-non-current-onexiting 2022-12-24 14:01:11 -08:00
Dean Herbert
57048f0eba Add test coverage of featured artist filter confirmation process 2022-12-15 18:42:58 +09:00
Bartłomiej Dach
894ef15e79
Merge branch 'master' into update-framework 2022-11-26 16:19:36 +01:00
Dan Balasescu
7bc8908ca9 Partial everything 2022-11-27 00:00:27 +09:00
Dean Herbert
2425878e67 Add test coverage 2022-11-25 20:06:36 +09:00
Salman Ahmed
ca67689a36 Fix intermittent present beatmap test failures 2022-11-19 07:44:43 +03:00
Salman Ahmed
8943819ee7 Add test coverage 2022-11-18 17:49:03 +03:00
Salman Ahmed
82829867db Fix beatmap options test failure due to no beatmap being selected 2022-11-18 07:07:56 +03:00
Bartłomiej Dach
b0314c67aa
Fix failing gameplay bindings test 2022-11-12 14:16:46 +09:00
Salman Ahmed
3909e5730e
Rename test steps
Co-authored-by: Joseph Madamba <madamba.joehu@outlook.com>
2022-11-09 21:33:28 +03:00
Dean Herbert
4c15794694 Add test coverage of overlay interplay 2022-11-08 14:58:57 +09:00
Salman Ahmed
45f590ca43 Add test case for hiding cursor on idle 2022-10-15 00:20:22 +03:00
Dean Herbert
7fbbe88c8e Add test coverage of song select score presentation failures 2022-10-03 20:29:44 +09:00
Dean Herbert
ed0752a5f1 Update test assumptions 2022-09-27 21:55:54 +09:00
Dean Herbert
41e69fbca6 Remove "default" prefix from naming 2022-09-18 00:15:26 +09:00
Dean Herbert
51841988bf Rename references to DefaultSkin to have Triangles suffix 2022-09-17 23:57:25 +09:00
Dean Herbert
40a60f7145 Remove all entity framework code and migrations 2022-09-15 16:58:58 +09:00
Dean Herbert
9e3228aa65 Fix completion notification not being posted if completion occurs during NotificationOverlay load 2022-09-06 04:07:49 +09:00
Dean Herbert
6a35b233e5 Merge branch 'master' into remove-dispose-updates 2022-09-01 23:03:19 +09:00
Dean Herbert
a62ba9e0d9 Remove notification blocking behaviour of first run setup 2022-08-31 00:57:18 +09:00
Dean Herbert
a215d009fe Update Remove/RemoveRange/RemoveAll calls in line with framework changes 2022-08-29 15:57:40 +09:00