0

I have developed xamarin hybrid app (html5 , css & js) for android. Now I am working on testing my android app on xamarin test cloud using xamarin ui testing. I have implemented file upload control (html5) in my app and I want to test file upload feature on xamarin cloud for all devices. Is this possible to test file upload feature using xamarin ui testing.

Thanks in advance.

1 Answers1

0

What you are trying to do doesn't make sense because with Xamarin UI test the only think you can do is moving by coordinates on a webview (the only "native component" inside your Activity). If you developed your app with an html hybrid tool try to test your UI with Protractor or similar tools.

I wrote a little post on my blog, it's in Italian but I guess that you can get what I mean looking at the pictures: http://mpic.it/xamarin-uitest-il-nome-inganna-ci-si-puo-testare-quasi-tutto/

Mauro Piccotti
  • 1,807
  • 2
  • 23
  • 34
  • Thanks for the update. I am new in xamarin and have to test my app on xamarin test cloud. I am able to test all feature of my app using xamarin UI test. The only issue is with file uploading feature. Is there is no way to test file upload using xamarin ui test. Actually I don't want to rewrite all my test cases again using protractor. – Tarlok Singh Mar 10 '17 at 13:27
  • @TarlokSingh probably I missed something... but have you developed you app with xamarin or with another hybrid framework based on html5+css+js like Ionic? Because Xamarin is not an Hybrid in the "web sense". Do you mean you developed an app with xamarin using inside it a lot of webviews? – Mauro Piccotti Mar 10 '17 at 13:30
  • Thanks for the update. I have developed Xamarin hybrid app using html5+css+js – Tarlok Singh Mar 10 '17 at 13:39
  • We have only one WebView and we are rendering different-2 html pages on same view. Below is url: https://developer.xamarin.com/guides/cross-platform/advanced/razor_html_templates/ – Tarlok Singh Mar 10 '17 at 13:45
  • It's an approach I strongly disagree to develop a xamarin app entirely based on html, I would understand it only if you have to show in a mobile app pages a website already online or if you need to build a very particular page and it's easier to do it with a webview and html... by the way, the only think you can do I guess is a TapCoordinates on the button of the file upload, but coordinates will change with the device. – Mauro Piccotti Mar 10 '17 at 13:46