mirror of
https://github.com/ppy/osu.git
synced 2025-01-26 12:25:04 +08:00
Fix assembly location lookups
This commit is contained in:
parent
de079e08dc
commit
dd9a418549
@ -185,7 +185,7 @@ namespace osu.Game.Tests.Beatmaps
|
||||
|
||||
private Stream openResource(string name)
|
||||
{
|
||||
string localPath = Path.GetDirectoryName(Uri.UnescapeDataString(new UriBuilder(Assembly.GetExecutingAssembly().Location).Path)).AsNonNull();
|
||||
string localPath = Path.GetDirectoryName(Assembly.GetExecutingAssembly().Location).AsNonNull();
|
||||
return Assembly.LoadFrom(Path.Combine(localPath, $"{ResourceAssembly}.dll")).GetManifestResourceStream($@"{ResourceAssembly}.Resources.{name}");
|
||||
}
|
||||
|
||||
|
@ -3,7 +3,6 @@
|
||||
|
||||
#nullable disable
|
||||
|
||||
using System;
|
||||
using System.IO;
|
||||
using System.Reflection;
|
||||
using NUnit.Framework;
|
||||
@ -54,7 +53,7 @@ namespace osu.Game.Tests.Beatmaps
|
||||
|
||||
private Stream openResource(string name)
|
||||
{
|
||||
string localPath = Path.GetDirectoryName(Uri.UnescapeDataString(new UriBuilder(Assembly.GetExecutingAssembly().Location).Path)).AsNonNull();
|
||||
string localPath = Path.GetDirectoryName(Assembly.GetExecutingAssembly().Location).AsNonNull();
|
||||
return Assembly.LoadFrom(Path.Combine(localPath, $"{ResourceAssembly}.dll")).GetManifestResourceStream($@"{ResourceAssembly}.Resources.{name}");
|
||||
}
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user