title: How to exclude Paths in the Pester configuration?
body: <p>We have a directory structure of modules like the following:</p>
  <pre><code>C:\Program Files\WindowsPowerShell\Modules\Toolbox.CustomModule1
  C:\Program Files\WindowsPowerShell\Modules\Toolbox.CustomModule2
  C:\Program Files\WindowsPowerShell\Modules\ModuleDownloaded
  C:\Program Files\WindowsPowerShell\Modules\ModuleDownloadedOther
  </code></pre>
  <p>All PowerShell modules starting with 'Toolbox.' are the ones we created and are the only ones that need to be tested with Pester 5. I was hoping it would be possible to use a wildcard:</p>
  <pre><code>$config = [PesterConfiguration]@{
      Run = @{
          Path = &quot;C:\Program Files\WindowsPowerShell\Modules\Toolbox.*&quot;
      }
  }
  Invoke-Pester -Configuration $config
  </code></pre>
  <p>But the above fails because wildcards are not supported in <code>Path</code>. Using only <code>C:\Program Files\WindowsPowerShell\Modules</code> fails too due to downloaded modules that are not compatible with Pester 5. So hunting down the documentation I stumbled upon this:</p>
  <pre><code>$test = [PesterConfiguration]::Default
  $test.Filter | Format-List
  </code></pre>
  <blockquote>
  <p>Tag        : Tags of Describe, Context or It to be run. (System.String[], default: System.String[])
  ExcludeTag : Tags of Describe, Context or It to be excluded from the run. (System.String[], default: System.String[])
  Line       : Filter by file and scriptblock start line, useful to run parsed tests programatically to avoid problems with expanded names. Example: 'C:\tests\file1.Tests.ps1:37' (System.String[],
  default: System.String[])
  FullName   : Full name of test with -like wildcards, joined by dot. Example: '*.describe Get-Item.test1' (System.String[], default: System.String[])</p>
  </blockquote>
  <p>But that doesn't seem to talk about full file names. Is there a simple way to do this (instead of a simple <code>foreach</code> but from within the <code>PesterConfiguration</code> itself?</p>