title: How to do Coded UI Test Automation in a UWP App having only a WebView
body: <p>I have made a <strong>UWP Application</strong> that contains <strong>only a WebView</strong>. When the App is launched the WebView is given the URL to the Azure Remote App login page where I can login using my Azure AD Credentials and use an App (e.g. Excel) after login. Now the problem is how do I automate all this using Coded UI? I have the following two projects in Visual Studio that I used.</p>
  
  <p><a href="https://i.stack.imgur.com/FiJdx.png" rel="nofollow noreferrer"><img src="https://i.stack.imgur.com/FiJdx.png" alt="enter image description here"></a></p>
  
  <p>Now the problems are:</p>
  
  <p>1) <strong>Record and Playback options are not supported for UWP</strong> in both the projects.</p>
  
  <p>2) If I use Coded UI Test Project (Universal Windows), <strong>It cannot detect the WebView or control/elements inside the WebView</strong> (so this is of no use for me).</p>
  
  <p>3) If I use Coded UI Test Project (Universal Windows - Phone), It is able to detect the webview and the elements inside it like the email and password fields and the sign in button, but in the code <strong>I don't have anything like XamlWebView</strong> which I can use and then use the SearchProperty to find the email field and use it (So I am half way there).</p>
  
  <p>The only two links that I found relevant are:</p>
  
  <p><a href="https://stackoverflow.com/questions/35025122/windows-10-uwp-coded-ui">Windows 10 (UWP) Coded UI</a></p>
  
  <p><a href="https://stackoverflow.com/questions/25872022/coded-ui-test-windows-universal-apps">Coded UI Test - Windows - Universal Apps</a></p>
  
  <p>But they don't offer much help.</p>
  
  <p>I also went through the <strong>WinAppDriver</strong> (saw a video on Channel9 of //build 2016 where Gopinath and Yusuf explained about WinAppDriver) thing but was not able to figure out whether it can be used in my Scenario and how.</p>
  
  <p>I hope I expressed my Question clearly. Thanks for your help in advance.</p>