Download as pptx, pdf, or txt
Download as pptx, pdf, or txt
You are on page 1of 15

Sir Syed University of Engineering & Technology, Karachi

CS-470
Software Quality Assurance & Testing
Week 7
Session 2

Batch - 2017 Department of Computer Science 1


Decision Tables …
• A decision table is an excellent tool to use in both testing and requirements
management.
• Essentially it is a structured exercise to formulate requirements when dealing with
complex business rules.
• Decision tables are used to model complicated logic.
• They can make it easy to see that all possible combinations of conditions have
been considered and when conditions are missed, it is easy to see this.
• In a decision table, conditions are usually expressed as true (T) or false (F).
• Each column in the table corresponds to a rule in the business logic that describes
the unique combination of circumstances that will result in the actions.
• It is normal to create at least one test case per column, which results in full
coverage of all business rules.

2
… Decision Tables …
• One advantage of using decision tables is that they make it possible to detect
combinations of conditions that would otherwise not have been found and
therefore not tested or developed.
• The requirements become much clearer and you often realize that some
requirements are illogical, something that is hard to see when the requirements
are only expressed in text.
• A disadvantage of the technique is that a decision table is not equivalent to
complete test cases containing step-by-step instructions of what to do in what
order.
• When this level of detail is required, the decision table has to be further detailed
into test cases.

3
… Decision Tables …
• Decision tables can be used in all situations where the outcome depends on the
combinations of different choices, and that is usually very often.
• In many systems there are tons of business rules where decision tables add a lot of
value.
• Decision tables should best be constructed during system design, since they
become useful to both developers and testers.
• The requirements specialist also becomes more confident that everything that is
important is actually documented.
• If there are no decision tables, testers can create them during test design to be
able to write better test cases.

4
… Decision Tables …

5
… Decision Tables …

6
… Decision Tables …

7
Decision Tables – Example 1
A customer requests a cash withdrawal. One of the business rules for the
ATM is that the ATM machine pays out the amount if the customer has
sufficient funds in their account or if the customer has the credit granted. 

8
Decision Tables – Example 2 ...
• A mutual insurance company has decided to float its shares on the stock
exchange and is offering its members rewards for their past custom at the
time of flotation. Anyone with a current policy will benefit provided it is
a ‘with-profits’ policy and they have held it since 2001. Those who meet
these criteria can opt for either a cash payment or an allocation of
shares in the new company; those who have held a qualifying policy for
less than the required time will be eligible for a cash payment but not for
shares. Generate decision table for the scenario.

9
... Decision Tables – Example 2

• Billy will be eligible for a cash payment but not for a share allocation.

10
The Psychology of testing …
• A variety of different people may be involved in the total testing effort,
and they may be drawn from a broad set of backgrounds.
• Some will be developers, some professional testers, and some will be
specialists, such as those with performance testing skills, whilst others
may be users drafted in to assist with acceptance testing.
• Who ever is involved in testing needs at least some understanding of the
skills and techniques of testing to make an effective contribution to the
overall testing effort.
• Testing can be more effective if it is not undertaken by the individual(s)
who wrote the code, for the simple reason that the creator of anything
(whether it is software or a work of art) has a special relationship with the
created object.
• The nature of that relationship is such that flaws in the created object are
rendered invisible to the creator. For that reason it is important that
someone other than the creator should test the object.
• Testers and developers think in different ways.

11
… The Psychology of testing …
• Developers can test their own code, but it requires a mindset change,
from that of a developer (to prove it works) to that of a tester (trying to
show that it does not work).
• If there are separate individuals involved, there are no potential conflicts
of interest.
• We therefore aim to have the software tested by someone who was not
involved in the creation of the software; this approach is called test
independence.
• If a defect is found in software, the software author may see this as
criticism.
• Testers need to use tact and diplomacy when raising defect reports.
• Defect reports need to be raised against the software, not against the
individual who made the mistake.
• The mistake may be in the code written, or in one of the documents upon
which the code is based (requirement documents or system specification).
• When we raise defects in a constructive way, bad feeling can be avoided.

12
… The Psychology of testing
• As testers and developers, one of our goals is better quality systems
delivered in a timely manner.
• Good communication between testers and the development teams is one
way that this goal can be reached.
• Testers and developers are not opposed, but working together, with the
joint target of better quality systems.
• Communication needs to be objective, and expressed in impersonal ways:
– The aim is to work together rather than be confrontational. Keep the
focus on delivering a quality product.
– Results should be presented in a non-personal way. The work-product
may be wrong, so say this in a non-personal way.
– Attempt to understand how others feel; it is possible to discuss
problems and still leave all parties feeling positive.

13
Code of ethics …
• Testers must adhere to a code of ethics: they are required to act in a
professional manner.
• Testers can have access to confidential and/or privileged information, and
they are to treat any information with care and attention, and act
responsibly to the owner(s) of this information, employers and the wider
public interest.
• Of course, anyone can test software, so the declaration of this code of
conduct applies to those who have achieved software testing certification!
The code of ethics applies to the following areas:
• Public – Certified software testers shall consider the wider public interest
in their actions.
• Client and employer – Certified software testers shall act in the best
interests of their client and employer (being consistent with the wider
public interest).
• Product – Certified software testers shall ensure that the deliverables they
provide (for any products and systems they work on) meet the highest
professional standards possible.
14
… Code of ethics
• Judgement – Certified software testers shall maintain integrity and
independence in their professional judgement.
• Management – Certified software test managers and leaders shall
subscribe to and promote and ethical approach to the management of
software testing.
• Profession – Certified software testers shall advance the integrity and
reputation of the profession consistent with the public interest.
• Colleagues – Certified software testers shall be fair to and supportive of
their colleagues, and promote cooperation with software developers.
• Self – Certified software testers shall participate in lifelong learning
regarding the practice of their profession, and shall promote an ethical
approach to the practice of the profession.

15

You might also like