Your New Team Writes the Tests First and You Have Never Worked That Way
In your first pairing session on the new team, your colleague opens an empty test file before touching any code. They write a test for something that does not exist yet, run it, watch it fail, and look pleased. Then they write just enough code to make it pass, and do it again. You have written tests for years, but always afterwards. This feels backwards, and a little slow.
You will be tempted to decide quickly whether you like it. Many developers have strong opinions about writing tests first, and plenty of them formed those opinions in an afternoon. Try not to join them yet. A way of working that feels awkward in the first week tells you very little about whether it is useful. Most new habits feel worse than old ones at the start, simply because the old ones are familiar.
So give it an honest trial with a clear end. Agree with yourself that for the next month you will do it properly, the way this team does it, and only then make up your mind. A month is long enough to get past the clumsiness and short enough that you will actually keep the promise.
Learn it from the people who do it well, not from arguments online. Pair with the colleague who seems most fluent and ask them to think out loud. How small is the first test? How do they decide what to test next? What do they do when they are not sure what the code should look like yet? You will learn more from watching someone take tiny steps than from any article.
Start with work that suits it. A function with clear inputs and outputs is a good place to practise. A screen layout or an exploratory spike may not be, and good practitioners will usually tell you so.
Notice what changes. Are you debugging less? Do you think about the shape of the code earlier? Is it harder to write something that cannot be tested? Write a few notes each week so your judgement at the end is based on evidence.
At the end of the month you may love it or you may use it only sometimes. Either answer is fine. What matters is that you earned it.
– Asael Shinder