Also, use TargetPlatform since it it better suited for tests (and seems to be now the recommended way of checking this for UI elements)