1"use strict";(self.webpackChunkpester_docs=self.webpackChunkpester_docs||[]).push([["6718"],{3766(e){e.exports=JSON.parse('{"version":{"pluginId":"default","version":"v5","label":"v5","banner":"unmaintained","badge":true,"noIndex":false,"className":"docs-version-v5","isLast":false,"docsSidebars":{"docs":[{"type":"category","label":"Documentation","collapsible":false,"items":[{"type":"category","label":"Introduction","items":[{"type":"link","href":"/docs/v5/quick-start","label":"Quick Start","docId":"quick-start","unlisted":false},{"type":"link","href":"/docs/v5/introduction/installation","label":"Installation","docId":"introduction/installation","unlisted":false}],"collapsed":true,"collapsible":true},{"type":"category","label":"Usage","items":[{"type":"link","href":"/docs/v5/usage/file-placement-and-naming","label":"File placement and naming","docId":"usage/file-placement-and-naming","unlisted":false},{"type":"link","href":"/docs/v5/usage/importing-tested-functions","label":"Importing tested functions","docId":"usage/importing-tested-functions","unlisted":false},{"type":"link","href":"/docs/v5/usage/test-file-structure","label":"Test file structure","docId":"usage/test-file-structure","unlisted":false},{"type":"link","href":"/docs/v5/usage/discovery-and-run","label":"Discovery and Run","docId":"usage/discovery-and-run","unlisted":false},{"type":"link","href":"/docs/v5/usage/data-driven-tests","label":"Data driven tests","docId":"usage/data-driven-tests","unlisted":false},{"type":"link","href":"/docs/v5/usage/setup-and-teardown","label":"Setup and teardown","docId":"usage/setup-and-teardown","unlisted":false},{"type":"link","href":"/docs/v5/usage/tags","label":"Tags","docId":"usage/tags","unlisted":false},{"type":"link","href":"/docs/v5/usage/skip","label":"Skip","docId":"usage/skip","unlisted":false},{"type":"link","href":"/docs/v5/usage/mocking","label":"Mocking","docId":"usage/mocking","unlisted":false},{"type":"link","href":"/docs/v5/usage/modules","label":"Modules","docId":"usage/modules","unlisted":false},{"type":"link","href":"/docs/v5/usage/testdrive","label":"TestDrive","docId":"usage/testdrive","unlisted":false},{"type":"link","href":"/docs/v5/usage/testregistry","label":"TestRegistry","docId":"usage/testregistry","unlisted":false},{"type":"link","href":"/docs/v5/usage/test-results","label":"Test Results","docId":"usage/test-results","unlisted":false},{"type":"link","href":"/docs/v5/usage/code-coverage","label":"Code Coverage","docId":"usage/code-coverage","unlisted":false},{"type":"link","href":"/docs/v5/usage/configuration","label":"Configuration","docId":"usage/configuration","unlisted":false},{"type":"link","href":"/docs/v5/usage/output","label":"Output","docId":"usage/output","unlisted":false},{"type":"link","href":"/docs/v5/usage/vscode","label":"Visual Studio Code","docId":"usage/vscode","unlisted":false},{"type":"link","href":"/docs/v5/usage/troubleshooting","label":"Troubleshooting","docId":"usage/troubleshooting","unlisted":false}],"collapsed":true,"collapsible":true},{"type":"category","label":"Assertions","items":[{"type":"link","href":"/docs/v5/assertions/should-command","label":"Should","docId":"assertions/should-command","unlisted":false},{"type":"link","href":"/docs/v5/assertions/","label":"Assertion Reference","docId":"assertions/assertions","unlisted":false},{"type":"link","href":"/docs/v5/assertions/custom-assertions","label":"Custom Assertions","docId":"assertions/custom-assertions","unlisted":false}],"collapsed":true,"collapsible":true},{"type":"category","label":"Migration Guides","items":[{"type":"link","href":"/docs/v5/migrations/v4-to-v5","label":"Pester v4 to v5","docId":"migrations/v4-to-v5","unlisted":false},{"type":"link","href":"/docs/v5/migrations/breaking-changes-in-v5","label":"Breaking changes in v5","docId":"migrations/breaking-changes-in-v5","unlisted":false},{"type":"link","href":"/docs/v5/migrations/v3-to-v4","label":"Pester v3 to v4","docId":"migrations/v3-to-v4","unlisted":false}],"collapsed":true,"collapsible":true},{"type":"category","label":"Additional Resources","items":[{"type":"link","href":"/docs/v5/additional-resources/articles","label":"Articles","docId":"additional-resources/articles","unlisted":false},{"type":"link","href":"/docs/v5/additional-resources/courses","label":"Courses","docId":"additional-resources/courses","unlisted":false},{"type":"link","href":"/docs/v5/additional-resources/misc","label":"Misc","docId":"additional-resources/misc","unlisted":false},{"type":"link","href":"/docs/v5/additional-resources/projects","label":"Projects","docId":"additional-resources/projects","unlisted":false},{"type":"link","href":"/docs/v5/additional-resources/videos","label":"Videos","docId":"additional-resources/videos","unlisted":false}],"collapsed":true,"collapsible":true},{"type":"category","label":"Contributing","items":[{"type":"link","href":"/docs/v5/contributing/introduction","label":"Introduction","docId":"contributing/introduction","unlisted":false},{"type":"link","href":"/docs/v5/contributing/reporting-issues","label":"Reporting Issues","docId":"contributing/reporting-issues","unlisted":false},{"type":"link","href":"/docs/v5/contributing/feature-requests","label":"Feature Requests","docId":"contributing/feature-requests","unlisted":false},{"type":"link","href":"/docs/v5/contributing/pull-requests","label":"Pull Requests","docId":"contributing/pull-requests","unlisted":false}],"collapsed":true,"collapsible":true}],"collapsed":false}],"commands":[{"type":"category","label":"Command Reference","collapsible":false,"items":[{"type":"link","href":"/docs/v5/commands/Add-ShouldOperator","label":"Add-ShouldOperator","docId":"commands/Add-ShouldOperator","unlisted":false},{"type":"link","href":"/docs/v5/commands/AfterAll","label":"AfterAll","docId":"commands/AfterAll","unlisted":false},{"type":"link","href":"/docs/v5/commands/AfterEach","label":"AfterEach","docId":"commands/AfterEach","unlisted":false},{"type":"link","href":"/docs/v5/commands/Assert-MockCalled","label":"Assert-MockCalled","docId":"commands/Assert-MockCalled","unlisted":false},{"type":"link","href":"/docs/v5/commands/Assert-VerifiableMock","label":"Assert-VerifiableMock","docId":"commands/Assert-VerifiableMock","unlisted":false},{"type":"link","href":"/docs/v5/commands/BeforeAll","label":"BeforeAll","docId":"commands/BeforeAll","unlisted":false},{"type":"link","href":"/docs/v5/commands/BeforeDiscovery","label":"BeforeDiscovery","docId":"commands/BeforeDiscovery","unlisted":false},{"type":"link","href":"/docs/v5/commands/BeforeEach","label":"BeforeEach","docId":"commands/BeforeEach","unlisted":false},{"type":"link","href":"/docs/v5/commands/Context","label":"Context","docId":"commands/Context","unlisted":false},{"type":"link","href":"/docs/v5/commands/ConvertTo-JUnitReport","label":"ConvertTo-JUnitReport","docId":"commands/ConvertTo-JUnitReport","unlisted":false},{"type":"link","href":"/docs/v5/commands/ConvertTo-NUnitReport","label":"ConvertTo-NUnitReport","docId":"commands/ConvertTo-NUnitReport","unlisted":false},{"type":"link","href":"/docs/v5/commands/ConvertTo-Pester4Result","label":"ConvertTo-Pester4Result","docId":"commands/ConvertTo-Pester4Result","unlisted":false},{"type":"link","href":"/docs/v5/commands/Describe","label":"Describe","docId":"commands/Describe","unlisted":false},{"type":"link","href":"/docs/v5/commands/Export-JUnitReport","label":"Export-JUnitReport","docId":"commands/Export-JUnitReport","unlisted":false},{"type":"link","href":"/docs/v5/commands/Export-NUnitReport","label":"Export-NUnitReport","docId":"commands/Export-NUnitReport","unlisted":false},{"type":"link","href":"/docs/v5/commands/Get-ShouldOperator","label":"Get-ShouldOperator","docId":"commands/Get-ShouldOperator","unlisted":false},{"type":"link","href":"/docs/v5/commands/InModuleScope","label":"InModuleScope","docId":"commands/InModuleScope","unlisted":false},{"type":"link","href":"/docs/v5/commands/Invoke-Pester","label":"Invoke-Pester","docId":"commands/Invoke-Pester","unlisted":false},{"type":"link","href":"/docs/v5/commands/It","label":"It","docId":"commands/It","unlisted":false},{"type":"link","href":"/docs/v5/commands/Mock","label":"Mock","docId":"commands/Mock","unlisted":false},{"type":"link","href":"/docs/v5/commands/New-Fixture","label":"New-Fixture","docId":"commands/New-Fixture","unlisted":false},{"type":"link","href":"/docs/v5/commands/New-MockObject","label":"New-MockObject","docId":"commands/New-MockObject","unlisted":false},{"type":"link","href":"/docs/v5/commands/New-PesterConfiguration","label":"New-PesterConfiguration","docId":"commands/New-PesterConfiguration","unlisted":false},{"type":"link","href":"/docs/v5/commands/New-PesterContainer","label":"New-PesterContainer","docId":"commands/New-PesterContainer","unlisted":false},{"type":"link","href":"/docs/v5/commands/Set-ItResult","label":"Set-ItResult","docId":"commands/Set-ItResult","unlisted":false},{"type":"link","href":"/docs/v5/commands/Should","label":"Should","docId":"commands/Should","unlisted":false}],"collapsed":false}]},"docs":{"additional-resources/articles":{"id":"additional-resources/articles","title":"Articles","description":"Published articles about using Pester for testing PowerShell code, infrastru
1cture and more","sidebar":"docs"},"additional-resources/courses":{"id":"additional-resources/courses","title":"Courses","description":"List of known courses about learning and using Pester for testing PowerShell","sidebar":"docs"},"additional-resources/misc":{"id":"additional-resources/misc","title":"Miscellaneous","description":"Integrations, books and other resources about using Pester","sidebar":"docs"},"additional-resources/projects":{"id":"additional-resources/projects","title":"Projects","description":"List of third-party modules and projects that extend or compliment Pester","sidebar":"docs"},"additional-resources/videos":{"id":"additional-resources/videos","title":"Videos","description":"List of videos about using Pester and PowerShell testing provided by the community","sidebar":"docs"},"assertions/assertions":{"id":"assertions/assertions","title":"Assertion Reference","description":"Introduction to the built-in assertion operators in Pester to get you started with the most common scenarios","sidebar":"docs"},"assertions/custom-assertions":{"id":"assertions/custom-assertions","title":"Custom Assertions","description":"A guide for creating your own custom operators for more advanced or user-specific assertion needs","sidebar":"docs"},"assertions/should-command":{"id":"assertions/should-command","title":"Should","description":"Introduction to the Should command that\'s used to define assertions that fail or pass the test","sidebar":"docs"},"commands/Add-ShouldOperator":{"id":"commands/Add-ShouldOperator","title":"Add-ShouldOperator","description":"Help for Pester command \'Add-ShouldOperator\'. Register a Should Operator with Pester","sidebar":"commands"},"commands/AfterAll":{"id":"commands/AfterAll","title":"AfterAll","description":"Help for Pester command \'AfterAll\'. Defines a series of steps to perform at the end of the current container, Context or Describe block.","sidebar":"commands"},"commands/AfterEach":{"id":"commands/AfterEach","title":"AfterEach","description":"Help for Pester command \'AfterEach\'. Defines a series of steps to perform at the end of every It block within the current Context or Describe block.","sidebar":"commands"},"commands/Assert-MockCalled":{"id":"commands/Assert-MockCalled","title":"Assert-MockCalled","description":"Help for Pester command \'Assert-MockCalled\'. Checks if a Mocked command has been called a certain number of times and throws an exception if it has not.","sidebar":"commands"},"commands/Assert-VerifiableMock":{"id":"commands/Assert-VerifiableMock","title":"Assert-VerifiableMock","description":"Help for Pester command \'Assert-VerifiableMock\'. Checks if all verifiable Mocks has been called at least once.","sidebar":"commands"},"commands/BeforeAll":{"id":"commands/BeforeAll","title":"BeforeAll","description":"Help for Pester command \'BeforeAll\'. Defines a series of steps to perform at the beginning of the current container, Context or Describe block.","sidebar":"commands"},"commands/BeforeDiscovery":{"id":"commands/BeforeDiscovery","title":"BeforeDiscovery","description":"Help for Pester command \'BeforeDiscovery\'. Runs setup code that is used during Discovery phase.","sidebar":"commands"},"commands/BeforeEach":{"id":"commands/BeforeEach","title":"BeforeEach","description":"Help for Pester command \'BeforeEach\'. Defines a series of steps to perform at the beginning of every It block within the current Context or Describe block.","sidebar":"commands"},"commands/Context":{"id":"commands/Context","title":"Context","description":"Help for Pester command \'Context\'. Provides logical grouping of It blocks within a single Describe block.","sidebar":"commands"},"commands/ConvertTo-JUnitReport":{"id":"commands/ConvertTo-JUnitReport","title":"ConvertTo-JUnitReport","description":"Help for Pester command \'ConvertTo-JUnitReport\'. Converts a Pester result-object to an JUnit-compatible XML report","sidebar":"commands"},"commands/ConvertTo-NUnitReport":{"id":"commands/ConvertTo-NUnitReport","title":"ConvertTo-NUnitReport","description":"Help for Pester command \'ConvertTo-NUnitReport\'. Converts a Pester result-object to an NUnit 2.5 or 3-compatible XML-report","sidebar":"commands"},"commands/ConvertTo-Pester4Result":{"id":"commands/ConvertTo-Pester4Result","title":"ConvertTo-Pester4Result","description":"Help for Pester command \'ConvertTo-Pester4Result\'. Converts a Pester 5 result-object to an Pester 4-compatible object","sidebar":"commands"}
1,"commands/Describe":{"id":"commands/Describe","title":"Describe","description":"Help for Pester command \'Describe\'. Creates a logical group of tests.","sidebar":"commands"},"commands/Export-JUnitReport":{"id":"commands/Export-JUnitReport","title":"Export-JUnitReport","description":"Help for Pester command \'Export-JUnitReport\'. Exports a Pester result-object to an JUnit-compatible XML-report","sidebar":"commands"},"commands/Export-NUnitReport":{"id":"commands/Export-NUnitReport","title":"Export-NUnitReport","description":"Help for Pester command \'Export-NUnitReport\'. Exports a Pester result-object to an NUnit-compatible XML-report","sidebar":"commands"},"commands/Get-ShouldOperator":{"id":"commands/Get-ShouldOperator","title":"Get-ShouldOperator","description":"Help for Pester command \'Get-ShouldOperator\'. Display the assertion operators available for use with Should.","sidebar":"commands"},"commands/InModuleScope":{"id":"commands/InModuleScope","title":"InModuleScope","description":"Help for Pester command \'InModuleScope\'. Allows you to execute parts of a test script within the scope of a PowerShell script or manifest module.","sidebar":"commands"},"commands/Invoke-Pester":{"id":"commands/Invoke-Pester","title":"Invoke-Pester","description":"Help for Pester command \'Invoke-Pester\'. Runs Pester tests","sidebar":"commands"},"commands/It":{"id":"commands/It","title":"It","description":"Help for Pester command \'It\'. Validates the results of a test inside of a Describe block.","sidebar":"commands"},"commands/Mock":{"id":"commands/Mock","title":"Mock","description":"Help for Pester command \'Mock\'. Mocks the behavior of an existing command with an alternate implementation.","sidebar":"commands"},"commands/New-Fixture":{"id":"commands/New-Fixture","title":"New-Fixture","description":"Help for Pester command \'New-Fixture\'. This function generates two scripts, one that defines a function and another one that contains its tests.","sidebar":"commands"},"commands/New-MockObject":{"id":"commands/New-MockObject","title":"New-MockObject","description":"Help for Pester command \'New-MockObject\'. This function instantiates a .NET object from a type.","sidebar":"commands"},"commands/New-PesterConfiguration":{"id":"commands/New-PesterConfiguration","title":"New-PesterConfiguration","description":"Help for Pester command \'New-PesterConfiguration\'. Creates a new PesterConfiguration object for advanced configuration of Invoke-Pester.","sidebar":"commands"},"commands/New-PesterContainer":{"id":"commands/New-PesterContainer","title":"New-PesterContainer","description":"Help for Pester command \'New-PesterContainer\'. Generates ContainerInfo-objects used as for Invoke-Pester -Container","sidebar":"commands"},"commands/Set-ItResult":{"id":"commands/Set-ItResult","title":"Set-ItResult","description":"Help for Pester command \'Set-ItResult\'. Set-ItResult is used inside the It block to explicitly set the test result","sidebar":"commands"},"commands/Should":{"id":"commands/Should","title":"Should","description":"Help for Pester command \'Should\'. Should is a keyword that is used to define an assertion inside an It block.","sidebar":"commands"},"contributing/feature-requests":{"id":"contributing/feature-requests","title":"Feature Requests","description":"How to suggest a new feature or improvement to the Pester PowerShell-module","sidebar":"docs"},"contributing/introduction":{"id":"contributing/introduction","title":"Introduction for contributors","description":"There are many ways to contribute to the Pester project and community. Check out this short introduction for how to get started","sidebar":"docs"},"contributing/pull-requests":{"id":"contributing/pull-requests","title":"Submitting Pull Requests","description":"Introduction on how to start contributing to the Pester project either by filing a bug, feature requests, support or submitting a pull request","sidebar":"docs"},"contributing/reporting-issues":{"id":"contributing/reporting-issues","title":"Reporting Issues","description":"Found an issue with Pester? Check out this guide for how to create an issue and provide us feedback so we can help you","sidebar":"docs"},"introduction/installation":{"id":"introduction/installation","title":"Installation and Update","description":"Pester is a cross-platform PowerShell module for testing your PowerShell code. Follow these steps to install or update your Pester-module to get started today","sidebar":"docs"},"migrations/breaking-changes-in-v5":{"id":"migrations/breaking-changes-in-v5","title":"Breaking changes in v5","description":"Pester v5 included an all-new runtime which lead to some breaking changes in syntax and features for existing users. See this list of breaking changes when upgrading to Pester v5","sidebar":"docs"},"migrations/v3-to-v4":{"id":"migrations/v3-to-v4","title":"Migrating from Pester v3 to v4","description":"Migration from Pester v3 to v4 may require minor changes to your test code. See this guide to get help understanding and making the necessary changes to be compatible with Pester v4","sidebar":"docs"},"migrations/v4-to-v5":{"id":"migrations/v4-to-v5","title":"Migrating from Pester v4 to v5","description":"Pester v5 introduced some fundamental changes compared with Pester v4. See this guide to get help understanding and making the necessary changes to be compatible with Pester v5","sidebar":"docs"},"quick-start":{"id":"quick-start","title":"Quick Start","description":"Get started using Pester to test your PowerShell scripts, functions and modules","sidebar":"docs"}
1,"usage/code-coverage":{"id":"usage/code-coverage","title":"Generating Code Coverage Metrics","description":"Pester can generate code coverage metrics to help you understand how many lines of your PowerShell code that is actually covered by your Pester-tests. Use this to increase confidence in your tests","sidebar":"docs"},"usage/configuration":{"id":"usage/configuration","title":"Configuration","description":"Documentation about how to configure the behavior, options and features in Pester","sidebar":"docs"},"usage/data-driven-tests":{"id":"usage/data-driven-tests","title":"Data driven tests","description":"Pester can generate tests based on data. This can range from providing multiple examples on a single `It`, to generating whole set of tests based on an external configuration file","sidebar":"docs"},"usage/discovery-and-run":{"id":"usage/discovery-and-run","title":"Discovery and Run","description":"Pester runs your test files in two phases, Discovery and Run. This introduction explains how they work and how it affects they way your structure and write your tests","sidebar":"docs"},"usage/file-placement-and-naming":{"id":"usage/file-placement-and-naming","title":"File placement and naming","description":"Tips on how to name and structure your Pester test files and categorize your tests","sidebar":"docs"},"usage/importing-tested-functions":{"id":"usage/importing-tested-functions","title":"Importing tested functions","description":"Importing your PowerShell-code is essential to being able to test it. See how to import functions from your code to make them available for your tests","sidebar":"docs"},"usage/mocking":{"id":"usage/mocking","title":"Mocking with Pester","description":"Pester provides a set of Mocking functions making it easy to fake dependencies and also to verify behavior. Using these mocking functions can allow you to \\"shim\\" a data layer or mock other complex functions that already have their own tests","sidebar":"docs"},"usage/modules":{"id":"usage/modules","title":"Unit Testing within Modules","description":"PowerShell code in modules run in their own module state. This requires special attention when writing tests for internal functions or when mocking dependencies used by code in a module","sidebar":"docs"},"usage/output":{"id":"usage/output","title":"Output","description":"Pester uses customizable console output to show tests results, errors and summary. See how you can customize this output to fit your preference","sidebar":"docs"},"usage/setup-and-teardown":{"id":"usage/setup-and-teardown","title":"Setup and teardown","description":"Pester offers multiple ways to run code before, and after your tests to set them up, and clean up after them","sidebar":"docs"},"usage/skip":{"id":"usage/skip","title":"Skip","description":"Skipping tests can be useful in many scenarios or when certain conditions are not met like OS-compatibility. Read about how to control this in Pester tests","sidebar":"docs"},"usage/tags":{"id":"usage/tags","title":"Tags","description":"Use tags on tests and blocks to categorize code and easily choose which tests to run with simple parameters","sidebar":"docs"},"usage/test-file-structure":{"id":"usage/test-file-structure","title":"Test file structure","description":"Pester uses special keywords and blocks to structure your tests like Describe, Context, It, BeforeAll/-Each etc. See this to learn how they relate and fit together","sidebar":"docs"},"usage/test-results":{"id":"usage/test-results","title":"Showing Test Results in CI","description":"Pester can output tests results to NUnit and JUnit XML reports that can be consumed by test reporting tools and CI-solutions","sidebar":"docs"},"usage/testdrive":{"id":"usage/testdrive","title":"Isolating File Operations using the TestDrive","description":"TestDrive is a PowerShell PSDrive where you can create temporary files used in your tests that are automatically cleaned up after your tests are finished","sidebar":"docs"},"usage/testregistry":{"id":"usage/testregistry","title":"Isolating Windows Registry Operations using the TestRegistry","description":"TestRegistry is a PowerShell PSDrive (Windows only) to help your store temporary values used in your tests in the Windows Registry that are automatically cleaned up after your tests are finished","sidebar":"docs"}
1,"usage/troubleshooting":{"id":"usage/troubleshooting","title":"Troubleshooting","description":"Introduction to useful logging for troubleshooting your tests or Pester itself","sidebar":"docs"},"usage/vscode":{"id":"usage/vscode","title":"Visual Studio Code","description":"See how Visual Studio Code and its extensions helps you run and debug your Pester tests directly inside the editor","sidebar":"docs"}}}}')}}]);
Line numbers count LF bytes from the start of the resource, as the search results do. Vendor segments are library code the classifier recognised; they are stored but not indexed. Bytes are shown as Latin1 characters, one per byte.