Final Flashcards

1
Q

Change tracking systems like GitHub Issues track all changes to a product-both bugs and enhancement requests.

A

True

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
2
Q

The reason for using a change tracking system like GitHub Issues is that it:

A
  • encourages decisions regarding specific changes
  • allows project management to understand how complete or incomplete the project is
  • ensures that proposed changes are not lost
How well did you know this?
1
Not at all
2
3
4
5
Perfectly
3
Q

All HTML elements must have a name, id, or class.

A

False

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
4
Q

What does the following snippet print?
url_ddg = “https://api.duckduckgo.com”

resp = requests.get(url_ddg + “/?=presidents%20of%20the%20united%20states&format=json”
rsp_data = resp.json()
print(rsp_data[“Heading”])

A

prints the one and only value of the “Heading” dictionary item returned by the website, assuming that such an item exists

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
5
Q

Using relative XPath is preferred over absolute XPath.

A

True

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
6
Q

In pytest-bdd, scenario outlines can usually be replaced by pytest parametrization.

A

True

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
7
Q

In Selenium tests, what type of wait should one use if there is an element that might load slowly, such as an image?

A

Explicit

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
8
Q

Every element on a page might have a unique locator, but it is not required.

A

True

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
9
Q

Why are Web elements and locators separate concerns?

A
  • Page structure could change at any time due to dynamic content
  • Referencing every element directly from root-to-child becomes unwieldy for large pages
  • Elements might disappear from a page due to code changes or even bugs
How well did you know this?
1
Not at all
2
3
4
5
Perfectly
10
Q

HTML class attributes are unique within a document.

A

False

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
11
Q

What are the commands or actions supported by python’s requests REST API?

A

get - retrieves information from a server

post - can create a subordinate resource

put - can replace a resource at a known URL

delete - removes a resource

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
12
Q

In a Selenium test, how do find_element and find_elements differ?

A
  • If multiple applicable elements exist, find_element returns only the first
  • If no applicable elements are found, find_elements returns an empty list
  • If no applicable element is found, find_element throws an exception
How well did you know this?
1
Not at all
2
3
4
5
Perfectly
13
Q

In Selenium tests, an element may exist before it appears.

A

True

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
14
Q

HTML name attribute is unique within a document.

A

False

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
15
Q

Which of the following CSS selectors would select only “div” elements with the class name “parent”?

A

div.parent

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
16
Q

The HTML DOM structures the web page as a tree.

A

True

17
Q

CSS selectors can uniquely identify any given element on a Web page.

A

False

18
Q

A Gherkin Background section will execute before each Scenario.

A

True

19
Q

JSON is represented in Python by a dictionary.

A

True

20
Q

Testing often requires the tester to identify manually the element to test and its locator.

A

True

21
Q

The HTML DOM defines the logical structure of documents and the way a document is accessed and manipulated.

A

True