The Agile Way — Practical Automated E2E Testing

The Agile Way — Practical Automated E2E Testing

Why Auto-Retry of Test Execution in a Test Framework is Wrong?

Auto-Retry shall be done at CT server, not messing up with the test scripts.

Zhimin Zhan's avatar
Zhimin Zhan
Nov 13, 2022
∙ Paid

Recently, I noticed the ‘Auto-Retry’ feature in some ‘new test frameworks’, such as Jest and Cypress. It is wrong! I pioneered (and implemented) the ‘auto-retry’ back in 2007 and have been using it ever since. The difference is that my ‘Auto-Retry’ is in the Continuous Testing Server, not the automation or syntax framework. BuildWise, the CT server I created with the Auto-Retry feature, received Ruby Award from Matz (the creator of Ruby, a true software legend).

“Infrastructure failures get retried” — from an excellent CI presentation “CI at Facebook”

Let’s see a sample ‘auto-retry’ syntax in the Jest test framework:

jest.retryTimes(3) //set maximum retries number

describe('Test', () => {
    test('Test_Test', async () => {
        //test code
        ...
    })
})

First of all, I am sure most will agree that adding retryTimesto a test framework does not sound ‘right’. Still, why is it bad?

1. It does not address the root problem.

User's avatar

Continue reading this post for free, courtesy of Zhimin Zhan.

Or purchase a paid subscription.
© 2026 Zhimin Zhan · Privacy ∙ Terms ∙ Collection notice
Start your SubstackGet the app
Substack is the home for great culture