Fixed #23707 -- Prevented discovery of duplicated tests