ChatGPT in Software Testing
ChatGPT in Software Testing
---------------------------------------
Prompt:
As a user,
I want to log in using my email and password,
so that I can access all the features of the ecommerce application.
Acceptance Criteria:
User should be able to navigate to the login page from the homepage.
User should see fields for email and password.
User should be able to enter their email and password.
User should be able to click a "Login" button.
If the email and password are correct, the user should be redirected to their
dashboard or homepage.
If the email or password is incorrect, an error message should be displayed.
Prompt: Find syntax errors and correct the below java code.
int number = 10
if (number = 10) {
System.out.println("Number is ten");
} else {
System.out.println("Number is not ten";
}
Prompt: Find out logical errors and correct the below java code.
Prompt: Write automation test script using Selenium with Java and TestNG for the
following test case.
Prompt: Write Selenium XPath Locators for all the elements in the page
"https://demo.nopcommerce.com/"
9) Utility creation
Prompt 1: " Create an utility in java to handle excel sheet using Apache POI . I
would like to do following operations 1) Count number of rows in excel sheet 2)
Count Number of cells in a row 3) Read data from cell 4) Write data into cell.”
Prompt 2: " Create an utility in java to handle MySQL database . I would like to do
following operations 1) read data from the table 2) insert data into table 3)
update data into table 4) delete rows from a table."
Prompt 1: " Create test data for registration form in tabular format. Data includes
First Name, Last Name, DOB, Email, Password, Conform Password.”
Prompt 2: " Create test data for registration form in JSON format. Data includes
First Name, Last Name, DOB, Email, Password, Conform Password.”
AI tool google
---
Google Bard (Gemini)