~/talk

PowerShell Unit and Infrastructure Testing

Talkat PowerShell + DevOps Global Summit 2024 · 2024-04-08..04-11· [testing]
slides:none on file

Shows concrete, runnable work: Pester 4→5 breaks scoping and forces fixes; demos mock of Invoke‑RestMethod to fake an external IP and verify get‑IP logic; explains beforeEach vs beforeAll scope bugs and why tests must be atomic; uses VS Code Pester Test extension for watch, debug and detailed output; runs real tests against a 2,165‑line module (modulefast), finds a flaky AZ dependency count and trims runtime to ~2.5s. Tests pass or fail with exact expected vs actual output so regressions are visible.

AI-written summary · about

  1. 0:00PowerShell testing with Pester
  2. 2:14Why testing matters
  3. 10:13Pester basics and DSL
  4. 1:01:34Running basic Pester tests
  5. 1:31:50Mocking dependencies
  6. 2:11:50VS Code extension for testing
  7. 2:43:48Advanced Pester features
  8. 3:01:30Q&A
~/search
type to search 6,249 conferences, 138,987 speakers and 185,172 talks
~/help
cmdctrl k
search every conference, speaker and series
/
focus the filter search
h
home
c
conferences
s
speakers
e
series
t
light / dark — the status bar button does the same
?
this help
esc
close this, then clear every filter — or just the search, while you are typing in it

Ignored while you are typing. Pages without a filter rail have no search to focus.