12.07.2015 Views

Software Quality Assurance - Software Engineering: Dependability

Software Quality Assurance - Software Engineering: Dependability

Software Quality Assurance - Software Engineering: Dependability

SHOW MORE
SHOW LESS

You also want an ePaper? Increase the reach of your titles

YUMPU automatically turns print PDFs into web optimized ePapers that Google loves.

Problem 4:Control Flow TestingGiven is a function ALL_POSITIVE implemented in Java, which examines all elements of aone-dimensional field of simple integers to see whether these are bigger than 0.boolean ALL_POSITIVE(int[] array) {boolean result;int i,len,tmp;len = array.length;i=0;result=true;while (i


) Statement CoveragePlease find a minimal necessary test case for achieving the statement coverage of theoperation ALL_POSITIVE.c) Branch CoveragePlease determine a minimal necessary test case for fulfilling the branch coverage of theoperation ALL_POSITIVE.3


Problem 5: Condition CoverageGiven is this section from a Java source code....if ((a0)||(c==0&&d!=0))...a) Simple Condition CoveragePlease find out the minimal set of necessary logical value combinations for fulfilling thesimple condition coverage for the complete evaluation of the partial decisions and for theincomplete evaluation of the partial decisions from left to right. Please determine thecorresponding test data for each logical value combination that would lead to the appropriatelogical values.Complete EvaluationA B C Da0 c==0 d!=0 TotalIncomplete Evaluation from left to rightA B C Da0 c==0 d!=0 Total4


) Multiple Condition CoveragePlease find out the minimal set of necessary logical value combinations for fulfilling themultiple condition coverage for the complete evaluation of the partial decisions and for theincomplete evaluation of the partial decisions from left to right. Please state how many testcases are needed as a minimum for the complete evaluation. Please determine thecorresponding test data for each logical value combination that would lead to the appropriatelogical values.Complete EvaluationA B C Da0 c==0 d!=0 TotalIncomplete Evaluation from left to rightA B C Da0 c==0 d!=0 Total5


c) Minimal Multiple Condition CoveragePlease find out the minimal set of necessary logical value combinations for fulfilling theminimal multiple condition coverage for the complete evaluation of the partial decisions andfor the incomplete evaluation of the partial decisions from left to right. Please determine thecorresponding test data for each logical value combination that would lead to the appropriatelogical values.Complete EvaluationA B C D E F Totala0 c==0 d!=0 A&&B C&&D E||FIncomplete Evaluation from left to rightA B C D E F Totala0 c==0 d!=0 A&&B C&&D E||F6


d) Modified Condition / Decision CoveragePlease find out the minimal set of necessary logical value combinations for fulfilling themodified condition decision coverage for the complete evaluation of the partial decisions andfor the incomplete evaluation of the partial decisions from left to right. Please determine thecorresponding test data for each logical value combination that would lead to the appropriatelogical values.Complete EvaluationA B C D E F Totala0 c==0 d!=0 A&&B C&&D E||FIncomplete Evaluation from left to rightA B C D E F Totala0 c==0 d!=0 A&&B C&&D E||F7

Hooray! Your file is uploaded and ready to be published.

Saved successfully!

Ooh no, something went wrong!