Software Development
Software Development
A Practical Approach!
Hans-Petter Halvorsen
[Link]
[Link]
Software Development
A Practical Approach!
Hans-Petter Halvorsen - 2026-05-13
Software Development
A Practical Approach!
Hans-Petter Halvorsen
ISBN: 978-82-691106-0-9
ii
Preface
The main goal with this document:
iii
• Quality and Performance
o Make sure the software fulfills the customers’ needs
o Make sure the software is secure
We will learn how to build good (i.e., high quality) software, which includes:
iv
Table of Contents
Preface .................................................................................................iii
1 Introduction .................................................................................... 18
1.1 Background ...................................................................................................... 23
4.2 Roles................................................................................................................. 44
4.2.1 Stakeholders................................................................................................................... 45
5.4 Testing.............................................................................................................. 51
6.5 Exercises........................................................................................................... 67
7 Scrum .............................................................................................. 69
7.1 The Scrum Process ........................................................................................... 70
9.7 Exercises........................................................................................................... 99
System Engineering: The process of analyzing and designing an entire system, including the
hardware and the software.
Software Engineering: The discipline for creating software applications. A systematic approach to
the design, development, testing, and maintenance of software.
A lot of systems today have a mix of hardware and software that is tightly integrated, like modern
smartphones, tablets, etc. Creating such systems involves a lot of different disciplines.
In Figure 1-2 we see a typical network and infrastructure that the software relies on.
Part 1: Introduction
20 1 Introduction
Figure 1-3 we see the complexity of software development and different components that are
involved.
In Figure 1-4 we see the different phases involved in the Software Development Lifecycle (SDLC).
Part 1: Introduction
21 1 Introduction
• Planning
• Requirements Analysis
• Design
• Implementation
• Testing
• Deployment and Maintenance
In Figure 1-5 we see examples of some of the different activities involved in the different phases of
software development.
Part 1: Introduction
22 1 Introduction
As you see, software development involves a lot of phases, they are executed by different
disciplines and different people. We will discuss and explain all these things later in this document.
Part 1: Introduction
23 1 Introduction
1.1 Background
Software and software systems are getting more and more complex, so it is important to have the
necessary “tools” in your “toolbox” to be able to create and maintain your software.
Software Development is a complex process, and it may involve a lot of money and a lot of people.
Here are some examples:
• Number of Code Lines: Real systems may have millions of code lines
• Combination of Hardware and Software: Most of the projects involve both hardware and
software and integration between them.
• iPhone 1: Development period 2004-2007, 1000 Apple employees worked with the device,
Estimated cost: $150 mill.
Part 1: Introduction
24 1 Introduction
[[Link]
Project Planning and Management is important in Software Development, and we can use
different approaches to deal with Software Development, which we will cover in this document.
Especially so-called Agile approaches, such as Scrum, have become very popular today.
1.2 Topics
Below we list the different topics covered in this document. The Software Development Life Cycle,
shorted SDLC, involves distinct phases, such as:
• Market research
• Gathering requirements for the proposed business solution
• Analyzing the problem
• Create a plan or design for the software-based solution
• Implementation (coding) of the software
• Documentation in different ways
• Testing the software
• Deployment and Installation
• Maintenance and bug fixing
• Marketing
Part 1: Introduction
25 1 Introduction
There are different approaches (Software Development Processes) that deal with these phases,
such as:
• Waterfall model
• V-model
• Agile Software Development (such as Scrum, XP, etc.)
• Spiral model
• Rational Unified Process (RUP)
• etc.
We will learn more about these development processes later in this document.
Software development also involves separate roles, which are organized in different teams (Figure
1-8). Typical roles are:
• Project Manager
• System Architect
• UX Designer
• Programmer, System Developer
• Tester
• Customer
It is crucial that the separate roles and teams can work together and collaborate.
The programmer or system engineer must deal with the fact that there exist hundreds of different
programming languages. Each language has pros and cons, so it is important to find out which
programming language is best suited in each situation.
Part 1: Introduction
26 1 Introduction
In this document, we will learn how to build good (i.e., high quality) software, which includes:
• Requirements Specification
• Technical Design
• User Experience (UX)
• Improved Code Quality and Implementation
• Testing
• System Documentation
• User Documentation
• etc.
1.3 Tools
To create great software, as a software engineer you need a toolbox with proper tools, otherwise
you will not succeed in your job (see Figure 1-9).
Part 1: Introduction
27 1 Introduction
When working with software development it is important to have good tools. The developer needs
of course to use a programming language and proper IDE (Integrated Development Environment).
In addition, a so-called ALM Tool should be used. ALM is short for Application Lifecycle
Management. An ALM tool typically facilitates and integrates things like:
• Requirements Management
• Architecture
• Coding
• Source Code Control (SCC)
• Testing
• Bug Tracking
• Release Management
• etc.
There exist a lot of such tools, e.g., Azure DevOps, Jira, GitHub, ClickUp, etc.
We will take a closer look at Azure DevOps in this document. Azure DevOps from Microsoft is
tightly integrated with Visual Studio.
Typically, you need to share the code with other developers or testers in your team or other
teams, so it is crucial that you have tools that can be used to share your code, that makes sure that
Part 1: Introduction
28 1 Introduction
old versions of your code will be stored, and can be restored, etc. Such a system is called a Source
Code Control (SCC) system.
Your software will also contain a lot of bugs that need to be found, tracked, and fixed, etc. To
handle that we need a so-called Bug Tracking system.
In Figure 1-10 we see some of the bug tracking functionality in Azure DevOps.
In Figure 1-11 we see a typical software project with different platforms and frameworks involved.
Part 1: Introduction
29 1 Introduction
Figure 1-11: Typical Software Project with different Platforms and Frameworks involved
Typically, your software needs to be installed and be running on different devices, such as PCs,
tablets, smartphones, etc. You also need to store the data, typically in a database, such as
Microsoft SQL Server, MySQL, etc.
All these devices and data also need to communicate with each other over a network, either an
internal network (LAN, Local Area Network) or over Internet (WAN, Wide Area Network).
All these things make it very complicated to develop, test, deploy and install such systems. That’s
the reality for a modern software developer.
• Requirements Management
• Architecture
• Coding
• Source Code Control (SCC)
Part 1: Introduction
30 1 Introduction
• Testing
• Bug Tracking
• Release Management
• etc.
Some examples of such ALM tools are Azure DevOps, Atlassian Suite (which includes Jira,
Confluence and Bitbucket), GitHub, etc.
You use Azure DevOps through your web browser and as an integration in Visual Studio and Visual
Studio Code.
Note! Azure DevOps from Microsoft and Microsoft Azure are not the same!!
• Microsoft Azure is a cloud infrastructure where you can host Virtual Machines (VMs),
databases and websites, etc. Microsoft Azure can be compared to Amazon Web Services
(AWS) and Google Cloud Platform (GCP).
Part 1: Introduction
31 1 Introduction
• Azure DevOps is an ALM collaboration platform used during the planning and development
of your software where you can use code repositories, Scrum features, create the product
backlogs, task boards, etc. See chapter 24 for a detailed overview of Azure DevOps.
1.4.3 GitHub
GitHub started as a code hosting platform that was using Git as a repository but has grown to
include many ALM features. GitHub comes also in a free version and paid versions, including
GitHub Enterprise.
Part 1: Introduction
2 Software History
2.1 Introduction
Computer and software history goes back to the beginning of the 1900 century. IBM was
established in 1911, Hewlet Packard (HP) was established in 1939, the transistor came in 1947, the
first Microprocessor came in 1972, etc. But “personal computing” started in 1981 with MS-DOS
and the IBM PC. In 1984 came the famous Macintosh from Apple. Windows 1.0 was released in
1985.
They found a bug (a moth) inside a computer in 1947 that made the program not behave as
expected. This was the “first” real bug.
In the 80s and 90s we saw the beginning of the personal computer era that started with Mac
computers from Apple (Macintosh, 1984) and IBM computers from IBM (or IBM compatible
computers from other vendors) with MS-DOS and later Windows installed (Figure 2-1).
32
33 2 Software History
World Wide Web (WWW) was established in 1991. The first Web Browser, as we know it today,
came in 1994 (Netscape). Google was established as late as 1998. Facebook was first invented in
2004. The first smartphone was released in 2007 (iPhone).
In Figure 2-2 we see some of the people that have founded and shaped the modern software
industry.
The companies that they created still dominate the software industry today. Some of the people
are still active within these companies today, either as CEOs or members of the board.
• Apple (Software and Hardware) (established 1976), Steve Jobs, Steve Wozniak
Part 1: Introduction
34 2 Software History
In addition, we can mention companies like IBM, Oracle, Samsung (more hardware than software),
Amazon, SAP, Adobe, Symantec, VMware, etc.
Apps and Mobil devices: Everybody has a mobile device today and fewer PCs are sold than ever
before. Licensing: You don’t buy, but lease software these days and all your information is stored
in the Cloud, and some software is running in the Cloud (so-called Cloud Computing). Security
challenges is very important in this case.
The companies that develop software need to face these facts and make the necessary changes to
survive.
“Softwear” and Wearable Computing: Now we have watches like Galaxy Gear, the Apple Watch,
Google Glass, etc.
Part 1: Introduction
35 2 Software History
Part 1: Introduction
3 Software Development
In this chapter, we will give a short overview of software development, the challenges and what
kind of different software categories we have, what kind of documents that are needed and
created during the software development process, what kind of skills needed, etc.
Terms:
In Figure 3-1 we see how a software application typically interacts with users, the underlying
operating system and hardware.
36
37 3 Software Development
3.1 Challenges
In Figure 3-2 we see some of the challenges in software development.
Collaboration and communication within the team and with stakeholders, etc. is crucial when it
comes to creating good software.
Market research, etc. is a good start, but in the end, you need to go much deeper to understand
the customer. Most of the time the customer doesn’t even know what they need.
• Stand-alone applications
Part 1: Introduction
38 3 Software Development
– These are application systems that run on a local computer, such as a PC. They
include all necessary functionality and do not need to be connected to a network.
– Applications that are executed on a remote computer and are accessed by users
from their own PCs or terminals. These include web applications such as e-
commerce applications.
– These are software control systems that control and manage hardware devices.
Numerically, there are probably more embedded systems than any other type of
system.
– These are business systems that are designed to process data in large batches. They
process large numbers of individual inputs to create corresponding outputs.
• Entertainment systems
– These are systems that are primarily for personal use, and which are intended to
entertain the user.
– These are systems that are developed by scientists and engineers to model physical
processes or situations, which include many, separate, interacting objects.
– These are systems that collect data from their environment using a set of sensors
and send that data to other systems for processing.
• Systems of systems
– These are systems that are composed of several other software systems.
Generic products
• Stand-alone systems that are marketed and sold to any customer who wishes to buy them.
Part 1: Introduction
39 3 Software Development
Customized products
• Examples – embedded control systems, air traffic control software, traffic monitoring
systems.
3.3 Documentation
Lots of documentation is involved in software development, see Figure 3-3. In this document, we
will go through all the documentation needed in the different phases involved in software
development.
o Documentation stating what parts of an application will be tested, and the schedule
of when the testing is to be performed
o Contents: Introduction, Test Plan, Test Design, Test Cases, Test procedures, Test
Log, …, Summary
Part 1: Introduction
40 3 Software Development
QA – Quality Assurance. Quality Assurance (QA) refers to the engineering activities implemented
in a quality system so that requirements for a product or service will be fulfilled.
Part 1: Introduction
41 3 Software Development
Part 1: Introduction
Part 2 : Software
Engineering
In this part, we introduce the different features and topics involved in software engineering, such
as software teams, software development processes, software project management, etc.
42
4 Development Teams
A typical Software Team consists of the following roles:
• Project Manager
• System Architect
• UX Designer (Software Designer)
• Programmer
• Software Tester
In addition, we have Stakeholders or Customers that play an important role in the development.
A System Engineer is a general person that could be a Programmer, Architect, Designer, Tester in
different phases in the project, or he could be a tester in one project and a programmer in another
project – all in one person. That is usually the case in small companies, while in larger companies
these roles (designer, tester, programmer) could be a full-time job.
43
44 4 Development Teams
4.1 Teams
To successfully create software, collaboration inside the team is essential.
4.2 Roles
A typical Software Team consists of the following roles:
• Project Manager
• System Architect
• UX Designer (Software Designer)
• Programmer
• Software Tester
In addition, we have Stakeholders or Customers that play an important role in the development.
4.2.1 Stakeholders
All the people that have an interest in the outcome of the software are called Stakeholders. In
most cases the Stakeholders are referred to as “Customers” but others may also be referred to as
stakeholders, such as management, shareholders, etc.
4.2.4 UX Designer
UX Design is the Design of the User eXperience (UX) and the Graphical User Interface (GUI),
sometimes also called Human Machine Interface (HMI). This is what the end user of the software
sees.
4.2.5 Programmer
The Programmer or the Developer is doing the actual implementation of the software, i.e., the
coding.
This chapter introduces these phases. Figure 5-1 shows an overview of the different phases
involved in Software Development:
47
48 5 Software Development Phases
5.1 Requirements
In the requirements, we describe what the system should do. The requirements include both
functional requirements and non-functional requirements.
Functional Requirements: Statements of services the system should provide, how the system
should react to inputs and how the system should behave in different situations. May state what
the system should not do.
[[Link]
The requirements are often collected in a so-called “Software Requirements Specification (SRS)”
document.
• Introduction
o Purpose
o Definitions
o System overview
o References
• Overall description
o Product perspective
▪ System Interfaces
▪ User Interfaces
▪ Hardware interfaces
▪ Software interfaces
▪ Communication Interfaces
▪ Memory Constraints
▪ Operations
▪ Site Adaptation Requirements
o Product functions
o User characteristics
o Constraints, assumptions, and dependencies
• Specific requirements
o External interface requirements
o Functional requirements
o Performance requirements
o Design constraints
▪ Standards Compliance
o Logical database requirement
o Software System attributes
▪ Reliability
▪ Availability
▪ Security
▪ Maintainability
▪ Portability
• Other requirements
The Requirements is normally given by the Customer if we deal with customized products. The
software requirements document is the official statement of what is required of the system. It
should include both a definition of user requirements and a specification of the system
requirements. It is NOT a design document. As far as possible, it should include a set of WHAT the
system should do rather than HOW it should do it.
5.2 Design
In the design phase, we use the specification and transform it into descriptions of how we should
do it.
In principle, requirements should state what the system should do, and the design should describe
how it does this – but in practice this is not so easy! - In practice, requirements and design are
inseparable.
• Technical Design – Platform and Architecture Design, i.e., how to build the software.
• UX Design – Design of User eXperience (UX) and the Graphical User Interface (GUI),
sometimes also called Human Machine Interface (HMI). This is what the end user of the
software sees.
5.2.2 UX Design
UX Design is the Design of the User eXperience (UX) and the Graphical User Interface (GUI),
sometimes also called Human Machine Interface (HMI). This is what the end user of the software
sees. This is typically done by a so-called UX Designer.
5.3 Implementation
Implementation = Coding.
Most of the software has a Graphical User Interface (GUI). Normally you separate the GUI design
and code into different layers or files.
[[Link]
5.4 Testing
Testing can be performed on different levels and by different people. Testing is a very important
part of software development. About 50% of the software development is about testing your
software. Creating User-friendly Software is Crucial! More about Testing later in this document.
5.5 Deployment
What is Deployment?
Software deployment is all the activities that make a software system available for use.
Examples:
• Installation
• etc.
Deployment strategies may vary depending on what kind of software we create, etc.
When the software is deployed, or installed, you normally go into a Maintenance phase. The
maintenance of software involves bug fixes of the software after the software is released, etc. At
some time, you also need to start planning new releases of the software.
• Waterfall model
• V-model
• Spiral model
• Unified Process (UP)/ Rational Unified Process (RUP)
• Scrum
• eXtreme Programming (XP)
• Lean Software Development
• TDD (Test Driven Development)
• Lean Software Development
• Kanban
• etc.
These processes or models may be divided into 2 main categories: Plan-driven models and Agile
methods. The Waterfall model, V-model and Spiral model are so-called plan-driven models, while
Scrum and eXtreme Programming are so-called Agile methods.
[[Link]
52
53 6 Software Development Process
Traditionally plan-driven methods were used in software development, while today Agile methods
such as Scrum have become very popular, especially in smaller development teams.
Plan-driven models (e.g. Waterfall) generally produce more documentation than Agile models.
In Figure 6-2 we see the main difference between Agile development and ordinary plan-driven
development.
[[Link]
Traditionally with the Waterfall model, you can only start on the next phase when the previous
phase is finished. Therefore, it is called the Waterfall method, see Figure 6-3.
In practice, there is impossible to create perfect requirements and design before you start
implementing the code, so it is common to go back and update these phases iteratively.
6.1.2 V-model
The V-model is derived from the more traditional Waterfall model. The V-model is an extension of
the waterfall model, but it’s using a more flexible approach.
“The V-Model reflects a project management view of software development and fits the needs of
project managers, accountants and lawyers rather than software developers or users.”
As we see in Figure 6-4, the left side is about requirements and design, while the right-side of the
model is about testing and validating.
[[Link]
• Scrum
• eXtreme Programming (XP)
In Figure 6-6 we see the key features with Agile Software Development.
Figure 6-7 shows some main differences between Agile development and more traditional
development methods, such as, e.g., the Waterfall method.
We are uncovering better ways of developing software by doing it and helping others do it.
Through this work, we have come to value:
That is, while there is value in the items on the right, we value the items on the left more.
[[Link]
It is often used in agile software development methodologies such as Scrum. However, burn down
charts can be applied to any project containing measurable progress over time.
Here are some key factors that separate the traditional waterfall method versus the more flexible
Agile methods, such as Scrum:
In Figure 6-9 we see some important differences between the traditional waterfall method and
the Agile Development approach. We see that Agile delivers value in each iteration of the
development.
• Pair Programming
• Code Reviews
• Refactoring
• Unit Testing - In XP you start by writing Unit Tests before you start coding
• Standup Meetings
[[Link]
In XP, they practice so-called “Pair Programming” (Figure 6-11), meaning 2 developers working
together.
So, is Pair Programming Good or Bad? There exist various studies of the productivity of Pair
Programming (Sommerville):
A reasonable question is: Should the 2 developers have the same skills or not?
• Collective Ownership for the code created and the results of the project.
• Continuous informal Review process because each code line is looked at by at least 2
people
• It supports Refactoring, which is a continuous process of software improvement
• Less time is spent on repairing bugs.
• Improved Code Quality
• It reduces the overall risk
[[Link]
6.2.5 Scrum
Scrum is a so-called Agile method, and it has become very popular today. In Figure 6-12 we see an
overview of the Scrum method.
Scrum is simple and easy to understand. The method is more flexible and more informal than plan-
driven methods.
An example of a Daily Scrum Meeting is shown in Figure 6-13. It is normal to hold this meeting as a
“standup meeting”, where participants standing during the meeting.
• Max 15 min.
• The meeting is held at the same time and place every day
• “Stand Up” Meeting
• Purpose:
o Synchronize activities and create a plan for the next 24 hours.
o Track Progress
• Agenda – Each Team member explains:
o What has been accomplished since the last meeting?
o What will be done before the next meeting?
o What obstacles are there in the way?
6.2.6 Kanban
Kanban is based on Lean and Toyota production principles and Just-in-Time principles. Kanban has
fewer “rules” than scrum. Kanban is flow-based, while Scrum is Time box-based (Sprints). Kanban
focuses on limiting the WIP (Work in Progress). Kanban has focus on estimation.
In Kanban, they use a Kanban board (Figure 6-14) to track the progress. The Kanban board is very
similar to the Task board/Scrum board used in Scrum.
The RUP has been designed to work together with UML (Unified Modelling Language).
• Inception
• Elaboration
• Construction
• Transition
6.4 Summary
Agile methods have become very popular today. Agile methods are good in some situations, while
more traditional methods are better in other situations.
To create great software, we need to combine the best of all these approaches and adjust them to
fit the needs of your company. There are lots of different kinds of software, and one method is not
fit to solve all these different situations.
6.5 Exercises
Make sure to discuss and reflect over the following:
7. Explain the differences between Agile and plan-driven development. Give some examples in
each category
9. What is Scrum?
13. Suggest a Software Project where it may be beneficial to use the Waterfall model and another
where Scrum is the best choice
69
70 7 Scrum
An example of a Daily Scrum Meeting is shown in Figure 7-3. It is normal to hold this meeting as a
“standup meeting”, where participants standing during the meeting.
• Max 15 min.
• The meeting is held at the same time and place every day
• “Stand Up” Meeting
• Purpose:
o Synchronize activities and create a plan for the next 24 hours.
o Track Progress
• Agenda – Each Team member explains:
o What has been accomplished since the last meeting?
o What will be done before the next meeting?
o What obstacles are there in the way?
[[Link]
• Product Backlog
• Sprint Backlog
• Increment
Scrum’s artifacts represent work or value in various ways that are useful in providing transparency and
opportunities for inspection and adaptation. Artifacts defined by Scrum are specifically designed to
maximize transparency of key information needed to ensure Scrum Teams are successful in delivering a
“Done” Increment (The Scrum Guide - [Link]
• Product Owner
• Scrum Master
• Development Team
In addition, we have the Stakeholders, but they are not part of the Scrum team itself.
[[Link]
Figure 7-4 summarizes the different meetings (purpose, duration, and frequency).
Scrum:
The Scrum Team consists of a Product Owner, the Development Team, and a Scrum Master. Scrum
Teams are self-organizing and cross-functional. Self-organizing teams choose best to accomplish
their work, rather than being directed by others outside the team.
Development Team:
The Development Team are the professionals who do the work of delivering a potentially
releasable Increment of “Done” product at the end of each Sprint. Development Teams are
structured and empowered by the organization to organize and manage their own work.
Product Owner:
The Product Owner is the person responsible for maximizing the value of the product, the work of
the Development Team, and management of the Product Backlog.
Scrum Master:
The Scrum Master is a servant-leader for the Scrum Team responsible for ensuring Scrum is
understood and enacted. Scrum Masters do this by ensuring that the Scrum Team adheres to
Scrum theory, practices, and rules.
Product Backlog:
The Product Backlog is an ordered list of everything that might be needed in the product and is the
single source of requirements for any changes to be made to the product. The Product Owner is
responsible for the Product Backlog, including its content, availability, and ordering.
Sprint Backlog:
The Sprint Backlog is the set of Product Backlog items selected for the Sprint plus a plan for
delivering the product Increment and realizing the Sprint Goal. The Sprint Backlog is a forecast by
the Development Team about what functionality will be in the next Increment and the work
needed to deliver that functionality.
Increment:
The Increment is the sum of all the Product Backlog items completed during a Sprint and all
previous Sprints.
Sprint:
The heart of Scrum is a Sprint, a time-box of one month or less during which a “Done”, useable,
and potentially releasable product Increment is created. Sprints have consistent durations
throughout a development effort. A new Sprint starts immediately after the conclusion of the
previous Sprint.
The work to be performed in the Sprint is planned at the Sprint Planning Meeting. This plan is
created by the collaborative work of the entire Scrum Team.
Daily Scrum:
The Daily Scrum is a 15-minute time-boxed event for the Development Team to synchronize
activities and create a plan for the next 24 hours. This is done by inspecting the work since the last
Daily Scrum and forecasting the work that could be done before the next one.
Sprint Review:
A Sprint Review is held at the end of the Sprint to inspect the Increment and adapt the Product
Backlog if needed. During the Sprint Review, the Scrum Team and stakeholders collaborate about
what was done in the Sprint. Based on that and any changes to the Product Backlog during the
Sprint, attendees collaborate on the next things that could be done. This is an informal meeting,
and the presentation of the Increment is intended to elicit feedback and foster collaboration.
Sprint Retrospective:
The Sprint Retrospective is an opportunity for the Scrum Team to inspect itself and create a plan
for improvements to be enacted during the next Sprint. The Sprint Retrospective occurs after the
Sprint Review and prior to the next Sprint Planning Meeting. This is a three-hour time-boxed
meeting for one-month Sprints. Proportionately less time is allocated for shorter Sprints.
• Proper Planning
• Kick-off and Brainstorming
• Planning and Estimation
• Project Tracking
78
79 8 Project Management
Project Work consists of working with Project Management, Development and Documentation in
parallel.
If you remove one of these, the project will fail! Assume you have a table with 3 legs, see Figure
8-2. If you remove one of the legs from the table, the table will fall apart.
Agile Development also needs Project Management and Planning, which we will discuss in more
detail later in this chapter.
[[Link]
In project work in general it is important that you complete the plans for this week so that you
don't fall behind and must do last week's work in addition to this week's work. Then there will be
increasingly more work to do every week. See Figure 8-3.
8.2 Kick-off/Brainstorming
A Project should always start with a Kick-off meeting where a brainstorming session is important
of that meeting.
In addition to getting good ideas for solving the project, you should learn from previous projects.
Examples: Who are going to solve the different parts, what kind of Frameworks are you going to
use, what kind of development tools you use, etc.
[[Link]
A good idea is to create a Software Development Plan. The Software Development Plan gives an
overview of all the communication within the project or within the team, i.e., what kind of
communication, how the communication should be done, etc.
Examples of Communication:
1. Introduction: This briefly describes the objectives of the project and set out the constraints
(e.g., budget, time, etc.) that affects the management of the project
2. Project Organization: This section describes how the development team is organized, the
people involved and their roles in the team.
3. Risk Analysis
5. Work Breakdown (WBS, Work Breakdown Structure): Break down the project into
activities and identifies milestones
6. Project Schedule: Shows dependencies between activities, the estimated time required to
reach each milestone, allocation of people to activities. (5) and (6) is typically done in a
Gantt Chart (created in e.g., Microsoft Project)
7. Monitoring and Reporting Mechanisms: Definition of the Management Report that should
be produced, when these should be produced, etc.
Other words for the Software Development Plan may be “Communication Plan” or “Project Plan”.
A Software Development Plan (SDP) is all about the Internal Communication within the
Development Team and how it Communicates with rest of the Organization, the Customers, etc.
A project plan should include an overview of the project’s main activities, duration, start and end
dates for each task, identification of dependencies between tasks, key milestones, allocation of
responsibilities, and an indicator of the status of the various activities to ensure control and
visibility. It must also show purpose and goals, and be realistic and flexible enough to handle
unforeseen events
One of the most used tools for project planning is the Gantt chart. The Gantt chart gives an
overview of tasks, subtasks, milestones, resources, etc. in a project. A Gantt chart is a project
management tool that visually represents a project plan over time. It uses horizontal bars to
illustrate the start and end dates of tasks, their duration, and their dependencies. You can use
Excel or, for example, a web-based alternative such as [Link].
In Figure 8-4 we see a Gant Chart example created with Microsoft Excel.
Tools for creating Gantt Charts: Microsoft Excel can be used, but there are also many other tools
that are more tailored to the task, including downloadable applications as well as web applications
such as ClickUp. Online tools make it much easier to share and collaborate on the progress plan
within a development team, share status updates with customers and management, etc. Other
alternatives include Canva, Miro and [Link].
A project plan and a Gantt chart are created to structure, visualize, and monitor the different
elements and tasks that are part of a project. They provide a clear overview of activities,
milestones, dependencies, and resource usage, which ensures better communication, progress
tracking, and a higher likelihood of achieving the project goals within time and budget constraints.
• Visual overview: Provides a “bird’s-eye view” of the entire project, where start and end
dates for various tasks are shown as horizontal bars on a timeline.
• Structured progress: Makes it easy to track progress by showing how far activities have
progressed (e.g., using colors or partially filled bars).
• Identification of dependencies: Clearly shows which tasks must be completed before
others can start, which is essential for planning.
• Resource management: Helps distribute and manage resources (people, equipment)
efficiently over time.
• Improved communication: Serves as a shared tool for the team and stakeholders (project
manager, customer, etc.), making it easier to understand the plan and manage changes.
• Milestone management: Highlights important checkpoints (milestones) in the project to
ensure that intermediate goals are achieved.
In addition to a Gantt diagram the development team will typically use a Task board (which is
often called a Scrum board or a Kanban board) for development details.
• Project title
• Overview of available resources/personnel
• Project start and end dates
• Total number of hours available (School project: How many hours do you want to work per
week? Multiply by the number of weeks to calculate the total number of hours.)
In addition to the general project information above it should include a table with the following
information:
Important! It is important that project management is an active part of your software project. The
Gantt Chart should be used through the whole project; it is not something you create in the
beginning of the project and put in a drawer.
In Figure 8-5 we see the recommended way of working with the different project activities.
Here is an example of a Gantt chart created using [Link] (see Figure 8-6):
Summary: With a Gantt chart you can determine how much work your team has completed and
how much work that remains. Project managers should routinely update and share a Gantt chart
with the project team. This allows all members to see how they are working together to achieve
the same outcomes. It becomes much easier to manage project dependencies and update plans
along the way. Communication is significantly improved by using it. Make sure to update the Gantt
chart regularly and share it continuously with everyone involved throughout the project. Always
create a Project Plan!
8.4 Meetings
It is necessary to have meetings when planning and creating software, but these meetings should
not be misused.
Below we list some typical meetings needed during the software development project:
Always be prepared before the meetings (otherwise you don’t need to be there)!
o Other matters
When you are finished with the meeting, write a short Minutes of Meeting as soon as possible.
… … …
… … …
In this way, we can easily get an overview of the tasks agreed in the meeting, which is responsible
for the tasks, and a specific deadline for each task. This task list should be followed up in the next
meeting.
Figure 8-7 shows the steps involved in Agile Project Planning and Tracking.
In Agile Project Planning and Tracking, everything is broken down to so-called iterations, as shown
in Figure 8-8.
The Task board is a key tool in Agile Project Planning and Tracking, see Figure 8-9
The Task board is used together with the Burndown chart, as shown in Figure 8-10.
A burn down chart is a graphical representation of work left to do versus time. The outstanding
work (or backlog) is often on the vertical axis, with time along the horizontal. That is, it is a run
chart of outstanding work. It is useful for predicting when all the work will be completed.
It is often used in agile software development methodologies such as Scrum. However, burn down
charts can be applied to any project containing measurable progress over time.
Azure DevOps have all these features (Task board, Burndown chart, etc.) built in.
8.7 Summary
Here are some important keywords for successful project management:
• Useful tools are in Project Management and Tracking are Gantt Chart, Task board,
Burndown Chart
The results of the Requirement Analysis or Requirement Engineering process is normally one or
more documents, called the Software Requirement Specification (shorted “SRS”).
The requirements are in some cases created by the customer, at least the overall requirements (it
defines “What” the customers want), while more details are normally created by architects and
developers in the software company that is going to develop the actual software. Here we can
have both “What” and “How” the software shall be designed or implemented.
The main challenges in Requirements Engineering are that the customers most often don’t know
what they want or are not qualified to know what they need.
93
94 9 Requirements Engineering
In Figure 9-2 and below we explain the different software requirements categories in more detail.
User Requirements
Statements in natural language plus diagrams of the services the system provides and their
operational constraints. Written for customers.
System Requirements
A structured document setting out detailed descriptions of the system’s functions, services and
operational constraints. Defines what should be implemented so may be part of a contract
between client and contractor.
Functional Requirements
Statements of services the system should provide, how the system should react to inputs and how
the system should behave in different situations.
Non-Functional Requirements
Constraints on the services or functions offered by the system such as timing constraints,
constraints on the development process, standards, etc.
They often apply to the system rather than individual features or services.
Since there are different people involved creating and reading the requirements documents, the
requirements are normally split into “High-Level Requirements” and “Detailed Requirements”
(Figure 9-4).
High-level requirements are for “business” people, while detailed requirements are for
developers, etc.
• Depending on the type of software, expected users and the type of system where the
software is used.
• Functional user requirements may be high-level statements of what the system should do.
• These define system properties and constraints e.g. reliability, response time and storage
requirements. Constraints are I/O device capability, system representations, etc.
• Process requirements may also be specified using an IDE, programming language or
development method.
• Non-functional requirements may be more critical than functional requirements. If these
are not met, the system may be useless.
9.5 SRS
Software Requirements Specifications (SRS) are:
• The software requirements document is the official statement of what is required of the
system developers.
• It should include both a definition of user requirements and a specification of the system
requirements.
• It is NOT a design document. As far as possible, it should set of WHAT the system should do
rather than HOW it should do it.
In practice, requirements and design are inseparable. Many don’t separate SRS and SDD (Software
Design Document) documents but include everything in a Requirements & Design Document. Such
a document could be called “Software Requirements and Design Document” (SRD).
In Figure 9-6 we see the different users involved in the SRS document.
In Table 9-1 we see an example of what chapters that we can include in an SRS document.
Table 9-1: Example of Table of Contents for the SRS document (Sommerville)
Chapter Description
Preface This should define the expected readership of the document and
describe its version history, including a rationale for the creation of a
new version and a summary of the changes made in each version.
Introduction This should describe the need for the system. It should briefly describe
the system’s functions and explain how it will work with other systems.
It should also describe how the system fits into the overall business or
strategic objectives of the organization commissioning the software.
Glossary This should define the technical terms used in the document. You
should not make assumptions about the experience or expertise of the
reader.
User Requirements Here, you describe the services provided for the user. The
Definition nonfunctional system requirements should also be described in this
section. This description may use natural language, diagrams, or other
notations that are understandable to customers. Product and process
standards that must be followed should be specified.
System Architecture This chapter should present a high-level overview of the anticipated
system architecture, showing the distribution of functions across
system modules. Architectural components that are reused should be
highlighted.
System Models This might include graphical system models showing the relationships
between the system components and the system and its environment.
Examples of possible models are object models, data-flow models, or
semantic data models.
System Evolution This should describe the fundamental assumptions on which the
system is based, and any anticipated changes due to hardware
evolution, changing user needs, and so on. This section is useful for
system designers as it may help them avoid design decisions that would
constrain likely future changes to the system.
9.7 Exercises
Make sure to discuss and reflect over the following:
9. What is SRS?
GUI design has been in constant change since the first computers and software were created. In
Figure 10-1 we see some images of different Windows versions.
It is important that documents, GUI, code, etc. have the same “Look and Feel”, i.e. make sure to
use common guidelines, templates, etc.
In software design, look and feel is a term used in respect of a graphical user interface and
comprises aspects of its design, including elements such as colors, shapes, layout, and typefaces
(the "look"), as well as the behavior of dynamic elements such as buttons, boxes, and menus (the
"feel"). The term can also refer to aspects of an API, mostly to parts of an API that are not related
to its functional properties.
“Look and Feel”in operating system user interfaces serve two general purposes. First, it provides
branding, helping to identify a set of products from one company. Second, it increases ease of use,
since users will become familiar with how one product functions (looks, reads, etc.) and can
translate their experience to other products with the same look and feel.
101
102 10 User eXperience (UX)
It is the “UX Designer” that design the GUI, while the Programmer make sure to implement it in
the proper programming language (Figure 10-2).
10.1 UX Guidelines
Different platforms have different UX and UX guidelines, so it is important to follow these general
guidelines for the different platforms. The GUI is totally different on, e.g., Windows and Mac OS X.
The different platform vendors create their own guidelines that the developers should follow.
Mockups and prototypes are not so cleanly distinguished in software and systems engineering,
where mockups are a way of designing user interfaces on paper or in computer images. A software
mockup will thus look like the real thing but will not do useful work beyond what the user sees. A
software prototype, on the other hand, will look and work just like the real thing. In many cases it
is best to design or prototype the user interface before source code is written or hardware is built,
to avoid having to go back and make expensive changes.
Be creative - Think outside the box! “Thinking outside the box” is a metaphor that means to think
differently, unconventionally, or from a new perspective.
The goal is to create inclusive solutions that provide equal opportunities for participation and
accessibility for all. That is, to create content and functionality that is accessible to everyone.
Creating applications that are easily navigable, have readable content, and support different ways
of accessing information.
It is important that everyone can use the software we make. Therefore, universal design of ICT
systems is a legal requirement for both public and private sectors. ICT is short for Information and
Communication Technology.
Note! Universal design is required by law! So it is very important that all public services follow the
guidelines and regulations given by the authorities. See more information below.
The Web Accessibility Directive (WAD) is a European Union (EU) law that shall ensure that all
public websites and mobile applications are accessible to everyone, particularly people with
disabilities.
In Norway we have Uutilsynet. Uutilsynet (“Tilsynet for universell utforming av ikt” or in English:
“The Authority for Universal Design of ICT”) give guidelines and check that web solutions and apps
are available to everyone, in line with the regulations given.
Here you will find the Norwegian Authority's guide for websites and apps:
[Link] - You can use this as a guide to
ensure that your systems meet the requirements of the WCAG standard and the authorities in the
EU and Norway.
To create user-friendly websites or web applications, you need to create solutions that focus on
the user's needs. Which target groups are you targeting? After all, they are the ones who will use
what you create/develop. That is, it is important to take this into account already in the initial
phase of the project, when specifying what and how the system should be created.
An important part of the development work is to test how the solution works. When you test for
yourself, you can find a lot of problems that users may encounter. At the same time, by testing
yourself, the road to doing something about what you discover is short.
Elements that you should think about in connection with. The development and testing of the
website or web application include the following:
• Keyboard navigation – Does the solution support the use of a keyboard and not just mouse
use?
• Magnification and responsive design – Do the solution work well even when you enlarge
or shrink the page in the browser or drag the corners of the browser? Does the solution
work on both PC and mobile phone?
• Colors and contrast – Ensure good contrast between text and background. Some are also
color blind, so color alone should not convey information
• Headings – Good and clear headings make it easier for all users to orient themselves in the
text. Use the HTML headings <h1>, <h2> and <h3>.
• Links – It must be clear what are clickable links in the text.
• Images – Do all images have an alternative text?
• Forms – Forms are widely used on websites to enable the user to fill in different types of
information. Make sure to use good prompts, etc.
• Search function – Have you implemented a good search functionality so that it is easy to
find the desired information?
• Page titles – Have you implemented good page titles (HTML <title>) on all your web pages?
Page title is presented at the top of the window or in the tab of the browser and helps the
user find the right browser tab. Page title is also the name suggestion when saving a
bookmark or favorite in the browser.
• Code validation - Correct code is important to ensure that the website works correctly with
various browsers and aids. Your web page should meet the applicable HTML requirements,
syntax, and standards. I.e. check your website using e.g. WC3 Validator:
[Link]
For more information see the following resources given by the Norwegian Authority for Universal
Design of ICT (Uutilsynet):
Important! Make sure to follow the guidelines given during the requirements analysis phase, the
design phase, the development phase and the testing phase.
• Structure Diagrams
• Behavior Diagrams
o Interaction Diagrams (subcategory of Behavior Diagrams)
• Class Diagram
• Component Diagram
• Deployment Diagram
• Object Diagram
• Package Diagram
• Activity Diagram
108
109 0 Why is universal design important? Here are
some key elements:
Easier to navigate.
Note! Universal design is required by law! So it is very important that all public services follow the
guidelines and regulations given by the authorities. See more information below.
Web Content Accessibility Guidelines (WCAG) are international standards developed by the W3C
to make digital content accessible to people with disabilities, covering websites, applications, and
other digital materials. They are built on four principles (POUR): Perceivable, Operable,
Easier to navigate.
Note! Universal design is required by law! So it is very important that all public services follow the
guidelines and regulations given by the authorities. See more information below.
Web Content Accessibility Guidelines (WCAG) are international standards developed by the W3C
to make digital content accessible to people with disabilities, covering websites, applications, and
other digital materials. They are built on four principles (POUR): Perceivable, Operable,
Easier to navigate.
Note! Universal design is required by law! So it is very important that all public services follow the
guidelines and regulations given by the authorities. See more information below.
Web Content Accessibility Guidelines (WCAG) are international standards developed by the W3C
to make digital content accessible to people with disabilities, covering websites, applications, and
other digital materials. They are built on four principles (POUR): Perceivable, Operable,
Easier to navigate.
Note! Universal design is required by law! So it is very important that all public services follow the
guidelines and regulations given by the authorities. See more information below.
Web Content Accessibility Guidelines (WCAG) are international standards developed by the W3C
to make digital content accessible to people with disabilities, covering websites, applications, and
other digital materials. They are built on four principles (POUR): Perceivable, Operable,
Easier to navigate.
Note! Universal design is required by law! So it is very important that all public services follow the
guidelines and regulations given by the authorities. See more information below.
Web Content Accessibility Guidelines (WCAG) are international standards developed by the W3C
to make digital content accessible to people with disabilities, covering websites, applications, and
other digital materials. They are built on four principles (POUR): Perceivable, Operable,
Easier to navigate.
Note! Universal design is required by law! So it is very important that all public services follow the
guidelines and regulations given by the authorities. See more information below.
Web Content Accessibility Guidelines (WCAG) are international standards developed by the W3C
to make digital content accessible to people with disabilities, covering websites, applications, and
other digital materials. They are built on four principles (POUR): Perceivable, Operable,
Easier to navigate.
Note! Universal design is required by law! So it is very important that all public services follow the
guidelines and regulations given by the authorities. See more information below.
Web Content Accessibility Guidelines (WCAG) are international standards developed by the W3C
to make digital content accessible to people with disabilities, covering websites, applications, and
other digital materials. They are built on four principles (POUR): Perceivable, Operable,
Easier to navigate.
Note! Universal design is required by law! So it is very important that all public services follow the
guidelines and regulations given by the authorities. See more information below.
Web Content Accessibility Guidelines (WCAG) are international standards developed by the W3C
to make digital content accessible to people with disabilities, covering websites, applications, and
other digital materials. They are built on four principles (POUR): Perceivable, Operable,
Easier to navigate.
Note! Universal design is required by law! So it is very important that all public services follow the
guidelines and regulations given by the authorities. See more information below.
Web Content Accessibility Guidelines (WCAG) are international standards developed by the W3C
to make digital content accessible to people with disabilities, covering websites, applications, and
other digital materials. They are built on four principles (POUR): Perceivable, Operable,
Easier to navigate.
Note! Universal design is required by law! So it is very important that all public services follow the
guidelines and regulations given by the authorities. See more information below.
Web Content Accessibility Guidelines (WCAG) are international standards developed by the W3C
to make digital content accessible to people with disabilities, covering websites, applications, and
other digital materials. They are built on four principles (POUR): Perceivable, Operable,
Easier to navigate.
Note! Universal design is required by law! So it is very important that all public services follow the
guidelines and regulations given by the authorities. See more information below.
Web Content Accessibility Guidelines (WCAG) are international standards developed by the W3C
to make digital content accessible to people with disabilities, covering websites, applications, and
other digital materials. They are built on four principles (POUR): Perceivable, Operable,
Easier to navigate.
Note! Universal design is required by law! So it is very important that all public services follow the
guidelines and regulations given by the authorities. See more information below.
Web Content Accessibility Guidelines (WCAG) are international standards developed by the W3C
to make digital content accessible to people with disabilities, covering websites, applications, and
other digital materials. They are built on four principles (POUR): Perceivable, Operable,
Easier to navigate.
Note! Universal design is required by law! So it is very important that all public services follow the
guidelines and regulations given by the authorities. See more information below.
Web Content Accessibility Guidelines (WCAG) are international standards developed by the W3C
to make digital content accessible to people with disabilities, covering websites, applications, and
other digital materials. They are built on four principles (POUR): Perceivable, Operable,
Easier to navigate.
Note! Universal design is required by law! So it is very important that all public services follow the
guidelines and regulations given by the authorities. See more information below.
Web Content Accessibility Guidelines (WCAG) are international standards developed by the W3C
to make digital content accessible to people with disabilities, covering websites, applications, and
other digital materials. They are built on four principles (POUR): Perceivable, Operable,
Easier to navigate.
Note! Universal design is required by law! So it is very important that all public services follow the
guidelines and regulations given by the authorities. See more information below.
Web Content Accessibility Guidelines (WCAG) are international standards developed by the W3C
to make digital content accessible to people with disabilities, covering websites, applications, and
other digital materials. They are built on four principles (POUR): Perceivable, Operable,
Easier to navigate.
Note! Universal design is required by law! So it is very important that all public services follow the
guidelines and regulations given by the authorities. See more information below.
Web Content Accessibility Guidelines (WCAG) are international standards developed by the W3C
to make digital content accessible to people with disabilities, covering websites, applications, and
other digital materials. They are built on four principles (POUR): Perceivable, Operable,
Easier to navigate.
Note! Universal design is required by law! So it is very important that all public services follow the
guidelines and regulations given by the authorities. See more information below.
Web Content Accessibility Guidelines (WCAG) are international standards developed by the W3C
to make digital content accessible to people with disabilities, covering websites, applications, and
other digital materials. They are built on four principles (POUR): Perceivable, Operable,
Easier to navigate.
Note! Universal design is required by law! So it is very important that all public services follow the
guidelines and regulations given by the authorities. See more information below.
Web Content Accessibility Guidelines (WCAG) are international standards developed by the W3C
to make digital content accessible to people with disabilities, covering websites, applications, and
other digital materials. They are built on four principles (POUR): Perceivable, Operable,
Easier to navigate.
Note! Universal design is required by law! So it is very important that all public services follow the
guidelines and regulations given by the authorities. See more information below.
Web Content Accessibility Guidelines (WCAG) are international standards developed by the W3C
to make digital content accessible to people with disabilities, covering websites, applications, and
other digital materials. They are built on four principles (POUR): Perceivable, Operable,
Easier to navigate.
Note! Universal design is required by law! So it is very important that all public services follow the
guidelines and regulations given by the authorities. See more information below.
Web Content Accessibility Guidelines (WCAG) are international standards developed by the W3C
to make digital content accessible to people with disabilities, covering websites, applications, and
other digital materials. They are built on four principles (POUR): Perceivable, Operable,
Easier to navigate.
Note! Universal design is required by law! So it is very important that all public services follow the
guidelines and regulations given by the authorities. See more information below.
Web Content Accessibility Guidelines (WCAG) are international standards developed by the W3C
to make digital content accessible to people with disabilities, covering websites, applications, and
other digital materials. They are built on four principles (POUR): Perceivable, Operable,
Easier to navigate.
Note! Universal design is required by law! So it is very important that all public services follow the
guidelines and regulations given by the authorities. See more information below.
Web Content Accessibility Guidelines (WCAG) are international standards developed by the W3C
to make digital content accessible to people with disabilities, covering websites, applications, and
other digital materials. They are built on four principles (POUR): Perceivable, Operable,
Easier to navigate.
Note! Universal design is required by law! So it is very important that all public services follow the
guidelines and regulations given by the authorities. See more information below.
Web Content Accessibility Guidelines (WCAG) are international standards developed by the W3C
to make digital content accessible to people with disabilities, covering websites, applications, and
other digital materials. They are built on four principles (POUR): Perceivable, Operable,
Easier to navigate.
Note! Universal design is required by law! So it is very important that all public services follow the
guidelines and regulations given by the authorities. See more information below.
Web Content Accessibility Guidelines (WCAG) are international standards developed by the W3C
to make digital content accessible to people with disabilities, covering websites, applications, and
other digital materials. They are built on four principles (POUR): Perceivable, Operable,
Easier to navigate.
Note! Universal design is required by law! So it is very important that all public services follow the
guidelines and regulations given by the authorities. See more information below.
Web Content Accessibility Guidelines (WCAG) are international standards developed by the W3C
to make digital content accessible to people with disabilities, covering websites, applications, and
other digital materials. They are built on four principles (POUR): Perceivable, Operable,
Easier to navigate.
Note! Universal design is required by law! So it is very important that all public services follow the
guidelines and regulations given by the authorities. See more information below.
Web Content Accessibility Guidelines (WCAG) are international standards developed by the W3C
to make digital content accessible to people with disabilities, covering websites, applications, and
other digital materials. They are built on four principles (POUR): Perceivable, Operable,
Easier to navigate.
Note! Universal design is required by law! So it is very important that all public services follow the
guidelines and regulations given by the authorities. See more information below.
Web Content Accessibility Guidelines (WCAG) are international standards developed by the W3C
to make digital content accessible to people with disabilities, covering websites, applications, and
other digital materials. They are built on four principles (POUR): Perceivable, Operable,
Easier to navigate.
Note! Universal design is required by law! So it is very important that all public services follow the
guidelines and regulations given by the authorities. See more information below.
Web Content Accessibility Guidelines (WCAG) are international standards developed by the W3C
to make digital content accessible to people with disabilities, covering websites, applications, and
other digital materials. They are built on four principles (POUR): Perceivable, Operable,
Easier to navigate.
Note! Universal design is required by law! So it is very important that all public services follow the
guidelines and regulations given by the authorities. See more information below.
Web Content Accessibility Guidelines (WCAG) are international standards developed by the W3C
to make digital content accessible to people with disabilities, covering websites, applications, and
other digital materials. They are built on four principles (POUR): Perceivable, Operable,
Easier to navigate.
Note! Universal design is required by law! So it is very important that all public services follow the
guidelines and regulations given by the authorities. See more information below.
Web Content Accessibility Guidelines (WCAG) are international standards developed by the W3C
to make digital content accessible to people with disabilities, covering websites, applications, and
other digital materials. They are built on four principles (POUR): Perceivable, Operable,
Easier to navigate.
Note! Universal design is required by law! So it is very important that all public services follow the
guidelines and regulations given by the authorities. See more information below.
Web Content Accessibility Guidelines (WCAG) are international standards developed by the W3C
to make digital content accessible to people with disabilities, covering websites, applications, and
other digital materials. They are built on four principles (POUR): Perceivable, Operable,
Easier to navigate.
Note! Universal design is required by law! So it is very important that all public services follow the
guidelines and regulations given by the authorities. See more information below.
Web Content Accessibility Guidelines (WCAG) are international standards developed by the W3C
to make digital content accessible to people with disabilities, covering websites, applications, and
other digital materials. They are built on four principles (POUR): Perceivable, Operable,
Easier to navigate.
Note! Universal design is required by law! So it is very important that all public services follow the
guidelines and regulations given by the authorities. See more information below.
Web Content Accessibility Guidelines (WCAG) are international standards developed by the W3C
to make digital content accessible to people with disabilities, covering websites, applications, and
other digital materials. They are built on four principles (POUR): Perceivable, Operable,
Easier to navigate.
Note! Universal design is required by law! So it is very important that all public services follow the
guidelines and regulations given by the authorities. See more information below.
Web Content Accessibility Guidelines (WCAG) are international standards developed by the W3C
to make digital content accessible to people with disabilities, covering websites, applications, and
other digital materials. They are built on four principles (POUR): Perceivable, Operable,
Easier to navigate.
Note! Universal design is required by law! So it is very important that all public services follow the
guidelines and regulations given by the authorities. See more information below.
Web Content Accessibility Guidelines (WCAG) are international standards developed by the W3C
to make digital content accessible to people with disabilities, covering websites, applications, and
other digital materials. They are built on four principles (POUR): Perceivable, Operable,
Easier to navigate.
Note! Universal design is required by law! So it is very important that all public services follow the
guidelines and regulations given by the authorities. See more information below.
Web Content Accessibility Guidelines (WCAG) are international standards developed by the W3C
to make digital content accessible to people with disabilities, covering websites, applications, and
other digital materials. They are built on four principles (POUR): Perceivable, Operable,
Easier to navigate.
Note! Universal design is required by law! So it is very important that all public services follow the
guidelines and regulations given by the authorities. See more information below.
Web Content Accessibility Guidelines (WCAG) are international standards developed by the W3C
to make digital content accessible to people with disabilities, covering websites, applications, and
other digital materials. They are built on four principles (POUR): Perceivable, Operable,
Easier to navigate.
Note! Universal design is required by law! So it is very important that all public services follow the
guidelines and regulations given by the authorities. See more information below.
Web Content Accessibility Guidelines (WCAG) are international standards developed by the W3C
to make digital content accessible to people with disabilities, covering websites, applications, and
other digital materials. They are built on four principles (POUR): Perceivable, Operable,
Easier to navigate.
Note! Universal design is required by law! So it is very important that all public services follow the
guidelines and regulations given by the authorities. See more information below.
Web Content Accessibility Guidelines (WCAG) are international standards developed by the W3C
to make digital content accessible to people with disabilities, covering websites, applications, and
other digital materials. They are built on four principles (POUR): Perceivable, Operable,
Easier to navigate.
Note! Universal design is required by law! So it is very important that all public services follow the
guidelines and regulations given by the authorities. See more information below.
Web Content Accessibility Guidelines (WCAG) are international standards developed by the W3C
to make digital content accessible to people with disabilities, covering websites, applications, and
other digital materials. They are built on four principles (POUR): Perceivable, Operable,
Easier to navigate.
Note! Universal design is required by law! So it is very important that all public services follow the
guidelines and regulations given by the authorities. See more information below.
Web Content Accessibility Guidelines (WCAG) are international standards developed by the W3C
to make digital content accessible to people with disabilities, covering websites, applications, and
other digital materials. They are built on four principles (POUR): Perceivable, Operable,
Easier to navigate.
Note! Universal design is required by law! So it is very important that all public services follow the
guidelines and regulations given by the authorities. See more information below.
Web Content Accessibility Guidelines (WCAG) are international standards developed by the W3C
to make digital content accessible to people with disabilities, covering websites, applications, and
other digital materials. They are built on four principles (POUR): Perceivable, Operable,
Easier to navigate.
Note! Universal design is required by law! So it is very important that all public services follow the
guidelines and regulations given by the authorities. See more information below.
Web Content Accessibility Guidelines (WCAG) are international standards developed by the W3C
to make digital content accessible to people with disabilities, covering websites, applications, and
other digital materials. They are built on four principles (POUR): Perceivable, Operable,
Easier to navigate.
Note! Universal design is required by law! So it is very important that all public services follow the
guidelines and regulations given by the authorities. See more information below.
Web Content Accessibility Guidelines (WCAG) are international standards developed by the W3C
to make digital content accessible to people with disabilities, covering websites, applications, and
other digital materials. They are built on four principles (POUR): Perceivable, Operable,
Easier to navigate.
Note! Universal design is required by law! So it is very important that all public services follow the
guidelines and regulations given by the authorities. See more information below.
Web Content Accessibility Guidelines (WCAG) are international standards developed by the W3C
to make digital content accessible to people with disabilities, covering websites, applications, and
other digital materials. They are built on four principles (POUR): Perceivable, Operable,
Easier to navigate.
Note! Universal design is required by law! So it is very important that all public services follow the
guidelines and regulations given by the authorities. See more information below.
Web Content Accessibility Guidelines (WCAG) are international standards developed by the W3C
to make digital content accessible to people with disabilities, covering websites, applications, and
other digital materials. They are built on four principles (POUR): Perceivable, Operable,
Easier to navigate.
Note! Universal design is required by law! So it is very important that all public services follow the
guidelines and regulations given by the authorities. See more information below.
Web Content Accessibility Guidelines (WCAG) are international standards developed by the W3C
to make digital content accessible to people with disabilities, covering websites, applications, and
other digital materials. They are built on four principles (POUR): Perceivable, Operable,
Easier to navigate.
Note! Universal design is required by law! So it is very important that all public services follow the
guidelines and regulations given by the authorities. See more information below.
Web Content Accessibility Guidelines (WCAG) are international standards developed by the W3C
to make digital content accessible to people with disabilities, covering websites, applications, and
other digital materials. They are built on four principles (POUR): Perceivable, Operable,
Easier to navigate.
Note! Universal design is required by law! So it is very important that all public services follow the
guidelines and regulations given by the authorities. See more information below.
Web Content Accessibility Guidelines (WCAG) are international standards developed by the W3C
to make digital content accessible to people with disabilities, covering websites, applications, and
other digital materials. They are built on four principles (POUR): Perceivable, Operable,
Easier to navigate.
Note! Universal design is required by law! So it is very important that all public services follow the
guidelines and regulations given by the authorities. See more information below.
Web Content Accessibility Guidelines (WCAG) are international standards developed by the W3C
to make digital content accessible to people with disabilities, covering websites, applications, and
other digital materials. They are built on four principles (POUR): Perceivable, Operable,
Easier to navigate.
Note! Universal design is required by law! So it is very important that all public services follow the
guidelines and regulations given by the authorities. See more information below.
Web Content Accessibility Guidelines (WCAG) are international standards developed by the W3C
to make digital content accessible to people with disabilities, covering websites, applications, and
other digital materials. They are built on four principles (POUR): Perceivable, Operable,
Easier to navigate.
Note! Universal design is required by law! So it is very important that all public services follow the
guidelines and regulations given by the authorities. See more information below.
Web Content Accessibility Guidelines (WCAG) are international standards developed by the W3C
to make digital content accessible to people with disabilities, covering websites, applications, and
other digital materials. They are built on four principles (POUR): Perceivable, Operable,
Easier to navigate.
Note! Universal design is required by law! So it is very important that all public services follow the
guidelines and regulations given by the authorities. See more information below.
Web Content Accessibility Guidelines (WCAG) are international standards developed by the W3C
to make digital content accessible to people with disabilities, covering websites, applications, and
other digital materials. They are built on four principles (POUR): Perceivable, Operable,
Easier to navigate.
Note! Universal design is required by law! So it is very important that all public services follow the
guidelines and regulations given by the authorities. See more information below.
Web Content Accessibility Guidelines (WCAG) are international standards developed by the W3C
to make digital content accessible to people with disabilities, covering websites, applications, and
other digital materials. They are built on four principles (POUR): Perceivable, Operable,
Easier to navigate.
Note! Universal design is required by law! So it is very important that all public services follow the
guidelines and regulations given by the authorities. See more information below.
Web Content Accessibility Guidelines (WCAG) are international standards developed by the W3C
to make digital content accessible to people with disabilities, covering websites, applications, and
other digital materials. They are built on four principles (POUR): Perceivable, Operable,
Easier to navigate.
Note! Universal design is required by law! So it is very important that all public services follow the
guidelines and regulations given by the authorities. See more information below.
Web Content Accessibility Guidelines (WCAG) are international standards developed by the W3C
to make digital content accessible to people with disabilities, covering websites, applications, and
other digital materials. They are built on four principles (POUR): Perceivable, Operable,
Easier to navigate.
Note! Universal design is required by law! So it is very important that all public services follow the
guidelines and regulations given by the authorities. See more information below.
Web Content Accessibility Guidelines (WCAG) are international standards developed by the W3C
to make digital content accessible to people with disabilities, covering websites, applications, and
other digital materials. They are built on four principles (POUR): Perceivable, Operable,
Easier to navigate.
Note! Universal design is required by law! So it is very important that all public services follow the
guidelines and regulations given by the authorities. See more information below.
Web Content Accessibility Guidelines (WCAG) are international standards developed by the W3C
to make digital content accessible to people with disabilities, covering websites, applications, and
other digital materials. They are built on four principles (POUR): Perceivable, Operable,
Easier to navigate.
Note! Universal design is required by law! So it is very important that all public services follow the
guidelines and regulations given by the authorities. See more information below.
Web Content Accessibility Guidelines (WCAG) are international standards developed by the W3C
to make digital content accessible to people with disabilities, covering websites, applications, and
other digital materials. They are built on four principles (POUR): Perceivable, Operable,
Easier to navigate.
Note! Universal design is required by law! So it is very important that all public services follow the
guidelines and regulations given by the authorities. See more information below.
Web Content Accessibility Guidelines (WCAG) are international standards developed by the W3C
to make digital content accessible to people with disabilities, covering websites, applications, and
other digital materials. They are built on four principles (POUR): Perceivable, Operable,
Easier to navigate.
Note! Universal design is required by law! So it is very important that all public services follow the
guidelines and regulations given by the authorities. See more information below.
Web Content Accessibility Guidelines (WCAG) are international standards developed by the W3C
to make digital content accessible to people with disabilities, covering websites, applications, and
other digital materials. They are built on four principles (POUR): Perceivable, Operable,
Easier to navigate.
Note! Universal design is required by law! So it is very important that all public services follow the
guidelines and regulations given by the authorities. See more information below.
Web Content Accessibility Guidelines (WCAG) are international standards developed by the W3C
to make digital content accessible to people with disabilities, covering websites, applications, and
other digital materials. They are built on four principles (POUR): Perceivable, Operable,
Easier to navigate.
Note! Universal design is required by law! So it is very important that all public services follow the
guidelines and regulations given by the authorities. See more information below.
Web Content Accessibility Guidelines (WCAG) are international standards developed by the W3C
to make digital content accessible to people with disabilities, covering websites, applications, and
other digital materials. They are built on four principles (POUR): Perceivable, Operable,
Easier to navigate.
Note! Universal design is required by law! So it is very important that all public services follow the
guidelines and regulations given by the authorities. See more information below.
Web Content Accessibility Guidelines (WCAG) are international standards developed by the W3C
to make digital content accessible to people with disabilities, covering websites, applications, and
other digital materials. They are built on four principles (POUR): Perceivable, Operable,
Easier to navigate.
Note! Universal design is required by law! So it is very important that all public services follow the
guidelines and regulations given by the authorities. See more information below.
Web Content Accessibility Guidelines (WCAG) are international standards developed by the W3C
to make digital content accessible to people with disabilities, covering websites, applications, and
other digital materials. They are built on four principles (POUR): Perceivable, Operable,
Easier to navigate.
Note! Universal design is required by law! So it is very important that all public services follow the
guidelines and regulations given by the authorities. See more information below.
Web Content Accessibility Guidelines (WCAG) are international standards developed by the W3C
to make digital content accessible to people with disabilities, covering websites, applications, and
other digital materials. They are built on four principles (POUR): Perceivable, Operable,
Easier to navigate.
Note! Universal design is required by law! So it is very important that all public services follow the
guidelines and regulations given by the authorities. See more information below.
Web Content Accessibility Guidelines (WCAG) are international standards developed by the W3C
to make digital content accessible to people with disabilities, covering websites, applications, and
other digital materials. They are built on four principles (POUR): Perceivable, Operable,
Easier to navigate.
Note! Universal design is required by law! So it is very important that all public services follow the
guidelines and regulations given by the authorities. See more information below.
Web Content Accessibility Guidelines (WCAG) are international standards developed by the W3C
to make digital content accessible to people with disabilities, covering websites, applications, and
other digital materials. They are built on four principles (POUR): Perceivable, Operable,
Easier to navigate.
Note! Universal design is required by law! So it is very important that all public services follow the
guidelines and regulations given by the authorities. See more information below.
Web Content Accessibility Guidelines (WCAG) are international standards developed by the W3C
to make digital content accessible to people with disabilities, covering websites, applications, and
other digital materials. They are built on four principles (POUR): Perceivable, Operable,
Easier to navigate.
Note! Universal design is required by law! So it is very important that all public services follow the
guidelines and regulations given by the authorities. See more information below.
Web Content Accessibility Guidelines (WCAG) are international standards developed by the W3C
to make digital content accessible to people with disabilities, covering websites, applications, and
other digital materials. They are built on four principles (POUR): Perceivable, Operable,
Easier to navigate.
Note! Universal design is required by law! So it is very important that all public services follow the
guidelines and regulations given by the authorities. See more information below.
Web Content Accessibility Guidelines (WCAG) are international standards developed by the W3C
to make digital content accessible to people with disabilities, covering websites, applications, and
other digital materials. They are built on four principles (POUR): Perceivable, Operable,
Easier to navigate.
Note! Universal design is required by law! So it is very important that all public services follow the
guidelines and regulations given by the authorities. See more information below.
Web Content Accessibility Guidelines (WCAG) are international standards developed by the W3C
to make digital content accessible to people with disabilities, covering websites, applications, and
other digital materials. They are built on four principles (POUR): Perceivable, Operable,
Easier to navigate.
Note! Universal design is required by law! So it is very important that all public services follow the
guidelines and regulations given by the authorities. See more information below.
Web Content Accessibility Guidelines (WCAG) are international standards developed by the W3C
to make digital content accessible to people with disabilities, covering websites, applications, and
other digital materials. They are built on four principles (POUR): Perceivable, Operable,
Easier to navigate.
Note! Universal design is required by law! So it is very important that all public services follow the
guidelines and regulations given by the authorities. See more information below.
Web Content Accessibility Guidelines (WCAG) are international standards developed by the W3C
to make digital content accessible to people with disabilities, covering websites, applications, and
other digital materials. They are built on four principles (POUR): Perceivable, Operable,
Easier to navigate.
Note! Universal design is required by law! So it is very important that all public services follow the
guidelines and regulations given by the authorities. See more information below.
Web Content Accessibility Guidelines (WCAG) are international standards developed by the W3C
to make digital content accessible to people with disabilities, covering websites, applications, and
other digital materials. They are built on four principles (POUR): Perceivable, Operable,
Easier to navigate.
Note! Universal design is required by law! So it is very important that all public services follow the
guidelines and regulations given by the authorities. See more information below.
Web Content Accessibility Guidelines (WCAG) are international standards developed by the W3C
to make digital content accessible to people with disabilities, covering websites, applications, and
other digital materials. They are built on four principles (POUR): Perceivable, Operable,
Easier to navigate.
Note! Universal design is required by law! So it is very important that all public services follow the
guidelines and regulations given by the authorities. See more information below.
Web Content Accessibility Guidelines (WCAG) are international standards developed by the W3C
to make digital content accessible to people with disabilities, covering websites, applications, and
other digital materials. They are built on four principles (POUR): Perceivable, Operable,
Easier to navigate.
Note! Universal design is required by law! So it is very important that all public services follow the
guidelines and regulations given by the authorities. See more information below.
Web Content Accessibility Guidelines (WCAG) are international standards developed by the W3C
to make digital content accessible to people with disabilities, covering websites, applications, and
other digital materials. They are built on four principles (POUR): Perceivable, Operable,
Easier to navigate.
Note! Universal design is required by law! So it is very important that all public services follow the
guidelines and regulations given by the authorities. See more information below.
Web Content Accessibility Guidelines (WCAG) are international standards developed by the W3C
to make digital content accessible to people with disabilities, covering websites, applications, and
other digital materials. They are built on four principles (POUR): Perceivable, Operable,
Easier to navigate.
Note! Universal design is required by law! So it is very important that all public services follow the
guidelines and regulations given by the authorities. See more information below.
Web Content Accessibility Guidelines (WCAG) are international standards developed by the W3C
to make digital content accessible to people with disabilities, covering websites, applications, and
other digital materials. They are built on four principles (POUR): Perceivable, Operable,
Easier to navigate.
Note! Universal design is required by law! So it is very important that all public services follow the
guidelines and regulations given by the authorities. See more information below.
Web Content Accessibility Guidelines (WCAG) are international standards developed by the W3C
to make digital content accessible to people with disabilities, covering websites, applications, and
other digital materials. They are built on four principles (POUR): Perceivable, Operable,
The act of transforming the detailed design into a valid program in some programming language,
together with all its supporting activities, is referred to as implementation.
Most of the text in this chapter is from (F. Tsui, O. Karam, and B. Bernal, Essentials of Software
Engineering).
The implementation phase involves more than just writing code. Code also needs to be tested and
debugged as well as compiled and built into a complete executable product (Figure 12-1).
We usually need to use a Source Code Control (SCC) tool to keep track of different versions of the
code.
Figure 12-1: Software Implementation (F. Tsui, O. Karam, and B. Bernal, Essentials of Software
Engineering)
In many cases the detailed design is not done explicitly (in the Design Phase) but is left as part of
the implementation. Doing the detailed design as part of the implementation is usually faster, but
it may result in a less cohesive and less organized design, because the detailed design of each
module will usually be done by a different person.
In small projects, the detailed design is usually left as part of the implementation. In larger
projects, or when the programmers are inexperienced, the detailed design will be done by a
separate person.
• Readability: The code can be easily read and understood by other programmers.
190
191 12 Software Implementation
• Maintainability: The code can be easily modified and maintained. Note that this is related
to readability, but it is not the same; for example, this involves the use of e.g., Hungarian
notation, in which variable names include abbreviations for the type of variable.
• Performance: All other things being equal, the implementation should produce code that
performs as fast as possible.
• Traceability: All code elements should correspond to a design element. Code can be traced
back to design (and design to requirements).
• Correctness: The implementation should do what it is intended to do (as defined in the
requirements and detailed design).
• Completeness: All the system requirements are met.
• Comments
• Debugging
• Code Review
• Refactorization
It is strongly recommended that you be consistent in your notation to avoid confusion when
others are debugging or maintaining your code later. Especially in large software projects there
are usually some programming conventions. These conventions may seem to be of little value at
first, but they may become extremely helpful during the maintenance of the code.
• Naming: This refers to choosing names for classes, methods, variables, and other
programming entities.
• Separating words and capitalization: Many times, a name will be composed of more than
one word. In human languages, we use spaces to separate words, but most programming
languages will not allow us to do so. (“do_something”, “doSomething”, “DoSomething”)
• Indentation and spacing: Indentation refers to adding horizontal spaces before some lines
to better reflect the structure of the code. Spacing refers to both spaces and blank lines
inserted in the code.
• Function/method size: Many studies have shown that large functions or methods are
statistically more error-prone than smaller ones.
• File-naming issues: Having a standard for specifying how to name the files, which files to
generate for each module, and how to locate a given file from a module is very
advantageous.
• Specific programming constructs: Different programming languages support different
features; although they usually have good reasons to include certain features, there are
many that can be misused and need special precautions.
• Camel notation
• Pascal notation
• Hungarian notation
Camel Notation
Pascal Notation
Examples: “ShowCarColor”
Hungarian Notation
For controls on your user interface, we either use “Pascal notation” or “Hungarian notation”, but
stick to one of them!
Acronyms
12.2 Comments
Comments are very important and can significantly aid or hurt readability and maintainability.
• they may distract from the actual code and make the program more difficult to read and
[[Link]
6. External references
o Sometimes, when the code is complex, programmers are tempted to explain what
the code does in human language.
o In almost every case, if the code is so complex that it requires an explanation, then
it should be rewritten.
– We recommend using a consistent notation for these markers and eliminating all of
them before the code is in production.
– Sometimes programmers put markers in the code to keep track of changes and who
made them. We believe that information is better tracked with version
management software and recommend doing so.
– Comments that summarize what the code does, rather than just repeating it, are
very helpful in understanding the code, but they need to be kept up to date.
– It is important to ensure that these comments are summarizing the code, not just
repeating, or explaining it.
– In many cases, the code that is being summarized can be abstracted into its own
function, which, if named correctly, will eliminate the need for the comment.
– These are the most useful kinds of comments; they describe what the code is
supposed to do rather than what it does.
– These are the only kinds of comments that override the code. If the code does not
fulfill its intent, then the code is wrong.
5. External references
– These are comments that link the code to external entities, usually books or other
programs.
– Many times, these can be viewed as a kind of intent statement, as in, “This function
implements the XYZ algorithm, as explained in . . .,” but we believe such comments
require special attention.
– There may also be external prerequisites for the code, such as the existence of
initializing data in the database tables.
The trade-off that comments imply should be recognized. Comments can help clarify code and
relate it to other sources, but they also represent some level of duplication of the code.
7. A comment that does not correspond to the actual code that it accompanies can cause
errors that are very hard to find and correct.
8. Another danger comments present is that they can be used to justify bad coding practices.
Many times, programmers will be tempted to produce code that is too complicated or too
hard to maintain, and add comments to it, rather than rewrite it to good standards.
9. In fact, many experts recommend avoiding comments completely and produce what is
called “self-documented code” - that is, code that is so well written that it does not need
any documentation.
10. Comments have their place, especially in the form of describing the programmer’s intent.
12.3 Debugging
Debugging is about different techniques for finding and fixing bugs (errors that make your code
not work as expected) in your code.
1. It is difficult to write code without errors (bugs), but e.g., Visual Studio and other tools
have powerful Debugging functionality (breakpoints, etc.)
3. For more “advanced” bugs other methods are required (Unit Testing, Integration Testing,
Regression Testing, Acceptance Testing, etc.).
4. The focus here will be on these methods, while Debugging is something you learned in
Programming courses.
If you are working in a geographically distributed team, your coding conventions may differ and if
you have some strict coding guidelines, this code review process will make it possible to recheck
the standards in the code that you have written.
1. There are some possibilities of repetitive code block which can be caught during a code
review process. Refactoring can be done based on that.
2. Unused code blocks, performance metrics etc. are some additional check points of doing a
review.
3. If you are new to development, this code review process will help you to find out your
mistakes and help you to improve them. This is a perfect knowledge sharing mechanism.
4. Find out the defects and correct them at the beginning before it is committed to the source
control system.
[[Link]
Here are some topics that should be checked during the Code Review process:
• Readability: The code can be easily read and understood by other programmers.
• Maintainability: The code can be easily modified and maintained. Note that this is related
to readability, but it is not the same; for example, this involves the use of e.g., Hungarian
notation, in which variable names include abbreviations for the type of variable.
• Performance: All other things being equal, the implementation should produce code that
performs as fast as possible.
• Traceability: All code elements should correspond to a design element. Code can be traced
back to design (and design to requirements).
• Correctness: The implementation should do what it is intended to do (as defined in the
requirements and detailed design).
• Completeness: All the system requirements are met.
12.5 Refactoring
Even when using best practices and making a conscious effort to produce high-quality software, it
is highly unlikely that you will consistently produce programs that cannot be improved.
Refactoring is defined as
• the activity of improving your code style without altering its behavior
• a change made to the internal structure of software to make it easier to understand and
cheaper to modify without changing its observable behavior
Any of these symptoms (and more) will indicate that your code can be improved. You can use
refactoring to help you deal with these problems.
You should Refactoring your continuously and especially after Code Reviews.
• To ensure that the software meets the agreed requirements and design.
• The application works as expected.
• The application doesn’t contain serious bugs.
• Meets its intended use as per user expectations.
• The system must follow guidelines and regulations given by the authorities such as
universal design and GDPR.
Testing can be performed on different levels and by different people. Testing is a very important
part of software development. About 50% of the software development is about testing your
software.
Since modern software has become very complex, testing has become a very important part of
software development (see Figure 13-1).
199
200 13 Testing
Since testing of advanced software systems is quite complex, we need a systematic approach to
testing that involves different levels of testing (see Figure 13-2).
Since Software Development today involves different platforms, different devices, networks,
servers, and clients, etc., it has become very complex to test it. Today we have not only ordinary
Desktop Apps, but we also have Web Apps, Mobile Apps, Apps for TVs, etc.
The software we create is a layer between the user of the software and the hardware and the
operating system (Figure 13-3).
If we find bugs at the earlier stage, the cost to fix this will be less and thus it will reduce the overall
cost of the application (Figure 13-4).
Testing is intended to show that a program does what it is intended to do and to discover program
defects before it is put into use. When you test software, you execute a program using artificial
data. You check for the presence of errors NOT their absence.
Testing is part of a more general verification and validation process, which also includes static
validation techniques.
• To demonstrate to the developer and the customer that the software meets its
requirements.
o For custom software, this means that there should be at least one test for every
requirement in the requirements document.
o For generic software products, it means that there should be tests for all the system
features, plus combinations of these features, that will be incorporated in the
product release.
• To discover situations in which the behavior of the software is incorrect, undesirable or
does not conform to its specification.
o This means undesirable system behavior such as system crashes, unwanted
interactions with other systems, incorrect computations, and data corruption.
The primary purpose of testing is to detect software failures so that defects may be discovered
and corrected.
It is commonly believed that the earlier a defect is found the cheaper it is to fix it.
Basically, we do the following: Planning the Test, then we execute the Tests, finally we document
the Test results.
1. Development testing, where the system is tested during development to discover bugs
and defects. Development testing includes all testing activities that are carried out by the
team developing the system.
2. Release testing, where a separate testing team test a complete version of the system
before it is released to users.
3. User testing, where users or potential users of a system test the system in their own
environment.
Release testing: Release testing is the process of testing a release of a system that is intended for
use outside of the development team.
The primary goal of the release testing process is to convince the supplier of the system that it is
good enough for use. Release testing is usually a black box testing process where tests are only
derived from the system specification.
• Alpha testing - Users of the software work with the development team to test the software
at the developer’s site.
• Beta testing - A release of the software is made available to users to allow them to
experiment and to raise problems that they discover with the system developers.
• Acceptance testing - Customers test a system to decide whether it is ready to be accepted
by the system developers and deployed in the customer environment. Primarily for custom
systems.
Short overview of the different Test levels in Figure 13-6 (more details later):
• Unit Tests are written by the Developers as part of the Programming. Each part is
developed, and Unit tested separately (Every Class and Method in the code)
• Regression testing is testing the system to check that changes have not “broken”
previously working code. Both Manually & Automatically (Re-run Unit Tests)
• Integration testing means the system is put together and tested to make sure everything
works together.
• System or validation testing is Black-box Tests that validate the entire system against its
requirements, i.e., checking that a software system meets the specifications
• Acceptance Testing: The Customer needs to test and approve the software before he can
take it into use. We have 2 types: FAT (Factory Acceptance Testing) and SAT (Site
Acceptance Testing).
They found a bug (a moth) inside a computer in 1947 that made the program not behave as
expected. This was the “first” real bug.
• Alpha Release(s)
• Beta Release(s)
• RC - Release Candidate(s)
• RTM – Release To Manufacturing
Software testing should be performed during the whole Software Development Life Cycle (SDLC)
as shown in Figure 13-8.
Figure 13-8: Testing during the Software Development Life Cycle (SDLC)
Sooner or later, you have to say enough is enough and release version 1.0 (see Figure 13-9).
One must define within the development company, development team or in dialogue with the
customer what is defined as "good enough".
• Black-box Testing
• White-box Testing
You need no knowledge of how the system is created. Black-box testing can be done by a person
who only knows what the software is supposed to do. You may compare to driving a car – you
don’t need to know how it is built to test it.
In White-box Testing you need to have knowledge of how (Design and Implementation) the
system is built. White-box Testing is also called “Glass-box testing”.
• Unit Testing
• Regression Testing
• Integration Testing
• System Testing
• Acceptance Testing
• Unit Tests are written by the Developers as part of the Programming. Each part is
developed, and Unit tested separately (Every Class and Method in the code)
• Regression testing is testing the system to check that changes have not “broken”
previously working code. Both Manually & Automatically (Re-run Unit Tests)
• Integration testing means the system is put together and tested to make sure everything
works together.
• System testing is typically Black-box Tests that validate the entire system against its
requirements, i.e., Checking that a software system meets the specifications
• Acceptance Testing: The Customer needs to test and approve the software before he can
take it into use. FAT/SAT.
Unit Tests are written by the developers as part of the programming. They are automatically
executed by the system, e.g., Visual Studio and Azure DevOps have built-in functionality for Unit
Testing.
Sometimes the Unit Tests are written before you start programming, so-called Test-Driven
Development (TDD).
[[Link]
Since Unit testing is part of the development process, so-called Unit Tests Framework are usually
integrated with the IDE.
• Visual Studio Unit Test Framework. Unit Tests are built into Visual Studio (no additional
installation needed)
• JUnit (Java)
• NUnit (.NET)
• NUnit is an open-source unit testing framework for Microsoft .NET. It serves the
same purpose as JUnit does in the Java world
• PHPUnit (PHP)
• etc.
Visual Studio has built-in features for Unit Testing. In the Solution Explorer you just add a “Test
Project” as part of your code (see Figure 13-13).
In Figure 13-14 we see an example of how you create Unit Tests in Visual Studio and C#.
For Test classes, you need to use [TestClass] and for Test Methods you need to use [TestMethod].
You also need to add a reference to the code under test (select “Add Reference” in the Solution
Explorer and include “using <namespace>”) in your code.
The basic concept in Unit Testing is to compare the results when running the Methods with some
Input Data (“Actual”) with some Known Results (“Expected”).
Example:
Here you see some basic best practice rules regarding unit tests:
• Create rules that make sure you need to run Unit Tests (and they need to pass) before you
can Check-in your code in the Source Code Control System
1. Regression testing is testing the system to check that changes have not “broken”
previously working code.
2. In a manual testing process, regression testing is expensive but, with automated testing, it
is simple and straightforward. All tests are rerun every time a change is made to the
program.
3. Tests must run “successfully” before the change is committed.
Since system tests make sure the requirements are fulfilled, they must systematically validate each
requirement in the SRS (Software Requirements Specification).
FAT – Factory Acceptance Testing is usually performed in the Test Environment at the software
company.
SAT – Site Acceptance Testing is performed at the Customer in the actual Production Environment.
This is the final step to determine if the requirements of a specification or contract are met.
If the test is accepted, the software is officially handed over to the customer.
Note! Other terms and definitions are used as well in different literature.
The goal is to create inclusive solutions that provide equal opportunities for participation and
accessibility for all. That is, to create content and functionality that is accessible to everyone.
Here you will find the Norwegian Authority's guide for websites and apps:
• [Link]
You can use this guide to ensure that your systems meet the requirements of the WCAG standard
and the authorities in the EU and Norway. More about universal design and WCAG in chapter
“10.3 - Universal Design”.
In general, make sure universal design is part of your test planning and testing procedures.
How to make sure you are GDPR compliant? Here are some important aspects:
In general, make sure GDPR is part of your test planning and testing procedures.
Documents involved:
In addition to writing different documents in your test phase, you should have a Bug Tracking
System. With a Bug Tracking System, you can easily store all your bugs in a database system, set
priorities, use search to find bugs, use different statistics, etc. More about Bug Tracking Systems
below.
As well as setting out the testing schedule and procedures, the test plan defines the hardware and
software resources that are required. Test plans are not static documents but evolve during the
development process. Test plans change because of delays at other stages in the development
process. Test planning is particularly important in large software system development. For small
and medium-sized systems, a less formal test plan may be used, but there is still a need for a
formal document to support the planning of the testing process.
• How shall tests be documented? It is not enough simply to run tests; the results of the
tests must be systematically recorded. It must be possible to audit the testing process to
check that it has been carried out correctly
• System tests: This section, which may be separate from the test plan, defines the test cases
that should be applied to the system. These tests are derived from the system
requirements specification.
• Azure DevOps
• Jira
• Bugzilla
• ClearQuest
We will focus on Azure DevOps in this document. The bug tracking features in Azure DevOps will
be discussed in another chapter.
In Azure DevOps we can add requirements, user stories, tasks, new features, bugs, etc. as so-called
“Work Items” (Figure 13-17).
Install [Link] Core Web App in Virtual Test Environment using VirtualBox:
[Link]
• On the Developers PCs, we have all kind of Software installed that the Customer don’t
have, e.g., Development Tools like Visual Studio, etc.
• etc.
This setup consists of a physical setup which includes hardware, and logical setup that includes
Server Operating system, client operating system, database server, front end running
environment, browser (if web application), IIS (version on server side) or any other software
components required to run this software product.
This testing setup is to be built on both the ends – i.e., the server and client.
[[Link]
13.7.1 Virtualization
To create test environments easily, virtualization is the answer. There exists lots of different
virtualization solutions on the market today.
• VirtualBox
• VMware Workstation
• VMware vSphere
• Microsoft Hyper-V
• VMware Fusion (Mac)
Install [Link] Core Web App in Virtual Test Environment using VirtualBox:
[Link]
With such tools you can create so-called Virtual Machines (VM) where you can install and run all
kinds of software.
In this way, you can easily test your software without destroying your own computer and you can
easily test it in different operating systems, etc.
13.8.1 Bugs
A software bug is an error, flaw, failure, defect, or fault in a computer program or system that
produces an incorrect or unexpected result or causes it to behave in unintended ways.
They found a bug (a moth) inside a computer in 1947 that made the program not behave as
expected. This was the “first” real bug.
13.8.2 Debugging
Debugging is about different techniques for finding and fixing bugs (errors that make your code
not work as expected) in your code. It is difficult to write code without errors (bugs), but e.g.,
Visual Studio and other tools have powerful Debugging functionality (breakpoints, etc.). The
Compiler will also find syntax errors, etc.
For more “advanced” bugs other methods are required (Unit Testing, Integration Testing,
Regression Testing, Acceptance Testing, etc.). The focus here will be on these methods, while
Debugging is something you learned in Programming courses.
Example:
When we test this function, it depends on the input arguments which parts of the code will be
executed. Unit Tests should be written to cover all parts of the code.
Example: Microsoft uses Windows PCs and Visual Studio to create their software.
[[Link]
[[Link]
The advantages of Development-Driven Testing are many. Instead of tests driving the
development, it’s developers driving the tests, so you get just a few tests, and they almost always
all pass. The project team can deliver on time for a change, with zero bugs found in every
iteration. This makes management happy, and isn’t that really the ultimate barometer of
success? Also, velocity is increased dramatically when using this process.
Development-driven testing makes all sense in the world for those who practice Agile.
[[Link]
1. Testing shows the presence of Bugs: Software Testing reduces the probability of
undiscovered defects remaining in the software but even if no defects are found, it is not a
proof of correctness.
2. Exhaustive Testing is impossible: Testing everything is impossible! Instead, we need
optimal amount of testing based on the risk assessment of the application.
3. Early Testing: Testing should start as early as possible in the Software Development Life
Cycle (SDLC)
4. Defect Clustering: A small number of modules contain most of the defects/bugs detected.
5. The Pesticide Paradox: If the same tests are repeated, eventually the same test cases will
no longer find new bugs
6. Testing is Context dependent: This means that the way you test a e-commerce site will be
different from the way you test a commercial off the shelf application
7. Absence of Error is a Fallacy: Finding and fixing defects does not help if the system build is
unusable and does not fulfill the users’ needs and requirements
For more information about these 7 principles of testing, see the following:
13.11 Exercises
Make sure to discuss and reflect over the following:
6. What is “Dogfooding”?
Virtualization Deployment:
Install [Link] Core Web App in Virtual Test Environment using VirtualBox:
[Link]
Software deployment is all the activities that make a software system available for use.
Examples:
• Documentation
• Installation
230
231 14 Deployment and Installation
• etc.
Deployment strategies may vary depending of what kind of software we create, etc.
14.2 Releases
Now we are finished with all the development and testing and are ready to start the deployment
process.
Typically, we have the following “Internal” releases (see also Figure 14-1):
• Alpha Release(s)
• Beta Release(s)
• RC - Release Candidate(s)
• Start planning and development of Windows 8, 2008/2009 (the planning started before
Windows 7 was released)
14.3 Deployment
What is Deployment?
Software deployment is all the activities that make a software system available for use.
Examples:
• Documentation
• Installation
• etc.
Deployment strategies may vary depending of what kind of software we create, etc.
• Business Processes: Most large software systems require the customer to change the way
they work.
• Expertise: Does the customer have the IT expertise to install the software?
• Integration: Shall the software interact/integrate with other systems of the customer.
• Performance: The Customer may not have the same hardware as in the Development/Test
Environment
During the software lifecycle, we have 3 different environments for the software we are creating:
• Development Environment
• Test Environment
• Production Environment
[[Link]
• etc.
A production environment can be thought of as a real-time setting where programs are run, and
hardware setups are installed and relied on for organization or commercial daily operations.
This setup consists of a physical setup which includes hardware, and logical setup that includes
Server Operating system, client operating system, database server, front end running
environment, browser (if web application), IIS (version on server side) or any other software
components required to run this software product.
This testing setup is to be built on both the ends – i.e., the server and client.
Some documents are for internal use inside the software company or inside the development
team, while other documents are important for the stakeholders and customers that are going to
use the software (Figure 15-2).
237
238 15 Project Documentation
o Documentation stating what parts of an application will be tested, and the schedule
of when the testing is to be performed.
o Introduction, Test Plan, Test Design, Test Cases, Test procedures, Test Log, …,
Summary
Documentation produced during a software Project can be divided into 2 main categories:
• Process Documentation
– These documents record the process of development and maintenance, e.g., Plans,
Schedules (e.g., Gantt Charts), etc.
• Product Documentation
– These documents describe the product that is being developed. Can be divided into
2 subcategories:
• System Documentation
• User Documentation
• Information for Management to help them Plan, Budget, and Schedule the Software
Development Process (Process Documentation)
• Some of the documents should tell users how to use and administer the system (Product
Documentation)
Satisfying these requirements requires different types of documents from informal working
documents through professionally produced User Manuals
• Plans, estimates, and schedules. These are documents produced by managers which are
used to predict and to control the software process.
• Reports. These are documents which report how resources were used during the process
of development.
• Standards. These are documents which set out how the process is to be implemented.
These may be developed by organizational, national, or international standards.
• Working papers. These are often the principal technical communication documents in a
project. They record the ideas and thoughts of the engineers working on the project, are
interim versions of product documentation, describe implementation strategies and set
out problems which have been identified. They often, implicitly, record the rationale for
design decisions.
• E-mail messages, wikis, etc. These record the details of everyday communication between
managers and development engineers.
• Evolve in step with the product that it describes. Product documentation includes.
– User documentation, which tells users how to use the software product,
1. System documentation includes all the documents describing the system itself from the
requirements specification to the final acceptance test plan.
2. Documents describing the design, implementation and testing of a system are essential if
the program is to be understood and maintained.
In Figure 15-4 we see an overview of different product documentation and readers of such
documents.
For large systems that are developed to a customer’s specification, the system documentation
should include:
• For each program in the system, a description of the architecture of that program.
• For each component in the system, a description of its functionality and interfaces.
• Program source code listings, which should be commented on, where the comments
should explain complex sections of code and provide a rationale for the coding method
used.
• If meaningful names are used and a good, structured programming style is used,
much of the code should be self-documenting without the need for additional
comments.
• Validation documents describing how each program is validated and how the validation
information relates to the requirements.
• These may be required for the quality assurance processes in the organization.
• A System Maintenance Guide, which describes known problems with the system,
describes which parts of the system are hardware and software dependent and which
describes how evolution of the system has been considered in its design.
– This may be flying an aircraft, managing insurance policies, writing a book, etc. They
want to know how the software can help them. They are not interested in
computer or administration details.
• System administrators are responsible for managing the software used by end-users.
– This may involve acting as an operator if the system is a large mainframe system, as
a network manager is the system involves a network of workstations or as a
technical guru who fixes end-users software problems and who liaises between
users and the software supplier.
• User Manual
• Installation Guide
• Wiki
• etc.
[[Link]
User Manual:
A user guide or user's guide, also commonly known as a manual, is a technical communication
document intended to give assistance to people using a system. It is usually written by a technical
writer, although user guides are written by programmers, product or project managers, or other
technical staff, particularly in smaller companies.
• A Cover page
• A Preface, containing details of related documents and information on how to navigate the
user guide
• A guide on how to use at least the main functions of the system (Text + Screen Shots)
• A troubleshooting section detailing possible errors or problems that may occur, along with
how to fix them
If we have a generic product, it is especially important that the customers can install the software
you create.
For e.g., web products setup and distribution to the end user computers are not necessary, since
the software is installed on a Web Server and can be accessed through an ordinary web browser.
Installation is about:
• Executable files
• Check the system for missing dependencies or drivers etc. (e.g., Your software may
need .NET X.x, etc.)
• Software has bugs (Bug /Support incidents need to be tracked and followed up -> A good
tool is needed).
• New features are required.
• Circumstances change. Therefore, the software has changed. Who changes it?
• Development teams have broken up, maintenance may be done by different company!
• Repeated change leads to architectural degradation. Old systems may have been degraded
from the start!
• Software rots. Even with no code changes, the systems change, and eventually you can't
compile the software.
Examples:
• Repair
o Fixing defects/bugs
• Enhancement
o New Requirements
16.2 Categories
246
247 16 Software Maintenance
• Corrective maintenance
• Adaptive maintenance
• Perfective maintenance
• Preventive maintenance
In Figure 16-1 we see an overview of the different software maintenance categories [12].
Maintenance Description
Corrective Repair of defects relative to existing requirements. These defects are typically
discovered by customers as they start using your software.
Adaptive Adapt your software to changes in the operating environment, e.g., when a
new OS is released or a new version of the hardware. As software systems
evolve, it is very likely that changes will happen in the external environment
(OS, hardware, etc.) your software depends on.
Perfective New features based on new user requests. The software must continuously
adapt to new needs, or your software will become useless.
While Sommerville only divide into 3 different categories, see Figure 16-2.
249
17 Software Platforms
17.1 Introduction
We have lots of different platforms today, here we will discuss the most common platforms used
today. They are:
• Desktop: We have different Desktop platforms such as Windows, Mac OS X, Linux, etc. To
create applications for Windows we can use, e.g., Visual Studio and C#. To create
applications for Mac OS X we can use, e.g., Xcode and Objective-C/Swift. LabVIEW exists for
both Windows, Mac OS X and Linux.
• Mobile: Today we have 3 major Mobile platforms: iOS (iPhone and iPad), Android (running
on different Smartphones and Tablets) and Windows 8 (Tablets)/Windows 8 Phone (Smart
Phones).
• Web: Web applications run inside a web browser, such as e.g., Internet Explorer, Chrome,
Safari, Opera or Firefox. In the simplest form we can use HTML. For more dynamic web
pages we can use [Link], PHP, JavaScript, AJAX, etc.
Desktop
• Windows
• Mac OS
• Linux
Web
• [Link]
• PHP
• IIS
• Apache
• HTML
• JavaScript
• AJAX
Mobile Devices
250
251 17 Software Platforms
Server-side
• Databases
• Web Servers
Figure 17-1 shows some advantages and disadvantages with the different Platforms.
17.3 Desktop
On the desktop, we have 3 main platforms, namely Windows, Linux and macOS. In addition, we
have Chrome OS from Google as a 4. alternative.
We have lots of development tools for these platforms, see Figure 17-3. These will be discussed in
more details later.
17.3.1 Windows
Microsoft Windows is a series of graphical interface operating systems developed, marketed, and
sold by Microsoft.
There are a lot of Windows releases, some of the most important releases are:
• Windows 3
• Windows 95
• Windows NT
• Windows XP
• Windows 7
• Windows 8
• Windows 10
• Windows 11
17.3.2 macOS
The operating system macOS (Figure 17-6) is developed by Apple Inc. macOS runs only on Mac
Computers from Apple. It is a UNIX-based OS based on NeXT OS (Apple bought NeXT, and Steve
Jobs returned to Apple as CEO) because Apples classic OS from 1984 (the first Macintosh) and later
(Mac OS 9) was lacking behind – they needed a fresh start.
In macOS software can be deployed to Mac App Store for easy installation.
A popular development platform on macOS is the Xcode IDE and the Swift programming language.
The previous releases of macOS were named after big cats like Puma, Jaguar, Tiger Leopard, Lion,
etc.
17.3.3 Linux
Linux is a UNIX-like operation system. It is a Free/Open-Source software platform. Linus Torvalds is
the founder of the Linux kernel. Linux was originally developed as a free operating system for
Intel x86-based personal computers. It has since been ported to more computer hardware
platforms than any other operating system.
From Figure 17-7 we see that both Linux and Mac OS X have their origins from the UNIX platform.
• Fedora
• Red Hat Linux
• SUSE
• Mandriva
• Ubuntu
• etc.
17.4 Web
The Web has become increasingly important as a platform for developing software.
A Web Browser and HTML are the foundation for web pages. HyperText Markup Language (HTML)
is the main markup language for creating web pages and other information that can be displayed
in a web browser.
In Figure 17-9 we see the typical web architecture, including web browsers, HTML, CSS, JavaScript,
and a web server for hosting the web pages. Microsoft Edge is the new version of the previous
Internet Explorer.
In Figure 17-10 we see the triangle of web programming. You cannot create a modern web page
without knowing the basics of HTML, CSS and JavaScript. They are the basic building blocks when
creating web pages.
HyperText Markup Language (HTML) is the visual appearance of a Web Site. All Web Browser
understand HTML. The latest version is HTML 5. CSS (Cascading Style Sheets) define how to display
HTML elements. CSS is used to control the style and layout of multiple Web pages all at once.
JavaScript is the programming language of the Web. All modern HTML pages are using JavaScript.
It was first released in January 2002 with version 1.0 of the .NET Framework and is the successor
to Microsoft's Active Server Pages (ASP) technology. [Link] is built on the Common Language
Runtime (CLR), allowing programmers to write [Link] code using any supported .NET language,
such as C# and [Link].
[Link] web pages or webpages, known officially as Web Forms], are the main building block for
application development. Web forms are contained in files with an “.aspx” extension.
17.4.4 Django
Django is a Python web development framework. Django is a backend/server-side web framework
like [Link] Core. Django has support for databases like SQLite, MySQL/MariaDB and PostgreSQL.
Django includes an SQLite database, but for the others you need to install the database system
you want to use from their respective websites and in addition install a Python package/driver for
the specific database system. Django is free, open source and written in Python.
JavaScript:
JavaScript is THE scripting language of the Web. JavaScript is used in billions of Web pages to add
functionality, validate forms, communicate with the server, and much more.
To insert a JavaScript into an HTML page, use the <script> tag. The <script> and </script> tells
where the JavaScript starts and ends. The lines between the <script> and </script> contain the
JavaScript. Below we see an example.
<!DOCTYPE html>
<html>
<head>
<script>
function myFunction()
{
[Link]("demo").innerHTML="My First JavaScript Function";
}
</script>
</head>
<body>
<h1>My Web Page</h1>
<p id="demo">A Paragraph</p>
<button type="button" onclick="myFunction()">Try it</button>
</body>
</html>
PHP:
PHP is a server scripting language and is a powerful tool for making dynamic and interactive Web
pages. PHP is free to use (open source) and it is widely used today.
The PHP code is merged between the HTML code, and the PHP code is executed on the web server
and translated to pure HTML syntax. Below we see an example.
<!DOCTYPE html>
<html>
<body>
<?php
echo "Hello World!";
?>
</body>
</html>
Typically, you have a combination of PHP code, HTML and JavaScript on a web page.
PHP runs on different platforms (Windows, Linux, Unix, Mac OS X, etc.) and it is compatible with
almost all web servers used today (Apache, IIS, etc.). PHP has support for a wide range of
databases as well.
• Angular
• React
• Bootstrap
• jQuery
• Vue
One of the most popular front-end libraries today is React. React is a front-end JavaScript library
for building user interfaces in web applications. Developed by Facebook in 2011. React is now free
and open source. Note! React is a front-end Library and not a Framework. So, you typically need a
Framework like [Link] or [Link] Core.
• iPhone (iOS)/iPad OS
• Android
In general, we have 2 different kinds of apps for mobile devices (Figure 17-14), i.e., we can
distinguish between “native apps” and “web apps”. Web apps are created using HTML 5
technology and run inside a standard web browser, while native apps are created specifically for a
specific device or platform, such as an iOS device, Android device, etc. If you want to support more
than one platform, you need to develop and maintain one app for each of these platforms.
Different platforms need different programming methods and languages, but native apps provide
better performance and usability compared to web-based apps. Native apps can use APIs that is
provided by the vendor, they have access to built-in sensors, GPS, etc.
Web apps are not real applications; they are websites that, in many ways, look and feel like native
applications, but are not implemented as such. They are run by a browser and typically written in
HTML5. Users first access them as they would access any web page: they navigate to a special URL
and then have the option of “installing” them on their home screen by creating a bookmark to that
page.
Web apps became popular when HTML5 came around and people realized that they can obtain
native-like–functionality in the browser. Today, as more and more sites use HTML5, the distinction
between web apps and regular web pages has become blurry.
• Native apps live on the device and are accessed through icons on the device home screen.
• Native apps are installed through an application store (such as Google Play or Apple’s App
Store).
• They are developed specifically for one platform, and can take full advantage of all the
device features — they can use the camera, the GPS, the accelerometer, the compass,
contact list, etc.
• Native apps can use the device’s notification system and can work offline.
17.5.1 iOS
iOS (see Figure 17-15) is a mobile operating system developed and distributed by Apple Inc.
Created in 2007 together with the iPhone. It has been extended to support other Apple devices
such iPad (2010), etc.
iOS is derived from OS X, which is the operation system used on Apple Mac computers.
Apps can be downloaded from the App Store. To create Apps, you use the Xcode IDE and the
Objective-C or Swift programming language. You need the iOS SDK, which is included with Xcode.
Xcode is only available for Mac OS X, this means you need a Mac computer to create apps for the
iOS platform.
17.5.2 Android
Android (see Figure 17-16) is a Linux-based operating system designed for mobile devices such as
smartphones and tablets. Android is developed by Google.
The source code for Android is available under a free and open-source software license, which
means everybody may change it and create their own version of it. Vendors like Samsung, etc. do
this.
You use the Eclipse IDE and Java programming language to create apps for Android. Apps can be
downloaded from Google Play, Amazon AppStore for Android, etc. Google Play is the official App
Store for Android.
Notice that all Android versions are named after a dessert, a cake, or other sorts of candy. They
are also in alphabetical order:
• C (Cupcake)
• D (Donut)
• E (Eclair)
• F (Froyo)
• G (Gingerbread)
• H (Honeycomb)
• I (Ice Cream Sandwich)
• J (Jelly Bean)
• K (KitKat) – Android 4.4x
• L (Lollipop) – Android 5.x
• M (Marshmallow) – Android 6
• N (Nougat) – Android 7
• O (Oro) – Android 8
• P (Pie) – Android 9
Now they have run out of cakes and cookies, and the latest versions are just called Android 10 11,
12, 13, 14, 15, etc.
Here you can get detailed information about Android and download resources, development
tools, etc., including Android Studio, which is the tool you should use when developing Apps for
the Android platform.
Android Studio is the official IDE for developing Apps for Android, but you may use many other
IDEs as well. Especially, many use the Eclipse software. In that case, you need to download and
install the Android SDK Tools.
Android has become a widely used platform for many kinds of devices, including smartphones,
tablets, TV’s (Android TV), watches (Android Wear), and even cars (Android Auto).
For native app development we use Xcode and Swift for iOS, for Android we use Android Studio
and Kotlin. See Figure 17-18.
For cross platform app development, we have many different options. See Figure 17-19.
Examples:
1. iCloud
2. Microsoft Azure
5. etc.
For more information about Open Source, see the following: [Link]
source_software
In this chapter, we will discuss some of the most used (probably) programming languages today.
The first step in OOP is to identify all the objects you want to manipulate and how they relate to
each other, an exercise often known as data modeling. Once you've identified an object, you
generalize it as a class of objects and define the kind of data it contains and any logic sequences
that can manipulate it. Each distinct logic sequence is known as a method. A real instance of a
class is called an “object” or an “instance of a class”. The object or class instance is what you run in
the computer. Its methods provide computer instructions, and the class object characteristics
provide relevant data. You communicate with objects - and they communicate with each other.
Simula was the first object-oriented programming language. Simula was developed in the 1960s
by Kristen Nygaard from Norway.
Java, Python, C++, Visual Basic .NET, and C# are popular OOP languages today.
272
273 18 Software Frameworks & Languages
Since Simula-type objects are reimplemented in C++, Java and C# the influence of Simula is often
understated. The creator of C++ (1979), Bjarne Stroustrup (from Denmark), has acknowledged that
Simula was the greatest influence on him to develop C++.
Here is a list of some of the most popular programming languages in use today.
• C, C++
• C#
• Java/Kotlin
• Python
• JavaScript
• SQL
• Swift
• ..
Each of these programming languages has good and bad qualities and is preferable in different
situations. Some language is good to use when you need to communicate with a database, while
others are good to use when you want to develop web applications, etc. So, in most situations you
probably need to know and use more than one programming language.
Some programming languages are interpreted (“interpreted language”), while others are compiled
(“compiled language”). Compiled languages need to be compiled and transform to “machine
code” before you can run the program. Interpreted languages translate the code step-by-step at
run-time.
Compiled languages are known in general to be faster than interpreted languages. Compiled
languages can also easily be compiled into executable programs that can run on their own, while
interpreted languages normally need to be run inside the development environment.
C, C++ and C# are typically compiled languages, while Python, PHP, MATLAB, etc. are so-called
interpreted languages.
Below we will give a very short introduction to some of the most popular programming languages.
C is one of the most popular programming languages of all time and there are very few computer
architectures for which a C compiler does not exist.
C has greatly influenced many other popular programming languages, most notably C++, which
began as an extension to C. C is a procedural language, i.e., no object-oriented programming. C is a
compiled language.
It was developed by Bjarne Stroustrup in 1979 as an extension to C. C++ is one of the most popular
programming languages and its application domains include systems software (such as Microsoft
Windows), application software, device drivers, embedded software, high-performance server and
client applications, and entertainment software such as video games.
Several groups provide both free and proprietary C++ compiler software.
18.2.2 C#
C# is pronounced “see sharp”. C# is an object-oriented programming language and part of the
.NET family from Microsoft. C# is intended to be a simple, modern, general-purpose, object-
oriented programming language. Its development team is led by Anders Hejlsberg.
C# is very like C++ and Java. C# is developed by Microsoft and works only on the Windows
platform. C# is based on the .NET Framework (pronounced “dot net”).
.NET is a software framework that runs primarily on Microsoft Windows. The .NET Framework 1.0
and C# 1.0 were released in 2002 as part of Visual Studio .NET 2002.
Visual Studio is the Integrated Development Environment (IDE) you use when programming in C#
and the .NET platform.
Java is currently one of the most popular programming languages in use and is widely used from
application software to web applications. Java applications are typically compiled, and it runs on
any Java Virtual Machine (JVM) regardless of the computer architecture. Java is a general-purpose
object-oriented. It is intended to let application developers “write once, run anywhere”.
Java is still one of the most popular programming languages, but a newer language called Kotlin
seems to be taken over for Java. Kotlin has among others replaced Java in Android programming.
18.2.4 Swift
Swift is the new programming language created by Apple (now open source) and is now the
preferred language when creating Apps for the iOS platform and macOS.
18.2.5 Python
Python is an interpreted high-level programming language and object-oriented programming, and
structured programming are fully supported. The reference implementation of Python (CPython) is
free and open-source software and has a community-based development model. In addition,
Python has alternative implementations.
Python logo:
Python interpreters are available for many operating systems, and Python programs can be
packaged into stand-alone executable code for many systems using various tools. Guido van
Rossum is the creator of Python (1989).
Python example:
[Link]
18.2.6 JavaScript
JavaScript is an object-oriented scripting language that is dynamic, weakly typed. JavaScript is
primarily used in the form of client-side JavaScript, implemented as part of a web browser to
provide enhanced user interfaces and dynamic websites.
As in most scripting languages, types are associated with values, not with variables. For example, a
variable x could be bound to a number, then later rebound to a string. JavaScript uses syntax
influenced by that of C.
JavaScript copies many names and naming conventions from Java, but the two languages are
otherwise unrelated and have very different semantics. JavaScript was first shipped in 1995.
JavaScript very quickly gained widespread success as a client-side scripting language for web
pages.
18.2.7 SQL
SQL, often referred to as Structured Query Language, is a database computer language designed
for managing data in relational database management systems (RDBMS).
SQL has become the most widely used database language today. All popular Database Systems
support SQL, such as Oracle, SQL Server, etc. SQL was developed at IBM by Donald D. Chamberlin
and Raymond F. Boyce in the early 1970s.
SQL Support all kind of CRUD (Create, Read, Update, Delete) operations on database systems.
For more information about SQL, please see Chapter 25. You may also see the following resource:
[Link]
Camel notation: For variables and parameters/arguments we normally use “Camel notation”.
Examples:
string myCar;
int number;
string backColor;
→ In Camel casing the first letter of an identifier is lowercase, and the first letter of each
subsequent concatenated word is capitalized.
Pascal notation: For classes, methods and properties, we normally use “Pascal notation”.
Examples:
class Car
{
void ShowCarColor()
{
…
}
}
→ In Pascal notation the first letter in the identifier and the first letter of each subsequent
concatenated word are capitalized.
Examples:
[Link]
[Link]
Controls: For controls on your user interface, we either use “Pascal notation” or “Hungarian
notation”, but stick to one of them!
Examples:
“Pascal notation”:
LoginName
LoginPassword
“Hungarian notation”:
txtName
txtPassword
lblName
btnCancel
Where “txt” means that it is a Text Control, “lbl” a Label Control, “btn” a Button Control, etc.
Acronyms: The casing of acronyms depends on the length of the acronym. All acronyms are at
least two characters long. If an acronym is exactly two characters, it is considered a short acronym.
An acronym of three or more characters is a long acronym.
In general, you should not use abbreviations or acronyms. These make your names less readable.
Similarly, it is difficult to know when it is safe to assume that an acronym is widely recognized.
DBRate
A property named DBRate is an example of a short acronym (DB) used as the first word of a Pascal-
cased identifier.
ioChannel
A parameter named ioChannel is an example of a short acronym (IO) used as the first word of a
camel-cased identifier.
XmlWriter
A class named XmlWriter is an example of a long acronym used as the first word of a Pascal-cased
identifier.
htmlReader
A parameter named htmlReader is an example of a long acronym used as the first word of a
camel-cased identifier.
Exceptions are unforeseen errors that happen in your programs. Most of the time, you can, and
should, detect and handle program errors in your code. For example, validating user input,
checking for null objects, and verifying the values returned from methods are what you expect, are
all examples of good standard error handling that you should be doing all the time.
However, there are times when you don't know if an error will occur. For example, you can't
predict when you'll receive a file I/O error, run out of system memory, or encounter a database
error. These things are generally unlikely, but they could still happen, and you want to be able to
deal with them when they do occur. This is where exception handling comes in.
Exception Handling: When exceptions occur, they are said to be “thrown”. C# uses the keywords
try, catch, throw and finally. It works like this: A method will try to execute a piece of code. If the
code detects a problem, it will throw an error indication, which your code can catch, and no
matter what happens, it finally executes a special code block at the end.
MyMethod()
{
try
{
... //Do Something that can cause an Exception
}
catch
{
... //Handle Exceptions
}
finally
{
... //Clean Up
}
Example:
AOChannel myAOChannel;
try
{
myAOChannel = [Link](
aoChannel,
"myAOChannel",
0,
5,
[Link]
);
[Link](true, analogDataOut);
}
catch (Exception e)
{
string errorMessage;
errorMessage = [Link]();
finally
{
[Link]();
}
• .NET Framework
• [Link]
18.5.2 [Link]
[Link] is an open-source web framework, created by Microsoft, for building web apps and
services using the .NET Framework or the .NET Core. We have both [Link] and [Link] Core.
[Link] Core is the new approach built on .NET Core.
In this document, we will focus on client-server, 3-tier architecture and creating and using Web
Services and APIs.
In Figure 19-2 we see how a typical software application is interacting with the surrounding
environments, such as the users of the software and the underlying operating system (which is
also software) and hardware.
283
284 19 Software Architecture
Based on the fundamental interaction between the software and the environment we have
different kinds of software architecture.
• Client – Server
• n-tier architecture, 3-tier architecture
• Model-View-Controller (MVC)
• Web Services
• Interfaces
• APIs
• Service-oriented architecture (SOA)
• Microservices
In Figure 19-3 we see some examples of different network and software architecture typically
used in software development.
Make sure to document your system and your architecture in your documentation. You should
typically include several drawings and sketches of your architecture.
19.1 API
API - Application Programming Interface. An API is a specification of how some software
components should interact with each other. Typically, it is a library with functions, etc. you can
use in your code.
Examples:
• Windows API
• Java API
But you can also create your own API that you use internally in the team or an API that you expose
to others.
Creating APIs is good practice and makes it easy to reuse your code in other components or
applications. If all the developers in the team create the same code without thinking of reusing
code from others or creating code in such manners as it can’t be used by others, the software
project is doomed to fail.
Pros:
Cons:
• Requires abstraction.
• Requires modularization.
[[Link]
API driven design requires planning and programming skills. API driven design is costly initially, but
it pays in the long run. So, obviously, creating APIs is good software practice in most cases.
It is impossible to imagine how anyone would design a car today without taking advantage of
existing modules or vehicle subsystems – it is the same with software!
19.2 Client-Server
Client/server describes the relationship between two computer programs in which one program,
the client, makes a service request from another program, the server, which fulfills the request.
Although the client/server idea can be used by programs within a single computer, it is a more
important idea in a network. In a network, the client/server model provides a convenient way to
interconnect programs that are distributed efficiently across different locations.
Direct connection between the database and the clients that need the data is normally not
possible, due to security, compatibility issues, etc. (firewalls, hacker attacks, etc.). Direct
connection in a local network (behind the firewall) is normally OK – but not over the Internet (see
Figure 19-5).
The solution: Web Services. Web Services use standard web protocols like HTTP, etc. HTTP is
supported by all Web Browser, Servers, and many Programming Languages.
Today Web Services have been very popular. A Web service is a method of communication
between two devices over the World Wide Web and makes it easy to share data over a network or
the internet.
• A Web API
• A Standard defined by W3C
• Cross-platform and Platform-independent Communication
• Distributed Application Development
Web Services can be implemented and used in most Programming Languages (C#/[Link], PHP,
LabVIEW, Objective-C, Java, etc.)
Web services use standard web technology (web protocols) such as HTTP, REST, SOAP, XML,
WSDL, JSON, etc.
A web service is typically deployed on a web server, similar as ordinary web pages, see Figure
19-7.
o “Complex”
o All major web services or web APIs on the Internet today use REST
This document only describes the basic principles of web services and web APIs.
XML:
XML stands for eXtensible Markup Language. XML is designed to transport and store data.
<?xml version="1.0"?>
<note>
<to>Tove</to>
<from>Jani</from>
<heading>Reminder</heading>
<body>Don't forget me this weekend!</body>
</note>
Figure 19-11: Creating Web Services using Visual Studio and [Link]
3-tier architecture is a client-server architecture in which the functional process logic, data access,
computer data storage and user interface are developed and maintained as independent modules
on separate platforms. Three-tier architecture is a software design pattern and a well-established
software architecture. Its three tiers are the presentation tier, application tier and data tier.
• Presentation Layer
• Business/Application Layer
• Data Access Layer
These layers may be on the same computer, but normally they are distributed on different
computers.
Presentation Tier:
This is the topmost level of application. The presentation tier displays information related to such
services as browsing merchandise, purchasing, and shopping cart contents. It communicates with
other tiers by which it puts out the results to the browser/client tier and all other tiers in the
network.
In simple terms, it is a layer which users can directly access such as a web page, or an operating
systems GUI
Application tier:
(Other term used: Business logic, logic tier, data access tier, or middle tier) The application tier is
pulled out from the presentation tier and, as its own layer. It controls an application’s functionality
by performing detailed processing.
Data tier:
This tier consists of database servers. Here information is stored and retrieved. This tier keeps data
neutral and independent from application servers or business logic. Giving data its own tier also
improves scalability and performance.
Figure 19-13 shows a sketch of the typical logical layers or tiers in a 3-tier/layer architecture.
Figure 19-14 gives an overview of the 3-tier architecture and gives a short description of the
different layers.
• A Web Server
• An Application Server
• A Database
Web Services could be used for communication between the different layers.
298
20 Integrated Development
Environment (IDE)
What is an IDE? What is the difference between an IDE and a Programming Language?
Popular IDEs:
• Visual Studio
• Visual Studio Code
• Xcode
• Eclipse
• Android Studio
• Spyder
• etc.
299
300 20 Integrated Development Environment (IDE)
It can be used to develop console applications and graphical user interface applications along with
Windows Forms applications, web sites, web applications, and web APIs, etc. Visual Studio Code is
also an alternative to Visual Studio.
20.3 Xcode
Xcode (see Figure 20-2) is the IDE created by Apple for developing software for Mac OS X and the
iOS platform (iPhone, iPad).
It is the main programming language used by Apple for the OS X and iOS and their respective APIs,
Cocoa and Cocoa Touch. Apple released a new programming language, called Swift. Swift has now
replaced Objective-C as the official language for iOS and Mac programming.
• Enterprise Architect
• StarUML
• UMLet and UMLetino
• Diagram tools like Lucidchart, Miro, [Link], etc.
• etc.
Some of these tools are explained in more detail below. For basic Use Case diagrams, you can also
use, e.g., Microsoft PowerPoint.
21.2 StarUML
StarUML is cross-platform, which makes it possible to use it on Windows, Linux and macOS. You
can evaluate for free without time limit. Figure 21-1 show the StarUML software.
303
304 21 UML Software
Download: [Link]
21.3.1 UMLet
UMLet is a free, open-source UML tool with a simple user interface. UMLet includes a stand-alone
app for Windows, macOS, and Linux, or as Eclipse plugin. It is also available as web app called
UMLetino, and as extension to Visual Studio Code (Figure 21-2).
21.3.2 UMLetino
UMLetino is a free online UML tool for fast UML diagrams. UMLetino runs in your web browser so
you don’t need to install it (see Figure 21-3). UMLetino is based on UMLet.
In this chapter, we will give a short overview of some of the most popular source code control
(SCC) systems on the market today.
Here is a list with some of the most popular SCC systems on the market today:
• Azure DevOps
• CVS
• SVN (Subversion)
• Git
• GitHub
• Mercurial
• Bazaar
• LibreSource
• Monotone
• BitKeeper
The focus will be on Azure DevOps from Microsoft because this software is tightly connected to
Visual Studio. Azure DevOps uses Git as a SCC repository. In addition, it has lots of other features
in addition to SCC.
• Checkout, Check-in/Commit
• Branching, Merging
• File Locking (avoid concurrent access)
• Label/Tag
• Change/Change List
• Conflict
• Revision, Iteration
306
307 22 Source Code Control (SCC)
• Centralized/client–server architecture
• Distributed Version Control System (DVCS)
In Figure 22-1 we see an overview of which architecture the different SCC systems are using.
Centralized/Client–Server architecture:
A server stores the current version(s) of a project and its history, and clients connect to the server
to “check out” a complete copy of the project, work on this copy and then later “check in” their
changes.
With a distributed version control system, there isn’t one centralized code base to pull the code
from. Different branches hold different parts of the code. Git is a DVCS. Other version control
systems, such as SVN and CVS, use centralized version control, meaning that only one master copy
of the software is used. DVCS systems use a peer-to-peer approach.
In some cases, the SCC system is integrated in a so-called Application Lifecycle Management
system.
Application Lifecycle Management (ALM) systems are systems that take care of all aspects in
software development from planning, requirements, coding, testing, deployment, and
maintenance.
ALM is short for Application Lifecycle Management. An ALM tool typically facilitates and integrate
things like:
• Requirements Management
• Architecture
• Coding
• Testing
• Bug Tracking
• Release Management
• etc.
Azure DevOps is a product designed specifically for software engineering teams with developers,
testers, architects, project managers, etc.
Azure DevOps is a Source Code Control (SCC), Bug Tracking, Project Management, and Team
Collaboration platform. Azure DevOps is tightly integrated with Visual Studio as Microsoft is the
vendor of both Visual Studio and Azure DevOps.
22.3 SVN
Part 4: : Management and Development Tools
309 22 Source Code Control (SCC)
SVN or Subversion uses an Open-Source License. SVN was established in 2000. Subversion is
probably the version control system with the widest adoption today. Many different Subversion
clients are available (Tortoise SVN, Mac: Versions, Xcode (built-in support for SVN)).
22.4 CVS
CVS, or Concurrent Versions System, was established between 1986-1990. It is free of charge. CVS
uses a client–server architecture. It is widely supported in different IDEs (Eclipse, Xcode, etc.).
22.5 Git
Git has become very popular today. Git is a Distributed Version Control System (DVCS). It was
initially designed and developed by Linus Torvalds (Linux Guru) in 2005. Git is free of use.
22.6 Others
Above we have discussed the most popular SCC systems today. Here are some other systems as
well:
• Mercurial
• Bazaar
• LibreSource
• Monotone
• BitKeeper
• Azure DevOps
• GitHub
• Bitbucket
22.7.2 GitHub
GitHub uses (as the name says) a Git repository.
22.7.3 Bitbucket
With Bitbucket you can either use a Mercurial or a Git repository. It is free for 5 users.
They found a bug (a moth) inside a computer in 1947 that made the program not behave as
expected. This was the “first” real bug.
A “bug tracking system” or “defect tracking system” is a software application that is designed to
help keep track of reported software bugs in software development efforts.
Having a bug tracking system is extremely valuable in software development, and they are used
extensively by companies developing software products.
• Azure DevOps
• Jira
• Bugzilla
• ClearQuest
• GitHub
We will focus on Azure DevOps in this document. The bug tracking features in Azure DevOps will
be discussed in another chapter
311
24 Azure DevOps
Azure DevOps is an Application Lifecycle Management (ALM) system, i.e., the system takes care of
all aspects in software development from planning, requirements, coding, testing, deployment,
and maintenance.
Azure DevOps is a product designed specifically for software engineering teams with developers,
testers, architects, project managers, etc.
It is free for up to 5 users and it is a good choice for small teams. It is also handy for personal use
or students.
• Goto [Link]
• Create an Account (You need a Windows Live ID) and specify an URL for your account
• Create a New Team Project
• You are ready to start
o Connect to Azure DevOps from Visual Studio
o Or use the Web based interface provided (except for SCC)
• Assign Team members
• Add Areas, Iterations, etc.
• Add your Source Code
• Check-in/Check-out your code
Azure DevOps (see Figure 24-1) is a Source Code Control (SCC), Bug Tracking, Project
Management, and Team Collaboration platform. Azure DevOps is tightly integrated with Visual
Studio as Microsoft is the vendor of both Visual Studio and Azure DevOps.
312
313 24 Azure DevOps
Azure DevOps has plenty of competitors. The main benefit of Azure DevOps is that all the systems
mentioned above is integrated in one package, normally you would need lots of different software
for this.
Git is a Distributed Version Control System (DVCS) that uses a local repository to track and version
files. Changes are shared with other developers by pushing and pulling changes through a remote,
shared repository.
Figure 24-2: Start by creating a proper folder structure within your new Azure DevOps project
Figure 24-4 shows an example of different Iterations in Azure DevOps. We can create Iterations for
the different releases/milestones, such as Alpha, Beta1, 2, 3, RC, RTM.
In Azure DevOps you can create different Work Items, such as:
• Task
• Bug
• Feature
• Scenario
• Issue
• User Story
• Test Case
• etc.
These Work Items will be used at different level in your development cycle. When the Testers
reports bugs, they will, e.g., use the “Bug” Work Item, etc.
In Figure 24-6 we see how we can enter new Work Items using the Work Item Editor.
24.3.1 Queries
Queries are used to find existing Work Items. You may create different Queries to make it easy to
find the Work Items you need. Queries may be personal or visible for everybody in the project
You can use the Query Editor (Figure 24-7) to tailoring your own queries.
24.4 Taskboard
In Agile development and Scrum the Taskboard feature (Figure 24-8) is very useful.
We have the Product Backlog, and the Sprint Backlog features (see Figure 24-9).
You may also group the items in the Product Backlog into “Features”.
To make that happen, you need to configure the different sprints as “Iterations” in Azure DevOps
(Figure 24-13). You also need to right-click and select “Set as Teams Backlog iteration”.
Finally, you break the Sprint Backlog Items into Tasks. In the Sprint Backlog click the sign to
add Tasks to the specific Backlog Item (see Figure 24-14).
Then give the Task a name and estimate the work it will take (Remaining Work).
Figure 24-15: The Sprint Backlog divided into a hierarchical structure with Features, Backlog
Items and Tasks
24.5.3 Taskboard
Based on the Sprint Backlog Items and the Tasks created for each Sprint Backlog Items we can
start using the Taskboard features inside Azure DevOps.
The Taskboard is the heart of Daily Scrum Meetings. We can easily move tasks (drag and drop with
the mouse) on the task board to reflect their current state.
We can also easily Assign/reassign people to the different tasks in addition to updating the
“Remaining Work” field before the Daily Scrum Meeting, see Figure 24-17.
Figure 24-17: Using the Taskboard to update the Sprint Tasks before/under the Daily Scrum
Meeting
324
325 25 Databases
25.2 ER Diagram
ER Diagram (Entity-Relationship Diagram) is used for design and modeling of databases. It specifies
tables and relationship between them (Primary Keys and Foreign Keys), see Figure 25-3.
Figure 25-3: ER diagram with Primary Keys and Foreign Keys relationships
SQL is a database computer language designed for managing data in Relational Database
Management Systems (RDBMS). In SQL, we have 4 different types of queries:
• INSERT
• SELECT
• UPDATE
• DELETE
These are referred to as CRUD – Create (Insert), Read (Select), Update and Delete.
• Tables: Use upper case and singular form in table names – not plural, e.g., “STUDENT” (not
students)
• Columns: Use Pascal notation, e.g., “StudentId”
• Primary Keys:
– If the table name is “COURSE”, name the Primary Key column “CourseId”, etc.
– “Always” use Integer and Identity(1,1) for Primary Keys
• Specify Required Columns (NOT NULL) – i.e., which columns that need to have data or not
• Data Types: Standardize on these Data Types: int, float, varchar(x), datetime, bit
• Use English for table and column names
• Avoid abbreviations! (Use RoomNumber – not RoomNo, RoomNr, ...)
2. Nunit: NUnit is an open-source unit testing framework for Microsoft .NET. It serves the
same purpose as JUnit does in the Java world
4. etc.
328
329 26 Unit Testing
Visual Studio has integrated possibilities for Unit Testing. In Figure 26-1 we see the Unit Test
Project that is built into Visual Studio.
Note! Some of the more advanced test features in Visual Studio are only available in the
Enterprise edition.
using System;
using [Link];
namespace BankTest
{
[TestClass]
public class BankAccountTests
{
[TestMethod]
public void TestMethod1()
{
…
}
…
}
}
[TestMethod]
public void Debit_WithValidAmount_UpdatesBalance()
{
// arrange
double beginningBalance = 11.99;
double debitAmount = 4.55;
double expected = 7.44;
BankAccount account = new BankAccount("Bryan Walton", beginningBalance);
// act
[Link](debitAmount);
// assert
double actual = [Link];
[Link](expected, actual, 0.001, "Account incorrectly");
}
We get an overview of all the Tests in the Test Explorer (Figure 26-2):
When you build the test project, the tests appear in the Test Explorer. If the Test Explorer is not
visible, choose Test on the Visual Studio menu, choose Windows, and then choose Test Explorer.
As you run, write, and rerun your tests, Test Explorer displays the results in default groups of
Failed Tests, Passed Tests, Skipped Tests and Not Run Tests.
You can choose to run the tests manually or automatically, e.g., every time you build the code, etc.
If you use Azure DevOps together with Unit Testing in Visual Studio you can also choose to force
Unit Testing before you can check-in the code.
Example:
When we test this function, it depends on the input arguments which parts of the code will be
executed. Unit Tests should be written to cover all parts of the code.
In Visual Studio (Ultimate or Premium) these features are built-in (see Figure 26-3).
26.4 Exercises
Make sure to discuss and reflect over the following:
1. Explain the difference between unit testing and integration testing (or interface testing in
Sommerville)
2. Suggest “test cases” for the use case “Take out Money” from an ATM, i.e., give examples of
Unit Tests and Integration Tests
Virtualization Deployment:
Install [Link] Core Web App in Virtual Test Environment using VirtualBox:
[Link]
We have
• Generic Software:
o Many Customers
o The Customers install the Software itself
• Tailor-made:
o Typically, only one Customer
o The Developer Company typically installs the software (at least server-side
components)
o If many Desktop Clients: A Setup is required
Different Deployment/Installation preparations required depending on what type of Apps you are
Developing.
333
334 27 Deployment in Visual Studio
Desktop Apps
– Mac: You can deploy to Mac App Store, Windows 8: You can deploy to Windows
Store
Web Apps
• Easy, simple to deploy new versions, bugfixes, etc. (Customers don’t need to do
anything)
• But make sure your App supports all major Web Browsers (Internet Explorer,
Chrome, Firefox, Opera, Safari)
Mobile Apps
• Deployed to "App Stores" like Apple App Store, Google Play, Windows Store
(Windows 8)
• InstallShield Professional/Premium
– The WiX toolset builds Windows installation packages from XML source code.
– Used by e.g., Microsoft to create Setup packages for Office, SQL Server, Visual
Studio, etc. Apple also uses it.
• Inno Setup
• etc.
336
28 Cyber Security
28.1 Introduction
Cybersecurity is the practice of protecting systems, networks, and programs from digital attacks.
These cyberattacks are usually aimed at accessing, changing, or destroying sensitive information,
extorting money from users, or interrupting normal business processes.
With the good comes the bad. Since the Internet connected all devices together a new era of our
life was a fact.
The Internet is great for many things, but it is also a great place for criminals.
Figure 28-1 we see the evolution of computers and internet from the early begging and until
today.
You probably use hundreds of different Internet services. Is your personal data safe within these
companies?
Some terms:
337
338 28 Cyber Security
Data Security: Protect digital data (e.g., data in a database) from destructive forces and from the
unwanted actions of unauthorized users (e.g., hackers, etc.).
Cyber Security is the practice of protecting systems, networks, and programs from digital attacks.
Cybersecurity, or computer security, is a catchall term for any strategy for protecting one’s system
from malicious attacks aimed at stealing money, personal information, system resources
(cryptojacking, botnets), and a whole host of other bad things. The attack might occur on your
hardware or software, or through social engineering.
GDPR: General Data Protection Regulation. EU directive. Purpose: Protect privacy and the data
stored, i.e., protection of your digital life.
• Ransomware
• Malware
• Social engineering
• Phishing
• SQL Injection
• Etc.
28.2.1 Ransomware
Ransomware is a type of malicious software. It is designed to extort money by blocking access to
files or the computer system until the ransom is paid.
These include, e.g., email phishing and malvertising (malicious advertising). After it is distributed,
the ransomware encrypts selected files and notifies the victim of the required payment.
Paying the ransom does not guarantee that the files will be recovered, or the system will be
restored.
28.2.2 Malware
Malware is a type of software designed to gain unauthorized access or to cause damage to a
computer. Malware is short for “malicious software”.
Examples of common malware include viruses, worms, Trojan viruses, spyware, adware, and
ransomware.
28.2.4 Phishing
Phishing is the practice of sending fraudulent emails that resemble emails from reputable sources.
The aim is to steal sensitive data like credit card numbers and login information, or to install
malware on the victim’s machine.
You can help protect yourself through education (teach them not to click on links, etc. from
untrusted sources) or a technology solution that filters malicious emails.
• Deceptive phishing - Deceptive phishing is the most common type of phishing. In this case,
an attacker attempts to obtain confidential information from the victims. Attackers use the
information to steal money or to launch other attacks. A fake email from a bank asking you
to click a link and verify your account details is an example of deceptive phishing.
• Spear phishing - Spear phishing targets specific individuals instead of a wide group of
people. Attackers often research their victims on social media and other sites. That way,
they can customize their communications and appear more authentic. Spear phishing is
often the first step used to penetrate a company’s defenses and carry out a targeted
attack.
• Whaling - When attackers go after a “big fish” like a CEO, it’s called whaling.
• Pharming - pharming sends users to a fraudulent website that appears to be legitimate.
However, in this case, victims do not even have to click a malicious link to be taken to the
bogus site.
28.2.5 Spam
Spam is unsolicited and unwanted junk email sent out in bulk to an indiscriminate recipient list.
Typically, spam is sent for commercial purposes. It can be sent in massive volume by botnets and
networks of infected computers.
Often, spam email is sent for commercial purposes. While some people view it as unethical, many
businesses still use spam. The cost per email is incredibly low, and businesses can send out mass
quantities consistently. Spam email can also be a malicious attempt to gain access to your
computer.
Spam email can be difficult to stop, as it can be sent from botnets. Botnets are a network of
previously infected computers. As a result, the original spammer can be difficult to trace and stop.
Spam email can be dangerous. It can include malicious links that can infect your computer with
malware (see What is malware?). Do not click links in spam. Dangerous spam emails often sound
urgent, so you feel the need to act.
An attacker could carry out a SQL injection simply by submitting malicious code into a vulnerable
website search box.
• Passwords
• Firewall
• Antivirus and antimalware software
• Access control
• VPN
• Wi-Fi Network
• Education
28.3.1 Passwords
Make sure to use secure passwords, don’t use the same password for all your services and
software systems.
28.3.2 Firewall
A firewall is a network security device that monitors incoming and outgoing network traffic and
decides whether to allow or block specific traffic based on a defined set of security rules.
The WAF software (or hardware) is installed on the server that runs the web applications or web
sites.
A WAF is used for protection of a specific web application or set of web applications.
A WAF creates a shield between the web application and the Internet, which can avoid many
common attacks.
A WAF helps protect web applications by filtering and monitoring HTTP traffic between a web
application and the Internet. It typically protects web applications from attacks such as cross-site
forgery, cross-site-scripting (XSS), file inclusion, and SQL injection, among others.
Most professional hosting platforms offer WAP solutions, like Amazon Web Services.
In addition, there are many types of WAF software you can buy and use, e.g., Imunify360.
References:
[Link]
[Link]
[Link]
The Windows 10 operating system has built in antivirus software called "Windows Defender".
The name “Antivirus” software is a little old, because viruses are just one kind of malware in
today’s world of cyber threats. Though viruses still exist, there are other forms of malware that are
more common these days, as mentioned in an earlier chapter.
A good example of two-factor authentication is the withdrawing of money from an ATM; only the
correct combination of a bank card (something the user possesses) and a PIN (something the user
knows) allows the transaction to be carried out.
All the large providers of internet services, like Facebook, Google, Apple, etc. offers Two-factor
authentication, you just need to turn it on.
References:
[Link]
28.3.7 VPN
A virtual private network encrypts the connection from an endpoint to a network, often over the
Internet.
You have large Cloud platform providers like Amazon Web Services (AWS), Microsoft Azure, Oracle
Cloud and Google Cloud Platform.
These large providers have a high level of security, they continuously update the systems with new
security patches, etc.
28.3.11 Education
Learning more about cyber security threats and how you can protect yourself as a private person
or a company is crucial.
An attacker could carry out a SQL injection simply by submitting malicious code into a vulnerable
website search box.
SQL Injection - with Practical Examples using [Link] Core and C#:
[Link]
Web Site:
SQL query executed by the web site for getting the user information:
For example, if an application accepts and processes user-supplied data without any validation, an
attacker could submit a maliciously crafted username and password. Consider the following string
sent by an attacker:
username=admin%27%29+--+&password=+
The SQL query executed by the web site for getting the user information will be:
select * from Users where (username = 'admin') -- and password = ' ');
In this example, an attacker could successfully log in to the application using the admin account
without knowledge of the password to that account.
Note that the string of two dash characters (--) indicates to the database server that the remaining
characters in the SQL statement are a comment and should be ignored.
344
345 29 SQL Injection
A hacker might get access to user names and passwords in a database by simply inserting " OR
""=" into the user name or password text box:
The SQL query executed by the web site for getting the user information will be:
select * from Users where Name ="" or ""="" AND Pass ="" or ""=""
The SQL above is valid and will return all rows from the "Users" table, since OR ""="" is always
TRUE.
References:
[Link]
29.2 Resources
Here are some other resources regarding SQL injections:
The concepts will be exemplified using web technology and the [Link] Core web framework
from Microsoft.
[Link] is an open-source web framework, created by Microsoft, for building web apps and
services using the .NET Framework or the .NET Core. We have both [Link] and [Link] Core.
[Link] Core is the new approach built on .NET Core.
In this chapter we will see how we can create and use login functionality in your [Link] Core
Web Applications.
Typically, you need to create functionality for User Registration, Login, etc. Here you will see how
this can be done from scratch. If you do it from scratch, you will have full control of your code.
If you use something called “[Link] Core Identity” (which will be explained and demonstrated in
the next chapter) lots of “magic” happens behind the curtains. If something is not working, it may
be more complicated to figure out why.
[Link]
• Hashing
• Salting
• 2 Factor Authentication
• Etc.
346
347 30 User Identity and Login
Encryption is a two-way function. When you encrypt something, you are doing so with the
intention of decrypting it later.
To encrypt data, you use an algorithm. Many different encryption algorithms do exist
30.1.2 Hashing
Hashing is the practice of using an algorithm to map data of any size to a fixed length. Encryption is
a two-way function. Hashing is a one-way function.
While it is technically possible to reverse-hash something, the computing power required makes it
unfeasible. Hashing is one-way. See Figure 30-2.
Encryption is meant to protect data in transit, hashing is meant to verify that a file or piece of data
has not been altered—that it is authentic. In other words, it serves as a checksum. Every hash
value is unique.
By using something called “Rainbow Table” the hacker can get access to your hashed password,
see Figure 30-3.
Figure 30-3: Using Rainbow Table for Hacking your Hashed Password
If a hacker gets access to this Database, he can see that Mike and Peter have the same password,
but he does not know the actual password. If the Hacker has access to a so-called “Rainbow table”
(which is essentially a pre-computed database of hashes), he may also be able to find the
Password, as seen in Figure 30-3. If you have a complicated password, it is less likely that your
password is in such a Rainbow table.
30.1.4 Salting
Salting is a technique typically used for Password Hashing. It is a unique value that can be added to
the end of the password to create a different hash value. The additional value is referred to as a
“salt”. This is done to make it even more secure. Typically, the Hashing Algorithm uses a Random
salt. This prevents an attacker from seeing whether users have the same password. See Figure
30-4.
Assume Mike and Peter use the same Password, see Table 30-1. If a hacker gets access to this
database, he cannot see that Mike and Peter have the same password. This is because a random
Salt has made these 2 Hashed Passwords different!
Mike 4420d1918bbcf7
Bob 73fb51a0c9be7d
Peter 4520d1818cbcf7
Figure 30-5 shows a typical Flow when Creating User and Login.
Web:
[Link]
Videos:
31.2 Authentication
SQL Server has 2 different types of authentications:
• Windows Authentication
• SQL Server Authentication
Using “SQL Server Authentication” the Connection String looks like this:
Replace <SQL Server Name> with the name of your SQL Server, typically
"<YourComputerName>\SQLEXPRESS" if you are using SQL Server Express.
351
352 31 SQL Server Authentication
UID is a SQL Server user, here you can create your own SQL Server user inside SQL Server
Management Studio or use the built-in sa user (sa=System Administrator). During the setup of SQL
Server, you need to select "Mixed Mode" and enter the password for your sa user.
DATA SOURCE=HPPCWORK\\SQLEXPRESS;DATABASE=MEASUREMENTS;UID=sa;PWD=Password123;
You can also turn on “SQL Server Authentication” in SQL Server Management Studio (SSMS) after
installation of SQL Server. See Figure 31-1.
• In SQL Server Management Studio Object Explorer, right-click the server, and then click Properties.
• On the Security page, under Server authentication, select the new server authentication mode, and
then click OK.
• In the SQL Server Management Studio dialog box, click OK to acknowledge the requirement to
restart SQL Server.
• In Object Explorer, right-click your server, and then click Restart. If SQL Server Agent is running, it
must also be restarted. Or just restart your computer.
355
32 Glossary
Below we will give a short overview of some important topics in software development.
Term Description
Agile Manifesto The philosophy behind Agile methods is reflected in the Agile Manifesto.
Burn Down A burn down chart is a graphical representation of work left to do versus
Chart time. The outstanding work (or backlog) is often on the vertical axis, with
time along the horizontal. That is, it is a run chart of outstanding work. It
is useful for predicting when all the work will be completed.
It is often used in agile software development methodologies such as
Scrum. However, burn down charts can be applied to any project
containing measurable progress over time.
Code Review Code inspections to check if code is properly written, and useful to avoid
bugs in your code.
Daily Scrum In Scrum Development they have daily 15 minutes meetings within the
Software Team. The Meeting is usually a Stand-up meeting.
356
357 32 Glossary
Dog-fooding Computer software companies use its own product to demonstrate the
quality and capabilities of the product.
GUI Graphical User Interface. The part of the software the user sees and
interacts with.
HMI Human Machine Interface. Another term for Graphical User Interface.
Internal Server Typical errors from web pages. The Web server (running the Web Site)
Error encountered an unexpected condition that prevented it from fulfilling the
request by the client.
SCC Source Code Control or Version Control. A version control system keeps
track of all work and all changes in a set of files. Allow several developers
(potentially widely separated in space and time) to collaborate and share
code.
Azure DevOps Azure DevOps is a Source Code Control (SCC), Bug Tracking, Project
Management, and Team Collaboration platform from Microsoft
359
Hans-Petter Halvorsen
E-mail: [Link]@[Link]
Web: [Link]
[Link]
Software Development
A Practical Approach!
Hans-Petter Halvorsen
Copyright ©
ISBN: 978-82-691106-0-9