Selenium Live Project Part-5

preview_player
Показать описание
Software Testing Live Project, Functional Test Automation using Selenium, Project Information, Project Description, Stake holders of the Project, Interfaces of the Project /AUT, Features to be Tested in Admin Interface, Features to be Tested in User Interface, Test Requirements, Test Scenarios, and Test Cases, Derive Smoke Test Cases for Admin Interface, Derive Smoke Test cases for User Interface, Derive Comprehensive (All Possible) Test Cases for Admin Interface, and Derive Comprehensive (All Possible) Test Cases for User Interface.
Рекомендации по теме
Комментарии
Автор

Class Notes:
Selenium Live Project Part-5

Writing Selenium Test Cases:

1) Verify "Launch Application" (Admin Interface) with Valid URL
2) Verify "Admin Login" with valid inputs
3) Verify Required / Important Elements in Admin Interface Index page (After Login)
4) Verify "Add Manufacturer"
5) Verify "Add Category"
6) Verify "Add Product"
7) Verify "Add Currency"
8) Verify "Track Report" (User or Product)

1) Verify "Launch Application" (Admin Interface) with Valid URL
Test Case Name: Lunch Admin Interface of the Application (gcrShop) with valid URL
Test Steps:
1) Instantiate Browser (For Selenium 3.0, it is required to Instantiate every Browser including Mozilla Firefox)
(You can launch either Firefox or Chrome or MS Edge etc...)
2) Create Browser driver instance /object
Verification Point
1) Verify Elements (Username, Password, Login) in the Login Page, if they are available then pass
Note: We can't use "Page Title" (It may duplicate), or URL (sometimes page may not open /white screen).
Test Data / Input Data
NA
Test Result / Status (Pass / Fail) : * After Test Case Execution

2) Verify "Admin Login" with valid inputs
Test Case Name: Verify gcrShop Admin Login in Admin Interface with valid Inputs (Username and Password)
Test Steps:
1) Instantiate Browser
2) Create Browser driver instance /object
4) Enter valid "Username"
5) Enter valid "Password"
6) Click "Login"

Verification Point/s:
1) Capture the Browser URL (After Login) and Compare with Expected URL

Test Data / Input Data:
1) Username: "admin"

Test Result / Status (Pass / Fail):

3) Verify "Important / Required Elements Availability and check the functionality" in gcrShop Web portal Admin Interface index page (after Logion)

Test Steps:
1) Instantiate Browser (For Selenium 3.0, it is required to Instantiate every Browser including Mozilla Firefox)
(You can launch either Firefox or Chrome or MS Edge etc...)
2) Create Browser driver instance /object
4) Enter valid "Username"
5) Enter valid "Password"
6) Enter / Click "Login" Button
* Verification for Login is Optional

Verification Point/s
Verify "Manufacturer", "Category", "Currency" and "Product" Elements availability and Check / Click...

Test Data / Input Data

Username: "admin"

4) Verify "Add Manufacturer" in gcrShop Web portal Admin Interface index page

Test Steps:
1) Instantiate Browser (For Selenium 3.0, it is required to Instantiate every Browser including Mozilla Firefox)
(You can launch either Firefox or Chrome or MS Edge etc...)
2) Create Browser driver instance /object
4) Enter valid "Username"
5) Enter valid "Password"
6) Enter / Click "Login" Button
* Verification for Login is Optional
7) Click "Manufacturer" Link
8) Select "Insert" Link
9) Enter "Manufacturer Name"
10) Upload "Manufacturer Image" * Optional
11) Enter "Manufacturer URL" * Optional

Verification Point/s
Capture Manufacturers count Before Add Manufacturer and After Add Manufacturer and Compare these two values.

Username: "admin"

Manufacturer Name: Ravindra
Manufacturer Image File * Optional
Manufacturer URL * Optional

5) Verify "Add Category" in gcrShop Web portal Admin Interface index page

1) Instantiate Browser (For Selenium 3.0, it is required to Instantiate every Browser including Mozilla Firefox)
(You can launch either Firefox or Chrome or MS Edge etc...)
2) Create Browser driver instance /object
4) Enter valid "Username"
5) Enter valid "Password"
6) Enter / Click "Login" Button
* Verification for Login is Optional
7) Click "Categories/Products" Link
8) Click "New Category" Link
9) Enter "Category Name"
10) Upload "Category Image" * Optional
11) Enter a value for Sort Order * Optional / Important
12) Click "Save" Button

Verification Point/s
Find Entered category in the Categories list and observe the sort position also

Test Data:
Username: "admin"

Category name: abcde
Category Image File * Optional
Category Sort value": 7 * Optional

Selenium Web Driver Test Batch for Admin Login Interface Smoke Tests

package abcd;

import org.openqa.selenium.By;
import
import

public class AdminInterface {

public static WebDriver driver;

public void launchApplication(){
driver = new FirefoxDriver();
}
public void closeApplication(){
driver.close();
}
public void adminLogin(String Username, String Password){



}
public void addManufacturers(String Name){




}
public void addCategory(String Name){




}
/*public void addProduct(String Name){



}*/
public static void main(String[] args) throws InterruptedException {
AdminInterface obj = new AdminInterface();
//Test Case 1: Verify "Launch Application (gcrShop Web portal Admin Interface)" using valid URL
obj.launchApplication();
boolean Username =
boolean Password =
boolean Login =

if (Username == true && Password == true && Login == true){
System.out.println("Test Case 1: "+"Username, Password, and Login Elements Exit - Passed");
}
else
System.out.println("Test Case 1: "+"Username, Password, and Login Elements Not Exit - Failed");
obj.closeApplication();
//Test Case 2: Verify "Admin Login" in gcrShop Web portal Admin Interface with valid Inputs
obj.launchApplication();
String url = driver.getCurrentUrl();

System.out.println("Test Case 2: "+"Admin Login Successful - Passed");
}
else {
System.out.println("Test Case 2: "+"Admin Login Unsuccessful - Failed");
}
obj.closeApplication();
//Test Case 3: Verify "Important / Required Elements availability" in gcrShop Web portal Admin Interface index page (after Logio
obj.launchApplication();
boolean Manufacturers =
boolean CatandProduct =

if (Manufacturers == true && CatandProduct == true){
System.out.println("Test Case 3: "+"Manufacturers, Categories, and products elements Exit - Passed");
}
else
{
System.out.println("Test Case 3: "+"Manufacturers, Categories, and products elements Not Exit - Failed");
}
obj.closeApplication();
//Test Case 4: Verify "Add Manufacturer" in gcrShop Web portal Admin Interface index page
obj.launchApplication();

int Manf_count = Integer.parseInt(Man_count);
driver.navigate().refresh();
Thread.sleep(5000);
if (Manf_count == 196){
System.out.println("Test Case 4: "+ "Manufacturer Added - Passed");
}
else {
System.out.println("Test Case 4: "+ "Manufacturer Not Added - Failed");
}
obj.closeApplication();
}
}

gcreddy
Автор

Sir please upload next video of this class

anitasalunke
Автор

Hi GC Reddy, your videos are excellent, please share the next video as well and am requesting to add few more videos on Live Project

ashokt
Автор

Sir can you please post next video of this class,

kishorekumarkalluri
Автор

Can u tell me what are the commonly used abstract methods in any selenium project

traghavendra
Автор

Sir, can we expect the next video of this class?

natalialal
Автор

Ys sir pls post next video of this class

deeptisrivastava
Автор

sir can u post next video of this class . Thank you

swethahr
Автор

If there are 100 test cases if I want to execute 1st case how to execute and also if I want to execute specific test case how to execute in selenium

traghavendra