Agreed. This idea could only by put forth by someone who has never had to do the work involved in hiring a software engineer.
I definitely believe you can get away with no coding questions like this for smaller organizations. But once you get to a big enough scale, all the other methods have too many issues (e.g. a large class of hiring methods which essentially skip anyone who currently has a job - trial periods). You can't afford to limit your hiring pool too much when you're big enough.