Episode 159 - Property-Based Testing & Authorization in APIs
About this episode
Chris and Desmond are back! In this episode we talk about Desmond’s exploration into Property-Based testing, and then do a deep dive into authorization and access control in Chris’ GraphQL API.
Property-based testing is a new world for both of us, but we do our best to tell you all about what libraries to use and how we’re thinking of using it.
Chris is deep in some reworking of the authorization code in his GraphQL API and we go into depth talking about how it is structured, some of the challenges of building a flexible authorization system and then how this integrates back into a system.
After talking about authorization we then go into validation of parameters in our APIs and how we think about typing and validating them at the boundaries, and in our Ecto Schemas.
Links
- EMPEX LA (https://empex.co/la)
- StreamData Library for property testing (https://github.com/whatyouhide/stream_data)
- PropEr (https://github.com/proper-testing/proper)
- PropSchema (https://github.com/podium/prop_schema)
- Property-Based Testing with PropEr (https://pragprog.com/book/fhproper/property-based-testing-with-proper-erlang-and-elixir)
- StreamData: Property-based testing and data generation for Elixir (https://elixir-lang.org/blog/2017/10/31/stream-data-property-based-testing-and-data-generation-for-elixir/)
- Canada Library (https://github.com/jarednorman/canada)
- GraphQL Scalar Types in Absinthe (https://hexdocs.pm/absinthe/custom-scalars.html)
- JSON Schema in Elixir (https://github.com/jonasschmidt/ex_json_schema)
- API versioning at Stripe (https://stripe.com/blog/api-versioning)
More from Elixir Talk
Episode 166 - Elixir at Boulevard w/ Sean Stavropoulos We're back after a hiatus on our irregularly posted podcast! Chris and Desmond are back in the hot seat, this time joined by CTO and co-founder a…
Episode 165 - José Valim on Bytepack, Open Source, and LiveView changes in Phoenix 1.5 Chris and Desmond are backed by a very special guest; José Valim! You might know José as the creator of the Elixi…
We’re back with another episode of ElixirTalk. In this episode Chris & Desmond do a deep dive on organizing code in Elixir and talk about some best practices. We recorded this a couple weeks ago so it…
We’re back with a recap with another episode of ElixirTalk. In this episode we cover quite a few topics; an EMPEX LA recap, a foray into project management tools that we like and use (!), and then we…
Episode 162 - Designing Elixir Systems with Bruce Tate It's another episode of ElixirTalk, this time Chris and Desmond are joined by the one and only Bruce Tate author of many notable titles such as P…