Now that Puma is the recommended web server for Rails on Heroku, they are warning of the dangers of using non-threadsafe code.
How do you test a Rails app for thread safety?
You generally test thread safety by assigning and verifying the value of a variable. In a rspec:
Expected: both variable have different values