1 / 6

JMUSE: Java 프로그램을 위한 돌연변이 기반 오류 추적 시스템

JMUSE: Java 프로그램을 위한 돌연변이 기반 오류 추적 시스템. 연광흠 , 김문주 Software Testing & Verification Group (SWTV) CS Dept., KAIST. Motivation: Finding Cause of SW Error is Difficult. Developer s hav e spen t a large amoun t o f time i n debugging.

Download Presentation

JMUSE: Java 프로그램을 위한 돌연변이 기반 오류 추적 시스템

An Image/Link below is provided (as is) to download presentation Download Policy: Content on the Website is provided to you AS IS for your information and personal use and may not be sold / licensed / shared on other websites without getting consent from its author. Content is provided to you AS IS for your information and personal use only. Download presentation by click this link. While downloading, if for some reason you are not able to download a presentation, the publisher may have deleted the file from their server. During download, if you can't get a presentation, the file might be deleted by the publisher.

E N D

Presentation Transcript


  1. JMUSE: Java 프로그램을 위한 돌연변이 기반 오류 추적 시스템 연광흠, 김문주 Software Testing & Verification Group (SWTV) CS Dept., KAIST

  2. Motivation: Finding Cause of SW Error is Difficult • Developershavespent alargeamountoftimeindebugging. • Oneof themost laborioustaskof debuggingactivities istolocatethe causeoffailures(i.e.,fault),whichiscalledfault localization. Testcase#1 : assertEquals(3, Example.setMax(3,1)) publicclass Example { publicintSetMax(intx,int y){ 1:intmax‐= x; // shouldbe ‘max=x;’ 2:if(max<y){3:max=y; 4:return max; 6: } 7:return max; 8:} Inspecting lineby line ==Laborioustask Testresult:pass Testresult:fail • Research Goal: To develop automated fault location techniques that assist developers effectively locate the cause of program failures (i.e., fault) JMUSE: Java 프로그램을 위한 돌연변이기반 오류 추적 시스템

  3. Key Idea of jMUSE • Utilize differences between testing result changes of mutating • correct statements • faulty statements Conjecture 2 1: stmt … k: stmt … n: stmt Mutate correct statement 1: stmt … f: stmt … n: stmt . . . Conjecture 1 1: stmt … k: stmt … n: stmt Mutate faulty statement What is the mutation? single syntactic code change Ex.: if(a) if(!a) a+ba–b JMUSE: Java 프로그램을 위한 돌연변이기반 오류 추적 시스템

  4. jMUSE Overall • Testing the program and analyzing the coverage • Generating and testing the mutants • Processing data and calculating suspiciousness using the MUSE metric Test suite T Exec. Test result1 m1 Step1 Execution Coverage analysis Mutation PITEST Source code of program P Stmts. Covered by tests Exec. Test resultn mn Byte code of Program P Test result Step2 Calc. Susp. Susp.& Rank Processing Step3 JMUSE: Java 프로그램을 위한 돌연변이기반 오류 추적 시스템

  5. 결과가 좋은 경우 • Faulty statement C14nHelper:137 • 41 failing test cases out of 94 test cases • (35 array index out of bounds exceptions and 6 null pointer exceptions) • jMUSE result: jMUSEgenerates a golden mutation ‘result[i+namespaces.length]’ 95: … 137: 141: public static final Object[]sortAttributes(…) { … result[i+ namespaces.length -1] //should be result[i + namespaces.length] = (Attr) nonNamespaces[i]; …} • The generated mutation은the faulty program이 정상적인 동작을 수행하도록 만든다. • Test cases를 the golden mutation에 대해 수행하면 정상적인 프로그램에서 실행했던 것과 같은 test case results를 얻게 된다. 따라서, 모든 failing test cases가 passingtest cases로 변하기 때문에 높은 suspiciousness를 얻게 된다. 2014-07-29 4/5 JMUSE: Java 프로그램을 위한 돌연변이기반 오류 추적 시스템

  6. 결과가 좋지 않은 경우 • Faulty statement Canonicalizer20010315Excl:1079 • 2 failing test cases out of 94 test cases (2 assert failed errors) • jMUSE result: jMUSEgenerates a mutation ‘return null’ Object[]handleAttributes(…) … { … return resultAsArray; //should be return sortedResultAsArray; } 563: … 1079: 1080: • The generated mutation은the faulty program이 더 많은 error를 발생하도록 만든다. • Test cases를 the generated mutation에 대해 수행하면 null pointer exception이발생하면서 기존 failing test cases를 포함한 더 많은 test cases들이 fail하게 된다. JMUSE: Java 프로그램을 위한 돌연변이기반 오류 추적 시스템

More Related