Skip to content
Draft
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
116 commits
Select commit Hold shift + click to select a range
7327290
Add `Describe`
guillermooo Aug 9, 2026
f542dbe
Add `BeforeAll`
guillermooo Aug 9, 2026
b4f6c5c
Add test
guillermooo Aug 9, 2026
a8390fe
Add test
guillermooo Aug 9, 2026
2eaf439
Add test
guillermooo Aug 9, 2026
e946e4d
Add test
guillermooo Aug 9, 2026
8448b34
Add new `Context`
guillermooo Aug 9, 2026
231af68
Add `BeforeAll` and `AfterAll`
guillermooo Aug 9, 2026
6b75ee8
Add test
guillermooo Aug 9, 2026
2b52fb6
Add test
guillermooo Aug 9, 2026
6258e72
Review: Avoid Windows-only convention
guillermooo Aug 10, 2026
95e9342
Review: Use `Join-Path`
guillermooo Aug 10, 2026
8dbc54d
Review: Fix `Should -Throw` tests
guillermooo Aug 10, 2026
bb7d1db
Review: Typo
guillermooo Aug 10, 2026
0b6503e
Review: Use dedicated $env:PSModulePath for tests
guillermooo Aug 10, 2026
c6d6a31
Refactor
guillermooo Aug 10, 2026
45075a9
Fix name
guillermooo Aug 10, 2026
0f4e5fb
Refactor: Use single variable for the same data
guillermooo Aug 11, 2026
c56d882
Consistent formatting
guillermooo Aug 11, 2026
8a0a003
Refactor: Consolidate variables
guillermooo Aug 11, 2026
c2bf6cf
Cleanup
guillermooo Aug 11, 2026
7dd5497
Add test
guillermooo Aug 11, 2026
92c622f
Add test
guillermooo Aug 11, 2026
4087b48
Add `Context`
guillermooo Aug 11, 2026
3dbf91e
Add `BeforeAll` and `AfterAll`
guillermooo Aug 11, 2026
dbf0587
Add test
guillermooo Aug 11, 2026
592a4a1
Add test
guillermooo Aug 11, 2026
11edc82
Add test
guillermooo Aug 11, 2026
8e822c6
Add test
guillermooo Aug 11, 2026
f385bcd
Add test
guillermooo Aug 11, 2026
5154898
Add test
guillermooo Aug 11, 2026
8afb65f
Add `Describe`
guillermooo Aug 11, 2026
0d362fe
Add test
guillermooo Aug 11, 2026
5d8168c
Add test
guillermooo Aug 11, 2026
52ec5a0
Add `Context`
guillermooo Aug 11, 2026
f28cb52
Add `BeforeAll` and `AfterAll`
guillermooo Aug 11, 2026
ff1c480
Add test
guillermooo Aug 11, 2026
9620dac
Add test
guillermooo Aug 11, 2026
3a3837b
Add `Context`
guillermooo Aug 9, 2026
f06e705
Add `BeforeAll` and `AfterAll`
guillermooo Aug 11, 2026
6d93261
Add test
guillermooo Aug 11, 2026
c8356e6
Add test
guillermooo Aug 11, 2026
aa7e56d
Add test
guillermooo Aug 11, 2026
d0f5508
Add `Describe`
guillermooo Aug 9, 2026
19c392a
Add test
guillermooo Aug 9, 2026
b75d60e
Add test
guillermooo Aug 9, 2026
1c65362
Add test
guillermooo Aug 9, 2026
f4ea1ea
Add `Context`
guillermooo Aug 9, 2026
2fcbc0c
Add `BeforeAll` and `AfterAll`
guillermooo Aug 9, 2026
eb36cb1
Add test
guillermooo Aug 9, 2026
cfe4855
Add test
guillermooo Aug 9, 2026
0deccbe
Add `Context`
guillermooo Aug 9, 2026
2fec8f5
Add `BeforeAll` and `AfterAll`
guillermooo Aug 9, 2026
2c58864
Add test
guillermooo Aug 9, 2026
e4e1696
Add test
guillermooo Aug 9, 2026
0bb5dda
Add test
guillermooo Aug 9, 2026
c6bdcf8
Add `Describe`
guillermooo Aug 9, 2026
0569427
Add test
guillermooo Aug 9, 2026
7bbd2b6
Add test
guillermooo Aug 9, 2026
f2f491e
Add `Context`
guillermooo Aug 9, 2026
63e403d
Add test
guillermooo Aug 9, 2026
9bff3f0
Add `Context`
guillermooo Aug 11, 2026
bdd49cc
Add test
guillermooo Aug 11, 2026
a48815c
Add test
guillermooo Aug 11, 2026
ebe1ecb
Add test
guillermooo Aug 11, 2026
e37c322
Add `Context`
guillermooo Aug 11, 2026
d9daa53
Add test
guillermooo Aug 11, 2026
963c04d
Add `Context`
guillermooo Aug 11, 2026
8fe0486
Add `Context`
guillermooo Aug 11, 2026
47a6d46
Add test
guillermooo Aug 11, 2026
47e4bad
Add `Context`
guillermooo Aug 11, 2026
8f1beaa
Add test
guillermooo Aug 11, 2026
3d826dd
Add `Context`
guillermooo Aug 11, 2026
ce944e9
Add test
guillermooo Aug 11, 2026
a2062ec
Add `Context`
guillermooo Aug 11, 2026
56c561d
Add test
guillermooo Aug 11, 2026
d099bf6
Add `Context`
guillermooo Aug 11, 2026
1075415
Add test
guillermooo Aug 11, 2026
b7b3126
Add `Context`
guillermooo Aug 11, 2026
2b27c51
Add test
guillermooo Aug 11, 2026
2695735
Add `Context`
guillermooo Aug 11, 2026
c8d5041
Add test
guillermooo Aug 11, 2026
33c6948
Clarify intent
guillermooo Jul 18, 2026
4c0f3dd
Use existing API
guillermooo Jul 18, 2026
1454a6a
Edit
guillermooo Jul 18, 2026
dab0c4e
More explicit comparison
guillermooo Jul 18, 2026
9471ebb
Consistency
guillermooo Jul 18, 2026
3233cef
Rename parameter
guillermooo Jul 18, 2026
aa29c6c
Rename parameter
guillermooo Jul 18, 2026
033f72b
Edit
guillermooo Jul 18, 2026
9aba90a
Add parameter precondition
guillermooo Jul 18, 2026
3abdc84
Add parameter precondition
guillermooo Jul 18, 2026
3f7e3c8
Remove redundant comment
guillermooo Jul 18, 2026
4a3ccdd
Edit documentation
guillermooo Jul 18, 2026
7ca24b8
Edit documentation
guillermooo Jul 18, 2026
29fcdf5
Edit documentation
guillermooo Jul 18, 2026
d85fea0
Format
guillermooo Jul 18, 2026
f10393f
Make old remark visible again
guillermooo Jul 18, 2026
85bc795
Hide old remark from Intellisense
guillermooo Jul 18, 2026
a3651a1
Add new path resolution API
guillermooo Jul 20, 2026
1f28de5
Refactor to use new path resolution API
guillermooo Jul 20, 2026
1704928
Rename method
guillermooo Jul 20, 2026
ff483fd
Refactor to use new path resolution API
guillermooo Jul 20, 2026
e6a1880
Rename
guillermooo Jul 20, 2026
abf3773
Refactor to use new path resolution API
guillermooo Jul 20, 2026
ae506ee
Rename
guillermooo Jul 20, 2026
7f75d1b
Add class
guillermooo Jul 20, 2026
415d6bf
Refactor to use new API
guillermooo Jul 20, 2026
cf604b4
Document
guillermooo Jul 21, 2026
3060a4b
Rename
guillermooo Jul 21, 2026
ebfec89
Rename
guillermooo Jul 21, 2026
9b3a71b
Remove comment
guillermooo Jul 21, 2026
c15876c
Document
guillermooo Jul 21, 2026
8f5a78c
Rename
guillermooo Jul 21, 2026
9b2667b
Rename
guillermooo Jul 21, 2026
df8f8af
Edit
guillermooo Jul 21, 2026
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
Expand Up @@ -788,7 +788,7 @@ private void ProcessTypeFiles()
for (int i = prependPathTotal.Count - 1; i >= 0; i--)
{
string formattedTarget = string.Format(CultureInfo.InvariantCulture, target, prependPathTotal[i]);
string resolvedPath = ModuleCmdletBase.ResolveRootedFilePath(prependPathTotal[i], Context) ?? prependPathTotal[i];
string resolvedPath = ModuleCmdletBase.ResolveToFileSystemPathIfRooted(prependPathTotal[i], Context) ?? prependPathTotal[i];

if (ShouldProcess(formattedTarget, action))
{
Expand All @@ -804,7 +804,7 @@ private void ProcessTypeFiles()
{
if (entry.FileName != null)
{
string resolvedPath = ModuleCmdletBase.ResolveRootedFilePath(entry.FileName, Context) ?? entry.FileName;
string resolvedPath = ModuleCmdletBase.ResolveToFileSystemPathIfRooted(entry.FileName, Context) ?? entry.FileName;
if (fullFileNameHash.Add(resolvedPath))
{
newTypes.Add(entry);
Expand All @@ -819,7 +819,7 @@ private void ProcessTypeFiles()
foreach (string appendPathTotalItem in appendPathTotal)
{
string formattedTarget = string.Format(CultureInfo.InvariantCulture, target, appendPathTotalItem);
string resolvedPath = ModuleCmdletBase.ResolveRootedFilePath(appendPathTotalItem, Context) ?? appendPathTotalItem;
string resolvedPath = ModuleCmdletBase.ResolveToFileSystemPathIfRooted(appendPathTotalItem, Context) ?? appendPathTotalItem;

if (ShouldProcess(formattedTarget, action))
{
Expand Down Expand Up @@ -1135,7 +1135,7 @@ protected override void ProcessRecord()

// Resolving the file path because the path to the types file in module manifest is now specified as
// ..\..\types.ps1xml which expands to C:\Windows\System32\WindowsPowerShell\v1.0\Modules\Microsoft.PowerShell.Core\..\..\types.ps1xml
fileName = ModuleCmdletBase.ResolveRootedFilePath(fileName, Context) ?? fileName;
fileName = ModuleCmdletBase.ResolveToFileSystemPathIfRooted(fileName, Context) ?? fileName;
ConstructFileToIndexMap(fileName, index, fileToIndexMap);
}
}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -3494,7 +3494,7 @@ internal static void RemoveTypesAndFormats(ExecutionContext context, IList<strin
List<string> resolvedTypeFilesToRemove = new List<string>();
foreach (var typeFile in typeFilesToRemove)
{
resolvedTypeFilesToRemove.Add(ModuleCmdletBase.ResolveRootedFilePath(typeFile, context) ?? typeFile);
resolvedTypeFilesToRemove.Add(ModuleCmdletBase.ResolveToFileSystemPathIfRooted(typeFile, context) ?? typeFile);
}

foreach (SessionStateTypeEntry entry in context.InitialSessionState.Types)
Expand All @@ -3508,7 +3508,7 @@ internal static void RemoveTypesAndFormats(ExecutionContext context, IList<strin
{
// Resolving the file path because the path to the types file in module manifest is now specified as
// ..\..\types.ps1xml which expands to C:\Windows\System32\WindowsPowerShell\v1.0\Modules\Microsoft.PowerShell.Core\..\..\types.ps1xml
string filePath = ModuleCmdletBase.ResolveRootedFilePath(entry.FileName, context) ?? entry.FileName;
string filePath = ModuleCmdletBase.ResolveToFileSystemPathIfRooted(entry.FileName, context) ?? entry.FileName;
if (!resolvedTypeFilesToRemove.Contains(filePath))
{
newTypes.Add(entry);
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -662,7 +662,7 @@ private PSModuleInfo ImportModule_LocallyViaName(ImportModuleOptions importModul
}

// If null check for full-qualified paths - either absolute or relative
rootedPath ??= ResolveRootedFilePath(name, this.Context);
rootedPath ??= ResolveToFileSystemPathIfRooted(name, this.Context);

bool alreadyLoaded = false;
var manifestProcessingFlags = ManifestProcessingFlags.LoadElements | ManifestProcessingFlags.NullOnFirstError;
Expand Down Expand Up @@ -1387,7 +1387,7 @@ private bool IsPs1xmlFileHelper_IsPresentInEntries(RemoteDiscoveryHelper.CimModu
foreach (string entry in manifestEntries)
{
string tempName = entry.EndsWith(ps1xmlExt, StringComparison.OrdinalIgnoreCase) ? entry : entry + ps1xmlExt;
string resolvedPath = ResolveRootedFilePath(tempName, Context);
string resolvedPath = ResolveToFileSystemPathIfRooted(tempName, Context);
if (resolvedPath is not null && resolvedPath.EndsWith(fileName, StringComparison.OrdinalIgnoreCase))
{
return true;
Expand Down
Loading