calabash/calabash-ios — pull request #229 by jmoody (2013-10-21 08:55:58+00:00)
Title: replaced 'device_orientation' with 'status_bar_orientation' detecting orientation of device

### motivation

the `device_orientation` function returns `{face up, face down, up, down, left, right, unknown}`.

this is confusing to users because:

1. `face up` and `face down` are only returned if testing on a device and if the device has not been previously rotated by calabash.

2. `unknown` is only returned if testing on the simulator and if the simulator has not been previously rotated by calabash.

in contrast, the `status_bar_orientation` only returns `{up, down, left, right}`

### testing

***NB:*** cannot test swiping on iOS Simulator because of an [Apple bug in the simulator](http://stackoverflow.com/questions/18792965/uiautomations-draginsidewithoptions-has-no-effect-on-ios7-simulator).

testing revealed an unrelated bug in iOS 7 swiping.

tested using briar gem and Briar-cal

* 0.1.1 branch -- https://github.com/jmoody/briar
* 0.1.2 branch -- https://github.com/jmoody/briar-ios-example

use the `@rotation` tag to test

* `bundle exec cucumber -p launch -p iphone --tags @rotation`
* `bundle exec cucumber -p launch -p ipad --tags @rotation`

- [x] iOS 6 iPhone 4S
- [ ] iOS 7 iPhone 5C `swiping broken`
- [x] iOS 5.1 iPad 1
- [ ] iOS 7.0 iPad 4 `swiping broken`
- [x] all simulator combinations
- [x] UIA launching (when supported)
- [x] manually launching (when supported)

### KNOWN ISSUES

on iOS 7 swiping is broken for any orientation other than portrait with the home button down.

this is an unrelated bug that was discovered during testing.