Is it possible to obtain a bachelor's degree by passing some test to prove equivalent knowledge rather than attending a university? Is it possible to obtain a bachelor's degree without attending a university? I'm talking about passing some kind of test or series of tests to prove my knowledge. I'm not asking about buying a fake degree or anything related to that. Is there a name for this type of procedure/way of obtaining a degree? Is it practiced in the US? If yes, is it possible for non-US citizens to pass these tests? If not, are there any countries that practice something like this?
In general, no, it is not possible to get a bachelor's degree from an accredited university in the US purely through examinations.

It is possible to get course credits that can partially satisfy graduation requirements through tests such as those administered as part of the Advanced Placement or International Baccalaureate programs. However, these normally tend to be restricted to satisfying general education requirements, rather than the in-depth major requirements.