# Ruby Conf 12 - Boundaries by Gary Bernhardt

> For agents: start with the [agent guide](https://ratstack.sh/llms.txt). Every page is Markdown by default; add `Accept: text/html` for HTML.

[Confreaks](https://www.youtube.com/@Confreaks) · Published 2012-11-25 · 45:55 · B tier · Systems thinking

[Watch on YouTube](https://www.youtube.com/watch?v=yTkzNHF6rMs) · [All RatTube videos](/tube)

## Summary

Gary Bernhardt explores boundaries between logic and the outside world. A [functional core](/lore/pure-cores-reduce-timelines) handles decisions with values, while an imperative shell connects those decisions to dependencies and side effects.

He relates those boundaries to [testing](/lore/testing-ladder): isolated tests cover the core's many paths, while integration tests check the shell's connections. Larger applications can contain many small core-and-shell systems rather than one enormous core surrounded by one shell.

## Section notes

- [1:16](https://www.youtube.com/watch?v=yTkzNHF6rMs\&t=76s): A billing example introduces isolated tests and stubbed dependencies.
- [7:50](https://www.youtube.com/watch?v=yTkzNHF6rMs\&t=470s): The discussion shifts from isolated testing to values.
- [15:45](https://www.youtube.com/watch?v=yTkzNHF6rMs\&t=945s): Logic with few dependencies suits unit tests; a shell with few paths suits integration tests.
- [23:51](https://www.youtube.com/watch?v=yTkzNHF6rMs\&t=1431s): Large systems can be composed from several smaller core-and-shell units.
- [32:24](https://www.youtube.com/watch?v=yTkzNHF6rMs\&t=1944s): The implementation demonstration compares the functional module with its imperative shell.

## Key concepts

- [functional core](/lore/pure-cores-reduce-timelines)
- [testing](/lore/testing-ladder)

## Our take

Gary Bernhardt starts from isolated unit tests and works toward a design that makes isolation natural: a functional core of values, wrapped in a thin imperative shell that talks to the outside world.

## Related videos

- [The Value of Values with Rich Hickey](/tube/value-of-values-rich-hickey)
- ["Simple Made Easy" - Rich Hickey (2011)](/tube/simple-made-easy-rich-hickey-2011)
- [John Hughes - Testing the Hard Stuff and Staying Sane](/tube/testing-hard-stuff-john-hughes)
- [John Hughes - How to specify it! A guide to writing properties of pure functions | Code Mesh LDN 19](/tube/how-to-specify-pure-function-properties)

Summary based on the transcript. Written 2026-11-15.
