What do you mean by "discriminatory"? Any criteria you might choose is discriminatory, we could check by IQ or by school marks or by emotional intelligence or by sums of money payed or by any other criteria, at the end someone will get in and someone else not.
You assume that just some test criteria is the only criteria that matters but why? Who said that someone with the best marks in some specific test deserve a place more than someone with lower marks? It is an indicator for ability for sure but guess what, genetics is also a very good indicator and social standings of the family is also a very good indicators and there are many other factors or correlation we could use. There is no "fair", it is only criteria and schools should be able to choose whatever criteria they want, even if they choose to bring in the most stupidest student if they feel like it.