InterviewAnswers
InterviewAnswers
1. Myself “Your Name”. I have about XX years of expereince in Software Testing in both Functional
and Selenium Automation.
2. Current I am working on project called - "EPIC” – is a web based application handling claims
processing for GMAC Insurance. Customers will be raising the claims for the loss .It will be go on
processing and approvals based on the policy terms they have enrolled with.
4. For Automation, We are using TestNG Framework implementing Page Object Model using
Selenium WebDriver in the language of Java.
FrameWork Questions
1. We are using TestNG Framework implementing Page Object Model and Maven build tool using
Selenium WebDriver in the language of Java.
2. As per Page object model, We have created two classes files for each pages present in our
application in two different packages which under src/main/java and src/main/test.
3. In Class 1, We have page objects associated with that page identified using page factory and
corresponding action method required. In Class 2, we have TestNG Tests created for that page.
4. In Addition to that, We have created a class called BasePage in which we have created reusable
functions to be used across all the object classes.
5. To Handle Test Data, We are using Apache POI Library. We have test data stored in excel sheet
and we read from there.
6. And, We have pom.xml as part of maven where we have defined all the depedencies and plugins
required for the project.
1. Using Page object model, We separate the code and tests for every page in the application.
Hence, it is easy to maintain and easy to understand.
2. Code Re - Usability
3. Page objects can be identified using page factory
What is pom.xml/testng.xml
pom.xml = Maven reads pom.xml. Maven is build tool helps for compilation, Execution, Dependency
Management and Reporting.In pom.xml, we wil define all the depedencies and plugins required for the
project.
testng.xml - Its an xml we will define our test configurations. Execution will triggered based on the
configuration defined in this xml file
What is BuildTool/Maven:
Maven is a Build Tool Tool ( or ) Build tool helps for comiplation, Execution, Dependency Management,
Packaging to Jar and Reporting purpose.
What is the Build tool Used in your project. How its works
In our project we are using Maven as build tool. Maven reads POM.XML where we have defined all the
depedencies and plugins required for the project.
How Maven dependency Works/How do you handle depedency in maven/ How do you specify the
depedency in Maven
1. We specify a dependency by providing group id, artifact id and version id inside depdency
tag
2. Once we build the project, Maven will check the depdency is available in Local Repository
(.m2 Folder). If it’s present, it will refer there.
3. If its not present in local repository then it will connect to Maven Central Repository and
download that depdency to the local repo
Git Commands:
1. We commit our loacl changes using command git commit to local repo.
2. We will pull the changes from remote repo using git pull command.
3. Git will auto merge the code and show the conflicts
4. We resolve the conflicts wherever it occurs.
5. We commit back to git and push the changes using git push
Where do you commit your code ? who does the code review ?
1. I will be pushing my changes to my user branch and create a pull request for review to my onsite
co-ordinator (Senior Technical Person in our team).
2. He will review the pull request and approve the changes.
3. He will merge with master branch
1. Depends on the story, I am working on. I will be pushing end of the day if I have completed the
story.
It’s a process to integrate our code with Version Control/Code Repository which verifies each check in by
an automated build and which helps to detect the problem earlier.
What’s CI tools you are using ?/ How Jenkin Works ? / How do you perform test execution and share
the report to Customer ? / How wil you trigger auto execution ? or when Build deployed ?
We are using Jenkins in our project and which is integrated with our code repository github.
In our project, We have created different Jenkins Jobs for Sanity Script, Functional Scripts and
Regression Scripts.
Sanity Jobs has been configured to auto execute after build deployed. Functional Script jobs has been
configured to execute in a Scheduled time (at 11AM IST ) on a daily basis.
On a daily basis, I will be checking Functional Script execution results in Jenkins. I will be analyzing the
results incase of fialure scripts . I will debug the scripts incase of code related issues (Like Changes in
Page Objects) and log the defect incase of functional issues with application.
How to create a job in Jenkins:
I didn’t get a chance to create a job In Jenkins as I have only read only access. I am aware of
creating the job by providing the details like – Code Repo, Build Execution details, Goals, post
build deploy and Email trigger.
1. Mostly we face challenges in handling page objects. Because often in our project
Page object would be changing dynamically. And, I have handled that by using Xpath ( // = Relative path)
2. And, I have faced challenges in handling StaleElementReference Exception as some of the object
gets refreshed during identification. I have handled that by using explicit wait.
3. And, I have faced challenges handling Proxies. Default proxy setting gets applied to IE and
Chrome browser. So we have to set proxy to Firefox browser to launch the our Test
Environment. I have handled that using Proxy class and defined it as part of capabilitie while
launching the browser.
What are all the Exceptions you have Handled: (Say First three – If he don’t satisfied they say rest )
1. ElementNotVisibleException.
2. StaleElementRefenceException
3. NoSuchElementException
4. NullPointerException
5. ArrayIndexBoundException
6. IndexBoundException
7. NumberFormatException
1. Depends on the complexity of the stories. Generally, We complete the stories within 20 – 25
story points
We are using excel for Test Cases. We map the each test cases with requirment id and TestScript Name
We get the requirement in JIRA. Product owner will be creating the stories in JIRA and it will be in
Backlogs
I am part of Scrum team, I will be creating the QA tasks for the stories picked for the current sprint in
JIRA. I will be working on those tasks for that Sprint.
3 – 4 Months
Who will give the build and how ofter you get the build ?
Developers provide the build. We get the build on a daily basis in a scheduled time 7AM IST.
How do you generate Reports in your project / What type of reports using in your framework:
1. TestNG by defaul by generate xml for failed test cases under Test output folder after test
execution completest. We can execute that xml to run failed test cases alone
2. We can implement Annotation Transformer and define the retry limit to execute fialed test
cases. Which can be specified in TestNG.XML file as listeners blocks
What are all the Oops concepts used in your project and explain.
Classes, Object, Encapsulation = As part of page object model, we have object class created for each
page in the application and hidden the members of class by declaring it as private.
Inheritance = Eash page object class extends something called BaseClass in our project, where we have
all the re-usable functions defined.
I have done Sanity Testing, Functional Testing, Regression Testing, Adhoc Testing.
Sanity Testing – We have automated Sanity Scripts, which will be auto triggered in Jenkins when build is
deployed.
Functional Testing – I have done insprint functional Testing and also have automated those
functionalities. Which will be scheduled in jenkins to execute every alternate days.
Regression Testing – I have involved in Regression testing in Regression phase of scrum process.
Framework Architecture: