Dean Herbert
7f75184a01
Merge branch 'master' into beatmap-update-test
2022-07-26 17:27:36 +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
98938821e5
Merge branch 'master' into beatmap-update-flow
2022-06-30 16:44:17 +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
06d59b717c
Move beatmap processing tasks to new BeatmapUpdater
class
2022-06-24 21:02:37 +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
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
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
Dean Herbert
0fcb3bdba9
Fix beatmap date added not being updated on reimporting a soft deleted beatmap
...
Addresses concerns raised in https://github.com/ppy/osu/discussions/17399 .
2022-03-22 14:10:36 +09:00
Dean Herbert
0138f22c8d
Update existing usages to point to RealmRulesetStore
2022-02-16 17:13:54 +09:00
Dean Herbert
cd71ec0edd
Remove ILive<>
interface (and use abstract Live<>
instead)
2022-01-26 13:38:56 +09:00
Dean Herbert
778d2a71b4
Remove Task
from the inner-most Import
method in RealmArchiveModelImporter
...
One of my pending work items for post-realm merge.
The lowest-level import task is no longer asynchronous, as we don't want
it to span multiple threads to allow easier interaction with realm.
Removing the `Task` spec simplifies a heap of usages.
Individual usages should decide whether they want to run the import
asynchronously, by either using an alternative override or spooling up a
thread themselves.
2022-01-25 15:30:29 +09:00
Dean Herbert
ae0fea8e26
Fix compilation issues due to misnamed fild
2022-01-25 15:29:45 +09:00
Dan Balasescu
bfa521bdd2
Merge pull request #16593 from peppy/realm-clean-up
...
Clean up realm naming
2022-01-25 14:33:53 +09:00
Dean Herbert
bbcc149e2e
During import if files are found to be missing, ensure they are restored
...
This is one step closer to sanity in terms of physical files. As per the
comment I have left in place, we really should be checking file sizes or
hashes, but to keep things simple and fast I've opted to just cover the
"missing file" scenario for now.
Ran into this when testing against a foreign `client.realm` by:
- Noticing a beatmap doesn't load
- Deleting said beatmap
- Downloading via beatmap overlay
- Beatmap is restored but still doesn't work
Note that I've kept the logic where this will undelete an existing
import rather than create one from fresh, as I think that is beneficial
to the user (ie. it will still keep any linked scores on restore).
2022-01-25 13:44:54 +09:00
Dean Herbert
6eb2c28e41
Rename RealmContextFactory
to RealmAccess
2022-01-24 20:38:07 +09:00
Dean Herbert
1db2135d70
Update tests to match new behaviour
2022-01-19 01:05:47 +09:00
Dean Herbert
f24b2b1be3
Make copying detached changes to realm only exposed for BeatmapSet
...
Also fixes remaining issues with the copy process.
2022-01-12 17:49:11 +09:00
Dean Herbert
a307f7e90e
Add test coverage of updating via copying changes from detached instance
2022-01-12 17:49:11 +09:00
Dean Herbert
c92aff8d2b
Add test of cyclic beatmap/beatmapset references
2022-01-12 17:49:11 +09:00
Dean Herbert
509301d94f
Update detach test to assert correct behaviour
2022-01-12 17:49:11 +09:00
Dean Herbert
8461eaab46
BeatmapSetInfo
detach support
2022-01-12 17:00:16 +09:00
Dean Herbert
31a3161189
Make tests compile again
2022-01-12 17:00:16 +09:00
Dean Herbert
00e3af3366
Update model manager and many related classes to get things compiling again
2022-01-12 17:00:00 +09:00
Dean Herbert
b8cd3cdbbc
Various updates to ruleset and primary key usages to move closer to realm support
2022-01-12 16:57:13 +09:00
Dean Herbert
3ecd889fef
Replace EF RulesetStore
with realm version
...
Pass full EF context factory to `RealmContextFactory` for migration purposes
2022-01-12 16:39:36 +09:00
Dean Herbert
618903c217
Rename realm to become imposter classes
2022-01-12 16:39:36 +09:00
Dean Herbert
dbb08f7d46
Use OnlineID
for set operations
2021-12-10 16:11:48 +09:00
Dean Herbert
0feec09966
Refactor beatmap importer tests to ensure realm is refreshed when waiting on state
2021-11-30 14:12:49 +09:00
Dean Herbert
d73e81ee63
Add test coverage of non-optimised existing model check
2021-11-29 14:48:28 +09:00
Dean Herbert
183b95cbc2
Rename BeatmapSetOnlineStatus
to BeatmapOnlineStatus
...
This variable is used at more than just a set level.
2021-11-24 18:42:49 +09:00
Dean Herbert
1cdfa6d9a0
Add helper property to access a realm beatmap's beatmap file
2021-11-22 15:30:11 +09:00