Example #1
0
 private void TapOnCoupling(string objName)
 {
     if (KeywordImplementation.UIObject(By.Id("Txt_ActionBar_Title"), TimeSpan.FromSeconds(5)).Text.Equals("Select Coupling"))
     {
         KeywordImplementation.Click(By.Name(objName));
     }
 }
Example #2
0
        /// <summary>
        /// Performs the playback of actions in this module.
        /// </summary>
        /// <remarks>You should not call this method directly, instead pass the module
        /// instance to the <see cref="TestModuleRunner.Run(ITestModule)"/> method
        /// that will in turn invoke this method.</remarks>
        void ITestModule.Run()
        {
            //initialising HI values globally based on the AppBrand.
            BrandBasedHINames();
            Mouse.DefaultMoveTime        = 300;
            Keyboard.DefaultKeyPressTime = 100;
            Delay.SpeedFactor            = 1.0;

            string applicationName = TestSuite.Current.Parameters["AppName"];
            string appActivity     = "md56f35e8d86ebdc1429f36073ae400eed3.SplashActivity";

            KeywordImplementation.LaunchAndroidApp(TestSuite.Current.Parameters["Device"], applicationName, appActivity);
//			KeywordImplementation.LaunchAndroidApp(TestSuite.Current.Parameters["Device"],applicationName,appActivity);

            if (KeywordImplementation.waitForObjectExist(By.Name("OK"), TimeSpan.FromSeconds(5)))
            {
                KeywordImplementation.Click(By.Name("OK"));
            }

            //Handling "Connect to cloud" window
//			if(KeywordImplementation.waitForObjectExist(By.Name("Would you like to connect to cloud ?"),TimeSpan.FromSeconds(2)))
//			{
//				KeywordImplementation.Click(By.Name("NO"));
//				Delay.Seconds(2);
//			}
            Report.Info(TestSuite.Current.Parameters["Device"]);
        }
        public void SwitchAudiogramAvailableinEditScreen(bool on, bool alert)
        {
            string message         = null;
            var    switchAudiogram = KeywordImplementation.UIObject(By.Id("switchAudiogramEnable"), TimeSpan.FromSeconds(1));

            if ((on.Equals(true) && (switchAudiogram.GetAttribute("value").Equals("0") || switchAudiogram.GetAttribute("value").Equals("false"))) || (on.Equals(false) && (switchAudiogram.GetAttribute("value").Equals("1") || switchAudiogram.GetAttribute("value").Equals("true"))))
            {
                switchAudiogram.Click();
                message = on?"Switch on the audiogram":"Switch off the audiogram";
                Logger.logInfo(message);
            }
            Logger.logSnapshot();
            if (KeywordImplementation.waitForObjectExist(By.ClassName("UIAAlert"), TimeSpan.FromSeconds(2)))
            {
                if (alert.Equals(true))
                {
                    KeywordImplementation.Click(By.Id("OK"));
                    Logger.logInfo("OK the alert");
                }
                else
                {
                    KeywordImplementation.Click(By.Id("Cancel"));
                    Logger.logInfo("Cancel the alert");
                }
            }
        }
Example #4
0
 public void ClickOnAlertMessageOk()
 {
     if (KeywordImplementation.waitForObjectExist(By.Name("OK"), TimeSpan.FromSeconds(2)))
     {
         KeywordImplementation.Click(By.Name("OK"));
     }
 }
Example #5
0
 public void CancelAuthenticationScreen()
 {
     Logger.logInfo("Authentication  screen is Cancelled");
     KeywordImplementation.Click(By.Id("Cancel"));
     Logger.logSnapshot();
     //CloseApp();
 }
Example #6
0
        public void ClickRateTheAppNow()
        {
            TestModuleRunner.Run(new AdbClear());
            TestModuleRunner.Run(new AndroidSuiteSetUp());
            CloseApp();
            bool check = false;

            for (int i = 3; i <= 20; i++)
            {
                StartApp(false);
                Logger.logInfo(string.Format("{0} Run of app ", i));
                if (i == 20 && KeywordImplementation.waitForObjectExist(By.Name("Rate the App Now"), TimeSpan.FromSeconds(1)))
                {
                    Logger.logSuccess(string.Format("Rate the app pop-up found at {0}th iteration", i), true);
                    KeywordImplementation.Click(By.Name("Rate the App Now"));
                    check = true;
                    break;
                }
                CloseApp();
            }
            if (!check)
            {
                Logger.logFailure("Rate the app pop-up not found", true);
            }
        }
        public void EditPatient(string lastName, string firstName)
        {
            var size = Accessor.getDriver().Manage().Window.Size;

            //Swipe from Bottom to Top and Top to bottom
            //Find swipe start and end point from screen's width and height.
            int starty = (int)(size.Height * 0.50);
            int endy   = (int)(size.Height * 0.20);
            int startx = size.Width / 2;

            int count = 0;

            while (count != 3 && (!KeywordImplementation.waitForObjectExist(By.Id("txtLastName"), TimeSpan.FromSeconds(1))))
            {
                ((IOSDriver <IOSElement>)Accessor.getDriver()).Swipe(startx, starty, startx, endy, 500);
                count++;
            }

            Logger.logInfo(string.Format("Edit the patient with info '{0}, {1}'", lastName, firstName));
            KeywordImplementation.TypeText(By.Id("txtLastName"), lastName);
            KeywordImplementation.Click(By.XPath("//UIAWindow[2]//UIAButton[contains(@name,'Done')]"));
            KeywordImplementation.TypeText(By.Id("txtFirstName"), firstName);
            KeywordImplementation.Click(By.XPath("//UIAWindow[2]//UIAButton[contains(@name,'Done')]"));
            //TapOnLeftButton("Press the back key");
        }
Example #8
0
//		string _isRatetheApp = "false";
//		[TestVariable("635e797b-0685-4779-afc7-0c158b0b4142")]
//		public string isRatetheApp
//		{
//			get { return _isRatetheApp; }
//			set { _isRatetheApp = value; }
//		}


        /// <summary>
        /// Performs the playback of actions in this module.
        /// </summary>
        /// <remarks>You should not call this method directly, instead pass the module
        /// instance to the <see cref="TestModuleRunner.Run(ITestModule)"/> method
        /// that will in turn invoke this method.</remarks>
        void ITestModule.Run()
        {
            Mouse.DefaultMoveTime        = 300;
            Keyboard.DefaultKeyPressTime = 100;
            Delay.SpeedFactor            = 1.0;

            string applicationName = TestSuite.Current.Parameters["AppName"];
            string appActivity     = "md558fba4ce7ce0bf1978fcd2662fa3cc65.SplashActivity";

            //appActivity="md56f35e8d86ebdc1429f36073ae400eed3.SplashActivity";
            KeywordImplementation.LaunchAndroidApp(TestSuite.Current.Parameters["Device"], applicationName, appActivity);
            //	KeywordImplementation.LaunchAndroidApp(TestSuite.Current.Parameters["Device"],applicationName,appActivity);

            if (KeywordImplementation.waitForObjectExist(By.Name("OK"), TimeSpan.FromSeconds(5)))
            {
                KeywordImplementation.Click(By.Name("OK"));
            }
            if (isPopup)
            {
                if (KeywordImplementation.waitForObjectExist(By.Name("Not now"), TimeSpan.FromSeconds(1)))
                {
                    KeywordImplementation.Click(By.Name("Not now"));
                }
                else if (KeywordImplementation.waitForObjectExist(By.Name("Später vielleicht"), TimeSpan.FromSeconds(1)))
                {
                    KeywordImplementation.Click(By.Name("Später vielleicht"));
                }
            }

            Report.Info(TestSuite.Current.Parameters["Device"]);
        }
        public void TapOnOverviewScreen()
        {
//			if(side.Equals("right",StringComparison.CurrentCultureIgnoreCase))
//				KeywordImplementation.Click(By.Id("Layout_Monaural_Audiogram"));
//			else if(side.Equals("left",StringComparison.CurrentCultureIgnoreCase))
//				KeywordImplementation.Click(By.Id("AudiogramGrid_LeftEar"));
            KeywordImplementation.Click(By.Id("Layout_Monaural_Audiogram"));
        }
Example #10
0
 private void PTEDone()
 {
     if (KeywordImplementation.waitForObjectExist(By.Id("Img_PureToneInst_Skip"), TimeSpan.FromSeconds(2)))
     {
         KeywordImplementation.Click(By.Id("Img_PureToneInst_Skip"));
     }
     KeywordImplementation.Click(By.Id("ImgBtn_PureToneInst_Next"));
 }
Example #11
0
 public void TapOnwithContentDisc(string objectName, string message)
 {
     if (message != String.Empty)
     {
         Logger.logInfo(message);
     }
     KeywordImplementation.Click(By.XPath("//*[contains(@content-desc,'" + objectName + "')]"));
 }
 private void TapOnOk()
 {
     if (KeywordImplementation.waitForObjectExist(By.Id("Txt_CommonAlert_Title"), TimeSpan.FromSeconds(3)))
     {
         Ranorex.Report.Success("Security alert has popped up");
         Logger.logSnapshot();
         KeywordImplementation.Click(By.Name("OK"));
     }
 }
Example #13
0
 private void SelectCustoEarMoldContinue()
 {
     Logger.logInfo("Select Custom Ear Molds Continue");
     KeywordImplementation.Click(By.Id("Btn_CustomMolds_Continue"));
     if (KeywordImplementation.waitForObjectExist(By.Name("OK"), TimeSpan.FromSeconds(5)))
     {
         KeywordImplementation.Click(By.Name("OK"));
     }
 }
Example #14
0
        public void ValidateTinnitusVolumeDecrease()
        {
            Bitmap imageBeforeVolumeChange = new Bitmap(Logger.CaptureSnapshot(By.Id("sliderVolumeControl")));

            KeywordImplementation.Click(By.Id("btnVolumeDown"));
            Bitmap imageAfterVolumeChange = new Bitmap(Logger.CaptureSnapshot(By.Id("sliderVolumeControl")));

            Logger.logInfo("Validating Tinnitus Volume has been Decreased");
            Logger.ValidateImagesChanged(imageBeforeVolumeChange, imageAfterVolumeChange, true);
        }
Example #15
0
        public void SliderVolumeIncrease()
        {
            Bitmap imageBeforeVolumeChange = new Bitmap(Logger.CaptureSnapshot(By.Id("layoutVolumeControl")));

            KeywordImplementation.Click(By.Id("imgViewVolumeUp"));
            KeywordImplementation.Click(By.Id("imgViewVolumeUp"));
            Bitmap imageAfterVolumeChange = new Bitmap(Logger.CaptureSnapshot(By.Id("layoutVolumeControl")));

            Logger.logInfo("Validating Volume has been Increased");
            Logger.ValidateImagesChanged(imageBeforeVolumeChange, imageAfterVolumeChange, true);
        }
Example #16
0
 public void PermissionPopUpHandle()
 {
     if (KeywordImplementation.waitForObjectExist(By.Name("ALLOW"), TimeSpan.FromSeconds(3)))
     {
         KeywordImplementation.Click(By.Name("ALLOW"));
     }
     else if (KeywordImplementation.waitForObjectExist(By.Name("Allow"), TimeSpan.FromSeconds(3)))
     {
         KeywordImplementation.Click(By.Name("Allow"));
     }
 }
 public void ValidateNotes(string notes)
 {
     KeywordImplementation.Click(By.Id("Notes"));
     if (KeywordImplementation.UIObject(By.Id("Txtnotes"), TimeSpan.FromSeconds(3)).GetAttribute("value").Contains(notes))
     {
         Logger.logSuccess(string.Format("Notes '{0}' has found", notes));
     }
     else
     {
         Logger.logFailure(string.Format("Notes '{0}' has not found", notes));
     }
     KeywordImplementation.Click(By.XPath("//UIAWindow[2]//UIAButton[contains(@name,'Done')]"));
 }
Example #18
0
        private void DrawPTEAudiogramPoints(string side, string points)
        {
            Logger.logInfo(string.Format("Draw audiogram points \"{0}\"", points));
            if (KeywordImplementation.UIObject(By.Id("Txt_ActionBar_Title"), TimeSpan.FromSeconds(5)).Text.Equals("Pure Tone Estimation"))
            {
                Logger.logInfo("PTE page is selected");
                if (side.Equals("right", StringComparison.CurrentCultureIgnoreCase))
                {
                    if (KeywordImplementation.UIObject(By.Id("Btn_ActionBar_Right")).GetAttribute("name").Contains("Right") && KeywordImplementation.UIObject(By.Id("Txt_PureToneTest_FreqWithoutBg")).Text.Contains("500 Hz"))
                    {
                        Logger.logInfo("PTE right side is selected");
                    }
                }

                if (side.Equals("left", StringComparison.CurrentCultureIgnoreCase))
                {
                    if (KeywordImplementation.UIObject(By.Id("Btn_ActionBar_Right")).GetAttribute("name").Contains("Right") && KeywordImplementation.UIObject(By.Id("Txt_PureToneTest_FreqWithoutBg")).Text.Contains("500 Hz"))
                    {
                        KeywordImplementation.Click(By.Id("Img_PureToneInst_Skip"));
                        Logger.logInfo("Selecting the PTE left side");
                    }
                    if (KeywordImplementation.UIObject(By.Id("Btn_ActionBar_Right")).GetAttribute("name").Contains("Left") && KeywordImplementation.UIObject(By.Id("Txt_PureToneTest_FreqWithoutBg")).Text.Contains("500 Hz"))
                    {
                        Logger.logInfo("PTE left side is selected");
                    }
                }

                //IWebElement elementImgBtnPteIncrease = Accessor.getDriver().FindElement(By.Id("ImgBtn_PureToneTest_Increase"));
                string[] aPoints = points.Split(';');
                foreach (string point in aPoints)
                {
                    int audValue = 0;
                    audValue = (int.Parse(point) - 30) / 5;
                    IWebElement elementImgBtnPteIncrease = Accessor.getDriver().FindElement(By.Id("ImgBtn_PureToneTest_Increase"));
                    for (int i = 0; i < audValue; i++)
                    {
                        elementImgBtnPteIncrease.Click();
                        //KeywordImplementation.Click(By.Id("ImgBtn_PureToneTest_Increase"));
                    }

                    if (audValue >= 13)
                    {
                        KeywordImplementation.Click(By.Id("ImgBtn_PureToneTest_HeardUnHeard"));
                    }

                    KeywordImplementation.Click(By.Id("ImgBtn_PureToneInst_Next"));
                }
            }
        }
Example #19
0
 public void EditNotes(string notes)
 {
     Logger.logInfo("Edit the notes field");
     KeywordImplementation.Click(By.Id("Notes"));
     KeywordImplementation.TypeText(By.Id("Txtnotes"), notes);
     //s((IOSDriver<IOSElement>)Accessor.getDriver()).PressKeyCode(AndroidKeyCode.Back);
     if (TestSuite.Current.Parameters["Version"].Equals("10", StringComparison.CurrentCultureIgnoreCase))
     {
         KeywordImplementation.Click(By.XPath("//XCUIElementTypeOther/XCUIElementTypeButton[contains(@name,'Done')]"));
     }
     else
     {
         KeywordImplementation.Click(By.XPath("//UIAScrollView//UIAButton[contains(@name,'Done')]"));
     }
 }
Example #20
0
        private void EnterCode()
        {
            for (int count = 0; count < 14; count++)
            {
                KeywordImplementation.Click(By.XPath("//*[contains(@content-desc,'imageConnectHCP')]"));
            }

            KeywordImplementation.Click(By.Name("Integration"));

            KeywordImplementation.TypeText(By.XPath("//*[contains(@content-desc,'entryFieldLeft')]"), AppVariables.entryLeftCode);
            KeywordImplementation.TypeText(By.XPath("//*[contains(@content-desc,'entryFieldRight')]"), AppVariables.entryRightCode);
            ((AndroidDriver <OpenQA.Selenium.Appium.Android.AndroidElement>)Accessor.getDriver()).PressKeyCode(AndroidKeyCode.Back);
            Logger.logSnapshot();
            KeywordImplementation.Tap("Connect Now");
        }
Example #21
0
        /// <summary>
        /// Performs the playback of actions in this module.
        /// </summary>
        /// <remarks>You should not call this method directly, instead pass the module
        /// instance to the <see cref="TestModuleRunner.Run(ITestModule)"/> method
        /// that will in turn invoke this method.</remarks>
        void ITestModule.Run()
        {
            //Set HI names based on brand of APP
            BrandBasedHINames();
            string applicationName = TestSuite.Current.Parameters["AppName"];
            //	string appActivity="md56f35e8d86ebdc1429f36073ae400eed3.SplashActivity";
            string appPath = TestSuite.Current.Parameters["AppPath"];

            KeywordImplementation.LaunchiOSApp(new Uri("http://" + TestSuite.Current.Parameters["Uri"] + ":4723/wd/hub"), TestSuite.Current.Parameters["Device"], applicationName, appPath);
            //KeywordImplementation.LaunchiOSApp(new Uri("http://"+TestSuite.Current.Parameters["Uri"]+":4723/wd/hub"),TestSuite.Current.Parameters["Device"],applicationName,appPath);

            if (KeywordImplementation.waitForObjectExist(By.Id("OK"), TimeSpan.FromSeconds(5)))
            {
                KeywordImplementation.Click(By.Id("OK"));
            }
        }
        public void TapOnRecommendedHearingAid(string objectName)
        {
            var size   = Accessor.getDriver().Manage().Window.Size;
            int starty = (int)(size.Height * 0.50);
            int endy   = (int)(size.Height * 0.20);
            int startx = size.Width / 2;
            int count  = 0;

            while (count != 3 && (!KeywordImplementation.waitForObjectExist(By.Id("Txt_HIRecommended"), TimeSpan.FromSeconds(1))))
            {
                ((AndroidDriver <OpenQA.Selenium.Appium.Android.AndroidElement>)Accessor.getDriver()).Swipe(startx, starty, startx, endy, 500);
                count++;
            }

            KeywordImplementation.Click(By.Name(objectName));
        }
Example #23
0
        public void ValidateSliderSteps()
        {
            string [] sliderSteps = null;
            for (int i = 0; i < 16; i++)
            {
                KeywordImplementation.Click(By.Id("imgViewVolumeUp"));
            }

            sliderSteps = KeywordImplementation.UIObject(By.Id("seekBarVolume")).GetAttribute("name").Split('_');
            if ((sliderSteps[1].Equals(sliderSteps[2])) && (sliderSteps[2].Equals("15")))
            {
                Logger.logInfo("Volume slider has 16 steps", true);
            }
            else
            {
                Logger.logFailure("Volume slider does not have 16 steps", false);
            }
        }
 public void EditNotes(string notes)
 {
     Logger.logInfo("Edit the notes field");
     KeywordImplementation.Click(By.Id("Notes"));
     KeywordImplementation.TypeText(By.Id("Txtnotes"), notes);
     if (TestSuite.Current.Parameters["Version"].Equals("10", StringComparison.CurrentCultureIgnoreCase))
     {
         KeywordImplementation.Click(By.XPath("//XCUIElementTypeOther/XCUIElementTypeButton[contains(@name,'Done')]"));
     }
     else if (TestSuite.Current.Parameters["Version"].Equals("9", StringComparison.CurrentCultureIgnoreCase))
     {
         KeywordImplementation.Click(By.XPath("//UIAWindow[2]//UIAButton[contains(@name,'Done')]"));
     }
     else
     {
         KeywordImplementation.Click(By.XPath("//UIAScrollView//UIAButton[contains(@name,'Done')]"));
     }
 }
Example #25
0
        /// <summary>
        /// Performs the playback of actions in this module.
        /// </summary>
        /// <remarks>You should not call this method directly, instead pass the module
        /// instance to the <see cref="TestModuleRunner.Run(ITestModule)"/> method
        /// that will in turn invoke this method.</remarks>
        void ITestModule.Run()
        {
            Mouse.DefaultMoveTime        = 300;
            Keyboard.DefaultKeyPressTime = 100;
            Delay.SpeedFactor            = 1.0;

            string applicationName = TestSuite.Current.Parameters["AppName"];
            string appActivity     = "md5887522972be76f398b6ce0dd53353466.MainActivity";

            //appActivity="md56f35e8d86ebdc1429f36073ae400eed3.SplashActivity";

            KeywordImplementation.LaunchAndroidApp(TestSuite.Current.Parameters["Device"], applicationName, appActivity);

            if (KeywordImplementation.waitForObjectExist(By.Name("Skip"), TimeSpan.FromSeconds(15)))
            {
                KeywordImplementation.Click(By.Name("Skip"));
            }

            Report.Info(TestSuite.Current.Parameters["Device"]);
        }
Example #26
0
 public void ValidateRateOurApp(string AppRate, bool isPopup, int runCount)
 {
     //bool check=false;
     for (int i = 1; i <= runCount; i++)
     {
         StartApp(false);
         Logger.logInfo(string.Format("{0} Run of App", i));
         if (isPopup.Equals(true))
         {
             if (i == runCount && KeywordImplementation.waitForObjectExist(By.Name("Rate our app"), TimeSpan.FromSeconds(2)))
             {
                 Logger.logSuccess(string.Format("Rate the app pop-up found at {0}th iteration", i), true);
                 ValidateContents("Not now;No rating;Rate the App Now");
                 KeywordImplementation.Click(By.Name(AppRate));
                 //	check=true;
                 break;
             }
             else if (i == runCount && !KeywordImplementation.waitForObjectExist(By.Name("Rate our app"), TimeSpan.FromSeconds(2)))
             {
                 Logger.logFailure("Rate the app - automatic pop-up not found");
                 break;
             }
         }
         else if (isPopup.Equals(false))
         {
             if (KeywordImplementation.waitForObjectExist(By.Name("Rate our app"), TimeSpan.FromSeconds(2)))
             {
                 Logger.logFailure(string.Format("Rate the app - automatic pop-up found at {0} itteration", i));
                 break;
             }
             else if (i == runCount)
             {
                 Logger.logSuccess("Rate the app - automatic pop-up not found");
             }
         }
         CloseApp();
     }
 }
Example #27
0
        /// <summary>
        /// Performs the playback of actions in this module.
        /// </summary>
        /// <remarks>You should not call this method directly, instead pass the module
        /// instance to the <see cref="TestModuleRunner.Run(ITestModule)"/> method
        /// that will in turn invoke this method.</remarks>
        void ITestModule.Run()
        {
            string applicationName = TestSuite.Current.Parameters["AppName"];
            string appPath         = TestSuite.Current.Parameters["AppPath"];

            KeywordImplementation.LaunchiOSApp(new Uri("http://" + TestSuite.Current.Parameters["Uri"] + ":4723/wd/hub"), TestSuite.Current.Parameters["Device"], applicationName, appPath);

            if (KeywordImplementation.waitForObjectExist(By.Id("OK"), TimeSpan.FromSeconds(5)))
            {
                KeywordImplementation.Click(By.Id("OK"));
            }

            if (isPopup)
            {
                if (KeywordImplementation.waitForObjectExist(By.Name("Not now"), TimeSpan.FromSeconds(1)))
                {
                    KeywordImplementation.Click(By.Name("Not now"));
                }
                else if (KeywordImplementation.waitForObjectExist(By.Name("Später vielleicht"), TimeSpan.FromSeconds(1)))
                {
                    KeywordImplementation.Click(By.Name("Später vielleicht"));
                }
            }
        }
 public void TapEnterAudiogram()
 {
     Logger.logInfo("Tap 'Enter Audiogram'");
     KeywordImplementation.Click(By.Id("Txt_Fitting_EnterAudiogram"));
 }
 public void ClearDateField()
 {
     Logger.logInfo("Clear the date field");
     KeywordImplementation.Click(By.Id("txtDOB"));
     KeywordImplementation.Click(By.Id("Clear"));
 }
        /// <summary>
        /// Performs the playback of actions in this module.
        /// </summary>
        /// <remarks>You should not call this method directly, instead pass the module
        /// instance to the <see cref="TestModuleRunner.Run(ITestModule)"/> method
        /// that will in turn invoke this method.</remarks>
        void ITestModule.Run()
        {
            //initialising HI values globally based on the AppBrand.
            BrandBasedHINames();
            Mouse.DefaultMoveTime        = 300;
            Keyboard.DefaultKeyPressTime = 100;
            Delay.SpeedFactor            = 1.0;

            string applicationName = TestSuite.Current.Parameters["AppName"];
            string appActivity     = "md56f35e8d86ebdc1429f36073ae400eed3.SplashActivity";

            try
            {
                KeywordImplementation.LaunchAndroidApp(TestSuite.Current.Parameters["Device"], applicationName, appActivity);

//				KeywordImplementation.LaunchAndroidApp(TestSuite.Current.Parameters["Device"], applicationName, appActivity);
                Report.Info("Platform Version " + ((AndroidDriver <OpenQA.Selenium.Appium.Android.AndroidElement>)Accessor.getDriver()).Capabilities.GetCapability("platformVersion"));               ////..getCapabilities().getCapability("platformVersion")
                Report.Info("Device Name " + ((AndroidDriver <OpenQA.Selenium.Appium.Android.AndroidElement>)Accessor.getDriver()).Capabilities.GetCapability("deviceName"));

                if (KeywordImplementation.waitForObjectExist(By.Name("OK"), TimeSpan.FromSeconds(5)))
                {
                    KeywordImplementation.Click(By.Name("OK"));
                }
                var size = Accessor.getDriver().Manage().Window.Size;

                //Swipe from Bottom to Top and Top to bottom
                //Find swipe start and end point from screen's width and height.
                int  starty = 0, endy = 0, startx = 0;
                bool isTablet = size.Width >= 600;
                starty = (int)(size.Height * 0.50);
                endy   = (int)(size.Height * 0.20);
                startx = size.Width / 2;
                int count = 0;
                while (count != 3 && (!KeywordImplementation.waitForObjectExist(By.Id("Btn_AppInfo_Accept"), TimeSpan.FromSeconds(1))))
                {
                    ((AndroidDriver <OpenQA.Selenium.Appium.Android.AndroidElement>)Accessor.getDriver()).Swipe(startx, starty, startx, endy, 500);
                    count++;
                }
                Report.Success("Welcome Page screen is available");
                Logger.logSnapshot();
                KeywordImplementation.Click(By.Id("CheckBox_AcceptTAndC"));
                KeywordImplementation.Click(By.Id("Btn_AppInfo_Accept"));
                Delay.Seconds(15);
                // For SSO
//				((AndroidDriver<OpenQA.Selenium.Appium.Android.AndroidElement>)Accessor.getDriver()).Swipe(startx, starty, startx, endy, 0);
//				((AndroidDriver<OpenQA.Selenium.Appium.Android.AndroidElement>)Accessor.getDriver()).Swipe(startx, starty, startx, endy, 0);
//				//                KeywordImplementation.SwipeVerticle(3,0.50,0.20,By.XPath("//*[contains(@content-desc,'Yes, Allow')]"));
//				KeywordImplementation.Click(By.XPath("//*[contains(@content-desc,'Yes, Allow')]"));
//
                if (KeywordImplementation.waitForObjectExist(By.Name("Country"), TimeSpan.FromSeconds(3)))
                {
                    KeywordImplementation.Click(By.Name("Done"));
                }

                KeywordImplementation.TypeText(By.Id("Txt_Legitimation_Code1"), "8981");
                KeywordImplementation.TypeText(By.Id("Txt_Legitimation_Code2"), "9313");
                KeywordImplementation.TypeText(By.Id("Txt_Legitimation_Code3"), "9666");
                Report.Success("Access code screeen is available");
                Logger.logSnapshot();
                KeywordImplementation.Click(By.Name("Done"));
                Delay.Seconds(3);

                Ranorex.Report.Success(Accessor.getDriver().FindElement(By.Id("Txt_Legitimation_Msg")).Text);
                Logger.logSnapshot();
                while (count != 3 && (!KeywordImplementation.waitForObjectExist(By.Id("Continue"), TimeSpan.FromSeconds(1))))
                {
                    ((AndroidDriver <OpenQA.Selenium.Appium.Android.AndroidElement>)Accessor.getDriver()).Swipe(startx, starty, startx, endy, 500);
                    count++;
                }
                KeywordImplementation.Click(By.Name("Continue"));
                if (applicationName.Equals("com.connexx.fit2go", StringComparison.CurrentCultureIgnoreCase))
                {
                    KeywordImplementation.Click(By.Name("Done"));
                }

                Ranorex.Report.Success("Customer Ear Molds screen is available");
                Logger.logSnapshot();
                count = 0;
                while (count != 3 && (!KeywordImplementation.waitForObjectExist(By.Id("Btn_CustomMolds_Continue"), TimeSpan.FromSeconds(1))))
                {
                    ((AndroidDriver <OpenQA.Selenium.Appium.Android.AndroidElement>)Accessor.getDriver()).Swipe(startx, starty, startx, endy, 500);
                    count++;
                }
                KeywordImplementation.Click(By.Id("Btn_CustomMolds_Continue"));
                //Selecting the HIs from the list available for recommendation
                //SwitchToChooseHI();

                if (KeywordImplementation.waitForObjectExist(By.Id("Txt_CommonAlert_Title"), TimeSpan.FromSeconds(3)))
                {
                    Ranorex.Report.Success("Security alert has popped up");
                    Logger.logSnapshot();
                    KeywordImplementation.Click(By.Name("OK"));
                }

                Logger.logSnapshot();

                if (TestSuite.Current.Parameters["isTablet"].Equals("True", StringComparison.CurrentCultureIgnoreCase))
                {
                    KeywordImplementation.Click(By.Id("Tab_Cutomer_Settings"));
                }
                else
                {
                    TearDown.CloseApplication();
                    TestModuleRunner.Run(new STSAndBasic.AndroidSetUp());

                    KeywordImplementation.Click(By.Id("Btn_ActionBar_Right"), "Click on Settings");
                }
                Delay.Seconds(2);
                SwitchSettingOmniture(false);
            }
            finally
            {
                if (Accessor.getDriver() != null)
                {
                    Accessor.getDriver().Quit();
                }
            }
        }