예제 #1
0
        public void SpawnVehicle()
        {
            // Select the btn btn-link collapsed class to expand
            TaxiServiceSetMethods.Click(driver, "mb-0", "ClassName");

            //Select the transport type from the DDL
            TaxiServiceSetMethods.SelectDropDowns(driver, "ddlTransportType", "Taxi", "Id");

            //Select the ddlTransportTypeCount from the DDL
            TaxiServiceSetMethods.SelectDropDowns(driver, "ddlTransportTypeCount", "1", "Id");

            //Select the ddlTransportTypeInterval from ddl
            TaxiServiceSetMethods.SelectDropDowns(driver, "ddlTransportTypeInterval", "6", "Id");

            //Select the ddlTransportTypeSpawn from the ddl
            TaxiServiceSetMethods.SelectDropDowns(driver, "ddlTransportTypeSpawn", "m", "Id");

            TaxiServiceSetMethods.Click(driver, "btnDeploy", "Id");
        }
예제 #2
0
        public void VehicleDetails()
        {
            //Set the taxi owner mobile numbr
            TaxiServiceSetMethods.EnterText(driver, "ownerMobileNumber", "0813996357", "Id");

            //Set the taxi driver name
            TaxiServiceSetMethods.EnterText(driver, "driverName", "Zethembiso Msomi", "Id");

            //Set the taxi registration Number
            TaxiServiceSetMethods.EnterText(driver, "registrationNumber", "ND 345 678", "Id");


            //Get the values in each element
            Console.WriteLine("The value of the taxi owner mobile number is: " + TaxiServiceGetMethods.GetText(driver, "ownerMobileNumber", "Id"));

            Console.WriteLine("The value of the taxi registration number is: " + TaxiServiceGetMethods.GetText(driver, "driverName", "Id"));

            Console.WriteLine("The value of the taxi driver name: " + TaxiServiceGetMethods.GetText(driver, "registrationNumber", "Id"));
            //Click the Save button
            TaxiServiceSetMethods.Click(driver, "btnTransportOwner", "Id");
        }