July 2018 - All About Testing July 2018

What is the recipe for successful achievement?

To my mind there are just four essential ingredients: Choose a career you love, give it the best there is in you, seize your opportunities, and be a member of the team.

“All our dreams can come true, if we have the courage to pursue them.”

“I’m a great believer in luck, and I find the harder I work, the more I have of it.”

Success unshared is failure.

To make our way, we must have firm resolve, persistence, tenacity. We must gear ourselves to work hard all the way. We can never let up.

"Everyone you will ever meet knows something you don't."

he fact that I can plant a seed and it becomes a flower, share a bit of knowledge and it becomes another's, smile at someone and receive a smile in return, are to me continual spiritual exercises.

The secret of success is to do the common things uncommonly well.

Good things come to people who wait, but better things come to those who go out and get them.

Tuesday 31 July 2018

Failed to load the JNI shared library jvm.dll

Failed to load the JNI shared library jvm.dll



When we will try to run eclipse, we will get following error


This is because you may be having a miss-match between 32-bit and 64-bit setups

64-bit Operating System: 64bit Eclipse and 32-Bit JDK or JRE Setup

or

64-bit Operating System: 32bit Eclipse and 64bit JDK or JRE Setup

So, you should have Eclipse + JDK + JRE all either 64-bit or 32-bit

Solution :


  1. Make sure that your windows is 64 bit
          Go to Control Panel -> System and Security -> System

          Check System Type within System section.

     2.  Make sure that you have 64-bit Java, follow these steps -

         Type "java -version" on command prompt and You should get the following message if its 64 bit.
java version "10.0.2" 2018-07-17
Java(TM) SE Runtime Environment 18.3 (build 10.0.2+13)
Java HotSpot(TM) 64-Bit Server VM 18.3 (build 10.0.2+13, mixed mode)


If your windows is 64 bit then download eclipse of 64 bit
you can download from here http://www.eclipse.org/downloads/packages/
As well as download JDK of 64 bit

this will solve the issue. :)
best luck.

Monday 30 July 2018

Urgent Opening for QA Tester

AEQUOR INFORMATION TECHNOLOGIES PVT.LTD


Experience required for the Job: 3 - 5 years
Job Location: Mumbai (All Areas)

Job Description:
  • QA experience of 3 to 4 years with at least 1 year working as a Automation tester.
  • Strong Experience in Testing Processes & Tools using HP Unified Functional Tester (UFT) and HP Application Life Cycle Management is must.
  • Good knowledge in Investment Banking, BFSI Domain is preferred..
  • Hands on experience creating complex SQL queries, knowledge of SQL Joins and functions mandatory. Should be comfortable writing complex SQL queries
  • Agile Methodology.
  • Good Analytical Skills and Communication skills required
  • Automation Tool Ranorex knowledge would be an added advantage
  • Resource should be willing to work on Manual project also
  • Banking Domain Experience (Investment banking, Fund Management, Custodian banking)
  • Strong communication skills to operate in a multi-cultural and multi-regional team
  • Customer focused; strong focus on delivering value to our customers;
  • Good Team player, who shares problems and solutions, pro-actively offers to help others
  • Takes accountability for delivering results, Self-driven wanting to make things happen
  • Strong focus on operational excellence and on continuous improvement

If interested please share your resume to shanthini.p@aequor.com

P. Siva Shanthini
HR - Senior Technical Recruiter
Aequor Information Technologies (Pvt) Ltd
Mobile : +91 – 98400 31736
Website : www.aequor.com


Sunday 29 July 2018

API Testing Interview Questions And Answers


1.   While using the API tool, after entering the URL in the field, what response will happen in the backend.?
Ans - HTTPRequest with header and body is created

2.  What request will be served by the web service and what will be the request by the server to the browser.?
Ans -HttpRequest and HttpResponse

3.  In API testing, where we use POST and GET methods?
Ans - 
Post - sending data / uploading file
Get - requesting for data

4.  While testing the Registration Page and Login page in API, which comes under POST and GET methods?.
Ans -
Open login page - GET
Submit login id and password - POST
Open reg page - GET
Submit reg form - POST

Tuesday 3 July 2018

TestNG Interview Questions with Answers

TestNG is the most widely used testing framework in the software industry.  It provides a lot of features over the conventional JUnit framework and is used for different kinds of testing like unit, functional, integration testing etc. 

Question 1: How TestNg is better Junit?

Answer :
          1.TestNG have advance annotations and more annotations then Junit 
          2. Execution pattern can be set in TestNG 
          3. We can concurrently execution our test scripts. 
          4. Test case dependencies can be set in TestNG 
          5.The data-driven framework can be easily implemented using Data Provider. 
          6.TestNG can generate the report in a readable format. 
          7.Grouping of test methods 
  8.Multithreaded execution

Question 2: What is NG stands for in TestNG?

Answer :
NG stands for "next generation" in TestNG.

Question 3 : How suites and tests are configured in TestNG?

Answer :
Suites and tests are configured through XML 
files. By default, the name of the file is testng.xml

Question 4: Why TestNG XML files are used?

Answer :
It allows to include (or exclude) respective packages, classes, and methods in their test suite, used to pass parameters to test methods ,It also allows users to group test methods.

Question 5 : Write an TestNG xml code to execute a particular class.

Answer :
<suite name="First Suite" verbose="1"> 
<test name="First Test" >
<classes>
<class name="test.FirstTest" />
</classes>
</test>
</suite>

Question 6 : How to execute TestNG xml using command line?

Answer :
java -cp "/opt/testng-6.8.jar:bin" org.testng.TestNG testng.xml 

//Write above code in command line 
//-cp option of Java to compiled code 
//org.testng.TestNG consists of the main method 
///opt/testng-6.8.jar is the path to the testng JAR

Question 7 : After execution an HTML report is generated by TestNG in which folder?

Answer :
After execution an HTML report is generated by TestNG in a folder named "test-output".

Question 8: How to execute testng.xml using Eclipse

Answer :
1. Open Eclipse and go to the project where we have created the testng.xml file. 
2. Select the testng.xml file, right-click on it, and select Run As | TestNG suite. 
3. Eclipse will execute the XML file as TestNG suite.

Question 9: Tell Before and After annotations in testNG

Answer :
1.@BeforeSuite/@AfterSuite 
2.@BeforeTest/@AfterTest 
3.@BeforeGroups/@AfterGroups 
4.@BeforeClass/@AfterClass 
5.@BeforeMethod/@AfterMethod

Question 10: Give the name of the attribute which provides method dependency

Answer :
"dependsOnMethods" attribute provides method dependency

Question 11: Give the name of the attribute which provides Groups dependency

Answer :
"dependsOnGroups" attribute provides method dependency

Question 12: What will happen if any method under @Test annotations is set private?

Answer :
If a class is annotated by the Test annotation, TestNG will consider only the methods with public access modifiers as test methods. All the methods with other access modifiers will be neglected by TestNG.

Question 13 : How to disable a test method?

Answer :
Disabling a test can be achieved in TestNG by setting the enable attribute of the Test 
annotation to false 
@Test(enabled=false) 
public void testMethodOne(){ 
System.out.println("Test method one."); 
}

Question 14 : How to set time test at suite level?

Answer :
Add a testng.xml file to the project and put the following code to it: 
<suite name="Time test Suite" time-out="500" verbose="1">
<test name="Timed Test">
<classes>
<class name="test.timetest.TimeSuite" />
</classes>
</test>
</suite>

Question 15: How to set time test at test method level?

Answer :
@Test(timeOut=500) 
public void timeTestOne() throws InterruptedException{ 
Thread.sleep(1000); 
System.out.println("Time test method one"); 
}

Question 16 : How will you create a test that belongs to a group?

Answer :
Test that belong to a group 
public class TestGroup { 
@Test(groups={"test-group"}) 
public void testMethodOne(){ 
System.out.println("Test method one belonging to group."); 
}

Question 17 : List Out Common Testng Assertions?

Answer :
Common Testng Assertions : 
1.assertEqual(String actual,String expected) 
2.assertEqual(String actual,String expected, String message) 
3.assertEquals(boolean actual,boolean expected) 
4.assertTrue(condition) 
5.assertTrue(condition, message) 
6.assertFalse(condition) 
7.assertFalse(condition, message)

Question 18 : What Is Soft Assert In TestNG?

Answer :
Soft Assert collects errors during @Test. Soft Assert does not throw an exception when an assert fails and would continue with execution.

Question 19: What Is Hard Assert In Testng?

Answer :
Hard Assert throws an AssertException immediately when an assert statement fails and test suite continues with execution.

Question 20 : How To Set Test Case Priority In Testng?

Answer :
Setting Test Case Priority In Testng 
'@Test(priority=0) 
public void testCase1() { 
//line of code 
@Test(priority=1) 
public void testCase2() { 
//line of code 
}

Question 21 : How To Exclude A Particular Test Method From A Test Case Execution?

Answer :
Excluding a Particular Test Method From Test Case Execution 
<classes>
<class name="TestCaseName">
<methods>
<exclude name="TestMethodNameToExclude"/>//using exclude tag 
</methods>
</class>
</classes>

Question 22 : create a test having multiple groups

Answer :
Test having multiple groups 
@Test(groups={"group-one","group-two"}) //Two groups are defined here 
public void testMethodTwo(){ 
System.out.println("Test method two belonging to both 
group."); 
}

Question 23 : Write TestNG.xml code to run a group of test cases using group attribute of testng

Answer :
<suite name="Multi Group Suite" verbose="1">
<test name="Group Test one">
<groups>
<run>
<include name="group-one" />
</run>
</groups>
<classes>
<class name="test.groups.MultiGroup" />
</classed>
</test>
</suit>

Question 24 : List out various ways in which TestNG can be run?

Answer :
TestNG can be run with 
1.Eclipse IDE 
2.ant build tool 
3.command line 
4.IntelliJ’s IDEA

Question 25 : Explain how will you define dependencies in TestNG ?

Answer :
defining dependencies in TestNG 
1.dependsOnMethods in @Test annotations 
2.dependsOnGroups in @Test annotations

Question 26 : What are the Different build tools available?

Answer :
Different build tools available are 
1.Ant 
2.Maven 
3.Gradle

Question 27 : How to pass a parameter with a testng.xml file to use It In test case?

Answer :
  <parameter name="browser" value="FFX" /> //Parameter Tag you will write in TestNG.xml 
@Parameters ({"browser"}) //Parameters annotation you will define belwo @Test Annotation

Question 28 : Arrange testng.xml tags from parent to child.

Answer :
<suit> 
<test>
<classes>
<class>
<methods>

Question 29 : What are the two main ways to generate a report with TestNG?

Answer :
1.Listeners: For implementing a listener class, the class has to implement the org.testng.ITestListener interface. These classes are notified at runtime by TestNG when the test starts, finishes, fails, skips, or passes. 

2.Reporters: For implementing a reporting class, the class has to implement an org.testng.IReporter interface. These classes are called when the whole suite run ends. The object containing the information of the whole test run is passed to this class when called.

Question 30 : What is TestNG Reporting Support?

Answer :
TestNG generates test reports in HTML and XML formats. WebDriver does not have any native mechanism for generating reports.
TestNG window is more useful than console window in Eclipse as it generates text-based result while TestNG window generates a graphical output of the test result. 
It gives the Runtimes of each and every method and also the order in which methods are executed.

Expansion Pune Aundh Interview Questions Automation

*Expansion Pune Aundh*
Interview Questions Automation
Dated: 10 march 2018

1. What is the Explicit wait and Implicit wait?

2. What is a headless browser?

3. How to get a screenshot in Selenium? Can you write the syntax?

4. What are the different type of Locators in Selenium?

5. What is the best way to locate a web element if there is no unique XPath?

6. What is StaleElementReference Exception? Have you encountered it ever and how you handled it?

7. Do you run test cases in parallel with TestNG? If yes how many threads and does it cause any problem?

8. What is the most common locator you use in your project?

9. Have you ever done profiling of a web page?

10.How frequently you use Thread.Sleep()?

11. Suppose there are two elements on a web page with same ids, how will you handle it?

12. Can we create an object for an interface?

13.Difference between @BeforeTest and @BeforeMethod in TestNG?

14. How does Selenium interact with the Web browser?

15. Can you make the constructor of a class static?

16. How do you maintain your test scripts and how frequently you have to modify them?

17. How to find all broken links on a webpage?

18. Explain your Automation Framework.

19. Write a dynamic XPath to locate a table's 2nd row 3rd column data.

20.Hashmap vs Hashtable.

21. What is the significance of hash table?

22. What is the return type of findElements?

23. What’s the difference between a Maven project and a Java project?

24.Getwindowhandle vs Getwindowhandles and the return types.

25.Comparable vs comparator.

26. Explain about the Project along with how the Automation was done.

27. How to upload a file in Selenium?

28. How to upload a file without using Sendkeys?

29. How to connect to a Database using Selenium?

30.Any idea or experience with Continous Integration tool?

31. How to handle a drop-down in Selenium?

32. What is WebDriver – interface?

33. Why do we need Interface in the test?

34. How to integrate your test with Jenkins?

35.Any example or practical usage of Runtime polymorphism?

36. How to find dynamic elements?

37. What is the difference between CSS selector and XPath? Which is better from a performance perspective?

38.Difference between Instantiate and Initialize in Java.

39. What is mean by fluent wait?

40. What kind of framework have you made?

41. What’s TestNG Listener Class & why do we use it?

42.Any idea about Selenium Grid? Or Parallel execution.

43. What are the challenges you face when running automation scripts?

44.Difference between == and =.

45. What’s Page Factory?

46. How to click a button without using click() and without using CSS & XPath selectors?

47. Are multiple inheritances possible in Java? Why?

48. Are all methods in an abstract class, abstract?

49. Can we make an Object of Abstract class or an Interface?

50. What’s the difference between method overloading and overriding?

51. What’s the use of Java Static keyword?

52.Different type of polymorphism.

53.Can we write webdriver dr = new webdriver();

54. What are the different plugins used for Maven? And it's used?

55.Difference between Abstract and Interface?

56. Try, Throw & Catch syntax. And why is it used?

57. How do you manage to re-run only failed test cases?

58. How to make TestNG.xml at run-time?

59. What’s Singleton class?

60. Can we have Finally block without Try & Catch blocks?