I find the idea intriguing, but I just don’t see how it would work.
For starters, who would design such a test, and what guarantee would we have that it would be based on core American values when our own people can’t even agree on what those values are or ought to be?
Second, what’s to keep would-be immigrants from simply giving us the appropriate answers? Even the ones who are either too dumb or too culturally isolated to figure it out themselves could be coached on how to answer. And there are people both inside and outside this country who would be all too glad to help them defeat such a system.