• (nodebb)

    https://thedailywtf.com/articles/The_Brillant_Paula_Bean

  • (nodebb)

    Apparently someone planned to inject a CensusDao int the bean, but then decided it's not needed and forgot to remove the setter.

  • Richard Brantley (unregistered)

    The unit tests will continue as long as bad copy/paste gets into the code.

  • (nodebb)

    I suppose it could have been worse if they decided to return a value...

  • Duke of New York (unregistered)

    Dependency inception: Your bean is the scene of the WTF.

  • Erwin (unregistered)

    The unit tests are created by copy/paste as well.

  • (nodebb)

    But it works in the one-off case where CensusDao.BEAN_NAME==reportDatesDao, and if you use that as the only test then unit tests will pass.

    This is, indeed, Brillant!!

Leave a comment on “Using the Old Bean”

Log In or post as a guest

Replying to comment #:

« Return to Article