Re:Cucumber: BDD Testing and Collaboration Tools
by ljm on Wednesday July 19, 2023 @04:18PM
(#36792591)
“If done right” is carrying a lot of weight there.
I don’t mind it if you use cucumber and it still serves the purpose of describing your code’s behaviour, so the output is readable. RSpec’s documentation is a nice example of that.
The problem is if people just use it as a syntax over a webdriver, which means that your test behaviour and logic is arbitrarily split into two different languages, the cucumber output is useless, the tests are needlessly slow, and it’s really hard to debug. Cucumber itself is not able to add value there.
But that’s not unique to cucumber either. I don’t think many people realise that test writing and architecture is its own skill in programming and so many suites turn into write-only cludges that take 12 hours to run on a cluster of 50 CI workers.
I don’t mind it if you use cucumber and it still serves the purpose of describing your code’s behaviour, so the output is readable. RSpec’s documentation is a nice example of that.
The problem is if people just use it as a syntax over a webdriver, which means that your test behaviour and logic is arbitrarily split into two different languages, the cucumber output is useless, the tests are needlessly slow, and it’s really hard to debug. Cucumber itself is not able to add value there.
But that’s not unique to cucumber either. I don’t think many people realise that test writing and architecture is its own skill in programming and so many suites turn into write-only cludges that take 12 hours to run on a cluster of 50 CI workers.