Ok, but there's no uniform grading in school or employment. We all know people who managed to get through university without learning anything and manage to hold a job in software development without knowing or doing anything. It'd be nice if a degree and a job history guaranteed competence, but it doesn't.
Lots of professions can bring a portfolio and/or a sample of their work, but most software developers can't because the work is often propriatary and a trade secret, and anyway would need a lot of specific setup to operate.
I've only taken test tests for government jobs, and they were laughably outdated; approximately nobody knew how much space was on a 5 1/4" floppy in 1998 when I took the test, but they were asking about 8" floppies, and I assume they still are, because the test had to go through some process and doing a new test would be expensive. But yeah, I expect a company to validate that I can both describe solutions to problems and turn that description into code.