terça-feira, 21 de julho de 2015

Working with BackDoors

The following link could be useful.


http://developer.xamarin.com/guides/testcloud/uitest/intro-to-uitest/

http://developer.xamarin.com/guides/testcloud/uitest/working-with/backdoors/

http://developer.xamarin.com/api/namespace/Xamarin.UITest.Queries/



http://developer.xamarin.com/api/member/Xamarin.UITest.IApp.WaitForElement%28System.Func%7BXamarin.UITest.Queries.AppQuery,Xamarin.UITest.Queries.AppQuery%7D,System.String,System.Nullable%7BSystem.TimeSpan%7D,System.Nullable%7BSystem.TimeSpan%7D,System.Nullable%7BSystem.TimeSpan%7D%29/

http://developer.xamarin.com/guides/testcloud/uitest/working-with/gestures/




using System.IO;
using System.Linq;
using NUnit.Framework;
using Xamarin.UITest;
using Xamarin.UITest.Android;
using Xamarin.UITest.Queries;

namespace XamarinTestLab.UITests
{
        [TestFixture]
        public class Tests
        {
                AndroidApp app;
                static readonly Func btnEntrar = c => c.Marked("ENTER");
                static readonly Func spDomain = c => c.Marked("spDomain");
                static readonly Func txtMatricula = c => c.Marked("txtLogin");
                static readonly Func txtPassword = c => c.Marked("txtPassword");

                [SetUp]
                public void BeforeEachTest ()
                {
                        app = ConfigureApp.Android.ApkFile("d:\\teste\\auto.apk").StartApp();
                }

                [Test]
                public void WelcomeTextIsDisplayed ()
                {
                        app.WaitForElement (btnEntrar);
                        app.Tap (spDomain);
                        app.ScrollDownTo("YOURDOMAIN");
                        app.Tap (txtLogin);
                        app.EnterText("YOURUSER");
                        app.Tap (txtPassword);
                        app.EnterText("YOURPASSSWORD");
                        app.Tap(spDomain);

                }
        }
}
Postar um comentário