Skip to main content

Posts

Showing posts with the label Automation

TestNG Questions

Question:  TestNG Annotations Answer: @Test @BeforeMethod @AfterMethod @BeforeTest @AfterTest @BeforeClass @AfterClass @Test(enabled = false) @Test(enabled = true) @Test(priority=2) @Test(priority=5,dependsOnMethods={"method1","method2"}) @Test(dependsOnMethods = {"method1"}, alwaysRun=true) @Test(groups = { "Group1", "Group2" }) @Parameters({"testparameter1", "testparameter2"}) @Listeners(packagename.ListenerClassName.class) @Test (dataProvider = "getUserIDandPassword") @Test (description = "Open Facebook Login Page", timeOut=35000) @Test (invocationCount = 3, invocationTimeOut = 20000) @Test (invocationCount = 3, skipFailedInvocations = true) @Test (invocationCount = 3) @Test (invocationCount = 7, threadPoolSize = 2) Question:  Order of TestNG annotations Answer:  Order of TestNG annotations is as below : - @BeforeSuite @BeforeTest @BeforeClass @BeforeMethod @Test @AfterMethod @AfterClass @After

Selenium Question

Question:  What is Selenium Answer:  Selenium is a widely-used open-source automation testing framework primarily used for automating web applications. It provides a suite of tools that supports different aspects of test automation, including Selenium WebDriver, Selenium IDE, and Selenium Grid. Question:  Explain the difference between Selenium WebDriver and Selenium IDE Answer:  Selenium WebDriver: It is a powerful automation tool used for automating web applications by directly interacting with the browser. WebDriver provides a programming interface to create and execute automation scripts in various programming languages. Selenium IDE: It is a record and playback tool used for creating automation scripts without writing any code. Selenium IDE is a Firefox plugin that allows users to record interactions with the browser and play them back as automated tests. Question: Explain S elenium Architecture Answer:  Selenium's architecture consists of several components: Selenium Client L