Coder Social home page Coder Social logo

Comments (10)

login4amit avatar login4amit commented on September 28, 2024

@jlipps Any Comments.

from dotnet-client.

Astro03 avatar Astro03 commented on September 28, 2024

@login4amit - i'm no expert but i'm almost positive you can't switch from one to another. I've actually never tried your con ops (concept of operations). I would assume if you use the iOS driver one from the beginning, it should work though. Try it out and let me know - i'm curious too since i've only used it with apps.

from dotnet-client.

TikhomirovSergey avatar TikhomirovSergey commented on September 28, 2024

i'm no expert but i'm almost positive you can't switch from one to another.

I've never tried this.
But I can advice this...

driver.Context = "NATIVE_APP";

I'am really not sure that it works...

@Astro03 What do you think about the enhancement on the server-side if client code above doesn't work with case described by @login4amit ?

from dotnet-client.

login4amit avatar login4amit commented on September 28, 2024

@Astro03 & @TikhomirovSergey
Sure I will take a look at it and will get back to u soon.
Thanks for the response.

from dotnet-client.

talsurizon avatar talsurizon commented on September 28, 2024

i'm having the same problem, did you find a solution?

from dotnet-client.

rutin31 avatar rutin31 commented on September 28, 2024

Hi,
do you get any solution?

from dotnet-client.

obstar avatar obstar commented on September 28, 2024

example of the code we use in our mobile framework

`public IDevice SwitchToNativeAppContext()
	{
		_driver.Context = "NATIVE_APP";
		return this;
	}

public IDevice SwitchToWebViewContext()
	{
		//wait until webview context load in app
		var i = 0;
		string context;
		while (true)
		{
			var contextList = _driver.Contexts.ToList();
			context = contextList.FirstOrDefault(c => c.Contains("WEBVIEW"));
			if (context != null)
				break;
			if (i >= 50) //wait up to 5 seconds to load webview
				throw new Exception("Could not find WEBVIEW context");

			Thread.Sleep(TimeSpan.FromMilliseconds(100)); //Maybe the view hasn't loaded yet
			i++;
		}

		_driver.Context = context;
		return this;
	}`

from dotnet-client.

rutin31 avatar rutin31 commented on September 28, 2024

thank you very much
I have to switch between two iOS apps
what should I define on
_driver.Context=?

from dotnet-client.

obstar avatar obstar commented on September 28, 2024

I don't think its possible. Because when you start driver you're define app package and it can't be changed during same webdriver session.

from dotnet-client.

rutin31 avatar rutin31 commented on September 28, 2024

I have the problem to get OTP
when I do Swipe to notification the appium logs:
[debug] [XCUITest] Connection to WDA timed out
[debug] [iProxy] recv failed: Operation not permitted

and C# error is:
A exception with a null response was thrown sending an HTTP request to the remote WebDriver server for URL ...
The status of the exception was KeepAliveFailure, and the message was: The underlying connection was closed: A connection that was expected to be kept alive was closed by the server.

I thought that there is a way to get otp from SMS app
maybe you have any idea for this?

from dotnet-client.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.