UI Testing Flashcards

1
Q

System and _____ testing is more expensive and challenging to automate. Why?

A

UI.

The concerns we have about testability in each stage of AAA are amplified

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

When arranging a UI test, what sort of challenges are there?

A
Not a CLI or API call
Event  based
Polyglot and multi system
Nondeterminism
Time matters
How well did you know this?
1
Not at all
2
3
4
5
Perfectly
3
Q

When running a UI test, what sort of challenges are there?

A

Nondeterminism

Performance

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

When asserting a UI test, what sort of challenges are there?

A

Nondeterminism
Visual results
Final vs intermediate states

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

What functionalities to UI testing frameworks provide to facilitate tests?

A

Hook into event system
Synthesize events
Programmatic interface
Provide logical time based on events

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

A ___ _____ generally contains the requirements for each step in AAA

A

user story

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

What are 3 ways to find components in a UI?

A

Contents
Path through Tree
ID

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

Why can finding components by contents be useful?

A

If we cant control components

Things we don’t expect to change

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

Why can finding components by paths be useful?

A

We don’t expect structure to change. Older systems cannot give components IDs

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

Why can finding components by ID be useful?

A

If we have control of the code, this is the best way. Doesn’t matter if the structure or content changes

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

We can either ______ or ______ _____ time in UI tests

A

tolerate, abstract away

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

In many cases, _____ can be abstracted to ordered events. What does this mean?

A

time

Instead of waiting x seconds, we wait until the page loads

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

If we cannot abstract away time, what do we do instead? What are the consequences?

A

Fallback to thresholded waits. We can expect flaky tests and higher maintenance costs

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

Selenium can ______ tests, which makes tests easier to produce for non-programmers, but are more flaky

A

record

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

Behaviour Driven Development is another way for non-programmers to make tests. What is the common structure of these tests?

A

Given some initial context
When some event occurs
Then ensure some outcome

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