Switching between online/offline

classic Classic list List threaded Threaded
5 messages Options
Reply | Threaded
Open this post in threaded view
|

Switching between online/offline

Selenium - Developers mailing list
Hi. I'm on a team that's working on a Progressive Web App, and want to have some automated tests for its offline support.

As far as I can tell, while Chrome's Dev Tools API allows one to tell Chrome "pretend you're offline", there's no way to access this via selenium.

Before I start sharpening my Yak Razor, were I to develop a Webdriver Capability/Extension that exposed this functionality (and a chromedriver implementation thereof) as a completely unofficial 20% project, would there be interest in accepting the patch into selenium?

thanks

Mark

--
You received this message because you are subscribed to the Google Groups "Selenium Developers" group.
To unsubscribe from this group and stop receiving emails from it, send an email to [hidden email].
To view this discussion on the web visit https://groups.google.com/d/msgid/selenium-developers/c322d7ee-ce56-4fe1-872c-b8982db54d25%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.
Reply | Threaded
Open this post in threaded view
|

Re: Switching between online/offline

Luke Inman-Semerau
There is a NetworkConnection[1] API that was created for Mobile support and was implemented in Appium and Selendroid (maybe others?). It's been detailed in the Mobile Spec[2]. Sounds like chrome / chromedriver could implement those API calls for enabling / disabling network. If you're not aware, the chromedriver source code is here[3].


On Wed, Oct 26, 2016 at 1:22 AM, 'Mark Charsley' via Selenium Developers <[hidden email]> wrote:
Hi. I'm on a team that's working on a Progressive Web App, and want to have some automated tests for its offline support.

As far as I can tell, while Chrome's Dev Tools API allows one to tell Chrome "pretend you're offline", there's no way to access this via selenium.

Before I start sharpening my Yak Razor, were I to develop a Webdriver Capability/Extension that exposed this functionality (and a chromedriver implementation thereof) as a completely unofficial 20% project, would there be interest in accepting the patch into selenium?

thanks

Mark

--
You received this message because you are subscribed to the Google Groups "Selenium Developers" group.
To unsubscribe from this group and stop receiving emails from it, send an email to [hidden email].
To view this discussion on the web visit https://groups.google.com/d/msgid/selenium-developers/c322d7ee-ce56-4fe1-872c-b8982db54d25%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.

--
You received this message because you are subscribed to the Google Groups "Selenium Developers" group.
To unsubscribe from this group and stop receiving emails from it, send an email to [hidden email].
To view this discussion on the web visit https://groups.google.com/d/msgid/selenium-developers/CAL97Zu5gfZc2Qtf2XAFtPx9qE0ofaojJRZ%3DuNN3Bjc0-Pr3sZQ%40mail.gmail.com.
For more options, visit https://groups.google.com/d/optout.
Reply | Threaded
Open this post in threaded view
|

Re: Switching between online/offline

Selenium - Developers mailing list
In reply to this post by Selenium - Developers mailing list
Should I view the lack of replies as "no-one has any objections" or "no-one wants this"? :-)

Mark

On Wed, Oct 26, 2016 at 9:22 AM, Mark Charsley <[hidden email]> wrote:
Hi. I'm on a team that's working on a Progressive Web App, and want to have some automated tests for its offline support.

As far as I can tell, while Chrome's Dev Tools API allows one to tell Chrome "pretend you're offline", there's no way to access this via selenium.

Before I start sharpening my Yak Razor, were I to develop a Webdriver Capability/Extension that exposed this functionality (and a chromedriver implementation thereof) as a completely unofficial 20% project, would there be interest in accepting the patch into selenium?

thanks

Mark

--
You received this message because you are subscribed to the Google Groups "Selenium Developers" group.
To unsubscribe from this group and stop receiving emails from it, send an email to [hidden email].
To view this discussion on the web visit https://groups.google.com/d/msgid/selenium-developers/CAAf4L0d6pnjwqwZBdANwrSEnLnKR1v2OFVo-asMHLpwbxJVB%2BQ%40mail.gmail.com.
For more options, visit https://groups.google.com/d/optout.
Reply | Threaded
Open this post in threaded view
|

Re: Switching between online/offline

Selenium - Developers mailing list
In reply to this post by Luke Inman-Semerau
Ah perfect. That'll save me a lot of work. Please ignore my email about silence: I sent that before I say your reply

Mark

On Thursday, October 27, 2016 at 5:03:21 PM UTC+1, Luke Inman-Semerau wrote:
There is a NetworkConnection[1] API that was created for Mobile support and was implemented in Appium and Selendroid (maybe others?). It's been detailed in the Mobile Spec[2]. Sounds like chrome / chromedriver could implement those API calls for enabling / disabling network. If you're not aware, the chromedriver source code is here[3].

Mobile related and potentially network online / offline is planned to be discussed in the next level of the w3c spec for webdriver.


[1] <a href="https://github.com/SeleniumHQ/selenium/blob/master/java/client/src/org/openqa/selenium/mobile/NetworkConnection.java" target="_blank" rel="nofollow" onmousedown="this.href=&#39;https://www.google.com/url?q\x3dhttps%3A%2F%2Fgithub.com%2FSeleniumHQ%2Fselenium%2Fblob%2Fmaster%2Fjava%2Fclient%2Fsrc%2Forg%2Fopenqa%2Fselenium%2Fmobile%2FNetworkConnection.java\x26sa\x3dD\x26sntz\x3d1\x26usg\x3dAFQjCNF0WI39mpWT7Hct2dxZEwu35C3TEQ&#39;;return true;" onclick="this.href=&#39;https://www.google.com/url?q\x3dhttps%3A%2F%2Fgithub.com%2FSeleniumHQ%2Fselenium%2Fblob%2Fmaster%2Fjava%2Fclient%2Fsrc%2Forg%2Fopenqa%2Fselenium%2Fmobile%2FNetworkConnection.java\x26sa\x3dD\x26sntz\x3d1\x26usg\x3dAFQjCNF0WI39mpWT7Hct2dxZEwu35C3TEQ&#39;;return true;">https://github.com/SeleniumHQ/selenium/blob/master/java/client/src/org/openqa/selenium/mobile/NetworkConnection.java
[2] <a href="https://github.com/SeleniumHQ/mobile-spec/blob/master/spec-draft.md#device-modes" target="_blank" rel="nofollow" onmousedown="this.href=&#39;https://www.google.com/url?q\x3dhttps%3A%2F%2Fgithub.com%2FSeleniumHQ%2Fmobile-spec%2Fblob%2Fmaster%2Fspec-draft.md%23device-modes\x26sa\x3dD\x26sntz\x3d1\x26usg\x3dAFQjCNHN-qSU5NcwOrWaX5WyrVu6nmBGmw&#39;;return true;" onclick="this.href=&#39;https://www.google.com/url?q\x3dhttps%3A%2F%2Fgithub.com%2FSeleniumHQ%2Fmobile-spec%2Fblob%2Fmaster%2Fspec-draft.md%23device-modes\x26sa\x3dD\x26sntz\x3d1\x26usg\x3dAFQjCNHN-qSU5NcwOrWaX5WyrVu6nmBGmw&#39;;return true;">https://github.com/SeleniumHQ/mobile-spec/blob/master/spec-draft.md#device-modes
[3] <a href="https://chromium.googlesource.com/chromium/src.git/+/master/chrome/test/chromedriver/" target="_blank" rel="nofollow" onmousedown="this.href=&#39;https://chromium.googlesource.com/chromium/src.git/+/master/chrome/test/chromedriver/&#39;;return true;" onclick="this.href=&#39;https://chromium.googlesource.com/chromium/src.git/+/master/chrome/test/chromedriver/&#39;;return true;">https://chromium.googlesource.com/chromium/src.git/+/master/chrome/test/chromedriver/

On Wed, Oct 26, 2016 at 1:22 AM, 'Mark Charsley' via Selenium Developers <<a href="javascript:" target="_blank" gdf-obfuscated-mailto="YxdA1xnUAAAJ" rel="nofollow" onmousedown="this.href=&#39;javascript:&#39;;return true;" onclick="this.href=&#39;javascript:&#39;;return true;">selenium-...@googlegroups.com> wrote:
Hi. I'm on a team that's working on a Progressive Web App, and want to have some automated tests for its offline support.

As far as I can tell, while Chrome's Dev Tools API allows one to tell Chrome "pretend you're offline", there's no way to access this via selenium.

Before I start sharpening my Yak Razor, were I to develop a Webdriver Capability/Extension that exposed this functionality (and a chromedriver implementation thereof) as a completely unofficial 20% project, would there be interest in accepting the patch into selenium?

thanks

Mark

--
You received this message because you are subscribed to the Google Groups "Selenium Developers" group.
To unsubscribe from this group and stop receiving emails from it, send an email to <a href="javascript:" target="_blank" gdf-obfuscated-mailto="YxdA1xnUAAAJ" rel="nofollow" onmousedown="this.href=&#39;javascript:&#39;;return true;" onclick="this.href=&#39;javascript:&#39;;return true;">selenium-developers+unsubscribe@....
To view this discussion on the web visit <a href="https://groups.google.com/d/msgid/selenium-developers/c322d7ee-ce56-4fe1-872c-b8982db54d25%40googlegroups.com?utm_medium=email&amp;utm_source=footer" target="_blank" rel="nofollow" onmousedown="this.href=&#39;https://groups.google.com/d/msgid/selenium-developers/c322d7ee-ce56-4fe1-872c-b8982db54d25%40googlegroups.com?utm_medium\x3demail\x26utm_source\x3dfooter&#39;;return true;" onclick="this.href=&#39;https://groups.google.com/d/msgid/selenium-developers/c322d7ee-ce56-4fe1-872c-b8982db54d25%40googlegroups.com?utm_medium\x3demail\x26utm_source\x3dfooter&#39;;return true;">https://groups.google.com/d/msgid/selenium-developers/c322d7ee-ce56-4fe1-872c-b8982db54d25%40googlegroups.com.
For more options, visit <a href="https://groups.google.com/d/optout" target="_blank" rel="nofollow" onmousedown="this.href=&#39;https://groups.google.com/d/optout&#39;;return true;" onclick="this.href=&#39;https://groups.google.com/d/optout&#39;;return true;">https://groups.google.com/d/optout.

--
You received this message because you are subscribed to the Google Groups "Selenium Developers" group.
To unsubscribe from this group and stop receiving emails from it, send an email to [hidden email].
To view this discussion on the web visit https://groups.google.com/d/msgid/selenium-developers/60a69977-6809-4e68-9dbe-229fb4be48bf%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.
Reply | Threaded
Open this post in threaded view
|

Re: Switching between online/offline

Andreas Tolfsen
In reply to this post by Selenium - Developers mailing list
"'Mark Charsley' via Selenium Developers"
<[hidden email]> writes:

> Should I view the lack of replies as "no-one has any objections" or
> "no-one wants this"? :-)

This is probably something we would consider for the ‘level 2’ of the
W3C WebDriver specification.

--
You received this message because you are subscribed to the Google Groups "Selenium Developers" group.
To unsubscribe from this group and stop receiving emails from it, send an email to [hidden email].
To view this discussion on the web visit https://groups.google.com/d/msgid/selenium-developers/20161028161316.5d14fcb55f6d39c54a614ede%40mozilla.com.
For more options, visit https://groups.google.com/d/optout.