Device actions
Set Orientation
Rotates the screen — and tells you whether the app actually allowed it.
device.orientation
The piece
Rotate the screen. Only apps that support the orientation actually rotate — the home screen and portrait-locked apps stay as they are; the step reports whether it took.
Reach for it when
- Checking a landscape layout.
- Reproducing a bug that only happens on rotation.
Set Orientation
Idle
In the bag
Every setting this block has. A field marked only when appears once you have chosen the mode above it — those are alternatives to each other, not extra things to fill in.
- Orientationstarts at Portrait
The home screen and portrait-locked apps won't rotate — the result says whether it actually applied.
PortraitLandscape
Build it
Pick which way up
Set OrientationSettings OrientationLandscapeExpect it not always to take
The home screen and portrait-locked apps stay where they are. The step reports whether the rotation applied rather than pretending it did.
if the app allows it
What comes out
- The orientation after the attempt, and whether it changed.
Watch out
- Rotating and immediately asserting catches the layout mid-animation. Put a Wait for Element between them.
Usually next to