Simplify the _LEGACY_TEST check.