Skip to content

TabCompletion: Miscellaneous completion tests - Test completion with splatted variable #15601

@rjmholt

Description

@rjmholt

The following test is failing on Ubuntu 20.04 in PS 7.2.0-preview.7:

It "Test completion with splatted variable" {
$inputStr = 'Get-Content @Splat -P'
$res = TabExpansion2 -inputScript $inputStr -cursorColumn $inputStr.Length
$res.CompletionMatches | Should -HaveCount 4
[string]::Join(',', ($res.CompletionMatches.completiontext | Sort-Object)) | Should -BeExactly "-Path,-PipelineVariable,-PSPath,-pv"
}

The error message is:

Expected a collection with size 4, but got collection with size 2 @(System.Management.Automation.CompletionResult, System.Management.Automation.CompletionResult).

Metadata

Metadata

Assignees

No one assigned

    Labels

    Issue-BugIssue has been identified as a bug in the productNeeds-TriageThe issue is new and needs to be triaged by a work group.Release-TestingResolution-No ActivityIssue has had no activity for 6 months or moreWG-Quality-Testissues in a test or in test infrastructure

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions