1
0
mirror of https://github.com/ppy/osu.git synced 2024-11-06 11:27:24 +08:00
Commit Graph

150 Commits

Author SHA1 Message Date
Dean Herbert
485d140a21 Add realm refresh calls to fix intermittent test failures on new update tests 2022-07-28 15:15:41 +09:00
Dean Herbert
494486ad09 Fix potential test failure if scores are added to the beatmap which is subsequently removed 2022-07-27 16:27:10 +09:00
Dean Herbert
7f75184a01
Merge branch 'master' into beatmap-update-test 2022-07-26 17:27:36 +09:00
Dean Herbert
ee694c1257 Add test coverage of no online ID scenario 2022-07-26 17:27:23 +09:00
Dean Herbert
1221cb1a42 Add comprehensive test coverage of update scenarios 2022-07-26 17:22:52 +09:00
Dean Herbert
846291d203 Refactor new tests to not suck as much as the old importer tests 2022-07-26 16:33:00 +09:00
Dean Herbert
8370ca9765 Add ImportAsUpdate method to IModelImporter to avoid otehr changes 2022-07-26 15:49:04 +09:00
Dean Herbert
ac553d22ea Fix left over resource file which isn't actually imported 2022-07-26 15:08:18 +09:00
Dean Herbert
59d3cc52c4 Avoid leaving left-over files after test run completes 2022-07-26 15:08:18 +09:00
Dean Herbert
7d8a78ef01 Move tests to own class 2022-07-26 14:53:20 +09:00
Dean Herbert
9c411c2250 Fix test nullability assertions 2022-07-25 20:06:37 +09:00
Dean Herbert
92dd1bcddb Add test coverage of actual update flow 2022-07-25 19:51:19 +09:00
Dean Herbert
6a3e8e31de Centralise calls to reset online info of a BeatmapInfo 2022-07-25 19:51:19 +09:00
Dean Herbert
ec477a3ebf Add basic coverage of current behaviour of beatmap reimport 2022-07-25 19:51:19 +09:00
Dean Herbert
1374738a0d Add test coverage 2022-07-21 18:20:46 +09:00
Dean Herbert
bf10f2db2e Add test coverage of nested rollback for good measure 2022-07-07 18:19:01 +09:00
Dean Herbert
ac216d94a8 Fix transaction not being disposed 2022-07-07 18:15:38 +09:00
Dean Herbert
5197d0fa9e Add automatic transaction handling to realm helper methods 2022-07-07 17:36:25 +09:00
Dean Herbert
4fd47b5fa0 Add more verbose logging to realm blocking process 2022-07-02 12:36:56 +09:00
Dan Balasescu
3b1842a2c2
Merge pull request #18835 from peppy/beatmap-update-flow
Split out beatmap update tasks to `BeatmapUpdater` and invoke from editor save flow
2022-07-01 20:28:04 +09:00
Dean Herbert
447b496eff
Merge branch 'master' into realm-fix-async-write-after-disposal 2022-06-30 19:07:15 +09:00
Dean Herbert
98938821e5 Merge branch 'master' into beatmap-update-flow 2022-06-30 16:44:17 +09:00
Dean Herbert
0abb400f64 Add reproduction of transaction not being exited correctly 2022-06-30 15:15:09 +09:00
Dean Herbert
a3b4a515fc Merge branch 'master' into realm-fix-async-write-after-disposal 2022-06-29 22:39:05 +09:00
Dean Herbert
d64959ad0c Add test coverage of async writes during a blocking operation 2022-06-28 17:07:49 +09:00
Dean Herbert
6203885040 Add test coverage of realm async writes 2022-06-27 19:38:14 +09:00
Dean Herbert
1fc4fa6820 Remove unnecessary Task.Run workaround in tests 2022-06-27 19:21:05 +09:00
Dean Herbert
5af1106fa5 Remove unused using statement 2022-06-27 18:04:52 +09:00
Dean Herbert
8c3c1f095e Update rollback test expectations
I can't find a better way to do this. It's very hard to trigger an
actual failure in the import process these days. For now I've just made
this work with the new assumptions. May be worth removing the test in
the future if this ever backfires.
2022-06-27 17:04:35 +09:00
Dean Herbert
31a447fda0 Update parameter discards 2022-06-24 21:26:19 +09:00
Dean Herbert
06d59b717c Move beatmap processing tasks to new BeatmapUpdater class 2022-06-24 21:02:37 +09:00
Dean Herbert
7ef8b7df5f Add timeout for all ManualResetEventSlim.Wait invocations
Timeout values were taken as best-guesses of upper values we'd expect
from sane execution.
2022-06-23 14:46:00 +09:00
Dan Balasescu
c402e90598
Merge pull request #18777 from peppy/output-directory-on-import-failure
Silence exception and provide more log output when import fails due to empty `.osu` files
2022-06-20 17:36:21 +09:00
Dean Herbert
e82d948acc Add test coverage of import throwing when no valid .osu files are found 2022-06-20 16:06:22 +09:00
Dean Herbert
92f1a2958c Rename Import(TModel) to ImportModel to differentiate from other import methods 2022-06-20 15:18:07 +09:00
Dean Herbert
a6c8a832aa Remove Import(ArchiveReader) and redirect existing usages to Import(ImportTask) 2022-06-20 15:14:57 +09:00
Dan Balasescu
f8830c6850 Automated #nullable processing 2022-06-17 16:37:17 +09:00
Dean Herbert
f3984d98e6 Remove RealmArchiveModelManager from hierarchy 2022-06-16 18:53:13 +09:00
Dean Herbert
84dba36cf5 Update usages of BeatmapModelManager which only require importing to use BeatmapImporter 2022-06-16 17:59:24 +09:00
Dean Herbert
f23ddfe6cc Move remaining realm classes out of Stores namespace 2022-06-15 21:56:00 +09:00
Dean Herbert
080f2859ef
Merge pull request #18689 from peppy/quick-import-only-on-batch
Always perform full consistency checks for single imports
2022-06-15 17:06:06 +09:00
Salman Ahmed
3d638abc52 Fix test files stream not disposed after creation 2022-06-15 08:24:20 +03:00
Salman Ahmed
ee8045d507 Add failing test case 2022-06-15 07:33:21 +03:00
Dean Herbert
cac724f436 Re-enable ignored tests that will work again now 2022-06-15 00:51:08 +09:00
Dean Herbert
f11fe54385 Remove custom hash function flow 2022-06-15 00:42:30 +09:00
Dean Herbert
1b4c89c418 Update realm to latest version
Contains minor changes to async usage in line with upstream API changes.

I believe a feedback issue we were seeing with offset changes (the only
component using async write flow) may have been resolved by these
upstream changes (see [release
notes](https://github.com/realm/realm-dotnet/releases/tag/10.14.0)) but
am not investigating further just yet.
2022-06-03 14:16:10 +09:00
Dean Herbert
218642c300 Update unsafe file write usages 2022-05-16 18:05:27 +09:00
Dean Herbert
87f6f74795 Add failing test coverage of adding a file to a detached beatmap across threads 2022-05-10 21:04:30 +09:00
Dean Herbert
975883da5c Move all usages of client.realm filename to a single const 2022-03-30 13:34:48 +09:00
Dean Herbert
4d0b4c2541 Fix realm potentially not being refreshed in time for test asserts in BeatmapImporterTests
As seen at https://github.com/ppy/osu/runs/5659368512?check_suite_focus=true

Went through every usage of `.Import` and added either an
`EnsureLoaded`, or where that provides too many checks, an explicit
`realm.Refresh()`.
2022-03-24 12:59:17 +09:00