Ruby Conf 12 - Boundaries by Gary Bernhardt

Channel:Confreaks · Length:45:55 · Published:2012-11-25 · Views:58205

Watch on YouTube

Summary

Gary Bernhardt's RubyConf 2012 talk on testing in isolation without mocking everything. It goes through behavior versus data, mutation versus immutability, and how a functional core with an imperative shell yields natural isolation and parallelism.

Why HN recommends it

HN recommends it as the canonical presentation of 'functional core, imperative shell' and a practical answer to unit versus integration testing.

I highly recommend this video for a more philosophical take on how to do "impure FP" without OO — HN, 2020

Functional programming · Software architecture & design · Testing, debugging & developer tools

Subtitles (excerpt)

The title of this talk is boundaries. Uh this is the only one-word talk title at this conference which I'm very proud of. The next shortest is three words. Thank you. Um this is uh some of the stuff in this talk is going to be very familiar to anyone who comes from certain functional programming backgrounds but um this is a story of me approaching some ideas that they have from a very different direction and from a very different history. So uh I am Gary Burnernheart. I look like look like this on the internet where sometimes I get mad and uh my Bluetooth is not working very well. I might have to forego it. I own a company called Destroy All Software that produces screencasts on various advanced software development topics. And to start us off in this talk, we're going to to start with test doubles. Uh there are a couple talks about test doubles mocking and stubbing at this conference. This is not a talk about test doubles, but they are going to be part of my motivation. U just to make sure everyone's on the same page, let's go through a quick example of what an isolated unit test might look like. I have a sweeper class. This is in some kind of recurring billing situation. And if I have a user who has subscribed but has not paid in the last month, I want

On Hacker News

A few years ago I was on a team and the dev lead had a practice of sharing Gary Bernhardt's Boundaries talk every time there was some degree of rotation or churn on the team. Almost part of the onboarding. As a functional programming aficionado, I didn't need the sales pitch, but it was the presentation that was gripping. Keep in mind, Ruby isn't a functional language, but here was this presenter… — AaronFriel, 2020-10
> I find some problems are solved better in an OO way such as interacting with a relational database. I've switched to functional interactions with a database, (Elixir/Ecto) and really, it's much better. In particular the explicit and declarative nature of the database interactions combines the convenience of an ORM with "not hiding important gotchas from you". I'm not arguing for pure functional… — dnautics, 2020-03
if you are a rubyist, I can't more strongly recommend watching this video, which has nothing to do directly with Elixir (in fact it precedes elixir by a couple of years) but if the topics that Bernhart (of wat fame) brings up resonate with you, then you will really like Elixir. [VIDEO] — dnautics, 2020-01
Here is the infamous Nagappan TDD paper from Microsoft Research [LINK] Also discussed in this infoq article [LINK] Here's someone's thesis paper on it, with data: [LINK] There's also interesting discussions like this [LINK] "it is my experience that the value proposition for TDD grows exponentially as the time and resources involved in a project grows linearly." This has also been my own experien… — pmarreck, 2016-04
> Jose has really thread a needle with Elixir I feel. There was kind of something in the zeitgeist ready for this... This was a video by Gary Bernhardt in 2012 (that's like, Elixir -2 years?). I've queued it up to where he talks about basically wanting to go live on a cruise ship, fork rubinius, and rebuild ruby on top of erlang. The main chunk of the talk is about the software pattern that Phoen… — dnautics, 2021-06

Related videos