Chapter 22Building Test Data with Elixir
by Bruce Tate
In Chapter 21, A Testing Framework for Elixir, I described a new unit and functional test framework we’ve built. In this article, I’ll describe how we use macros to build fake test data.
At icanmakeitbetter, Elixir has made a huge difference. Because it is a functional language that fully supports concurrency and distribution, we are able to get much more performance out of our website. Elixir is also one of the first languages to support both a higher-level syntax and macros, and I’m going to talk about putting those features to good use to build beautiful test data.
Yes, I said beautiful.
Business applications need business data, and tests for those applications need fake data. ...
Become an O’Reilly member and get unlimited access to this title plus top books and audiobooks from O’Reilly and nearly 200 top publishers, thousands of courses curated by job role, 150+ live events each month,
and much more.
Read now
Unlock full access