gd,
@gd@ruby.social avatar

It's so annoying to see developers calling failing tests "flaky".

Last week I found a factory that assigned a random age to a user instance, so no wonder a test that used the age in some bit of logic failed sometimes. That's not a "flaky test", that's a bug in the factory.

Today I saw a date parser bug be called a "flaky test". It was written on the 21st of April and worked fine until it began to fail today, the 1st of May.

gd,
@gd@ruby.social avatar

"Flaky test" makes it sound like RSpec is at fault when it's almost always buggy code, or random factory data.

penryu,
@penryu@hachyderm.io avatar

@gd Yeah, "flaky test" is almost always a euphemism for "a bug that hides briefly if we run the tests enough."

zenspider,
@zenspider@ruby.social avatar

@penryu @gd hides briefly is generally great. Hides 99% of the time is a real pain.

penryu,
@penryu@hachyderm.io avatar

@zenspider @gd inability to repro definitely adds a dimension of difficulty. In some ways I found "briefly hidden" flaky test bugs more frustrating because they were fairly easy to reproduce, but led people to just rerun the tests a few times until they pass, rather than fix the underlying bugs.

  • All
  • Subscribed
  • Moderated
  • Favorites
  • ruby
  • mdbf
  • DreamBathrooms
  • thenastyranch
  • ngwrru68w68
  • tacticalgear
  • magazineikmin
  • Youngstown
  • khanakhh
  • rosin
  • slotface
  • InstantRegret
  • everett
  • kavyap
  • cubers
  • megavids
  • GTA5RPClips
  • cisconetworking
  • modclub
  • ethstaker
  • osvaldo12
  • Durango
  • normalnudes
  • tester
  • provamag3
  • Leos
  • anitta
  • JUstTest
  • lostlight
  • All magazines