~/talk

DI Containers in NUnit Tests

TalkinRussianat DotNext 2023 · 2023-09-15..09-16· [testing, dotnet]
links:none on file
slides:none on file

The talk examines using dependency-injection (DI) containers inside NUnit tests to address common test-code issues: hard-to-read and hard-to-refactor test code, lack of parallelizability, expensive shared setup, and confusing test context caused by SetUp methods and inheritance. It demonstrates applying standard coding and DI practices to improve test readability, enable parallel execution, reduce unnecessary preparation work, and clarify each test’s execution context.

AI-written summary · about

  1. 0:00Introduction
  2. 1:26About the talk
  3. 2:31Unit testing practices
  4. 10:01Setup attribute problems
  5. 13:31Test code best practices
  6. 15:41Fixing setup attributes
  7. 19:21Inheritance to delegation
  8. 21:28DI containers in tests
  9. 25:20Refactoring tests
  10. 32:52Advanced DI features
  11. 35:25Pitfalls and tips
  12. 39:22Pros and cons
  13. 40:49xUnit comparison
  14. 44:46Q&A
~/search
type to search 8,222 conferences, 162,397 speakers and 219,688 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
← →
on a talk: 5 seconds back / forward
0–9
on a talk: jump to 0%–90% of the recording
?
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.