~/talk

Writing test driven apps with http4k

Talkat Joker 2020 · 2020-11-25..11-28· [testing, kotlin]
links:none on file
links:none on file
slides:none on file

http4k is a Kotlin library that models servers and clients as the same function so tests run in-memory http handler tests at ~8ms instead of ~150ms over the network. Example builds: a routed app, an atomic Integer call-counter implemented as a Filter, JSON marshalling via JSON lenses, and a fake dictionary HTTP handler used for contract tests and failure injection. All pieces compose as handlers so tests stay fast, deterministic, and reusable across unit and integration contexts.

AI-written summary · about

  1. 0:00Introduction
  2. 3:52Overview
  3. 8:43What is http4k
  4. 11:08App overview
  5. 12:02Prerecorded coding
  6. 12:22Creating a test
  7. 13:13Creating a request
  8. 18:34Creating a second test
  9. 21:31Crosscutting middleware
  10. 22:22Filters
  11. 24:22Call counter filter
  12. 29:54Reuse test code
  13. 37:11Testing the analyzer
  14. 40:36Introducing the lens
  15. 47:36Introducing the dictionary
  16. 53:14Building a fake dictionary
~/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.