There are a number of problems with layout tests which require different device types. Currently, iOS Simulator test runs handle this by running the test suite first with 5s devices, then with iPads and then with iPhone 7s. This is super inefficient since we boot up an entire new queue of devices (on our bots, this means 12 devices) to run maybe a half-dozen to two-dozen tests. When running layout tests on actual iOS devices, the problem is even worse. Currently, we need to skip any device specific test no mater what type of device is connected. We need to re-factor the way we handle these types of tests.
Gardened test for on-device testing in <https://trac.webkit.org/changeset/221188/webkit>.
We implemented this when implementing better support for iPad testing.