词条 | Modified condition/decision coverage |
释义 |
In software testing, the modified condition/decision coverage (MC/DC) is a code coverage criterion that requires all of the below during testing:[1]
Independence of a condition is shown by proving that only one condition changes at a time. MC/DC is used in avionics software development guidance DO-178B and DO-178C to ensure adequate testing of the most critical (Level A) software, which is defined as that software which could provide (or prevent failure of) continued safe flight and landing of an aircraft. It is also highly recommended for SIL 4 in part 3 Annex B of the basic safety publication[2] and ASIL D in part 6 of automotive standard ISO 26262.[3] Definitions
Criticism{{Dubious|date=January 2018}}Purely syntactic rearrangements of decisions (breaking them into several independently evaluated conditions using temporary variables, the values of which are then used in the decision) which do not change the semantics of a program can lower the difficulty of obtaining complete MC/DC coverage.[4] This is because MC/DC is driven by the program syntax. However, this kind of "cheating" can be done to simplify expressions, not simply to avoid MC/DC complexities. For example, assignment of the number of days in a month (excluding leap years) could be achieved by using either a switch statement or by using a table with an enumeration value as an index. The number of tests required based on the source code could be considerably different depending upon the coverage required, although semantically we would want to test both approaches with a minimum number of tests. See also
References1. ^{{cite journal | title = A Practical Tutorial on Modified Condition/ Decision Coverage |date=May 2001 | journal = NASA | last1 = Hayhurst | first1 = Kelly | last2 = Veerhusen | first2 = Dan | last3 = Chilenski | first3 = John | last4 = Rierson | first4 = Leanna | url = http://shemesh.larc.nasa.gov/fm/papers/Hayhurst-2001-tm210876-MCDC.pdf}} 2. ^IEC 61508-3:2010 3. ^ISO 26262-2011 Part 6 Table 12 4. ^{{cite journal | title = The Effect of Program and Model Structure on MC⁄DC Test Adequacy Coverage | last1 = Rajan | first1 = Ajitha | last2 = Heimdahl | first2 = Mats | last3 = Whalen | first3 = Michael | date = March 2003 | url = http://se.inf.ethz.ch/old/teaching/2009-S/0276/slides/fiva.pdf }} External links
1 : Software testing |
随便看 |
|
开放百科全书收录14589846条英语、德语、日语等多语种百科知识,基本涵盖了大多数领域的百科知识,是一部内容自由、开放的电子版国际百科全书。