Exemplo n.º 1
0
 public void SetUp()
 {
     app = ConfigureApp
           .Android
           .StartApp();
     //app = ConfigureApp.Android.ApkFile("/Users/administrator/Desktop/neumann.conferenceapp.apk").StartApp();
 }
Exemplo n.º 2
0
        public CustomerSalesPage(AndroidApp app)
            : base(app)
        {
            app.WaitForElement("WEEKLY AVERAGE", timeout: TimeSpan.FromMinutes(2));

            app.Screenshot("On " + this.GetType().Name);
        }
Exemplo n.º 3
0
        public void BeforeEachTest()
        {
            var          setup   = ConfigureApp.Android;
            const string apkPath = "../../../../src/SymbolCollector.Android/bin/Release/net6.0-android/io.sentry.symbolcollector.android-Signed.apk";

            if (File.Exists(apkPath))
            {
                setup = setup.ApkFile(apkPath);
                Console.WriteLine($"Using APK: {apkPath}");
            }

            // Quick feedback in debug, not running on a farm:
#if DEBUG
            else
            {
                var msg = $"APK path defined but no file exists at this path: {apkPath}";
                Console.WriteLine(msg);
                Assert.Fail(msg);
            }
#endif

            _app = setup
                   .PreferIdeSettings()
                   .StartApp();
        }
Exemplo n.º 4
0
 public void BeforeEachTest ()
 {
     app = ConfigureApp
         .Android
         .ApkFile ("app.apk")
         .StartApp ();
 }
Exemplo n.º 5
0
 public void BeforeEachTest()
 {
     app = ConfigureApp
           .Android
           .ApkFile("app.apk")
           .StartApp();
 }
Exemplo n.º 6
0
 public void BeforeEachTest()
 {
     app = ConfigureApp
           .Android
           .ApkFile(@"..\..\..\Plugin.Fingerprint.Test.UI.Android\bin\Debug\Plugin.Fingerprint.Test.UI.Android-Signed.apk")
           .StartApp();
 }
 public void BeforeEachTest()
 {
     app = ConfigureApp
           .Android
           .ApkFile("../../../com.xamarin.xamarincrm-Signed.apk")
           .StartApp();
 }
Exemplo n.º 8
0
 public void BeforeEachTest()
 {
     app = ConfigureApp
         .Android
         .EnableLocalScreenshots ()
         .StartApp ();
 }
Exemplo n.º 9
0
 public void BeforeEachTest ()
 {
     app = (AndroidApp)AppInitializer.StartApp (
         platform,
         null,
         TestConsts.iOSBundleId);
 }
 public CustomerOrderDetailsPage(AndroidApp app)
     : base(app, "Company")
 {
     ProductField = x => x.Class("EditTextEnter").Descendant(0);
     PriceField   = x => x.Class("EntryEditText").Descendant(1);
     DateField    = x => x.Class("EditText").Index(0);
 }
Exemplo n.º 11
0
 public void BeforeEachTest()
 {
     app = ConfigureApp
           .Android
           .ApkFile("../../../BMICalculator/bin/Debug/BMICalculator.BMICalculator.apk")
           .StartApp();
 }
Exemplo n.º 12
0
 public void BeforeEachTest()
 {
     app = ConfigureApp
           .Android
           .ApkFile("../../../XamarinTestsForAndroid/bin/Debug/test.apk")
           .StartApp();
 }
Exemplo n.º 13
0
 public void BeforeEachTest()
 {
     app = ConfigureApp
           .Android
           .InstalledApp("AppShortcuts.AppShortcuts")
           .StartApp();
 }
Exemplo n.º 14
0
 public void BeforeEachTest()
 {
     app = ConfigureApp
           .Android
           .ApkFile(@"C:\Users\sorinpe\Source\Repos\CoffeeTipper2\Droid\bin\Release\com.xamarin.coffee_tip.apk")
           .StartApp();
 }
Exemplo n.º 15
0
 public void BeforeEachTest()
 {
     app = ConfigureApp.Android
           .ApkFile("app.apk")
           .PreferIdeSettings()
           .StartApp();
 }
 public void SetUp()
 {
     app = ConfigureApp
         .Android
         .ApkFile (AppFile)
         .StartApp ();
 }
Exemplo n.º 17
0
 public void BeforeEachTest ()
 {
     app = ConfigureApp.Android
         .ApkFile ("app.apk")
         .PreferIdeSettings ()
         .StartApp ();
 }
 public GlobalPage(AndroidApp app)
     : base(app)
 {
     SalesTab = "Sales";
     CustomersTab = "Customers";
     ProductsTab = "Products";
 }
Exemplo n.º 19
0
 public AndroidDeviceSettings(AndroidApp app) : base(app)
 {
     _activity     = app.MainActivity;
     _powerManager = _activity.GetSystemService(Context.PowerService) as PowerManager;
     _wifiManager  = _activity.GetSystemService(Context.WifiService) as WifiManager;
     _wakeLock     = _powerManager.NewWakeLock(WakeLockFlags.Full, "DSAMobile");
 }
Exemplo n.º 20
0
 public void BeforeEachTest()
 {
     app = ConfigureApp
           .Android
           .ApkFile(@"..\..\..\App3\App3.Android\bin\Debug\com.companyname.App3.apk")
           .StartApp();
 }
        protected BasePage(AndroidApp app, Func<AppQuery, AppQuery> androidTrait)
            : this(app)
        {
            Assert.DoesNotThrow(() => app.WaitForElement(androidTrait), "Unable to verify on page: " + this.GetType().Name);

            app.Screenshot("On " + this.GetType().Name);
        }
Exemplo n.º 22
0
 public void BeforeEachTest()
 {
     app = ConfigureApp
           .Android
           .ApkFile(@"..\..\..\SecureStorageTest\bin\Release\SecureStorageTest.SecureStorageTest.apk")
           .StartApp();
 }
 public CustomerOrderDetailsPage(AndroidApp app)
     : base(app, "Company")
 {
     ProductField = x => x.Class("EditTextEnter").Descendant(0);
     PriceField = x => x.Class("EntryEditText").Descendant(1);
     DateField = x => x.Class("EditText").Index(0);
 }
 public CustomerContactPage(AndroidApp app)
     : base(app, "Address")
 {
     PhoneButton = x => x.Class("FormsImageView").Index(2);
     MapButton = x => x.Class("FormsImageView").Index(3);
     HeaderImage = x => x.Class("ImageRenderer").Index(0);
 }
        public void BeforeEachTest ()
        {
            app = ConfigureApp
				.Android
                //.DeviceSerial()
				.StartApp ();
        }
Exemplo n.º 26
0
 public void Setup()
 {
     app = ConfigureApp
           .Android
           //.ApkFile("/Users/brent/Projects/Xamarin/VoltageRegulatorTemperature/Droid/bin/Release/com.sparkfun.voltageregulatortemperature.apk")
           .StartApp();
 }
Exemplo n.º 27
0
 public GlobalPage(AndroidApp app)
     : base(app)
 {
     SalesTab     = "Sales";
     CustomersTab = "Customers";
     ProductsTab  = "Products";
 }
Exemplo n.º 28
0
 public void BeforeEachTest()
 {
     app = ConfigureApp.Android
           .ApkFile("C:\\Users\\admin\\Desktop\app\\com.honeywell-Signed.apk")
           .DeviceSerial("51baf25d")
           .StartApp();
 }
Exemplo n.º 29
0
 public void BeforeEachTest()
 {
     app = ConfigureApp
           .Android
           .ApkFile("../../../ms-enterprise/platforms/android/build/outputs/apk/android-debug.apk")
           .StartApp();
 }
Exemplo n.º 30
0
 public void BeforeEachTest()
 {
     app = (AndroidApp)AppInitializer.StartApp(
         platform,
         null,
         TestConsts.iOSBundleId);
 }
Exemplo n.º 31
0
        protected BasePage(AndroidApp app, Func <AppQuery, AppQuery> androidTrait)
            : this(app)
        {
            Assert.DoesNotThrow(() => app.WaitForElement(androidTrait), "Unable to verify on page: " + this.GetType().Name);

            app.Screenshot("On " + this.GetType().Name);
        }
Exemplo n.º 32
0
 public CustomerContactPage(AndroidApp app)
     : base(app, "Address")
 {
     PhoneButton = x => x.Class("FormsImageView").Index(2);
     MapButton   = x => x.Class("FormsImageView").Index(3);
     HeaderImage = x => x.Class("ImageRenderer").Index(0);
 }
Exemplo n.º 33
0
 public void BeforeEachTest()
 {
     app = ConfigureApp
           .Android
           //.DeviceSerial()
           .StartApp();
 }
        public CustomerSalesPage(AndroidApp app)
            : base(app)
        {
            app.WaitForElement("WEEKLY AVERAGE", timeout: TimeSpan.FromMinutes(2));

            app.Screenshot("On " + this.GetType().Name);
        }
 public void BeforeEachTest()
 {
     app = ConfigureApp.Android
           .ApkFile(@"C:\temp/com.companyname.appname.apk")
           .StartApp();
     _mainPagePageObject = new MainPageViewObject(app);
 }
Exemplo n.º 36
0
 public void BeforeEachTest()
 {
     app = ConfigureApp
           .Android
           .ApkFile(@"..\..\..\eXam.Droid\bin\Release\eXam.Droid.apk")
           .StartApp();
 }
Exemplo n.º 37
0
        public void AfterEachTest()
        {
            // Start the application
            app = ConfigureApp.Android.StartApp();

            // Delete recently created city if still existing
            // Depending on your test configuration and environment, ConfigureApp.Android.StartApp(); sometimes
            // deployes a complete new package of the app. In this case, no cleanup work is needed.
            app.WaitForElement(x => x.Id("textView1"));
            var city = app.Query(x => x.Text(testCityName)).FirstOrDefault();
            if (city != null)
            {
                // Delete the recently created city
                app.Tap(x => x.Text(testCityName));
                app.WaitForElement(x => x.Class("OverflowMenuButton"));
                app.Tap(x => x.Class("OverflowMenuButton"));
                app.Tap(x => x.Class("TextView").Index(0)); // Edit button

                app.WaitForElement(x => x.Id("action_delete_city"), "Delete city button never appeared...");
                app.Tap(x => x.Id("action_delete_city"));
                app.Tap(x => x.Id("button1"));

                // Check if city has been deleted successfully
                var results = app.Query(x => x.Text(testCityName));
                Assert.IsFalse(results.Any());
            }
        }
Exemplo n.º 38
0
 public void BeforeEachTest()
 {
     app = ConfigureApp
           .Android
           .EnableLocalScreenshots()
           .StartApp();
 }
Exemplo n.º 39
0
        public static void AssemblyInitialize(TestContext testContext)
        {
            var app = new AndroidApp();

            app.UseExceptionLogger();
            app.UseMsTestSettings();
            app.UseAppBehavior();
            app.UseLogExecutionBehavior();
            app.UseLogExecutionBehavior();
            app.UseFFmpegVideoRecorder();
            app.UseIOSDriverScreenshotsOnFail();
            app.UseElementsBddLogging();
            app.UseValidateExtensionsBddLogging();
            app.UseLayoutAssertionExtensionsBddLogging();
            app.StartAppiumLocalService();
            app.Initialize();

            // Software machine automation module helps you to install the required software to the developer's machine
            // such as a specific version of the browsers, browser extensions, and any other required software.
            // You can configure it from BELLATRIX configuration file testFrameworkSettings.json
            //  "machineAutomationSettings": {
            //      "isEnabled": "true",
            //      "packagesToBeInstalled": [ "googlechrome", "firefox --version=65.0.2", "opera" ]
            //  }
            //
            // You need to specify the packages to be installed in the packagesToBeInstalled array. You can search for packages in the
            // public community repository- https://chocolatey.org/
            //
            // To use the service you need to start Visual Studio in Administrative Mode. The service supports currently only Windows.
            // In the future BELLATRIX releases we will support OSX and Linux as well.
            //
            // To use the machine automation setup- install Bellatrix.MachineAutomation NuGet package.
            // SoftwareAutomationService.InstallRequiredSoftware();
        }
 public void BeforeEachTest()
 {
     app = ConfigureApp.Android.StartApp ();
     Func<AppQuery, AppQuery> menu_button_query = e => e.Id("menu_button");
     app.Tap (menu_button_query);
     Func<AppQuery, AppQuery> search_button = e => e.Text ("Search");
     app.Tap (search_button);
 }
 public void BeforeEachTest()
 {
     app = ConfigureApp
           .Android
           .EnableLocalScreenshots()
           .ApkFile("C:/data/visualstudio_diverseprojecten/travellingsalesman/TSMApp/bin/Debug/TSMApp.TSMApp.apk")
           .StartApp();
 }
Exemplo n.º 42
0
 public void BeforeEachTest()
 {
     app = ConfigureApp
           .Android
           .ApkFile(@"C:\Users\omehe\Desktop\Calculadora.apk")
           //.DeviceSerial("emulator-5554")
           .StartApp();
 }
Exemplo n.º 43
0
 public void BeforeEachTest()
 {
     app = ConfigureApp.Android
           .ApkFile(@"C:\temp/com.companyname.appname.apk")
           .StartApp();
     _mainPageViewObject = new MainPageViewObject(app);
     _dogsListViewObject = _mainPageViewObject.UserHasDogSignIn();
 }
Exemplo n.º 44
0
        public void BeforeEachTest ()
        {
            app = (AndroidApp)AppInitializer.StartApp (
                platform, 
                TestConsts.ApkFile, 
                null);

            app.WakeUpAndroidDevice ();
        }
Exemplo n.º 45
0
 public void BeforeEachTest()
 {
     // TODO: If the Android app being tested is included in the solution then open
     // the Unit Tests window, right click Test Apps, select Add App Project
     // and select the app projects that should be tested.
     app = ConfigureApp
         .Android.ApkFile ("../../../APK/Test/com.refractored.bikenowpronto.apk")
         .StartApp();
 }
Exemplo n.º 46
0
 public void BeforeEachTest()
 {
     // TODO: If the Android app being tested is included in the solution then open
     // the Unit Tests window, right click Test Apps, select Add App Project
     // and select the app projects that should be tested.
     app = ConfigureApp
         .Android
         .ApkFile("../../../GeneticsTests/bin/Release/com.example.genetics.GeneticsTests.apk")
         .StartApp();
 }
        public void Setup(bool clear)
        {
            var appConfig = ConfigureApp
                .Android
                .ApkFile("../../../com.xamarin.xamarincrm-Signed.apk");

            if (clear)
                app = appConfig.StartApp();
            else
                app = appConfig.StartApp(Xamarin.UITest.Configuration.AppDataMode.DoNotClear);
        }
Exemplo n.º 48
0
 public void BeforeEachTest()
 {
     // TODO: If the Android app being tested is included in the solution then open
     // the Unit Tests window, right click Test Apps, select Add App Project
     // and select the app projects that should be tested.
     app = ConfigureApp
         .Android
         .ApiKey(Key)
         .ApkFile("Kinder.apk")
         .StartApp();
 }
Exemplo n.º 49
0
        public void BeforeEachTest()
        {
            app = ConfigureApp.Android.StartApp ();
            app.Screenshot ("Given the app is loaded");
            app.Tap (x => x.Button ("btn_play"));

            app.WaitForElement (x => x.Id ("tv_bingoItem"));

            var results = app.Query (x => x.Id ("tv_bingoItem"));
            Assert.AreEqual (25, results.Length);
            app.Screenshot ("25 items should be shown");
        }
		public void BeforeEachTest()
		{
			// TODO: If the Android app being tested is included in the solution then open
			// the Unit Tests window, right click Test Apps, select Add App Project
			// and select the app projects that should be tested.
			app = ConfigureApp
				.Android
				// TODO: Update this path to point to your Android app and uncomment the
				// code if the app is not included in the solution.
				//.ApkFile ("../../../Droid/bin/Debug/xamarinforms.apk")
				.StartApp();
		}
 public LeadDetailsPage(AndroidApp app)
     : base(app, "Opportunity")
 {
     ContactTab = x => x.Descendant("Contact");
         EditCompany = x => x.Marked("Company").Sibling();
         EditIndustry = x => x.Class("android.widget.EditText").Index(1);
         EditSize = x => x.Marked("Size").Sibling();
         EditStage = x => x.Class("android.widget.EditText").Index(3);
         Done = x => x.Marked("Save");
         Save = x => x.Marked("Save");
         ScrollPanel = x => x.Marked("customPanel");
         OkButton = x => x.Marked("button1");
 }
Exemplo n.º 52
0
        public void BeforeEachTest()
        {
            var path = @"../../../NewBankMobile.Droid/bin/Debug/";
            var apkName = "com.megsoftconsulting.talk.newbankmobile.apk";
            var apkPath = $"{path}{apkName}";

            app = ConfigureApp
                .Android
                .ApkFile(apkPath)
                .EnableLocalScreenshots()
                //.PreferIdeSettings()
                //.DeviceSerial("")
                .StartApp();
        }
        public SalesHomePage(AndroidApp app)
            : base(app, "WEEKLY AVERAGE")
        {
            FirstLead = x => x.Marked("50% - Value Proposition");
            ListView = x => x.Id("content");
            AddLeadButton = x => x.Class("FormsImageView");
            LeadCell = x => x.Class("ViewCellRenderer_ViewCellContainer");
            ChartIdentifier = x => x.Id("stripLinesLayout");
            //Verifying page has loaded
            app.WaitForElement(LeadCell);
            app.WaitForElement(ChartIdentifier);

            app.WaitForNoElement(SalesDataLoading, timeout: TimeSpan.FromSeconds(20));
            app.WaitForNoElement(LeadsLoading, timeout: TimeSpan.FromSeconds(20));
        }
Exemplo n.º 54
0
        public void BeforeEachTest()
        {
            // Start the application
            app = ConfigureApp.Android.StartApp();

            // Create a new city
            app.WaitForElement(x => x.Id("action_add_city"));
            app.Tap(x => x.Id("action_add_city"));
            app.EnterText(x => x.Id("addEditCityName"), testCityName);
            app.EnterText(x => x.Id("addEditCityZip"), testCityZip);
            app.Tap(x => x.Id("action_add_city_confirm"));

            // Check if city has been created successfully
            var results = app.Query(x => x.Text(testCityName));
            Assert.IsTrue(results.Any());
        }
        public virtual void BeforeEachTest()
        {
            app = AppInitializer.StartApp();

            Thread.Sleep(TimeSpan.FromSeconds(5));

            if (app.Query("SIGN IN").Any())
            {
                new SplashScreenPage(app)
                    .ExitSplashScreen();
            }

            //waiting for next screen to load
            Thread.Sleep(TimeSpan.FromSeconds(5));

            app.Screenshot("On Home Page");
        }
 public LeadContactPage(AndroidApp app)
     : base(app, "Phone")
 {
     DetailsTab = x => x.Index(9);
     RoleField = x => x.Marked("Role").Sibling();
     FirstNameField = x => x.Marked("First Name").Sibling();
     LastNameField = x => x.Marked("Last Name").Sibling();
     PhoneField = x => x.Marked("Phone").Sibling();
     EmailField = x => x.Marked("Email").Sibling();
     AddressField = x => x.Marked("Address").Sibling();
     PostalCodeField = x => x.Marked("Postal Code").Sibling();
     CityField = x => x.Marked("City").Sibling();
     StateField = x => x.Marked("State").Sibling();
     CountryField = x => x.Marked("Country").Sibling();
     ContactList = x => x.Class("ListView");
     Done = "DONE";
     Save = "Save";
 }
		public void BeforeEachTest ()
		{
			// TODO: If the Android app being tested is included in the solution then open
			// the Unit Tests window, right click Test Apps, select Add App Project
			// and select the app projects that should be tested.
			app = ConfigureApp
				.Android
				// TODO: Update this path to point to your Android app and uncomment the
				// code if the app is not included in the solution.
				.ApkFile ("../../../Tasky.Droid/bin/Release/com.xamarin.samples.taskydroid.apk")
				.StartApp ();


			app.Screenshot("uslika.png");

			//app.Repl();

			return;
		}
Exemplo n.º 58
0
		public void BeforeEachTest ()
		{
			app = ConfigureApp.Android.StartApp ();
		}
 public LoginPage(AndroidApp app)
     : base(app, "Sign in")
 {
 }
Exemplo n.º 60
0
 protected BasePage(AndroidApp app)
 {
     this.app = app;
        //app.WaitForElement(element);
 }