The answer is NO! Unequivocally, NO. Just No.
Look, I'm not saying this is an easy topic. Here, just a couple reddit posts and a ycombinator post and read some of the comments.
One thing you cannot tell me is that this topic is not polarizing. It absolutely is.
Let me see if I can explain a view that I don't think has truly been addressed. To get there, let's work through some of the arguments.
I've been in the "employer" shoes. As a developer, I've also had the opportunity to work with a great deal of awesome developers. As well as some less than stellar ones.
If you get a developer on board who is either extremely inexperienced but somehow "duped" you into thinking they were more experienced OR someone who maybe has the experience but just really doesn't care about their job (it's just a paycheck) OR (and God forbid) you get someone who's in both sides of the spectrum...
I don't need to spell any of that out.
The number of hours that get sunk and lost can be innumerable if you have a developer who doesn't care about their job. Look, I'm not saying be a super passionate developer evangelist who does it day in and day out every single waking moment of their life. I'm saying, CARE. Care enough to try and be good at your job during the hours in which you are being paid to be good at your job.
Where did that sense of honest ethical workmanship go?
I've diverged. The point is, as an employer, having experienced developers of these sorts, I know the cost it takes on the colleagues and the company. Hours lost means money lost. There's also a demoralizing factor to that.
Of course, the biggest price for any company to pay is failure to exist anymore. It takes only one person to deceive or not care enough to create that scenario. Just as one person has the power to make incredible and positive change.
To this point, therefore, I am not shocked that employers ask you to complete a quiz or a code challenge so you can at least prove you know something about what you're applying for. I totally understand that.
I'm a dad. Fresh. A few months old now. I have very little time. So let's do some math here.
Imagine yourself in a job where that job is no longer sustainable, for you, maybe because the company is going under or because you're going to get fired or maybe you just hate your job. Doesn't matter. You're exiting.
Time to go look for work!
So you decide to play the numbers game. The more places you apply to, the better your chances of getting into one of those places, and you are fully aware of quality vs quantity. That means you're not just going to robo-market yourself to everywhere. You will take the time to read job postings and listen to what's being asked from recruiters but you will also make sacrifices of your time to apply for as many places as you can.
That's a great start.
So you start applying.
What happens next? Some interest! Finally. So you get asked to do a test. You've got 48 hours to accomplish it and the test usually takes somewhere around 2 - 5 hours.
Cool, your first test. You sit down and crank it out in a night because you're so pumped and hopeful. You submit it. Now you have to wait for the review.
The next day, another person shows interest. Things are starting to pick up now. You get asked to do another test. This one has 3 days to complete it and, again, 2 - 5 hours to accomplish it.
The day after that you get TWO people who are interested and one asks for a 5 hours test and another for a 2 hour test but you have to do the 2 hour test right away. That same day, the first company you applied for would like a one hour call with you to discuss your test submission and chat with you about the technical reasons you chose to do it.
Ok it's a bit of a crazy day, you have to do all this while still managing to be productive at your normal job, if you can manage that. Doable. Not the best scenario, but doable.
Keep going, man.
What does the end of your week look like? Between the tests and interviews and maybe you're doing multiple interviews and maybe you get flown down somewhere for in person interviews. Do you know how much time you spend in a month doing tests? Let's take just the tests.
Let's say you did 3 tests a week, each taking you approximately 2 hours, and you did that for a month. 4 weeks in a month and each week had 6 hours worth of tests. That's 24 hours of tests. That means you've now given over 3 full business days of FREE work.
Let's say you make around 3,000 a month. Let's say 20 approximate working days in a month. That's about 150 bucks a day. Pre-tax.
You've thrown away 450 dollars of YOUR time.
That's not to include time with the regular interviews, chatting with a tech team to present your solution like you're some kind of a puppet who puts on a show, time taken to prepare your presentation, and so on and so on and so on.
The last time I checked, the way capitalism works is that there is an exchange of something between two parties, typically where one gives you money that puts a value on something you offer in return. An exchange of goods, if you will.
If a company paid me 450 dollars, they'd damn sure expect something back, and rightfully so.
What can YOU expect from a company back when YOU spend YOUR money on them? Are you guaranteed to get the job at the end? Absolutely not. If anything, and I've experienced this, you might submit your test, a better candidate (so to speak) comes along and they fail your test based on some stupid and arbitrary point so they can disqualify you without feeling bad that they wasted your time so they could hold out for that someone better.
If you're someone like me and you don't even have the time to do a 2 hour test, you're missing out on potentially a good developer with lots of experience who won't bother to do your stupid test. Then you can sit there and complain about a shortage of good talent.
Look, here's the way I see it. Employers are trying to answer the WRONG question. Developers are answering the WRONG question when they accept these tests.
What's more, developers are very much part of the problem. The developers who don't care or who lie, in particular, or maybe have grand delusions that with minimal effort they deserve riches, and there are plenty of those around, they're all part of the problem.
Employers are trying to answer the question of "How do we ensure we hire the best developers we can possibly get that fit in our company and have the skills we want?" with the answer: technical tests.
The right question is: "How do we make sure that as many developers as possible have the training and qualifications they need to be productive in ANY company? Anywhere. Ever."
In other words, what the hell is wrong with the developer ecosystem that produces such disparate polarities of developer quality that employers feel it necessary to make us ALL jump through a dog and pony show of hoops just to have the OPPORTUNITY to be considered for an opportunity?
Why don't we fix the ecosystem itself? Instead of trying to apply more and more rules and, thereby, pissing off the developers who have always played fair and who have cared deeply about their craft to the point where they don't want to play the game anymore either? How does that solve anything at all?
Stop accepting technical tests. Stop asking for them too. Developers need to be made responsible for their willing inadequacies and the threat of being fired or let go or not getting that promotion can be great inducers. Companies need to treat developers with respect, too, invest in them a bit, treat them like human beings instead of code churning machines with a computerized brain full of all kinds of knowledge that no average person can reasonably maintain.
How do we solve the underlying problems here? Better training for everyone. Better training for developers (I don't believe bootcamps are the answer) and better training for organizations so they understand that world enough to make some informed decisions.
Those are topics for a different post.