home.social

#mockists — Public Fediverse posts

Live and recent posts from across the Fediverse tagged #mockists, aggregated by home.social.

fetched live
  1. I'm not trying to pick on #mockists, but as I point out in this #StackOverflow comment, mocks, #testdoubles, and stubbed methods don't always add value. In addition, this approach requires the rspec-mocks gem in addition to #RSpec core and expectations to create an RSpec::Mocks::Double, plus `allow(dbl).to receive` just to `expect(dbl).to receive`.

    This is a layer of overhead and test indirection that is often unnecessary IMHO. YMMV, but it's often worth rethinking.

    stackoverflow.com/questions/78

  2. I'm not trying to pick on #mockists, but as I point out in this #StackOverflow comment, mocks, #testdoubles, and stubbed methods don't always add value. In addition, this approach requires the rspec-mocks gem in addition to #RSpec core and expectations to create an RSpec::Mocks::Double, plus `allow(dbl).to receive` just to `expect(dbl).to receive`.

    This is a layer of overhead and test indirection that is often unnecessary IMHO. YMMV, but it's often worth rethinking.

    stackoverflow.com/questions/78

  3. Test #mockists don't like it when you point out that they're suffering from self-inflicted X/Y problems. They think mocking objects tests something useful, but it almost never does. The only reason to use mocks and stubs is to *isolate* the object under test from irrelevant or expensive calls to collaborators or outside systems, or to return a predefined result. You can never convince such people that it's a fallacious solution to a non-problem, though.

    stackoverflow.com/q/78265716/1

  4. Test #mockists don't like it when you point out that they're suffering from self-inflicted X/Y problems. They think mocking objects tests something useful, but it almost never does. The only reason to use mocks and stubs is to *isolate* the object under test from irrelevant or expensive calls to collaborators or outside systems, or to return a predefined result. You can never convince such people that it's a fallacious solution to a non-problem, though.

    stackoverflow.com/q/78265716/1