public static void Resize(this BrowserSession browser, Constants.Device device)
        {
            switch (device)
            {
            case Constants.Device.Mobile:
                browser.ResizeTo(320, 568);
                break;

            case Constants.Device.Tablet:
                browser.ResizeTo(768, 1024);
                break;

            case Constants.Device.Desktop:
            case Constants.Device.Unknown:
                browser.MaximiseWindow();
                break;

            default:
                throw new ArgumentOutOfRangeException("device");
            }
        }
 public void GivenImUsingADevice(Constants.Device device)
 {
     ScenarioContext.Current.SetDevice(device);
     Browser.Session.Resize(device);
 }
 public static void SetDevice(this ScenarioContext ctx, Constants.Device device)
 {
     ctx.Set(device, DeviceKey);
 }