wroclove.rb 2026 lightning talk with a three-lightning-talks framing. The first planned talk was abandoned — the speaker's intended material was a story about accidentally running `rm -rf` on their home directory while uninstalling Docker Desktop (missing quotes + a stray space) with no Time Machine backup. Pivoted to a second topic: testing code that depends on Rails.env, specifically branches gated on Rails.env.development? that normally can't run inside the test environment. Shows two helpers. In minitest, using stub_any_instance, a stub_environment(:development) block stubs Rails.env.development? to true and both .test? and .production? to false (and vice versa for :production), letting tests assert predicates and actually exercise the branch. In RSpec, a similar helper using RSpec mocks with temporary message-scoping and around-example hooks achieves the same result, though it measurably slows down the affected tests — likely because test-environment optimizations are bypassed when the Rails.env predicates are stubbed.