Calabash Multi-Device Extension

This is an extension we have applied to test multiple (physical) devices against each other (we only do this in iOS) in a single Calabash test. To use this technique you can add the devices via USB, then build & start the Calabash Server apps on both (all) devices and finally run the tests on your host computer via Ethernet / WiFi. 

In order to use our extension, you e.g. have to add these variables to the cucumber command:

    DEVICE_ENDPOINT_1=192.168.13.1:37265 DEVICE_ENDPOINT_2=192.168.14.1:37265 cucumber

And then you can extend your test by writing:

    Then on device 1 do:
      Then I see „No connected device"
    Then on device 2 do:
      Then tap „connect"
      Then wait 3 seconds
    Then on device 1 do:
      Then I see „Device has connected"`

Hint: Instead of the command line variable `DEVICE_ENDPOINT_1` you can also choose a more descriptive name (e.g. `DEVICE_ENDPOINT_IPAD`) and write this name then also in the test (`Then on device IPAD do:`).