The other issue is that there are layers of other skills that also evolve every few years.
So to create a "bar exam" for a front-end web engineer, for example, you would need a completely different version every two years or so.
But then probably a bigger problem is that software engineering requires certain types of problem solving and to get a realistic idea of problem solving abilities of a person at large enough scale problems you would need a huge investment into the testing infrastructure and varied content. You would need sophisticated programs to test the applicants programs. And people to review code. And those tests would quickly go out of date.
Then the other thing is that there is so much variation in the types of languages or frameworks or tools used, it is questionable whether it is meaningful to test on some lowest-common-denominator set of tools at all, if you could find enough agreement on such a thing (e.g. Angular vs React, React vs Vue).