Agile Software Engineering
© Ian Sommerville 2018
© Ian Sommerville 2018:
Agile Software Engineering
Agile software engineering
2
© Ian Sommerville 2018:
Agile Software Engineering
Agile methods
3
© Ian Sommerville 2018:
Agile Software Engineering
Table 2.1 The agile manifesto
We are uncovering better ways of developing software by doing it and helping others to do it. Through this work, we have come to value:
- individuals and interactions over processes and tools;
- working software over comprehensive documentation;
- customer collaboration over contract negotiation;
- responding to change over following a plan.
While there is value on the items on the right, we value the items on the left more.
4
© Ian Sommerville 2018:
Agile Software Engineering
© Ian Sommerville 2018:
Agile Software Engineering
Incremental development
5
© Ian Sommerville 2018:
Agile Software Engineering
Figure 2.1 Incremental development
6
© Ian Sommerville 2018:
Agile Software Engineering
© Ian Sommerville 2018:
Agile Software Engineering
Table 2.2 Incremental development activities
Choose features to be included in an increment�Using the list of features in the planned product, select those features that can be implemented in the next product increment.
Refine feature descriptions�Add detail to the feature descriptions so that the team have a common understanding of each feature and there is sufficient detail to begin implementation.
Implement and test�Implement the feature and develop automated tests for that feature that show that its behaviour is consistent with its description.
Integrate feature and test�Integrate the developed feature with the existing system and test it to check that it works in conjunction with other features.
Deliver system increment�Deliver the system increment to the customer or product manager for checking and comments. If enough features have been implemented, release a version of the system for customer use.
7
© Ian Sommerville 2018:
Agile Software Engineering
© Ian Sommerville 2018:
Agile Software Engineering
Table 2.3 Agile development principles
Involve the customer �Involve customers closely with the software development team. Their role is to provide and prioritize new system requirements and to evaluate each increment of the system.
Embrace change �Expect the features of the product and the details of these features to change as the development team and the product manager learn more about it. Adapt the software to cope with changes as they are made.
Develop and deliver incrementally �Always develop software products in increments. Test and evaluate each increment as it is developed and feed back required changes to the development team. �
8
© Ian Sommerville 2018:
Agile Software Engineering
© Ian Sommerville 2018:
Agile Software Engineering
Table 2.3 Agile development principles
Maintain simplicity�Focus on simplicity in both the software being developed and in the development process. Wherever possible, do what you can to eliminate complexity from the system.
Focus on people, not things �Trust the development team and do not expect everyone to always do the development process in the same way. Team members should be left to develop their own ways of working without being limited by prescriptive software processes.
9
© Ian Sommerville 2018:
Agile Software Engineering
© Ian Sommerville 2018:
Agile Software Engineering
Extreme programming
10
© Ian Sommerville 2018:
Agile Software Engineering
Figure 2.2 Extreme programming practices
11
© Ian Sommerville 2018:
Agile Software Engineering
© Ian Sommerville 2018:
Agile Software Engineering
Table 2.4 Widely adopted XP practices
Incremental planning/user stories �There is no ‘grand plan’ for the system. Instead, what needs to be implemented (the requirements) in each increment are established in discussions with a customer representative. The requirements are written as user stories. The stories to be included in a release are determined by the time available and their relative priority.
Small releases�The minimal useful set of functionality that provides business value is developed first. Releases of the system are frequent and incrementally add functionality to the previous release.
Test-driven development� Instead of writing code then tests for that code, developers write the tests first. This helps clarify what the code should actually do and that there is always a ‘tested’ version of the code available. An automated unit test framework is used to run the tests after every change. New code should not ‘break’ code that has already been implemented.
12
© Ian Sommerville 2018:
Agile Software Engineering
© Ian Sommerville 2018:
Agile Software Engineering
Table 2.4 Widely adopted XP practices
Continuous integration �As soon as the work on a task is complete, it is integrated into the whole system and a new version of the system is created. All unit tests from all developers are run automatically and must be successful before the new version of the system is accepted.
Refactoring�Refactoring means improving the structure, readability, efficiency and security of a program. All developers are expected to refactor the code as soon as potential code improvements are found. This keeps the code simple and maintainable.
13
© Ian Sommerville 2018:
Agile Software Engineering
© Ian Sommerville 2018:
Agile Software Engineering
Scrum
14
© Ian Sommerville 2018:
Agile Software Engineering
Table 2.5 Scrum terminology
Product�The software product that is being developed by the Scrum team.
Product owner�A team member who is responsible for identifying product features and attributes. They review work done and help to test the product.
Product backlog �A to-do list of items such as bugs, features and product improvements that the Scrum team have not yet completed.
Development team�A small self-organising team of five to eight people who are responsible for developing the product.
Sprint �A short period, typically two to four weeks, when a product increment is developed.
15
© Ian Sommerville 2018:
Agile Software Engineering
© Ian Sommerville 2018:
Agile Software Engineering
Table 2.5 Scrum terminology
Scrum �A daily team meeting where progress is reviewed and work to be done that day as discussed and agreed.
ScrumMaster �A team coach who guides the team in the effective use of Scrum.
Potentially shippable product increment�The output of a sprint which should be of high enough quality to be deployed for customer use.
Velocity�An estimate of how much work a team can do in a single sprint.
16
© Ian Sommerville 2018:
Agile Software Engineering
© Ian Sommerville 2018:
Agile Software Engineering
Key roles in Scrum
17
© Ian Sommerville 2018:
Agile Software Engineering
Scrum and sprints
18
© Ian Sommerville 2018:
Agile Software Engineering
Figure 2.3 Scrum cycles
19
© Ian Sommerville 2018:
Agile Software Engineering
© Ian Sommerville 2018:
Agile Software Engineering
Figure 2.4 The top five benefits of using Scrum
20
© Ian Sommerville 2018:
Agile Software Engineering
© Ian Sommerville 2018:
Agile Software Engineering
Key Scrum practices
21
© Ian Sommerville 2018:
Agile Software Engineering
Product backlogs
22
© Ian Sommerville 2018:
Agile Software Engineering
Table 2.6 Examples of product backlog items
1. As a teacher, I want to be able to configure the group of tools that are available to individual classes. (feature)
2. As a parent, I want to be able to view my childrens’ work and the assessments made by their teachers. (feature)
3. As a teacher of young children, I want a pictorial interface for children with limited reading ability. (user request)
4. Establish criteria for the assessment of open source software that might be used as a basis for parts of this system. (development activity)
5. Refactor user interface code to improve understandability and performance. (engineering improvement)
6. Implement encryption for all personal user data. (engineering improvement)
23
© Ian Sommerville 2018:
Agile Software Engineering
© Ian Sommerville 2018:
Agile Software Engineering
Table 2.7 Product backlog item states
Ready for consideration �These are high-level ideas and feature descriptions that will be considered for inclusion in the product. They are tentative so may radically change or may not be included in the final product.
Ready for refinement �The team has agreed that this is an important item that should be implemented as part of the current development. There is a reasonably clear definition of what is required. However, work is needed to understand and refine the item.
Ready for implementation �The PBI has enough detail for the team to estimate the effort involved and to implement the item. Dependencies on other items have been identified.
24
© Ian Sommerville 2018:
Agile Software Engineering
© Ian Sommerville 2018:
Agile Software Engineering
Figure 2.5 Product backlog activities
25
© Ian Sommerville 2018:
Agile Software Engineering
© Ian Sommerville 2018:
Agile Software Engineering
Product backlog activities
26
© Ian Sommerville 2018:
Agile Software Engineering
PBI estimation metrics
27
© Ian Sommerville 2018:
Agile Software Engineering
Timeboxed sprints
28
© Ian Sommerville 2018:
Agile Software Engineering
Figure 2.6 Benefits of using timeboxed sprints
29
© Ian Sommerville 2018:
Agile Software Engineering
© Ian Sommerville 2018:
Agile Software Engineering
Sprint activities
30
© Ian Sommerville 2018:
Agile Software Engineering
Figure 2.7 Sprint activities
31
© Ian Sommerville 2018:
Agile Software Engineering
© Ian Sommerville 2018:
Agile Software Engineering
Sprint planning
32
© Ian Sommerville 2018:
Agile Software Engineering
Figure 2.8 Sprint goals
33
© Ian Sommerville 2018:
Agile Software Engineering
© Ian Sommerville 2018:
Agile Software Engineering
Sprint planning
34
© Ian Sommerville 2018:
Agile Software Engineering
Table 2.8 Scrums
A scrum is a short, daily meeting that is usually held at the beginning of the day. During a scrum, all team members share information, describe their progress since the previous day’s scrum, problems that have arisen and plans for the coming day. This means that everyone on the team knows what is going on and, if problems arise, can re-plan short-term work to cope with them.
Scrum meetings should be short and focused. To dissuade team members from getting involved in long discussions, they are sometimes organized as ‘stand-up’ meetings where there are no chairs in the meeting room.
During a scrum, the sprint backlog is reviewed. Completed items are removed from it. New items may be added to the backlog as new information emerges. The team then decide who should work on sprint backlog items that day.
35
© Ian Sommerville 2018:
Agile Software Engineering
© Ian Sommerville 2018:
Agile Software Engineering
Agile activities
36
© Ian Sommerville 2018:
Agile Software Engineering
Table 2.9 Code completeness checklist
Reviewed�The code has been reviewed by another team member who has checked that it meets agreed coding standards, is understandable, includes appropriate comments, and has been refactored if necessary.
Unit tested�All unit tests have been run automatically and all tests have executed successfully.
Integrated�The code has been integrated with the project codebase and no integration errors have been reported.
Integration tested �All integration tests have been run automatically and all tests have executed successfully.
Accepted�Acceptance tests have been run if appropriate and the product owner or the development team have confirmed that the product backlog item has been completed.
37
© Ian Sommerville 2018:
Agile Software Engineering
© Ian Sommerville 2018:
Agile Software Engineering
Sprint reviews
38
© Ian Sommerville 2018:
Agile Software Engineering
Figure 2.9 Self-organizing teams
39
© Ian Sommerville 2018:
Agile Software Engineering
© Ian Sommerville 2018:
Agile Software Engineering
Team size and composition
40
© Ian Sommerville 2018:
Agile Software Engineering
Team coordination
41
© Ian Sommerville 2018:
Agile Software Engineering
External interactions
42
© Ian Sommerville 2018:
Agile Software Engineering
Figure 2.10 Managing external interactions
43
© Ian Sommerville 2018:
Agile Software Engineering
© Ian Sommerville 2018:
Agile Software Engineering
Project management
44
© Ian Sommerville 2018:
Agile Software Engineering
Figure 2.11 Project management responsibilities
45
© Ian Sommerville 2018:
Agile Software Engineering
© Ian Sommerville 2018:
Agile Software Engineering
Key points 1
46
© Ian Sommerville 2018:
Agile Software Engineering
Key points 2
47
© Ian Sommerville 2018:
Agile Software Engineering