Describe
#
SYNOPSISCreates a logical group of tests.
#
SYNTAX#
DESCRIPTIONCreates a logical group of tests. All Mocks, TestDrive and TestRegistry contents defined within a Describe block are scoped to that Describe; they will no longer be present when the Describe block exits. A Describe block may contain any number of Context and It blocks.
#
EXAMPLES#
EXAMPLE 1#
PARAMETERS#
-NameThe name of the test group. This is often an expressive phrase describing the scenario being tested.
#
-TagOptional parameter containing an array of strings. When calling Invoke-Pester, it is possible to specify a -Tag parameter which will only execute Describe blocks containing the same Tag.
#
-FixtureThe actual test script. If you are following the AAA pattern (Arrange-Act-Assert), this typically holds the arrange and act sections. The Asserts will also lie in this block but are typically nested each in its own It block. Assertions are typically performed by the Should command within the It blocks.
#
CommonParametersThis cmdlet supports the common parameters: -Debug, -ErrorAction, -ErrorVariable, -InformationAction, -InformationVariable, -OutVariable, -OutBuffer, -PipelineVariable, -Verbose, -WarningAction, and -WarningVariable. For more information, see about_CommonParameters.
#
INPUTS#
OUTPUTS#
NOTES#
RELATED LINKShttps://pester.dev/docs/v4/commands/It
https://pester.dev/docs/v4/commands/Context
https://pester.dev/docs/v4/commands/Invoke-Pester
https://pester.dev/docs/v4/commands/Should
https://pester.dev/docs/v4/usage/mocking
https://pester.dev/docs/v4/usage/testdrive
#
EDIT THIS PAGEThis page was auto-generated using Pester's comment based help. To edit the content of this page, change the corresponding help in the pester/Pester repository. See our contribution guide for more information.