Week 5 Flashcards

1
Q

What is the tradition method of product delivery?

A

Traditional product delivery (over years/months) uses 4 release:
Alpha
Beta
Release candidate
Release

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

What is the alpha release?

A

First release for sophisticated users, contains bugs but is for gathering feedback. Release for limited users.

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

What is the beta release?

A

Follows the alpha release, more stable but still requires feedback and contains some bugs.

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

What is a release candidate?

A

Comes after the beta release, it’s what the company plans to release, and is a final chance to make changes, if no bugs are found this is what will be released. Should be fairly stable. No new features.

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

When software was distributed on CDs why was it important that it was thoroughly tested before release?

A

Expensive and difficult to fix bugs, if you have a warehouse of 50000 CDs to update them all. Once the software is distributed to users it is far harder to update and fix their system when it is on a CD compared to digital download.

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

Issues with traditional software delivery

A

Adding features is hard the further down the cycle you go,
Fixing bugs is hard the further down the cycle you go
Very slow
Stressful for developers, working to time frames

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

What is Modern Feature Delivery?

A

Works within weeks rather than months
MVP moves between three environments:
Development
Staging
Production

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

What is the development environment?

A

The development environment you share with your scrum team, where the features are built, adds changes, does testing. At the end of the sprints, they are sent to staging.

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

What is the staging environment?

A

Staging is where the feature is set up in a mirror of the production environment.
Looks like production, we can use it to test on various platforms like Linux, etc. Tease out any bugs by moving environments, before we deploy it to customers using different OS. Perform more testing.

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

What is production?

A

Production is where the program runs and is operated by users in the real-world. If bugs are found here they are by real users affecting their real work. Failures are public.

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

Why is better to get your product to production quicker?

A

Get feedback faster, roll out updates quicker, stay on top of competitors.

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

What are the principles of software delivery?

A
  1. create a repeatable process
  2. automate almost everything
  3. version control for everything
  4. if it hurts, do it more frequently
  5. build quality in
  6. done means released
  7. everyone is responsible
  8. continuous improvement
How well did you know this?
1
Not at all
2
3
4
5
Perfectly
13
Q

What is ‘create a repeatable process?’

A

Releasing software should be easy, because it has been done thousands of times before. (minimize mistakes, faster, less stress)

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

What is ‘automate almost everything?’

A

The build should be push button operation. Scripts don’t make mistakes. (humans make mistakes)

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

What is ‘version control for everything?’

A

Everything you need to build, deploy, test and release your software should be kept in versioned storage. (helps you collaborate with team and back up code files)

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

What is ‘if it hurts, do it more frequently?’

A

If a build is painful, do it on every check-in. (people get used to it, less work to do in one go, better to merge code monthly than every 4 years)

17
Q

What is ‘build quality in?’

A

Defects are fixed as soon as they are found. TEST EARLY AND AUTOMATICALLY. (fix it earlier up the delivery chain, cheaper and easier to fix)

18
Q

What is ‘done means released?’

A

A feature is only considered ‘done’ once it is in production. You don’t know what problems you will encounter or how long they will take to fix. By production these should be done.

19
Q

What is ‘everyone is responsible?’

A

At a glance, the status of the build is visible to everyone. Having multiple teams such as test and dev creates an adversarial relationship. (you can’t pass your problems to another team).

20
Q

What is ‘continuous improvement?’

A

Teams should reflect on what has gone well, what has gone badly, and discuss how to improve. Don’t witch hunt people who make errors, we learn the lesson as an organization. For example, testing should have picked up the error. People will become scared to innovate otherwise.

21
Q

What is the iterative/incremental model?

A

Exploration, development and operation at the same time.
Iterative because the feed-forward between activities is augmented with the feedback between them
Incremental because the interleaves activities regularly deliver small addition pieces of functionality.

22
Q

What is shift left testing?

A

Beginning testing as early as practical in the lifecycle. Traditionally in a waterfall cycle it happens at the end which can happen at the end of a number of years, really long time to fix and expensive. Stops us overrunning.

23
Q

What is the test pyramid?

A

Describes tests carried out in development
Unit
Service
End to end

24
Q

What are unit tests?

A

Before code is accepted into dev, unit tests are ran, there may be thousands of unit tests, performed in seconds using testing frameworks (such as JUnit)

25
Q

What are service tests?

A

Before code for a MICROSERVICE is accepted into staging, service tests are run. There may be hundreds of them, performed in a few minutes, stubbing out collaborating services. Done in isolation. Test just your service (fake its results).

26
Q

What are end-to-end tests?

A

Before microservices are accepted into production environment, end-to-end tests are run. There may be tens of them, performed in several minutes mimicking user interaction through a GUI, testing interaction with over services.

27
Q

What is the test snow cone anti-pattern? (things you shouldnt do)

A

Test snow cone, where all test coverage is in end-to-end tests. Leads to slow test runs and long feedback cycles. (more tests should be in unit tests testing erroneous errors etc)

28
Q

What 2 things may a service test be implemented using?

A

stubbing,
mocking

(we want to test only our service, not others)

29
Q

What is stubbing?

A

A stub is a dummy service, calls to which are not verified as part of the test (pretend the output was 709 for example). Its consistent, fast, simple, and allows you to test before devs have finished their services. if your service fails its your problem.

30
Q

What is mocking?

A

A mock is a dummy service, calls to which are verified as part of the test. It makes a call to a dummy service, and returns the same result i.e. 709. It tests we can make http calls with the same protocol as well, which we dont do in stubbing.

31
Q

What 2 things might an end-to-end test implementation be?

A

brittle,
flaky

32
Q

What is a brittle end-to-end test?

A

A brittle test is one that fails because of another service fails.
e.g. in a mortgage system one service fails because the database call failed, but we see it as a failure of the first service.

33
Q

What is a flaky end-to-end test?

A

A flaky test is one that sometimes fails because another service fails, perhaps due to a time-out or race condition. (much harder to detect and replicate, and fix (its flaky))

34
Q

What 5 cautions may we have about end-to-end tests?

A
  1. individual team tests
  2. dedicated testing teams
  3. the normalisation of deviance
  4. the time to run
  5. the lack of independent testability
35
Q

What is the ‘individual team test’ caution in end to end testing?

A

end to end tests may be created by every individual team, leading to slow runs and a lack of ownership.

36
Q

What is the ‘dedicated testing teams’ caution in end to end testing?

A

They can lead to bottlenecks and adversarial friction. They are a team in the company that are often disliked.

37
Q

What is the ‘normalisation of deviance’ caution in end to end testing?

A

Flaky tests lead to the normalisation of deviance, devs lose faith in a test suit that ‘always fails like that’. We need to solve flaky tests asap, not just allow them to fail every now and then.

38
Q

What is the ‘time to run’ caution in end-to-end testing?

A

End to end tests may steadily pile up, increasing the time to run, perhaps to days, as teams take longer to finish their features, and requesting new end-to-end tests.

39
Q

What is ‘the lack of independent testability’ caution in end to end testing?

A

End to end tests may require teams to coordinate with each other or to wait for each other.