Sommerville, 10th Edition)questions with verified answers
"Bad Smells" in Code that can be fixed with Refactoring Ans✓✓✓-- Duplicate
code: The same or very similar code may be included at different places in a
program. This can be removed and implemented as a single method or function
that is called as required.
- Long methods: If a method is too long, it should be redesigned as a number of
shorter methods.
- Switch (case) statements: These often involve duplication, where the switch
depends on the type of a value. The switch statements may be scattered around a
program. In object-oriented languages, you can often use polymorphism to
achieve the same thing.
- Data clumping: Data clumps occur when the same group of data items (fields in
classes, parameters in methods) re-occur in several places in a program. These
can often be replaced with an object that encapsulates all of the data.
- Speculative generality: This occurs when developers include generality in a
program in case it is required in the future. This can often simply be removed.
Acceptance Testing Ans✓✓✓-- Stage of user testing
- Customers test a system to decide whether or not it is ready to be accepted
from the system developers and deployed in the customer environment. Primarily
for custom systems.
,Advantages of Reengineering Ans✓✓✓-- Reduced risk: There is a high risk in new
software development. There may be development problems, staffing problems
and specification problems.
- Reduced cost: The cost of re-engineering is often significantly less than the costs
of developing new software.
Alpha Testing Ans✓✓✓-- Stage of user testing
- Users of the software work with the development team to test the software at
the developer's site.
Application Security Ans✓✓✓-Concerned with the security of individual
application systems or related groups of systems
Asset Ans✓✓✓-Something of value that has to be protected. May be the
software system itself or the data used by that system.
ex: patient record
Attack Ans✓✓✓-An exploitation of a system's vulnerability where goal is to cause
damage to a system asset or assets. May be external or insider.
ex: impersonation of an authorized user
Automated Testing Ans✓✓✓-- Recommended wherever possible for Unit Testing
- Making use of a test automation framework (such as JUnit) to write and run
program tests.
,- These frameworks provide generic test cases that you extend to create specific
test cases.
Availability Ans✓✓✓-When normal access to a system or its data is prevented.
ex: denial-of-service attack
Availability. Ans✓✓✓-Is the probability that it will be up and running and able to
deliver useful services to users at any given time.
Beta Testing Ans✓✓✓-- Stage of user 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.
Change Implementation Ans✓✓✓-Iteration of the development process where
the revisions to the system are designed, implemented and tested.
Change Prediciton Ans✓✓✓-- Predicting the number of changes requires and
understanding of the relationships between a system and its environment.
- Tightly coupled systems require changes whenever the environment is changed.
- Factors influencing this relationship are:
1) Number and complexity of system interfaces
, 2) Number of inherently volatile system requirements
3) The business processes where the system is used.
Complexity Metrics Ans✓✓✓-- Predictions of maintainability can be made by
assessing the complexity of system components.
- Studies have shown that most maintenance effort is spent on a relatively small
number of system components.
- Complexity depends on:
1) Complexity of control structures
2) Complexity of data structures;
3) Object, method (procedure) and module size.
Component Interface Testing Ans✓✓✓-- Stage of Development testing
- Software components are often composite components that are made up of
several interacting objects accessed through defined component interfaces.
- This type of testing should then focus on showing that the interface behaves
according to its specification.