Testing
<Abhishek Bhat>
DLithe Training-Software Engineering Link: https://medium.com/@abhishekbhatyelluru/dlithe-training-3962c1311a4c
My Journey Started with IT Industry: https://medium.com/@abhishekbhatyelluru/my-first-step-into-corporate-world-a964abe19c65
06/09/2022
Finally, specific stream training is started…..
We were divided into different streams in that I got Automation testing. The session is started by Ranjitha with an introduction to testing, its types, the importance of testing, and SDLC models. The afternoon session is taken by Mr. Ashok, he gave the information about the functional and performance testing followed by an introduction about the Selenium tool. Then we started with Java basics and tried some examples in the online tool. By the end of the session, we installed Java and Eclipse.
Software Testing- Testing the software against the given requirements
What?- Verifying and validating software against the requirements
When?-once code is developed and handed over to tester
Who?-Test Engineers/Testers/Software Testers
Why?-To check if the software is stable
Where?-On a software
Principles
Test to find defect
Exhaustive testing
Early testing
Defect clustering
Pesticide Paradox
Testing is context dependent Absence of errors fallacy
What is Manual Testing?
Testing the application against the given requirements manually.
What is Automation Testing?
Testing the application against the given requirements without human intervention.
1. White Box Testing : Testing performed based on knowledge of the internal program design and code.
2. Black Box Testing : Testing performed based on requirements and functionalities.
3. Grey Box Testing : Grey Box Testing is a software testing method, which is a combination of both White Box Testing and Black Box Testing method.
4. Functional Testing : Type of Black Box Testing performed to verify and validate the application against the given requirements.
5. Non Functional Testing: Type of Black Box Testing performed to test the performance, load and reliability.
6. Unit Testing :Type of testing performed by developers to test individual unit/components of a software.
7. Integration Testing: Type of testing to test integration between different modules of an application.
8. System Testing: Type of testing to test the entire system as per the requirements.
9. Performance Testing: Type of testing performed to test response time, stability and stress.
10. Load Testing: Testing the application under a range of load to determine the threshold point where the system response time deviates or fails from the normal behavior.
11. Stress Testing: Testing the application with abnormal situation.
12. Compatibility Testing: Testing the behavior of an application on different hardware/OS/Software
13. Scalability Testing : Type of Performance testing, where we test the flexibility of the application to scale up in proportion to the increasing demand of the user work load.
13. Stability Testing: Type of Non Functional testing performed to measure quality and efficiency of a software application.
15. Usability Testing : Is also known as User Experience(UX) Testing and it is a method of measuring how easy is the application to use
16. Regression Testing: Testing performed when there is a code change in the application.
17. Smoke Testing: High level testing performed after the build and before the release.
18. Sanity Testing : Testing performed to test if build is working fine after the code change.
……………………………………………………………………
Levels of testing/ types of black box testing
- Functional Testing
- Integration Testing
- System Testing
- Acceptence Testing
Component/functional Testing
Functional Testing is a type of software testing that validates the software system against the functional requirements/specifications. The purpose of Functional tests is to test each function of the software application, by providing appropriate input, verifying the output against the Functional requirements.
Types:
- Positive Testing- Positive testing, also known as “happy path testing,” focuses on testing the system or software with valid and expected inputs to ensure that it behaves as per requirements. It checks whether the software application behaves as expected with positive inputs or not
- Negative Testing-Negative Testing is a testing method performed on the software application by providing invalid or improper data sets as input. It checks whether the software application behaves as expected with the negative or unwanted user inputs. The purpose of negative testing is to ensure that the software application does not crash and remains stable with invalid data inputs.
2. Integration testing
Integration testing is a crucial part of the software testing process that focuses on verifying the interactions between different components or modules of a software application. Its primary goal is to ensure that these components work together as intended when integrated into a complete system
Types:
# Incremental Testing
#Non Incremental Testing/Big Bang Approach
Big Bang Testing/Non Incremental: Big Bang Testing is an Integration testing approach in which all the components or modules are integrated together at once and then tested as a unit. This combined set of components is considered as an entity while testing. If all of the components in the unit are not completed, the integration process will not execute.
Advantages:
- Convenient for small systems.
Disadvantages:
- Fault Localization is difficult.
- Given the sheer number of interfaces that need to be tested in this approach, some interfaces link to be tested could be missed easily.
- Since the Integration testing can commence only after “all” the modules are designed, the testing team will have less time for execution in the testing phase.
- Since all modules are tested at once, high-risk critical modules are not isolated and tested on priority. Peripheral modules which deal with user interfaces are also not isolated and tested on priority.
Incremental Testing: In this approach, different parts of the system are integrated and tested incrementally, one at a time. This is often done in a specific order, like a sequence of integration steps.
Testing is done by integrating two or more modules that are logically related to each other and then tested for proper functioning of the application. Then the other related modules are integrated incrementally and the process continues until all the logically related modules are integrated and tested successfully.
Incremental Approach, in turn, is carried out by two different Methods:
- Bottom Up
- Top Down
Stubs and Drivers are the dummy programs in Integration testing used to facilitate the software testing activity. These programs act as a substitutes for the missing models in the testing. They do not implement the entire programming logic of the software module but they simulate data communication with the calling module while testing.
Stub: Is called by the Module under Test.
Driver: Calls the Module to be tested.
- Top Down Integration Testing
is a method in which integration testing takes place from top to bottom following the control flow of software system. The higher level modules are tested first and then lower level modules are tested and integrated in order to check the software functionality. Stubs are used for testing if some modules are not ready.
Advantages:
- Fault Localization is easier.
- Possibility to obtain an early prototype.
- Critical Modules are tested on priority; major design flaws could be found and fixed first.
Disadvantages:
- Needs many Stubs.
- Modules at a lower level are tested inadequately.
- Bottom-up Integration Testing
is a strategy in which the lower level modules are tested first. These tested modules are then further used to facilitate the testing of higher level modules. The process continues until all modules at top level are tested. Once the lower level modules are tested and integrated, then the next level of modules are formed. Drivers are used for testing if some modules are not ready.
Advantages:
- Fault localization is easier.
- No time is wasted waiting for all modules to be developed unlike Big-bang approach
Disadvantages:
- Critical modules (at the top level of software architecture) which control the flow of application are tested last and may be prone to defects.
- An early prototype is not possible
3. System Testing
Type of testing to test the entire system as per the requirements.
4. Acceptance testing
software or system is tested to determine if it meets the specified requirements and is ready for use in its intended environment.
- Accept
- Reject
- Accept with new build
Types:
- Alpha Testing
- Beta Testing
Alpha Testing is a type of acceptance testing; performed to identify all possible issues and bugs before releasing the final product to the end users. Alpha testing is carried out by the testers who are internal employees of the organization.
Beta Testing is performed by “real users” of the software application in “real environment” and it can be considered as a form of external User Acceptance Testing. Beta version of the software is released to a limited number of end-users of the product to obtain feedback on the product quality. Beta testing reduces product failure risks and provides increased quality of the product through customer validation.
Difference:
- Alpha Testing is performed by the Testers within the organization whereas Beta Testing is performed by the end users.
- Alpha Testing is performed at Developer’s site whereas Beta Testing is performed at Client’s location.
white box testing Techniques/Types
- Unit Testing-typically perform unit testing to verify that each part of the code functions correctly.
- Satatement — This technique measures the percentage of statements in the code that have been executed during testing. It aims to ensure that all code statements are tested at least once.
- Path- Like a flowchart-Path coverage aims to test all possible execution paths through the code, including loops and conditionals. It is a more comprehensive form of white box testing
- Condition-Branch coverage assesses the execution of different branches in the code, particularly in conditional statements (e.g., if-else). It helps ensure that all decision points are thoroughly tested.
Regression testing
Regression testing is a software testing technique used to ensure that new code changes or updates to a software application do not adversely affect the existing functionality. It involves re-running previously executed test cases to verify that the changes haven’t introduced new bugs or caused unintended side effects.
unit regression-changed modules checking
regional regression-checking related modules
full regression-checking complete website
Retesting
Retesting is the process of testing a specific part of the software that failed in a previous test. It is done to verify that the reported defects have been fixed correctly.
Recovery Testing
- Recovery testing, also known as resilience testing, assesses how well a system can recover from failures or crashes. It aims to ensure that the software can continue functioning after unexpected events or errors.
- Scenarios: Test scenarios may include sudden power loss, hardware failures, network interruptions, software crashes, and data corruption
Reliability Testing
- Reliability testing focuses on assessing the stability and consistency of a system’s performance over time. It is used to determine how reliable a software product is under normal operating conditions.
- Scenarios: Reliability testing involves running the software for an extended period under standard usage conditions to identify potential failures or inconsistencies.
Globalization testing
Globalization testing is a process of evaluating how well a software application can handle different languages, regional preferences, and cultural differences, without any code changes.
- Internationalization Testing: Focuses on making the software codebase adaptable for different locales.
- Localization Testing: Ensures that the application behaves correctly when translated into a specific language or adapted for a particular region.
- international-checking whether correct content(language) is displaying
localiztion-checking formats(img,country code,pin code)
Sanity Testing
Sanity testing is a kind of Software Testing performed after receiving a software build, with minor changes in code, or functionality, to ascertain that the bugs have been fixed and no further issues are introduced due to these changes. The goal is to determine that the proposed functionality works roughly as expected
- The main objective of sanity testing is to verify that the recent changes, enhancements, or bug fixes have not adversely affected the core functionality of the software.
- Only Manual Testing..No automation
Smoke Testing
Smoke Testing is a software testing technique performed post software build to verify that the critical functionalities of software are working fine
- sanity — checking basic function + previous bugs solved or not
- smoke testing — basic + critical(In depth testing). Type of UAT testing
- Smoke test is done to make sure that the critical functionalities of the program are working fine, whereas sanity testing is done to check that newly added functionalities, bugs, etc., have been fixed.
- Smoke testing is a subset of acceptance testing whereas Sanity testing is a subset of Regression Testing.
- Smoke Testing is done by both developers or testers whereas Sanity Testing is done by testers.
In summary:
- Smoke Testing is an initial, minimalistic test to check if the software build is stable.
- Sanity Testing is a focused test to ensure that recent changes or fixes haven’t adversely affected specific parts of the application.
- Regression Testing is a comprehensive test that verifies the overall quality and stability of the software after making changes
Compatibility Testing
Compatibility Testing is a type of Software testing to check whether your software is capable of running on different hardware, operating systems, applications, network environments or Mobile devices.
comaptibily testing- Ex. edge,chrome,linux
compatibily issue- Ex. It will work in one browser and it will not work in another browser.
functionality issue- Not working in any browser
Compatibility testing types
- Hardware: It checks software to be compatible with different hardware configurations.
- Operating Systems: It checks your software to be compatible with different Operating Systems like Windows, Unix, Mac OS etc.
- Software: It checks your developed software to be compatible with other software. For example, MS Word application should be compatible with other software like MS Outlook, MS Excel, VBA etc.
- Network: Evaluation of performance of a system in a network with varying parameters such as Bandwidth, Operating speed, Capacity. It also checks application in different networks with all parameters mentioned earlier.
- Browser: It checks the compatibility of your website with different browsers like Firefox, Google Chrome, Internet Explorer etc.
- Devices: It checks compatibility of your software with different devices like USB port Devices, Printers and Scanners, Other media devices and Blue tooth.
- Mobile: Checking your software is compatible with mobile platforms like Android, iOS etc.
- Versions of the software: It is verifying your software application to be compatible with different versions of the software. For instance checking your Microsoft Word to be compatible with Windows 7, Windows 7 SP1, Windows 7 SP2, Windows 7 SP3.
Installation Testing
Installation testing, also referred to as setup testing, is the process of testing the installation and uninstallation of a software application. It ensures that the installation process is straightforward, error-free, and that the application functions correctly once it is installed on a user’s system. This type of testing focuses on verifying that the software can be easily installed on different environments and that it does not interfere with existing software or system configurations
Migration Testing
It involves testing the migration of data, applications, or systems from one environment to another. The primary goal of migration testing is to ensure that the migration process is successful and that data and functionality are preserved throughout the transition.
- Data Migration Testing: This focuses on the accuracy and completeness of data transferred during migration.
- Application Migration Testing: Ensures that applications work as expected in the new environment.
Ad hoc Testing/Monkey Testing
Ad hoc Testing is an informal or unstructured software testing type that aims to break the testing process in order to find possible defects or errors at an early possible stage. Ad hoc testing is done randomly and it is usually an unplanned activity which does not follow any documentation and test design techniques to create test cases.
Exploratory Testing
Testers explore the application to find defects, usability issues, and other potential problems. Exploring such a way that we should get a bug.
Static Testing
Static testing is a type of software testing that does not involve the actual execution of the software. Instead, it focuses on examining the code, design, and documentation to identify issues, defects, and potential problems.
Dynamic Testing
Dynamic testing, on the other hand, involves the execution of the software to observe its behavior and functionality. This type of testing verifies that the software works as intended and meets its requirements.
STLC
1.Req analysis
2.Writting test plan
3.Test cases
4.Tracebility matrix
5.Test execution
6.Defect tracking
7.Test closure/Test execution report
Req analysis
1. implicite req- req not given by customers, added by BAs
2. Explicite req- req given by customer
Tracebility Matrix
1. Req tracebility matrix -mapping Testcase ID and Req ID
2. Defect tracebility matrix- Mapping testcase ID and defect Number
Testcase
*Req analysis
*Identifying all scenarios
*writting test case using testcase design techniques
*Review of Testcase
*approval of testcase
*store it in repository
Testcase design Techniques
- Boundry value analysis= A-1, A+1, A
boundry value, Nominal value, max+1,max-1. Writing tc for boundary values then nominal values and min-1 and max+1
2. Error guessing- Testers with their domain knowledge and experience guess the negative scenarios.
3. Equivalence partitioning- Writing the test cases based on dividing the input domain into equivalent classes.
Review of TC
1.Peer review-
2.Approval of cases-
Bug Life cycle
1.New
2.Assign
3.Open — —
*Reject
*Differed
4.Fixed
5.Test — — -Reopen(back to OPEN state)
6.Verify
7.close
Severity — It is a degree of impact that a defect or issue has on the software’s functionality of an application.
Priority — It is the measure of the importance to adderess the defect.
Defect riaging — When there is more number of bugs we need to prioratize the bugs based on risk, severity and how frequently bug is raising.
Software: It is a collecion of computer programs that helps us to perform a task.
Types of software:
- System S/M : Device drivers- Mouse, keyboard, 05
2. Programming S/w : Compilers, Interpreters
3. Application s/w : Web Applicatons, Mobile Apps, Desktop Apps — Snipping Tool
Software Quality : How good our project is working.
Why do we need testing? : To verify and validate if project/product met specified requirements.
Project- If s/w is developed based on specific customer based requirements. Service Based Company
Product- if s/w is developed based on market based requirements. Product based company.
Error vs Bug vs Failure
Error- It is created by human(developer edits the code)
Bug/Defect :Tester finds the bug
Failure-If tester missed to tell the presence of bug. moved to the end user. end user found bugs.
Testing Phases:
- SRS provided to testers
- Review SRS
3. Test Plan- Testers
4. Test Cases
5. Reviewed by ST/ Team Lead /Manager
6. Update Test Case
7. Execution
Performance Teeting: How much time it takes to respond.
Functional Testing- When we enter Password & email. It must show an Inbox of mail…
Selenium
Selenium is an open-source tool that automates web browsers. It provides a single interface that lets you write test scripts in programming languages like Ruby, Java, NodeJS, PHP, Perl, Python, and C#, among others.
What is Java?
Java is a programming language and a platform. Java is a high level, robust, object-oriented and secure programming language.
Why Selenium with Java?
A large number of users for Selenium with Java
Stronger community options
Selenium is also developed by Java
More than 80% of experts prefer to work Selenium with Java
Learning Java and its set of libraries gives you greater potential for testing
Programs written in Java are faster than python
*******************************************************************
07/09/2022
Good to go with the day two of training. Ranjitha started with the Agile methodology terms, what is QA,QE,QC and STLC, Types of testing in detail. The afternoon session is taken by Ashok, covered the Java loops, switch statement, Function declaration and function calling. We had a 6 assignment questions to solve based on above concepts
static Testing Techniques
1. Review: Correctness and completeness
2. walkthrough :connect with 2/3 persons
3. Inspection :Inspection Most formal review
a. Reader
b. writer
c. Moderator
Dynamic Testing Techniques
1. Unit Testing
2. Integration Testing
3. System tesing
4. UAT
QA, QC, QE
QA-Quality Assurance
Related to process
Building quality s/w
try to prevent the defects
SDLC
QC-Quality Control
Related to actual s/w testing (project/product)
Test the quality
findout the defects
part of sdlc
QE Quality Engineering
Agile Methodology
Scrum: Some of principle in agile methodology
Scrum Team:
- Product owner :Declare what to do ? why.
- scrum master: Team lead, Connect with all.
- Dev Team :Do the development.
Product backlog — The whole project plan is there in product backlog
User Story : needs of the customer
Epic :Collection up user stories.
Sprint :Divided to them, have specific time (3–4 week) to Complete the work
Sprint Planning meeting -
Sprint backlog -
Scrum meeting
retrospective meeting: At last
Burn down chart
STLC
STLC stands for Software Testing Life Cycle. STLC is a testing strategy performed by the testing team ensuring software quality standards are met. STLC is not to be confused with (SDLC) Software Development Life Cycle. SDLC embodies all software development phases while the software testing life cycle only focuses on the test phases
Software Testing Life Cycle is a subset of the Software Development Life Cycle
STLC v/s SDLC
There are differences between STLC and SDLC. The main difference is, Software Testing Life Cycle is a subset of the Software Development Life Cycle. Whereas, SDLC embodies the entire software creation process- from concept to completion. Testing software is a vital part of software creation. Therefore, STLC is a set of processes in the testable portions of creating software.
Software Testing Life Cycle is a subset of the Software Development Life Cycle .In the STLC process, various activities are carried out to improve the quality of the product. STLC is a testing strategy performed by the testing team ensuring software quality standards are met
However, STLC phases only deal with testing and detecting errors but not development itself.
Different companies define different phases in STLC. However, generic Software Test Life Cycle has the following stages.
- Requirement Analysis
- Test Planning
- Test Design
- Test Environment Setup
- Test Execution & Closure
Java………………
While Loop
Syntax:
initialization;
while (condition)
{
statements;
incrimination / decrementation of number
}Example:
int i=1;
while(i<=10)
{
statements;
i++ OR i=i+1; OR i-- OR i=i-1;
}
For Loop
Syntax:
for(initialization; condition; incrimination / decrementation)
{
statements;
}Example:
For(int i=1; i<=10;i++)
{
Statements;
}
Do-While Loop
syntax:
initialization
do
{
statements;
incrimination / decrementation of number
}while(condition);*******************************************************************
08/09/2022
Full Day session is taken by Ranjitha. Started with Blackbox techniques with example and some task given to us based on these topics. Then She given two coding question to solve and my friends stared discussing about the testing role because most of them want developer role and all are not happy with the testing role. Ranjitha tried her level best to explain the importance of testing and she motivated us too.
Black Box Testing Techniques:
1. Error Guessing
2. Boundary Value Analysis
3. Decision Table Technique
4. State Transition Technique
5. Equivalence Partitioning
Error Guessing : Is a technique in which testers use their skills and try to find bugs.
Requirement 1: Pin code Field- should be integer field and length =6. List down the negative scenarios where it may lead to defect.
Pincode field=6
Digits only
Error scenarios:
12345f- character error
2432@3-special case error
000000-zero error
123456- requires strong password
2134-less than 6 digit
123413255435- limit crossed
6363 3- No space
Equivalence Partitioning: Is a technique in which testers divide the input data into equal classes of data through test case
can be derived.
Requirement : To vote valid age is 18 or more. Divide input need to be provided to different classes.
valid age-18
1–8 — Cant vote
9–17 — Cant vote
valid votes:
18–28
29–38
39–48
49–58
59–68
69–78
79–88
89–98
99–108
Boundary Value Analysis : Boundary testing is the process of testing between extreme ends or boundaries between partitions of
the input values.
Requirement : To vote valid age is 18. Divide input need to be provided to different classes and find the boundary values need to tested.
A-1, A,A+1
10 Digit number
A-1=9 digit number-invalid
A=10-Testcase pass
A+1=11 digit number- invalid
Decision Table Technique : Is a software testing technique used to test system behavior for different input combinations, conditions
and rule criteria.
Requirement : Food company named ‘A’ having the offers to its customers as below.
New Customer = 15%
Old Customer = 10%
Coupon Code = 20%
3 condition are there.. So 2 the power of 3=8 rules
State Transition Technique :Is a software testing technique in which input provided causes the change in state changes.
*****************************************************************************
09/09/2022
In this day we learn about the test plan, how to write a test plan, test plan formats and we wrote a sample test plan as a assignment. Ranjitha explained the all fields in the test plan. In afternoon session Ashok started with the array concepts like one-dimensional array, two-dimensional array and he explained how agile methodology works in industry as he is a 16 years experience in IT field.
Test Plan Template:
Introduction:
Describe the purpose of the Plan, possibly identifying the level of the plan (System Test Plan etc.). This is essentially the executive summary part of the plan.
Features to be Tested:
This is a listing of what is to be tested from the Users viewpoint of what the system does. This is not a technical description of the software, but a Users view of the functions.
Features not to be Tested:
This is a listing of what is NOT to be tested from both the Users viewpoint of what the system does and a configuration management/version control view. This is not a technical description of the software, but a Users view of the functions.
Test Approach:
This is your overall test strategy for this test plan; it should be appropriate to the level of the plan (master, acceptance, etc.) and should be in agreement with all higher and lower levels of plans. Overall rules and processes should be identified.
Entry Criteria:
It describes when to start Testing
Exit Criteria:
It describes when to stop testing
Suspension Criteria:
It describes when to stop testing temporarily.
Roles & Responsibilities
Team Lead or Test Lead and Team members Roles and Responsibilities.
Schedule:
Schedule for all Test activities in this Software Test Process.
Training:
Training on the application/system (Domain Training)
Training for any test tools to be used.
Test Environment / Lab:
It describes Require Hardware and software for setting-up Test Environment or Test Lab.
Test Deliverables:
Lists out that what is to be delivered as part of this plan?
Approvals
Who can approve the process as complete and allow the project to proceed to the next level.
Java Array
Arrays are used to store multiple values in a single variable, instead of declaring separate variables for each value.
Following are the advantages of using array in Java:
- Using arrays increases code optimization.
- Ordered and indexed data structure to store the same type of elements.
- Elements of an array get stored in consecutive memory locations.
- The array can store variables as well objects of a class.
Following are the disadvantages of using array in Java:
- An array can only store the same type of elements.
- Adding and removing elements in between is hard.
Syntax of One-dimensional array in Java:
//declarationint iArray1[] = new int[4];//initializationiArray1[0] = 32;iArray1[1] = 13;iArray1[2] = 56;iArray1[3] = 78;//declaration and initialization of the 1D-arrayint[] numbers = {12, 4, 5, 2, 5};
Syntax of Multidimensional array in Java:
//declarationint matrix[] = new int[2][2];//initializationmatrix[0][0] = 1;matrix[0][1] = 2;matrix[1][0] = 3;matrix[1][1] = 4//declaration and initialization of the 2D-arrayint arr[][]={{1,2,3},{2,4,5},{4,4,5}};
****************************************************************************
12/09/2022
We covered the requirement traceability matrix, RTM, Types of RTM and we learn how to write the test scenario. Ranjitha explained the difference between the test scenario and the test case. In the afternoon session we started with the Java strings and some assignment programs on java strings. Later we moved to the new concept, that is oops. We learnt classes, object with example and also we covered the constructor topic as well..
What is RTM?
RTM is a table where you can link the test cases to the requirements and vice-versa. It is also called as Cross Reference Matrix
Traceability matrix is a table type document that is used in the development of software application to trace requirements. It can be used for both forward (from Requirements to Design or Coding) and backward (from Coding to Requirements) tracing. It is also known as Requirement Traceability Matrix (RTM) or Cross Reference Matrix (CRM)
Why and when we need RTM?
* To ensure all requirements are covered.
* It helps in displaying the complete test execution and bugs status based on requirement.
*Used in complex projects. Also can be used in small projects.
Types of RTM
Forward traceability
Backward or reverse traceability
Bi — directional traceability
Test case Scenario for Gmail registration and login page
Registration page
Scenario 1- Check user is navigating to gmail registration page when clicking on registration url. https://gmail.registration//
Scenario 2- Check url is opening or not
Scenario 3- Check for attributes/fields on registration page
Scenario 4- Password and Confirm Password field should match.
Scenario 5- Check for registration button
Login Page
Scenario 1- Check user is navigating to gmail login page when clicking on login url. https://gmail.login//
Scenario 2 -Valid username and password.
Scenario 3 -For password functionality.
Scenario 4- Forgot Username functionality.
Scenario 5- If registered user, one should be able to login
Scenario 6- If not register user, system should show notification to get registered.
Scenario 7- Enter Username and blank password
Scenario 8- vice versa of 8
Scenario 9- Login Button
Java
What is an object in Java
An entity that has state and behavior is known as an object e.g., chair, bike, marker, pen, table, car, etc. It can be physical or logical (tangible and intangible). The example of an intangible object is the banking system.
class
A class is a group of objects which have common properties. It is a template or blueprint from which objects are created. It is a logical entity. It can’t be physical.
new keyword in Java
The new keyword is used to allocate memory at runtime. All objects get memory in Heap memory area.
Constructors:
1. Is nothing but a special function which will have same name of the class.
2. Constructors are mainly used for initialization of the data
3. Constructors will not return any value not even void also
4. No need to call constructors like functions it will execute automatically when object is created
There are 2 types of constructors
1. Default Constructor: Which will not take any parameters
2. Parameterized Constructor: This will take the parameters
**************************************************************
13/09/2022
We learnt how to create a user stories in Jira tool. Adding a team members to the project and creating a test case in Jira tool is covered in this session. Then Ranjitha Started the topic, called defect life cycle. Then we learnt about the difference between the severity and priority. In the Ashoks session we started with the polymorphism concept and overriding then programming examples.
What is Defect Life Cycle ?
Journey in which raised bug will be fixed , retested and closed .
Defect Life Cycle- Terminologies
New- When defect is figured out by QA , the status of defect will be NEW .
New Defects can be changed to any of the following status .
Open- Raised defect is considered by developers and ready to fix .
Rejected- Raised defect is considered as not a defect .
Duplicate- Already similar defect is raised
Deferred- Developer considered the defect but postponed to fix it in next release .
Fixed- Developers worked on the raised defect and now it is ready to be tested
Closed- Tested by testers and if it is working as expected , defect will be closed
Reopen- Tested by testers and if it is not working as expected , defect will be reopened .
Java
Get Abhishekbhat’s stories in your inbox
Join Medium for free to get updates from this writer.
Polymorphism means “many forms”, and it occurs when we have many classes that are related to each other by inheritance.
It means many forms. In common words, polymorphism refers to the ability of multiple objects sharing the same name, but having different structures or serving different functionalities in different contexts. Polymorphism can be easily observed in function overloading and function overriding.
Function Overloading
3 Rules: No of parameters, Sequence of parameters, Datatype
example:
add()
add(int a)
add(float a)
add(int a,int b) add(int a, float b) add(float a, int b)
***************************************************************************
14/09/2022
In the morning session, we used to get the Jira tools and we created a test case for Gmail and how to make the documentation during the testing by taking the screenshots or using the snipping tool for future reference. In the afternoon session we started with the static keyword concept, which includes static variable, static function and static block. We also covered the inheritance concept and its types using example programs.
Java
Static key word in java:
The static keyword is used in java mainly for memory management. We may apply static
keyword with variables, methods, blocks and nested class. The static keyword belongs to the class than instance of the class.
Static variable:
If you declare any variable as static, it is known static variable.
The static variable can be used to refer the common property of all objects (that is not unique for each object) e.g. company name of employees, college name of students etc.
The static variable gets memory only once in class area at the time of class loading.
Advantage of static variable:
It makes your program memory efficient (i.e it saves memory).
Suppose there are 500 students in my college, now all instance data members will get memory each time when object is created. All student have its unique roll no and name so instance data member is good. Here, college refers to the common property of all objects. If we make it static, this field will get memory only once.
Static method:
If you apply static keyword with any method, it is known as static method
A static method belongs to the class rather than object of a class.
A static method can be called without the need for creating an instance(object) of a class.
Static methods called by classname. ex classname.methodName();
Static method can access only static data member and can change the value of it.
Restrictions for static method:
The static method cannot use non static data member or call non-static method directly.
This and super keywords cannot be used in static context.
Static block:
Is used to initialize the static data member.
It is executed before main method at the time of class loading
Why main method is static?
Because object is not required to call static method if it were non-static method, jvm create object first then call main() method that will lead the problem of extra memory allocation
Inheritance
Inheritance is one of the important concepts in OOPs that allows (child) classes to establish a sense of hierarchy by inheriting the attributes and methods of another (parent) class. This reduces redundancy as classes can share common logic, structure, and attributes while enforcing a clear hierarchy.
Types of Inheritance
single-> Parent(Base class)- Son/Daughter (Derived class)
Multiple-> Father and Mother (2 Base classes) Son/Daughter (Derived class) ->Disadvantages (Name Collision)
Java does not support multiple inheritance however it can implemented using Interfaces.
Multi-level- GrandParents ->Parents (Derived (GP) and Base (S/D))->Son/Daughter (Derived class)
Hybrid combination of 2 or more inheritance
***************************************************************************
15/09/2022
We continued with the Jira tool, we created a another two test case and raised a bug and learnt how the bug will be raise and assigned to the developers. We wrote the Requirement traceability matrix after the execution in Jira tool. In afternoon session we learnt about the method overriding and use of “Super” key in it. Next concept is all about the abstract class and abstract method . We also learnt about the “interface” keyword, what is the difference between abstract and interfaces and multiple inheritance will be implemented using these interfaces. “Final” keyword is also covered, what its use and how it will be used in the programming. Lastly about the packages and Ashok explained the use of Git in industry…
Java
What is Method Overriding
When the child class(subclass) has the method which has the same name, same parameters and same return type (or covariant return type) as a method in its parent class(or super-class), then the child method has overridden the parent class method.
Method Overriding is to enhance the code, edit the code or to add some code
super Keyword in Java Overriding
To access the method of the superclass from the subclass, we use the “super” keyword.
package javaoops;class car
{
void cars()
{
System.out.println("We have a veriety of cars");
}
}public class MethodOverriding extends car
{
public static void main(String[] args) {
MethodOverriding obj=new MethodOverriding();
obj.cars(); // It will call the local method(line no 20)}
void cars()
{
super.cars(); // It will inherit the super class
System.out.println("BMW is the best");
}}
Data abstraction is the process of hiding certain details and showing only essential information to the user.
Abstract class in Java
A class which is declared as abstract is known as an abstract class. It can have abstract and non-abstract methods(normal methods).
Points to Remember
- An abstract class must be declared with an abstract keyword.
- It can have abstract and non-abstract methods.
Abstract Method in Java
A method which is declared as abstract and does not have implementation is known as an abstract method.
package javaoops;abstract class employee{ abstract void details(); //No difinition void name() { System.out.println("Company name is Evry"); }}public class AbtractExample extends employee {public static void main(String[] args) { AbtractExample obj=new AbtractExample(); obj.details(); obj.name();} void details() { System.out.println("Employee Id is 123"); }}
Interface
An interface is a fully abstract class. It includes a group of abstract methods (methods without a body).
It is used to achieve abstraction and multiple inheritance in Java.
To use an interface, other classes must implement it. We use the implements keyword to implement an interface.
- Interface methods do not have a body — the body is provided by the “implement” class
- On implementation of an interface, you must override all of its methods
- Interface methods are by default
abstractandpublic - Interface attributes are by default
public,staticandfinal
package javaoops;interface vehicle{void cardetails();}public class InterfaceExample implements vehicle{public static void main(String[] args) {InterfaceExample obj=new InterfaceExample();obj.cardetails();}public void cardetails(){System.out.println("Car number is 123");}}
Multiple Inheritance using Interfaces
Final Keyword
*************************************************************************
16/09/2022
Morning session is all about the Jira tool. Ranjitha explained again as revision from the scratch that is creation of the project to the raising a bug. We also learnt about the cycle test in Jira tool. Then we had a team presentation, that is to note the user story for particular website. Our website is BookmyShow, so we noted all the user stories possible and presented with team. In the afternoon session , we started with the package concept like importing package from another packages. Later we moved to the Access specifier, we came know the difference between the public, private and protected. We also covered the exception handling topic and it will be used in programs with try and catch method…That's all for the day…………
Package in Java:
A package is a group of similar types of classes, interfaces and sub-packages.
Package can be categorized in two form
- Built-in Packages (packages from the Java API)
- User-defined Packages (create your own packages)
Built-in package and user-defined package. There are many built-in packages such as java, lang, awt, javax, swing, net, io, util, sql etc.
Advantage of Package:
Creation of Package:
Package packageName; // this package contains class called Example
How to access package from another package?
There are three ways to access the package from outside the package.
1.import packagename.*; It will import all the class and interfaces to this package. It is recommended not to use this as it will impact on performance as it as to load all the class.
2.import packagename.classname;
3.fully qualified name.
Using packagename.*:
If you use package.* then all the classes and interfaces of this package will be accessible but not subpackages.
The import keyword is used to make the classes and interface of another package accessible to the current package.
Example: import packageName.*
Using packagename.classname:
If you import package.classname then only declared class of this package will be accessible.
Example: import of packageName.ClassName
Access specifiers
- Private: The access level of a private modifier is only within the class. It cannot be accessed from outside the class.
- Default: The access level of a default modifier is only within the package. It cannot be accessed from outside the package. If you do not specify any access level, it will be the default.
- Protected: The access level of a protected modifier is within the package and outside the package through child class. If you do not make the child class, it cannot be accessed from outside the package.
- Public: The access level of a public modifier is everywhere. It can be accessed from within the class, outside the class, within the package and outside the package.
Exception Handling:
The exception handling is one of the powerful mechanism provided in java. It provides the mechanism to handle the run time errors so that normal flow of the application can be maintained.
Exception Dictionary Meaning: Exception is an abnormal condition.
In java, exception is an event that disrupts the normal flow of the program.
Let’s take a scenario:
1.statement 1;
2.statement 2;
3.statement 3;
4.statement 4;
5.10/0;
6.statement 6;
7.statement 7;
8.statement 8;
9.statement 9;
10.statement 10;
Suppose there is 10 statements in your program and there occurs an exception at statement 5, rest of the code will not be executed i.e. statement 6 to 10 will not run. If we perform exception handling, rest of the code will be executed. That is why we use exception handling.
****************************************************************************
17/09/2022
We started the day with the activity conducted by Karthiya. We had two activities and presented with our team. After we started doing the task given by Ranjitha about the test case writing. In the afternoon session, we had Exception handling, about the “Finally” keyword and then Throw concepts. After that, we started with the automation part, about selenium and its some common terminologies. Then we added selenium IDE to our chrome and did sample automation testing and downloaded the Maven project to Eclipse.
Introduction to Automation Testing
Automation is the process of using a program to execute user transactions against the system . This is achieved by using an automated test tool .
Types of Automation Testing :
Functional automation testing
Non — functional automation testing
Functional Automation Testing : Automating the functional manual test cases to test the functionality of the system is as expected by using any of the functional automation tools . Some of the functional automation tools available in the market are QTP , Silk Test , Selenium , VSTS etc. Majority of the time regression , smoke and build tests are
automated .
Non — functional automation testing : This testing is used see how soon system is responding to the user with respect to time like performance , stress testing . Here we are not testing the functionality of the system .
Ex : after clicking login how much time system is taking to display inbox to the user . Some of the Non — functional automation tools available in the market are Load runner , VSTS , Silk Performer etc.
What is Selenium?
Selenium is an open source automation testing tool for testing only web based applications. It cannot test your desktop application. Selenium supports multiple browsers. It’s easy to use, strong and is very flexible. You can work on many operating systems and you can code in many programming languages using selenium.
i) Languages supported by Selenium:
a) Java
b) C#
c) Ruby
d) Python
e) PHP
f) Pearl
ii) Browsers supported by Selenium:
a) Mozilla
b) IE
c) Google chrome
d) Opera
iii) Operating systems Supported by Selenium:
a) Windows
b) Mac
c) Linux
d)Unix
e) Android
Components of Selenium:
Selenium IDE:
Is an add on to Mozilla Firefox and Chrome. It’s got a strong feature of record and playback. It supports HTML as source language.
Selenium RC:
This is the older version of selenium. It works on multiple browsers. RC can be implemented in any one of the programming languages mentioned above.
RC is the older version of selenium. It works on multiple browsers & operating systems. In Selenium RC, whatever code we write in the supported language is converter to JavaScript by the remote control server. This helps our program to interact with the application. These JavaScript commands are sent to the Application under test (AUT) .Because of this JavaScript dependent behavior, and the limitation applied to JavaScript by the browsers, automation using Selenium RC is not very effective. This led to the invention of Selenium Web driver.
Selenium Web Driver:
Is the new version of selenium. It also works on multiple browsers. Its removed many drawbacks and issues in Selenium RC. It also supports Android and IPhone Testing.
Why is Selenium Web driver better than Selenium RC? :
i) Selenium-Web Driver makes direct calls to the browser using each browser’s native support for automation.
ii) Selenium-RC ‘injected’ JavaScript functions into the browser when the browser was loaded and then used its JavaScript to drive the AUT within the browser.
iii) Web Driver does not use this technique. Again, it drives the browser directly using the browser’s built in support for automation.
iv) Web Driver is faster compared to RC as it directly interacts with the browser
Selenium Grid:
Grid is used to run test cases parallel on multiple machines and browsers. It is used for Compatibility Testing
Selenium identifies Objects / Web Elements / Fields in AUT (Application Under Test) using below properties
CSS(Cascading Style Sheets)
Id
Name
Link
Xpath
1. Id: Selenium uses object id to identify the objects in the application.
syn: id = id name
2. Name: Selenium uses object names to identify the objects in the application.
syn: name= name of the element
3. LinkText syn: This is a simple method of locating a hyperlink in your web page by using the text of the link. If two links with the same text are present, then the first match will be used.
4. Xpath:
XPath is the language used for locating nodes in an XML document. As HTML can be an implementation of XML (XHTML), Selenium users can leverage this powerful language to target elements in their web applications.
5. CSS syn:
CSS (Cascading Style Sheets) is a language for describing the rendering of HTML and XML documents. CSS uses Selectors for binding style properties to elements in the document. These Selectors can be used by Selenium as another locating strategy.
Below shown is the selenium IDE example we did on the HRM website
**************************************************************
19/09/2022
In the morning we had a presentation, Ranjitha divided some important topics among the team members and my team topic is validation vs verification. After discussing with the team, we presented the topic. In the afternoon session, we started with the selenium automation testing. We wrote the code for Facebook signup and login of HRM using eclipse.
The internal structure of Web drivers in Selenium
Web Driver is the key interface against which tests are written, but there are several implementations.
These classes are implementing the WebDriver interface:
a) Html Unit Driver
b) Firefox Driver
c) Internet Explorer Driver
d) Chrome Driver
e) Opera Driver
f) iOS Driver
g) Microsoft Edge
Downloading Chrome driver
a) website: https://chromedriver.chromium.org/downloads
b) Depending on your chrome browser version, select the link.
c) Download and extract the zip file in your system.
Introduction to Maven
Maven is a powerful project management tool that is based on POM (project object model). It is used for projects build, dependency and documentation. It simplifies the build process like ANT. But it is too much advanced than ANT. In short terms we can tell maven is a tool that can be used for building and managing any Java-based project. maven make the day-to-day work of Java developers easier and generally help with the comprehension of any Java-based project.
Creating a maven project
a) Go to eclipse IDE, create a new project of type Maven project.
b) Click on next, and select the Maven archetype quickstart
c) Click on next and enter a group ID (folder name) and the artifact ID.
d) A new folder by the name of the group ID will be created in project explorer. Click on pom.xml file.
e) Changes need to be done in this file. Go to the dependencies tag and we have to add chrome dependency code.
f) Next enter the src/test/java file and create a new package in it.
g) Inside that package create a new class.
h) Once class is created, that’s it. You can now use this package to perform basic automation testing.
*******************************************************************
20/09/2022
In this session, we had fun with the cooking activity, where we were given 30 minutes and were asked to cook something for ourselves. Then Ranjitha reviewed our test case assignment on the Luma site. In the afternoon session, we covered the Xpath, alert function, dropdown, and introduction to the Assertion topic.
Xpath:
XPath is the language used for locating nodes in an XML document. As HTML can be an implementation of XML (XHTML), Selenium users can leverage this powerful language to target elements in their web applications.
XPath extends beyond the simple methods of locating by id or name attributes, and opens up all sorts of new possibilities such as locating the second radio button on the page.
Reasons for using XPath is when I don’t have a suitable id or name attribute for the element I wish to locate. You can use XPath to either locate the element in absolute or relative to an element that does not have an id or name attribute.
Syn:
a. //tagname[@atriburtname='value'] ex://input[@type='Submit']
Different Ways of writing Xpath :
Select in Selenium WebDriver (Drop Down)
The ‘Select’ class in Selenium WebDriver is used for selecting and deselecting option in a dropdown. The objects of Select type can be initialized by passing the dropdown webElement as parameter to its constructor.
Alerts/popups in Selenium
Alerts are small popup boxes/windows which display the messages/notifications and notify the user with some information seeking some permission on certain kinds of operations. Additionally, we can also use them for warning purposes. Sometimes, the user can enter a few details in the alert box as well.
For Example, The alert box displayed below requires an action from the user to press OK and accept or press Cancel and dismiss the message box.
- Void accept(): This method clicks on the ‘OK’ button of the alert box.
driver.switchTo( ).alert( ).accept();- Void dismiss(): We use this method when the ‘Cancel’ button clicks in the alert box.
driver.switchTo( ).alert( ).dismiss();- String getText(): This method captures the message from the alert box.
driver.switchTo().alert().getText();- Void sendKeys(String stringToSend): This method sends data to the alert box.
driver.switchTo().alert().sendKeys("Text");Synchronization in Web Driver:
There are three kinds of waits:
1. Implicit Wait — Used to set the default waiting time throughout the program.
2. Explicit Wait — Used to set the waiting time for a particular instance only.
3. Fluent Wait — Used to set the waiting time but it will keep checking for element present in given interval of times. As soon as object found it continue of execution of code.
Assignments:
***************************************************************************
21/09/2022
In this session, we had an overview of all the topics from starting to explain our new trainee in the group. We made her understand everything from starting and also made her download Selenium IDE, Driver and Eclipse for the automation testing along with creating a maven project. In the afternoon session, we learnt how to write xpath for table and we wrote methodoverloading concept to automate facebook signup.
Assignment: Click on “Selenium” check box
Assignment: User URL https://www.w3schools.com/html/html_tables.asp and try to get “ Centro commercial Moctezuma” and print name of the company.
Method overloading in Automation:
**************************************************************
22/09/2022
In this session, we learned to import files on JIRA for test case creations, and in the afternoon session we learned Assert topics and real-time examples like applying leave on HRM application and many more………
Asserts
There are two types of Assert:
1. Hard Assert
2. Soft Assert
When an assert fails the test script stops execution unless handled in some
form. We call general assert as Hard Assert.
Hard Assert — Hard Assert throws an AssertException immediately when an assert statement fails and test suite continues with next @Test. The disadvantage of Hard Assert — It marks method as fail if assert condition
gets failed and the remaining statements inside the method will be aborted.
Soft Assert — Soft Assert collects errors during @Test. Soft Assert does not throw an exception when an assert fails and would continue with the next step after the assert statement.
***************************************************************************
23/09/2022
In this session, we had a revision and presentations. We presented a presentation on software testing, covering topics like- What is Testing?, STLC, User Stories & Test Plan, Test Cases, RTM, JIRA Implementation, then Manual Testing to Automation Testing and advantages of Automation with its needs, and finally implementing some programs on automation testing on Eclipse. I did a test case concept in this presentation. In the afternoon session, we learned how to read the Excell sheets in Eclipse using Selenium. And we also learned about writing to Excel File and modifying the Excel File along with the Selenium Importing of examples.
How to handle excel file using POI (Maven POM Dependency)
To Read and Write Excel file in Java, Apache provides a very famous library
POI. This library is capable enough to read and write both XLS and XLSX file format of Excel.
To read XLS files, an HSSF implementation is provided by POI library.
To read XLSX, XSSF implementation of POI library will be the choice.
Workbook: XSSFWorkbook and HSSFWorkbook classes implement this interface.
XSSFWorkbook: Is a class representation of XLSX file.
HSSFWorkbook: Is a class representation of XLS file.
Sheet: XSSFSheet and HSSFSheet classes implement this interface.
XSSFSheet: Is a class representing a sheet in an XLSX file.
HSSFSheet: Is a class representing a sheet in an XLS file.
Row: XSSFRow and HSSFRow classes implement this interface.
XSSFRow: Is a class representing a row in the sheet of XLSX file.
HSSFRow: Is a class representing a row in the sheet of XLS file.
Cell: XSSFCell and HSSFCell classes implement this interface.
XSSFCell: Is a class representing a cell in a row of XLSX file.
HSSFCell: Is a class representing a cell in a row of XLS file.
**************************************************************
24/09/2022
In this session, we did review of test cases and Ranjitha told some corrections to improve the test cases. Then, Ranjitha told us to apply Black box technique for the credentials (username & password) for login. We worked as a team and applied different Black Box Techniques like Error Guessing, Boundary Value Analysis, Equivalence Partition, Decision Table Technique, and State Transition Technique.Then Ranjitha given time for to work on Big picture in teams.
Cucumber
Cucumber is a testing framework which supports Behaviour Driven Development (BDD). It lets us define application behaviour in plain meaningful English text using a simple grammar defined by a language called Gherkin. Cucumber itself is written in Ruby, but it can be used
to “test” code written in Ruby or other languages including but not limited to Java, C# and Python.
Gherkin (Language)
Gherkin is the language that Cucumber uses to define test cases. It is designed to be non-technical and human readable, and collectively describes use cases relating to a software system.
In addition to promoting Behavior Driven Development practices across an entire development team, including business analysts and managers it also provides script for automated testing, Gherkin’s natural language syntax is designed to provide simple documentation of the code under test. Gherkin currently supports keywords in dozens of languages.
Syntax:
Syntax is centered around a line-oriented design, Gherkin files have the .feature file extension. They contain a single Feature definition for the system under test and are an executable test script
Features, Scenarios, and Steps:
Cucumber tests are divided into individual Features. These Features are subdivided into Scenarios, which are sequences of Steps.
> Feature:
A feature is a Use Case that describes a specific function of the software being tested.
• The Feature: keyword
> Scenarios:
Each Feature is made of a collection of scenarios. A single scenario is a flow of events through the Feature being described and maps
> Steps:
The crux of a Scenario is defined by a sequence of Steps outlining the preconditions and flow of events that will take place. The first word of a step is a keyword, typically one of
• Given — Describes the preconditions and initial state before the start of a test and allows for any pre-test setup that may occur
• When — Describes actions taken by a user during a test
- Then — Describes the outcome resulting from actions taken in the When clause
Assignment :
**************************************************************
26/09/2022
In this session we executed the LUMA Site test cases. Firstly, we made the project named LUMA, created versions and epics and added user stories and Imported test cases. After that we executed on Jira and in the afternoon session we learnt about collections. We downloaded TestNG and executed some programs using TestNG.
What is TestNG?
TestNG is an automation testing framework in which NG stands for “Next Generation”. TestNG is inspired by JUnit which uses the annotations (@).
Using TestNG, you can generate a proper report, and you can easily come to know how many test cases are passed, failed, and skipped. You can execute the failed test cases separately.
What is Annotation in TestNG?
Annotations in TestNG are lines of code that can control how the method below them will be executed. They are always preceded by the @ symbol. A very early and quick TestNG Example is the one shown below.
@BeforeSuite: The annotated method will be run before all tests in this suite have run.
@AfterSuite: The annotated method will be run after all tests in this suite have run.
@BeforeTest: The annotated method will be run before any test method belonging to the classes inside the tag is run.
@AfterTest: The annotated method will be run after all the test methods belonging to the classes inside the tag have run.
@BeforeGroups: The list of groups that this configuration method will run before. This method is guaranteed to run shortly before the first test method that belongs to any of these groups is invoked.
@AfterGroups: The list of groups that this configuration method will run after. This method is guaranteed to run shortly after the last test method that belongs to any of these groups is invoked.
@BeforeClass: The annotated method will be run before the first test method in the current class is invoked.
@AfterClass: The annotated method will be run after all the test methods in the current class have been run.
@BeforeMethod: The annotated method will be run before each test method.
@AfterMethod: The annotated method will be run after each test method.
@Test: The annotated method is a part of a test case
**************************************************************
27/09/2022
In this session we executed Luma test cases and in the afternoon session we learnt about Css selector and Data provider in Testng. Then we executed all Testng files at a time using Testng XML file.
What is a CSS Selector?
CSS Selectors in Selenium are string patterns used to identify an element based on a combination of HTML tag, id, class, and attributes
Executing all Test case using XML file in TestNG
***********************************************
28/09/2022
In this session we executed Luma test cases and in the afternoon session we learnt about Xpath siblings and brief introduction about frame work. Ashok explained What is Page object model and how it works and also intro about the Jenkins. This was the last session of the Ashok and I really want to Thank him a Lot.
XPath Sibling
Xpath Sibling is defined as a is a function for retrieving a web element that is a child of the parent element. The web element may be readily recognized or accessed using the sibling attribute of the Xpath expression if the parent element is known.
- following-sibling
2.Preceding-sibling
Frameworks:
1. Data Driven: here we put test data in Excel / CSV file and read data from this file and put it into your application.
2. Keyword Driven: Here we use Excel and in this file we use keyword and every keyword will have a function. Based on your keyword that particular function will executed
3. Page Object Model(POM)
4. Hybrid (whenever we implement more than one framework then we call it as a Hybrid framework)
What is the Page Object Model(POM)?
Page Object Model or POM is a design pattern or a framework that we use in Selenium using which one can create an object repository of the different web elements across the application. To simplify, in the Page Object Model framework, we create a class file for each web page. This class file consists of different web elements present on the web page. Moreover, the test scripts then use these elements to perform different actions.
What are the advantages of the Page Object Model?
->Makes code maintainable- Since the test classes are separate from the classes containing the web elements and the operation on them, updating the code is very easy if any web element updates or a new one adds.
->Makes code readable- User can easily read through the project and test scripts due to a fine line between the test classes and the different web pages.
->And, makes code reusable- If multiple test scripts use the same web elements, then we need not write code to handle the web element in every test script. Placing it in a separate page class makes it reusable by making it accessible by any test script.
**************************************************************
29/09/2022
In this session, we started with the non-functional testing concepts and JMeter installation of software with JDK environment.
What is Non-Functional Testing?
Non-Functional Testing is defined as a type of Software testing to check non-functional aspects (performance, usability, reliability, etc) of a software application. It is designed to test the readiness of a system as per nonfunctional parameters which are never addressed by functional testing.
An excellent example of non-functional test would be to check how many people can simultaneously login into a software.
Performance Testing
Performance testing is an essential part of software testing that is performed to determine the scalability, reliability, resource usage, speed, response or load time of a software application under certain conditions of use. Basically, this test diagnoses and eliminates the performance related issues of a product or system under varying usage (stress) levels.
- Load Testing:
It is performed to measure the performance of a software under normal and anticipated peak load conditions. It enables testers to determine performance bottlenecks, check which element is causing degradation and accordingly ensure smooth functioning of the software before deployment. - Stress Testing:
It is used to test stability and reliability of the software or system. And, finding the breaking point of the application is its main focus. While determining the robustness and error handling capabilities under extreme workloads, stress testing also ensures that the system doesn’t fail or crash under crunch situations. - Endurance Testing:
It is a kind of software capacity testing where testers check how the software is going to behave under sustained use. Endurance test ensures that the software application is capable enough to take increased load without any major downfall in response time. - Spike Testing:
The job of spike testing is to test how a software will behave when the load is suddenly increased or decreased to an extreme extent. The objective of performing this test is to check the software’s reaction to instant load spike and determine quick recovery after that. - Volume Testing:
Also known as flood testing, volume testing is subjected to an immense volume of data. It is performed to analyze the software application’s performance under varying database volumes, most commonly by enlarging the volume of data in the database.
JMeter
JMeter Apache Jmeter is a popular open-source performance testing tool. Jmeter is designed to cover various categories of tests such as load testing, functional testing, performance testing, regression testing, etc., and it requires JDK 5 or higher.
***********************************************************
30/09/2022
In this session we wrote a signoff email .Since we have completed the execution for our LUMA Site. Now, we were asked to write a sign- off Email, to conclude our executions and steps in detail. This, is the last phase after execution and also the testing phase, also known as part of “Test Closure”.In the afternoon session we practised the Jmeter and explored ourself.
*********************************************************
1/10/2022
It was enjoyable today. We participated in a variety of activities led by my colleagues during the morning session because it was the weekend, including Cook it up, spin the wheel, and group activities.
Additionally, we were informed that our final exams would begin on Monday. In addition, we were informed that the group presentation we must prepare has a time limit of up to an hour. As a result, we worked on the Presentation in groups during the evening session so that everyone could contribute and work together.







