Protractor Interview Questions and Answers - Part 1 (Top 21+ Questions covered)

  Рет қаралды 3,767

The Testing Academy

The Testing Academy

Күн бұрын

In this video, We are going to cover the top 21+ Protractor Interview Questions and Answers with pdf download.
Question 1 : What is Protractor?
Answers : Protractor is an end-to-end test framework for Angular and AngularJS applications.
Protractor runs tests against your application running in a real browser, interacting with it as a user would.
Question 2 : Can Protractor be used for testing Non-Angular JS Applications?
Yes. Protractor can be used for testing Non-Angular JS or Non-Angular Apps.
browser.ignoreSynchronization = true;
browser.waitforangularenabled(false)
Question 3 : What are the test frameworks supported by Protractor?
Protractor supports two behavior driven development (BDD) test frameworks such as Jasmine & Mocha.
Question 4 : What is a conf file in Protractor?
The configuration file tells Protractor how to set up the Selenium Server, which tests to run, how to set up the browsers, and which test framework to use.
The configuration file can also include one or more global settings.
The config file provides explanations for all of the Protractor configuration options. Default settings include the standalone Selenium Server, the Chrome browser, and the Jasmine test framework.
Question 5 : What is a spec file in Protractor?
Spec file is the one where we write actual test code. It contains the logic and locators to interact with an application.
Question 6 : How to exclude a spec file in Protractor?
You can exclude the spec’s by adding them in the exclude tag in your conf.js file.
You can also add patterns to exclude many test scripts with similar names.
Sometimes we may face a situation of running only few tests out of all. In this case, we use exclude tag in our conf.js file to run only few tests. Say we want to exclude test name “myTest.js”
exclude: [myTest.js]
Question 7 : What are the locators in Protractor?
It has unique set of locators particularly to identify elements based on AngularJS attributes.
by.className
by.css
by.id
by.linkText
by.name
by.partialLinkText
by.tagName
by.xpath
Question 9 : How to add custom locator for Protractor?
By using addLocator method.
Question 10 : How do you check the status of a webdriver manager and how do you update webdriver manager?
To check the status of webdriver manager, run the following in your command prompt
webdriver-manager status
To update webdriver manager, run the following code in your command prompt
webdriver-manager update
Question 11 : What is browser’s command in Protractor?
driver.navigate().refresh();
browser.refresh makes a full reload of the current page and loads mock modules before Angular.
Question 12 : What is the difference between “GET” and “NAVIGATE in Protractor?
GET:
Get method is used to navigate to the given destination.
browser.get(“www.softwaretestingmaterial.com”);
Navigate:
Navigate method is used to navigate to the given destination
browser.navigate()
If we want to load a previous page or next page in a browser we can use back and forward.
browser.navigate().back();
browser.navigate().forward();
Question 13 : How to accept/cancel Alert in Protractor?
By using accept() method of Alerts class, we accept Alerts in Protractor.
Note: We have to switch the control to the alert using switchTo().alert() before accepting the alert.
browser.switchTo().alert().accept()
browser.switchTo().alert().dismiss()
Question 14 : How do you stop Page Loading in Protractor when an element is loaded?
By using Key.ESC to body element in Protractor.
browser.actions().sendKeys(protractor.Key.ESC).perform();
browser.actions().sendKeys(protractor.Key.ESC).perform();
Question 15 : What are the browsers supported by Protractor?
Chrome, firefox, opera, IE,Safari
-----------------------------------------------------
👪 Join our Community - bit.ly/learntesting2019
✅ Automation Community - thetestingacademy.com
🐦Follow us on Twitter - / itstechmode
📖 Like us on Facebook - / scrolltest
🎤 Listen to our Podcast - anchor.fm/thetestingacademy
------------------------------------------------------
#automationtesting #manualtesting #testautomation #thetestingacademy #scrolltest
`
🚀 Tools and services I recommend:
Some of the courses that I recommend to become better Automation Tester 🙌🙌
✅Selenium Training and Certification -
scrolltest.com/go/edureka
✅Learn Jenkins for QA -
bit.ly/learnjenkins-p1
✅Programming Java -
bit.ly/learnjava2020-p1
✅Test Automation -
bit.ly/learnautomation2020
✅API Testing -
www.learnapitesting.com
✅Cypress Tutorial with LIVE Projects -
cypresstutorial.com

Пікірлер: 4
@gayatrimungarwadi2477
@gayatrimungarwadi2477 3 жыл бұрын
Nice video but explanation is very fast ..
@TheTestingAcademy
@TheTestingAcademy 3 жыл бұрын
Will take care next time
Protractor for AngularJS Tutorial - Part 1
55:39
Naveen AutomationLabs
Рет қаралды 115 М.
Эффект Карбонаро и нестандартная коробка
01:00
История одного вокалиста
Рет қаралды 10 МЛН
Secret Experiment Toothpaste Pt.4 😱 #shorts
00:35
Mr DegrEE
Рет қаралды 34 МЛН
Testing Interview For Experienced| Automation Interview Questions
29:35
RD Automation Learning
Рет қаралды 6 М.
Protractor Interview Questions and Answers | ARC Tutorials
8:44
ARCTutorials
Рет қаралды 8 М.
How To Explain Project In Interview Freshers and Experienced
9:23
Бедная бабушка...
0:56
Почему?
Рет қаралды 4,2 МЛН
Телега - hahalivars
1:00
HAHALIVARS
Рет қаралды 7 МЛН
Быстрые листья для голубцов
0:36
Мистер Лайфхакер
Рет қаралды 2,8 МЛН
A little girl was shy at her first ballet lesson #shorts
0:35
Fabiosa Animated
Рет қаралды 14 МЛН
Bro didn’t make it 😬😟💀 (FAKE NOT REAL) #shorts
0:19
Nate Nahhh
Рет қаралды 11 МЛН
Байкеры помогли доехать маме и сыну 😯
0:20
Фильмы I Сериалы
Рет қаралды 2,6 МЛН