mirror of
https://github.com/aphrody-labs/PowerShell.git
synced 2026-10-17 04:36:39 +00:00
Add SessionStateTests to AssemblyLoadContext collection
This commit is contained in:
1 parent
c42258cfac
commit
1665d6c525
1 file changed
+1
-2
@@ -13,12 +13,12 @@ using Microsoft.PowerShell.Linux.Host;
|
||||
|
||||
namespace PSTests
|
||||
{
|
||||
[Collection("AssemblyLoadContext")]
|
||||
public class SessionStateTests
|
||||
{
|
||||
[Fact]
|
||||
public void TestDrives()
|
||||
{
|
||||
PowerShellAssemblyLoadContextInitializer.SetPowerShellAssemblyLoadContext(AppContext.BaseDirectory);
|
||||
CultureInfo currentCulture = CultureInfo.CurrentCulture;
|
||||
PSHost hostInterface = new DefaultHost(currentCulture,currentCulture);
|
||||
RunspaceConfiguration runspaceConfiguration = RunspaceConfiguration.Create();
|
||||
@@ -29,6 +29,5 @@ namespace PSTests
|
||||
Collection<PSDriveInfo> drives = sessionState.Drives(null);
|
||||
Assert.True(drives.Count>0);
|
||||
}
|
||||
|
||||
}
|
||||
}
|
||||
Reference in new issue
Block a user