diff --git a/.besouro/20160929153653315/actions.txt b/.besouro/20160929153653315/actions.txt new file mode 100644 index 0000000..dc612a9 --- /dev/null +++ b/.besouro/20160929153653315/actions.txt @@ -0,0 +1,198 @@ +FileOpenedAction 1475152613817 TestRomanNumerals.java 329 2 2 0 +EditAction 1475152622422 TestRomanNumerals.java 335 2 2 0 +EditAction 1475152622955 RomanNumerals.java 126 1 1 0 +RefactoringAction 1475152646342 TestRomanNumerals.java RENAME test_FirstRule()=>void test_Cher() METHOD +RefactoringAction 1475152647853 TestRomanNumerals.java RENAME test_Cher()=>void test_CherFor() METHOD +RefactoringAction 1475152659379 TestRomanNumerals.java RENAME test_CherFor()=>void test_CherFore() METHOD +RefactoringAction 1475152660407 TestRomanNumerals.java RENAME test_CherFore()=>void test_CherFor3() METHOD +RefactoringAction 1475152661434 TestRomanNumerals.java RENAME test_CherFor3()=>void test_CherFor3I() METHOD +RefactoringAction 1475152764363 TestRomanNumerals.java ADD RomanNumerals romanNumerals FIELD +EditAction 1475152770354 TestRomanNumerals.java 409 2 3 1 +CompilationAction 1475152770533 TestRomanNumerals.java +RefactoringAction 1475152785945 RomanNumerals.java ADD boolean cherFor3I(String) METHOD +CompilationAction 1475152910860 TestRomanNumerals.java +EditAction 1475152910876 RomanNumerals.java 389 2 4 0 +UnitTestCaseAction 1475152918095 TestRomanNumerals.java FAIL +UnitTestSessionAction 1475152918096 TestRomanNumerals.java FAIL +UnitTestCaseAction 1475152939535 TestRomanNumerals.java OK +UnitTestSessionAction 1475152939536 Rerun TestRomanNumerals.test_CherFor3I OK +EditAction 1475152954181 TestRomanNumerals.java 423 2 3 1 +UnitTestCaseAction 1475152954939 TestRomanNumerals.java FAIL +UnitTestSessionAction 1475152954939 TestRomanNumerals.java FAIL +EditAction 1475152967856 TestRomanNumerals.java 416 2 3 1 +RefactoringAction 1475152971810 TestRomanNumerals.java ADD void test_CherFor3I()/2 METHOD +RefactoringAction 1475152976846 TestRomanNumerals.java RENAME test_CherFor3I()/2=>void test_CherFor3() METHOD +RefactoringAction 1475152977894 TestRomanNumerals.java RENAME test_CherFor3()=>void test_CherFor3C() METHOD +RefactoringAction 1475152979943 TestRomanNumerals.java RENAME test_CherFor3C()=>void test_CherFor3X() METHOD +RefactoringAction 1475152992744 RomanNumerals.java ADD boolean cherFor3X(String) METHOD +EditAction 1475153008204 RomanNumerals.java 642 3 7 0 +EditAction 1475153008392 TestRomanNumerals.java 616 3 5 2 +UnitTestCaseAction 1475153009292 TestRomanNumerals.java FAIL +UnitTestSessionAction 1475153009292 TestRomanNumerals.java FAIL +RefactoringAction 1475153015583 TestRomanNumerals.java ADD void test_CherFor3X()/2 METHOD +RefactoringAction 1475153020107 TestRomanNumerals.java RENAME test_CherFor3X()/2=>void test_CherFor3C() METHOD +RefactoringAction 1475153026646 RomanNumerals.java ADD boolean cherFor3C(String) METHOD +EditAction 1475153041684 RomanNumerals.java 921 4 10 0 +EditAction 1475153041819 TestRomanNumerals.java 819 4 7 3 +UnitTestCaseAction 1475153042641 TestRomanNumerals.java FAIL +UnitTestSessionAction 1475153042642 TestRomanNumerals.java FAIL +RefactoringAction 1475153052280 TestRomanNumerals.java ADD void test_CherFor3C()/2 METHOD +RefactoringAction 1475153055319 TestRomanNumerals.java RENAME test_CherFor3C()/2=>void test_CherFor3M() METHOD +RefactoringAction 1475153062594 RomanNumerals.java ADD boolean cherFor3M(String) METHOD +EditAction 1475153074670 RomanNumerals.java 1175 5 13 0 +EditAction 1475153074829 TestRomanNumerals.java 1020 5 9 4 +UnitTestCaseAction 1475153075541 TestRomanNumerals.java FAIL +UnitTestSessionAction 1475153075542 TestRomanNumerals.java FAIL +RefactoringAction 1475153175046 TestRomanNumerals.java ADD void test_CherFor3M()/2 METHOD +RefactoringAction 1475153203606 TestRomanNumerals.java RENAME test_CherFor3M()/2=>void test_CherForNo() METHOD +RefactoringAction 1475153205127 TestRomanNumerals.java RENAME test_CherForNo()=>void test_CherForNoV() METHOD +EditAction 1475153210562 TestRomanNumerals.java 1127 6 9 4 +RefactoringAction 1475153266779 TestRomanNumerals.java ADD void test_checkFor3I() METHOD +RefactoringAction 1475153266780 TestRomanNumerals.java ADD void test_checkFor3X() METHOD +RefactoringAction 1475153266782 TestRomanNumerals.java ADD void test_checkFor3C() METHOD +RefactoringAction 1475153266785 TestRomanNumerals.java ADD void test_checkFor3M() METHOD +RefactoringAction 1475153266795 TestRomanNumerals.java ADD void test_checkForNoV() METHOD +RefactoringAction 1475153278295 RomanNumerals.java ADD boolean checkFor3I(String) METHOD +RefactoringAction 1475153278296 RomanNumerals.java ADD boolean checkFor3X(String) METHOD +RefactoringAction 1475153278297 RomanNumerals.java ADD boolean checkFor3C(String) METHOD +RefactoringAction 1475153278297 RomanNumerals.java ADD boolean checkFor3M(String) METHOD +EditAction 1475153280571 TestRomanNumerals.java 1206 6 11 5 +CompilationAction 1475153280845 TestRomanNumerals.java +CompilationAction 1475153280845 TestRomanNumerals.java +CompilationAction 1475153280845 TestRomanNumerals.java +CompilationAction 1475153280845 TestRomanNumerals.java +CompilationAction 1475153280845 TestRomanNumerals.java +CompilationAction 1475153281030 TestRomanNumerals.java +RefactoringAction 1475153296142 RomanNumerals.java ADD boolean checkForNorepeatV(String) METHOD +CompilationAction 1475153411415 TestRomanNumerals.java +UnitTestCaseAction 1475153412029 TestRomanNumerals.java FAIL +UnitTestSessionAction 1475153412029 TestRomanNumerals.java FAIL +RefactoringAction 1475153424069 TestRomanNumerals.java ADD void test_checkForNoV()/2 METHOD +RefactoringAction 1475153427599 TestRomanNumerals.java RENAME test_checkForNoV()/2=>void test_checkForNoL() METHOD +RefactoringAction 1475153436569 RomanNumerals.java ADD boolean checkForNorepeatL(String) METHOD +EditAction 1475153459314 RomanNumerals.java 1881 7 21 0 +EditAction 1475153459462 TestRomanNumerals.java 1392 7 13 6 +UnitTestCaseAction 1475153460322 TestRomanNumerals.java FAIL +UnitTestSessionAction 1475153460323 TestRomanNumerals.java FAIL +RefactoringAction 1475153468674 TestRomanNumerals.java ADD void test_checkForNoL()/2 METHOD +RefactoringAction 1475153470692 TestRomanNumerals.java RENAME test_checkForNoL()/2=>void test_checkForNo() METHOD +RefactoringAction 1475153471716 TestRomanNumerals.java RENAME test_checkForNo()=>void test_checkForNoD() METHOD +RefactoringAction 1475153478480 RomanNumerals.java ADD boolean checkForNorepeatD(String) METHOD +EditAction 1475153490459 RomanNumerals.java 2176 8 24 0 +EditAction 1475153490618 TestRomanNumerals.java 1573 8 15 7 +UnitTestCaseAction 1475153491557 TestRomanNumerals.java FAIL +UnitTestSessionAction 1475153491558 TestRomanNumerals.java FAIL +RefactoringAction 1475153530962 TestRomanNumerals.java ADD void test FIELD +RefactoringAction 1475153532482 TestRomanNumerals.java RENAME test=>void test_ FIELD +RefactoringAction 1475153536504 TestRomanNumerals.java RENAME test_=>void test_() METHOD +RefactoringAction 1475153615121 TestRomanNumerals.java RENAME test_()=>void test_First() METHOD +RefactoringAction 1475153616148 TestRomanNumerals.java RENAME test_First()=>void test_FirstI() METHOD +RefactoringAction 1475153638818 RomanNumerals.java ADD boolean checkFirstI(String) METHOD +RefactoringAction 1475154830909 TestRomanNumerals.java RENAME test_FirstI()=>void test_che() METHOD +RefactoringAction 1475154831978 TestRomanNumerals.java RENAME test_che()=>void test_check() METHOD +RefactoringAction 1475154835504 TestRomanNumerals.java RENAME test_check()=>void test_che() METHOD +RefactoringAction 1475154840030 TestRomanNumerals.java RENAME test_che()=>void test_check() METHOD +RefactoringAction 1475154843054 TestRomanNumerals.java RENAME test_check()=>void test_checkIf() METHOD +RefactoringAction 1475154846583 TestRomanNumerals.java RENAME test_checkIf()=>void test_checkIfIVis() METHOD +RefactoringAction 1475154848107 TestRomanNumerals.java RENAME test_checkIfIVis()=>void test_checkIfIVis$() METHOD +RefactoringAction 1475154849624 TestRomanNumerals.java RENAME test_checkIfIVis$()=>void test_checkIfIVis4() METHOD +RefactoringAction 1475154898952 RomanNumerals.java RENAME checkFirstI(String)=>boolean checkIfIVis4(String) METHOD +RefactoringAction 1475155051379 RomanNumerals.java RENAME checkIfIVis4(String)=>int wahtIVis4(String) METHOD +RefactoringAction 1475155052406 RomanNumerals.java RENAME wahtIVis4(String)=>int wahtIIVis4(String) METHOD +RefactoringAction 1475155053932 RomanNumerals.java RENAME wahtIIVis4(String)=>int wahtIsIVis4(String) METHOD +EditAction 1475155100008 TestRomanNumerals.java 1853 9 15 7 +CompilationAction 1475155100365 TestRomanNumerals.java +CompilationAction 1475155100366 TestRomanNumerals.java +UnitTestCaseAction 1475155102330 TestRomanNumerals.java FAIL +UnitTestSessionAction 1475155102331 TestRomanNumerals.java FAIL +RefactoringAction 1475155121960 RomanNumerals.java ADD Object checkIfIVis4(String) METHOD +RefactoringAction 1475155134198 RomanNumerals.java REMOVE checkIfIVis4(String) METHOD +CompilationAction 1475155138095 TestRomanNumerals.java +CompilationAction 1475155138096 TestRomanNumerals.java +UnitTestCaseAction 1475155138741 TestRomanNumerals.java FAIL +UnitTestSessionAction 1475155138742 TestRomanNumerals.java FAIL +RefactoringAction 1475155146594 TestRomanNumerals.java ADD void test_checkIfIVis4()/2 METHOD +RefactoringAction 1475155152619 TestRomanNumerals.java RENAME test_checkIfIVis4()/2=>void test_checkIfIVis9() METHOD +RefactoringAction 1475155185151 TestRomanNumerals.java REMOVE test_checkIfIVis9() METHOD +RefactoringAction 1475155211683 TestRomanNumerals.java ADD void test_checkIfIVis4()/2 METHOD +RefactoringAction 1475155222236 TestRomanNumerals.java RENAME test_checkIfIVis4()/2=>void test_() METHOD +RefactoringAction 1475155286106 TestRomanNumerals.java REMOVE test_() METHOD +RefactoringAction 1475155290188 TestRomanNumerals.java ADD void test_checkIfIVis4()/2 METHOD +RefactoringAction 1475155293215 TestRomanNumerals.java RENAME test_checkIfIVis4()/2=>void test_checkIfIVis9() METHOD +RefactoringAction 1475155304302 TestRomanNumerals.java ADD void test_checkIfIVis9()/2 METHOD +RefactoringAction 1475155307882 TestRomanNumerals.java RENAME test_checkIfIVis9()/2=>void test_checkIfIVis() METHOD +RefactoringAction 1475155312926 TestRomanNumerals.java RENAME test_checkIfIVis()=>void test_checkIfIVis49() METHOD +RefactoringAction 1475155321997 TestRomanNumerals.java ADD void test_checkIfIVis9()/2 METHOD +RefactoringAction 1475155336091 TestRomanNumerals.java RENAME test_checkIfIVis9()/2=>void test_checkIfIVis99() METHOD +RefactoringAction 1475155344137 TestRomanNumerals.java ADD void test_checkIfIVis99()/2 METHOD +RefactoringAction 1475155347156 TestRomanNumerals.java RENAME test_checkIfIVis99()/2=>void test_checkIfIVis49()/2 METHOD +RefactoringAction 1475155357608 RomanNumerals.java ADD Object wahtIsIVis9(String) METHOD +RefactoringAction 1475155363134 RomanNumerals.java ADD Object wahtIsIVis49(String) METHOD +RefactoringAction 1475155367896 RomanNumerals.java ADD Object wahtIsIVis99(String) METHOD +RefactoringAction 1475155373907 RomanNumerals.java ADD Object wahtIsIVis499(String) METHOD +RefactoringAction 1475155471553 TestRomanNumerals.java RENAME test_checkIfIVis49()/2=>void test_checkIfIVis490() METHOD +RefactoringAction 1475155472573 TestRomanNumerals.java RENAME test_checkIfIVis490()=>void test_checkIfIVis4909() METHOD +RefactoringAction 1475155473598 TestRomanNumerals.java RENAME test_checkIfIVis4909()=>void test_checkIfIVis499() METHOD +EditAction 1475155477149 RomanNumerals.java 3240 13 34 0 +EditAction 1475155477794 TestRomanNumerals.java 2925 13 25 12 +UnitTestCaseAction 1475155478566 TestRomanNumerals.java FAIL +UnitTestSessionAction 1475155478566 TestRomanNumerals.java FAIL +RefactoringAction 1475155599251 TestRomanNumerals.java ADD void test_checkIfIVis9()/2 METHOD +RefactoringAction 1475155599254 TestRomanNumerals.java ADD void test_checkIfIVis49()/2 METHOD +RefactoringAction 1475155599255 TestRomanNumerals.java ADD void test_checkIfIVis99()/2 METHOD +RefactoringAction 1475155599259 TestRomanNumerals.java ADD void test_checkIfIVis499()/2 METHOD +RefactoringAction 1475155613814 TestRomanNumerals.java RENAME test_checkIfIVis9()/2=>void test_checkIfIVis40() METHOD +RefactoringAction 1475155627910 TestRomanNumerals.java RENAME test_checkIfIVis49()/2=>void test_checkIfIVis90() METHOD +RefactoringAction 1475155662144 TestRomanNumerals.java RENAME test_checkIfIVis99()/2=>void test_checkIfIVis490() METHOD +RefactoringAction 1475155671204 TestRomanNumerals.java REMOVE test_checkIfIVis499()/2 METHOD +RefactoringAction 1475155709830 RomanNumerals.java ADD Object wahtIsXLis40(String) METHOD +RefactoringAction 1475155715450 RomanNumerals.java ADD Object wahtIsXCis90(String) METHOD +RefactoringAction 1475155719726 RomanNumerals.java ADD Object wahtIsXDis490(String) METHOD +RefactoringAction 1475155731080 RomanNumerals.java RENAME wahtIsIVis9(String)=>Object wahtIsIis9(String) METHOD +RefactoringAction 1475155732103 RomanNumerals.java RENAME wahtIsIis9(String)=>Object wahtIsIXis9(String) METHOD +RefactoringAction 1475155735651 RomanNumerals.java RENAME wahtIsIVis49(String)=>Object wahtIsIis49(String) METHOD +RefactoringAction 1475155736683 RomanNumerals.java RENAME wahtIsIis49(String)=>Object wahtIsILis49(String) METHOD +RefactoringAction 1475155740713 RomanNumerals.java RENAME wahtIsIVis99(String)=>Object wahtIsIis99(String) METHOD +RefactoringAction 1475155743743 RomanNumerals.java RENAME wahtIsIis99(String)=>Object wahtIsICis99(String) METHOD +RefactoringAction 1475155746765 RomanNumerals.java RENAME wahtIsIVis499(String)=>Object wahtIsIis499(String) METHOD +RefactoringAction 1475155747793 RomanNumerals.java RENAME wahtIsIis499(String)=>Object wahtIsIDis499(String) METHOD +EditAction 1475155790661 RomanNumerals.java 3830 16 40 0 +CompilationAction 1475155790853 TestRomanNumerals.java +CompilationAction 1475155790854 TestRomanNumerals.java +CompilationAction 1475155790854 TestRomanNumerals.java +CompilationAction 1475155790854 TestRomanNumerals.java +EditAction 1475155790871 TestRomanNumerals.java 3750 16 31 15 +CompilationAction 1475155791042 TestRomanNumerals.java +CompilationAction 1475155791042 TestRomanNumerals.java +CompilationAction 1475155791042 TestRomanNumerals.java +CompilationAction 1475155791043 TestRomanNumerals.java +EditAction 1475155823048 TestRomanNumerals.java 3750 16 31 15 +UnitTestCaseAction 1475155823717 TestRomanNumerals.java FAIL +UnitTestSessionAction 1475155823718 TestRomanNumerals.java FAIL +RefactoringAction 1475155837169 TestRomanNumerals.java ADD void test_checkIfIVis90()/2 METHOD +RefactoringAction 1475155837171 TestRomanNumerals.java ADD void test_checkIfIVis490()/2 METHOD +RefactoringAction 1475155841249 TestRomanNumerals.java RENAME test_checkIfIVis90()/2=>void test_checkIfLis90() METHOD +RefactoringAction 1475155844279 TestRomanNumerals.java RENAME test_checkIfLis90()=>void test_checkIfLCis90() METHOD +RefactoringAction 1475155869828 TestRomanNumerals.java REMOVE test_checkIfIVis490()/2 METHOD +RefactoringAction 1475155888376 TestRomanNumerals.java ADD void test_checkIfIVis490()/2 METHOD +RefactoringAction 1475155892424 TestRomanNumerals.java REMOVE test_checkIfIVis490()/2 METHOD +RefactoringAction 1475155905506 TestRomanNumerals.java REMOVE test_checkIfIVis99() METHOD +RefactoringAction 1475155905508 TestRomanNumerals.java REMOVE test_checkIfIVis499() METHOD +RefactoringAction 1475155905509 TestRomanNumerals.java REMOVE test_checkIfIVis49() METHOD +RefactoringAction 1475155928119 TestRomanNumerals.java RENAME test_checkIfLCis90()=>void test_checkIfis90() METHOD +RefactoringAction 1475155930164 TestRomanNumerals.java RENAME test_checkIfis90()=>void test_checkIfCDis90() METHOD +RefactoringAction 1475155936704 TestRomanNumerals.java RENAME test_checkIfCDis90()=>void test_checkIfCDis400() METHOD +RefactoringAction 1475155944229 TestRomanNumerals.java RENAME test_checkIfIVis490()=>void test_checkIfIVis900() METHOD +RefactoringAction 1475155971401 RomanNumerals.java ADD Object wahtIsCDis400(String) METHOD +RefactoringAction 1475155990571 RomanNumerals.java ADD Object wahtIsCMis900(String) METHOD +EditAction 1475156005715 RomanNumerals.java 4226 18 44 0 +EditAction 1475156006062 TestRomanNumerals.java 4284 14 27 13 +CompilationAction 1475156006248 TestRomanNumerals.java +CompilationAction 1475156016664 TestRomanNumerals.java +UnitTestCaseAction 1475156017235 TestRomanNumerals.java FAIL +UnitTestSessionAction 1475156017236 TestRomanNumerals.java FAIL +EditAction 1475156019752 TestRomanNumerals.java 4301 14 27 13 +RefactoringAction 1475156043750 TestRomanNumerals.java ADD be made FIELD +RefactoringAction 1475156043750 TestRomanNumerals.java ADD per numeral() METHOD +RefactoringAction 1475156046271 TestRomanNumerals.java REMOVE made FIELD +RefactoringAction 1475156046272 TestRomanNumerals.java REMOVE numeral() METHOD diff --git a/.besouro/20160929153653315/besouroEpisodes.txt b/.besouro/20160929153653315/besouroEpisodes.txt new file mode 100644 index 0000000..4876851 --- /dev/null +++ b/.besouro/20160929153653315/besouroEpisodes.txt @@ -0,0 +1,2 @@ +1475152939536 test-first 2 325 true +1475152939537 test-first 2 325 true diff --git a/.besouro/20160929153653315/disagreements.txt b/.besouro/20160929153653315/disagreements.txt new file mode 100644 index 0000000..e69de29 diff --git a/.besouro/20160929153653315/randomHeuristicEpisodes.txt b/.besouro/20160929153653315/randomHeuristicEpisodes.txt new file mode 100644 index 0000000..77b4ebb --- /dev/null +++ b/.besouro/20160929153653315/randomHeuristicEpisodes.txt @@ -0,0 +1 @@ +1475152939536 test-first 2 325 true diff --git a/.besouro/20160929153653315/userComments.txt b/.besouro/20160929153653315/userComments.txt new file mode 100644 index 0000000..e69de29 diff --git a/.besouro/20160929153653315/zorroEpisodes.txt b/.besouro/20160929153653315/zorroEpisodes.txt new file mode 100644 index 0000000..77b4ebb --- /dev/null +++ b/.besouro/20160929153653315/zorroEpisodes.txt @@ -0,0 +1 @@ +1475152939536 test-first 2 325 true diff --git a/.besouro/20161006150244533/actions.txt b/.besouro/20161006150244533/actions.txt new file mode 100644 index 0000000..70021f3 --- /dev/null +++ b/.besouro/20161006150244533/actions.txt @@ -0,0 +1,53 @@ +FileOpenedAction 1475755364932 RomanNumerals.java 4224 19 47 0 +EditAction 1475755810552 TestRomanNumerals.java 4449 14 28 14 +UnitTestCaseAction 1475755814154 TestRomanNumerals.java FAIL +UnitTestSessionAction 1475755814155 TestRomanNumerals.java FAIL +EditAction 1475755837577 RomanNumerals.java 4985 19 48 0 +UnitTestCaseAction 1475755838548 TestRomanNumerals.java FAIL +UnitTestSessionAction 1475755838549 TestRomanNumerals.java FAIL +UnitTestCaseAction 1475755871700 TestRomanNumerals.java FAIL +UnitTestSessionAction 1475755871700 TestRomanNumerals.java FAIL +UnitTestCaseAction 1475755884541 TestRomanNumerals.java FAIL +UnitTestSessionAction 1475755884542 TestRomanNumerals.java FAIL +EditAction 1475755911201 RomanNumerals.java 5017 19 48 0 +UnitTestCaseAction 1475755912205 TestRomanNumerals.java FAIL +UnitTestSessionAction 1475755912206 TestRomanNumerals.java FAIL +CompilationAction 1475755945334 RomanNumerals.java +CompilationAction 1475755945335 RomanNumerals.java +CompilationAction 1475755952198 RomanNumerals.java +CompilationAction 1475755952313 RomanNumerals.java +CompilationAction 1475755964261 RomanNumerals.java +UnitTestCaseAction 1475755966108 TestRomanNumerals.java FAIL +UnitTestSessionAction 1475755966109 TestRomanNumerals.java FAIL +EditAction 1475755984363 RomanNumerals.java 5025 19 48 0 +UnitTestCaseAction 1475755985232 TestRomanNumerals.java FAIL +UnitTestSessionAction 1475755985232 TestRomanNumerals.java FAIL +EditAction 1475755998614 RomanNumerals.java 5025 19 48 0 +UnitTestCaseAction 1475755999543 TestRomanNumerals.java FAIL +UnitTestSessionAction 1475755999543 TestRomanNumerals.java FAIL +UnitTestCaseAction 1475756079607 TestRomanNumerals.java FAIL +UnitTestSessionAction 1475756079607 TestRomanNumerals.java FAIL +UnitTestCaseAction 1475756106045 TestRomanNumerals.java FAIL +UnitTestSessionAction 1475756106046 TestRomanNumerals.java FAIL +UnitTestCaseAction 1475756111503 TestRomanNumerals.java FAIL +UnitTestSessionAction 1475756111503 TestRomanNumerals.java FAIL +UnitTestCaseAction 1475756370589 TestRomanNumerals.java FAIL +UnitTestSessionAction 1475756370589 TestRomanNumerals.java FAIL +UnitTestCaseAction 1475756466555 TestRomanNumerals.java FAIL +UnitTestSessionAction 1475756466556 TestRomanNumerals.java FAIL +UnitTestCaseAction 1475756505917 TestRomanNumerals.java FAIL +UnitTestSessionAction 1475756505918 TestRomanNumerals.java FAIL +UnitTestCaseAction 1475756945365 TestRomanNumerals.java FAIL +UnitTestSessionAction 1475756945366 TestRomanNumerals.java FAIL +UnitTestCaseAction 1475756993610 TestRomanNumerals.java FAIL +UnitTestSessionAction 1475756993610 TestRomanNumerals.java FAIL +UnitTestCaseAction 1475757046048 TestRomanNumerals.java FAIL +UnitTestSessionAction 1475757046049 TestRomanNumerals.java FAIL +UnitTestCaseAction 1475757122310 TestRomanNumerals.java FAIL +UnitTestSessionAction 1475757122311 TestRomanNumerals.java FAIL +CompilationAction 1475757204489 RomanNumerals.java +CompilationAction 1475757214645 RomanNumerals.java +CompilationAction 1475757214730 RomanNumerals.java +CompilationAction 1475757222140 RomanNumerals.java +UnitTestCaseAction 1475757222780 TestRomanNumerals.java FAIL +UnitTestSessionAction 1475757222780 TestRomanNumerals.java FAIL diff --git a/.besouro/20161006150244533/besouroEpisodes.txt b/.besouro/20161006150244533/besouroEpisodes.txt new file mode 100644 index 0000000..e69de29 diff --git a/.besouro/20161006150244533/disagreements.txt b/.besouro/20161006150244533/disagreements.txt new file mode 100644 index 0000000..e69de29 diff --git a/.besouro/20161006150244533/randomHeuristicEpisodes.txt b/.besouro/20161006150244533/randomHeuristicEpisodes.txt new file mode 100644 index 0000000..e69de29 diff --git a/.besouro/20161006150244533/userComments.txt b/.besouro/20161006150244533/userComments.txt new file mode 100644 index 0000000..e69de29 diff --git a/.besouro/20161006150244533/zorroEpisodes.txt b/.besouro/20161006150244533/zorroEpisodes.txt new file mode 100644 index 0000000..e69de29 diff --git a/.besouro/20161006160552135/actions.txt b/.besouro/20161006160552135/actions.txt new file mode 100644 index 0000000..4d5d45f --- /dev/null +++ b/.besouro/20161006160552135/actions.txt @@ -0,0 +1,13 @@ +FileOpenedAction 1475759152309 RomanNumerals.java 6083 19 48 0 +UnitTestCaseAction 1475760721216 TestRomanNumerals.java FAIL +UnitTestSessionAction 1475760721217 RomanNumerals.java FAIL +UnitTestCaseAction 1475760812760 TestRomanNumerals.java OK +UnitTestSessionAction 1475760812760 RomanNumerals.java OK +EditAction 1475760857210 TestRomanNumerals.java 4446 14 26 13 +CompilationAction 1475760857541 TestRomanNumerals.java +EditAction 1475760863070 TestRomanNumerals.java 4445 14 28 14 +UnitTestCaseAction 1475760863897 TestRomanNumerals.java OK +UnitTestSessionAction 1475760863897 TestRomanNumerals.java OK +EditAction 1475760876284 TestRomanNumerals.java 4449 14 28 14 +UnitTestCaseAction 1475760877100 TestRomanNumerals.java OK +UnitTestSessionAction 1475760877100 TestRomanNumerals.java OK diff --git a/.besouro/20161006160552135/besouroEpisodes.txt b/.besouro/20161006160552135/besouroEpisodes.txt new file mode 100644 index 0000000..3c56488 --- /dev/null +++ b/.besouro/20161006160552135/besouroEpisodes.txt @@ -0,0 +1,3 @@ +1475760812760 regression 2 1660 true +1475760863897 test-addition 1 6 true +1475760877100 regression 1 0 true diff --git a/.besouro/20161006160552135/disagreements.txt b/.besouro/20161006160552135/disagreements.txt new file mode 100644 index 0000000..e69de29 diff --git a/.besouro/20161006160552135/randomHeuristicEpisodes.txt b/.besouro/20161006160552135/randomHeuristicEpisodes.txt new file mode 100644 index 0000000..9404b75 --- /dev/null +++ b/.besouro/20161006160552135/randomHeuristicEpisodes.txt @@ -0,0 +1,3 @@ +1475760812760 regression 2 1660 true +1475760863897 test-addition 1 6 true +1475760877100 regression 1 0 false diff --git a/.besouro/20161006160552135/userComments.txt b/.besouro/20161006160552135/userComments.txt new file mode 100644 index 0000000..e69de29 diff --git a/.besouro/20161006160552135/zorroEpisodes.txt b/.besouro/20161006160552135/zorroEpisodes.txt new file mode 100644 index 0000000..e3940f9 --- /dev/null +++ b/.besouro/20161006160552135/zorroEpisodes.txt @@ -0,0 +1,3 @@ +1475760812760 regression 2 1660 false +1475760863897 test-addition 1 51 false +1475760877100 regression 1 13 false diff --git a/src/RomanNumerals.java b/src/RomanNumerals.java index 20904f0..ea29e50 100644 --- a/src/RomanNumerals.java +++ b/src/RomanNumerals.java @@ -2,7 +2,303 @@ public class RomanNumerals { public int convertToInteger(String romanNum) { // To be Implemented - return 0; - + //1984 = MCMLXXXIV + int num=0, tempNum=0, tempNum2=0, tempNum3=0, sigNum=0; + char tempChar; + if (checkFor3C(romanNum)&&checkFor3I(romanNum)&&checkFor3M(romanNum)&&checkFor3X(romanNum)) { + if (checkForNorepeatD(romanNum)&&checkForNorepeatL(romanNum)&&checkForNorepeatV(romanNum)) { + for (int i = romanNum.length()-1; i>=0 ; i--) { + tempNum=0; + tempNum2=0; + tempNum3=0; + if(sigNum==0){ + System.out.println("iep sumo"); + + tempChar= romanNum.charAt(i); + tempNum= convertCharToNum(tempChar); + if(i==1) { + + tempNum2=convertCharToNum(romanNum.charAt(i-1)); + if (tempNum>tempNum2) { + System.out.println(tempNum + "el sig es menor"+tempNum2); + + num= num+(tempNum-tempNum2); + sigNum=-1; + } else{ + num= num+tempNum; + } + + }else if(i==0){ + + num= num+tempNum; + + + }else if(i!=0 && i !=1){ + tempNum2=convertCharToNum(romanNum.charAt(i-1)); + tempNum3=convertCharToNum(romanNum.charAt(i-2)); + System.out.println("elnorma"+ tempNum+','+tempNum2+','+tempNum3); + + if (tempNum>tempNum2&&tempNum<=tempNum3) { + System.out.println(tempNum + "el sig es menor"+tempNum2); + num= num+(tempNum-tempNum2); + sigNum=-1; + System.out.println("sig"+sigNum); + } else if (tempNum>tempNum2&&tempNum>tempNum3) { + System.out.println(tempNum + "el sig y el sig es menor"+tempNum2+','+tempNum3); + + num= num+(tempNum-tempNum2-tempNum3); + sigNum=-2; + }else { + num= num+tempNum; + } + + + } + }else if (sigNum==-1) { + sigNum=0; + System.out.println("iep No sumo 1"); + + + }else if (sigNum==-2) { + sigNum=-1; + System.out.println("iep No sumo2"); + + } + System.out.println(num +" y "+sigNum); + } + } + } + return num; + + + } + + public int convertCharToNum(Character a){ + int num=0; + + if (a=='I') { + num=1; + + }else if(a=='V') { + num=5; + + }else if(a=='X') { + num=10; + + }else if(a=='L') { + num=50; + + }else if (a=='C') { + num=100; + + }else if(a=='M') { + num=1000; + + } + return num; + + } + //1 rule + public boolean checkFor3I(String num) { + // TODO Auto-generated method stub + int numOfThatChar=0; + for (int i = 0; i < num.length(); i++) { + if (num.charAt(i)=='I') { + numOfThatChar++; + } + + } + + + if (numOfThatChar<=3) { + return true; + }else return false; + } + + public boolean checkFor3X(String num) { + // TODO Auto-generated method stub + int numOfThatChar=0; + for (int i = 0; i < num.length(); i++) { + if (num.charAt(i)=='X') { + numOfThatChar++; + } + + } + + + if (numOfThatChar<=3) { + return true; + }else return false; } + + public boolean checkFor3C(String num) { + // TODO Auto-generated method stub + int numOfThatChar=0; + for (int i = 0; i < num.length(); i++) { + if (num.charAt(i)=='C') { + numOfThatChar++; + } + + } + + + if (numOfThatChar<=3) { + return true; + }else return false; + } + + public boolean checkFor3M(String num) { + // TODO Auto-generated method stub + int numOfThatChar=0; + for (int i = 0; i < num.length(); i++) { + if (num.charAt(i)=='M') { + numOfThatChar++; + } + + } + + + if (numOfThatChar<=3) { + return true; + }else return false; + } + + + //2rule + + public boolean checkForNorepeatV(String num) { + int numOfThatChar=0; + for (int i = 0; i < num.length(); i++) { + if (num.charAt(i)=='V') { + numOfThatChar++; + } + } + if (numOfThatChar>1) { + return false; + }else return true; + } + public boolean checkForNorepeatL(String num) { + // TODO Auto-generated method stub + int numOfThatChar=0; + for (int i = 0; i < num.length(); i++) { + if (num.charAt(i)=='L') { + numOfThatChar++; + } + } + if (numOfThatChar>1) { + return false; + }else return true; + } + public boolean checkForNorepeatD(String num) { + // TODO Auto-generated method stub + int numOfThatChar=0; + for (int i = 0; i < num.length(); i++) { + if (num.charAt(i)=='D') { + numOfThatChar++; + } + } + if (numOfThatChar>1) { + return false; + }else return true; + } + public int wahtIsIVis4(String num) { + + for (int i = 0; i < num.length(); i++) { + if (num.charAt(i)=='I' &&(num.charAt(i+1)=='V')) { + return 4; + }else return -1; + + + } + return -1; + } + public Object wahtIsIXis9(String num) { + for (int i = 0; i < num.length(); i++) { + if (num.charAt(i)=='I' &&(num.charAt(i+1)=='X')) { + return 9; + }else return -1; + + + } + return -1; + } + public Object wahtIsILis49(String num) { + for (int i = 0; i < num.length(); i++) { + if (num.charAt(i)=='I' &&(num.charAt(i+1)=='L')) { + return 49; + }else return -1; + + + } + return -1; + } + public Object wahtIsICis99(String num) { + for (int i = 0; i < num.length(); i++) { + if (num.charAt(i)=='I' &&(num.charAt(i+1)=='C')) { + return 99; + }else return -1; + + + } + return -1; + } + public Object wahtIsIDis499(String num) { + for (int i = 0; i < num.length(); i++) { + if (num.charAt(i)=='I' &&(num.charAt(i+1)=='D')) { + return 499; + }else return -1; + + + } + return -1; + } + public Object wahtIsXLis40(String num) { + for (int i = 0; i < num.length(); i++) { + if (num.charAt(i)=='X' &&(num.charAt(i+1)=='L')) { + return 40; + }else return -1; + + + } + return -1; + } + public Object wahtIsXCis90(String num) { + for (int i = 0; i < num.length(); i++) { + if (num.charAt(i)=='X' &&(num.charAt(i+1)=='C')) { + return 90; + }else return -1; + + + } + return -1; + } + public Object wahtIsXDis490(String num) { + for (int i = 0; i < num.length(); i++) { + if (num.charAt(i)=='X' &&(num.charAt(i+1)=='D')) { + return 490; + }else return -1; + + + } + return -1; + } + public Object wahtIsCDis400(String num) { + for (int i = 0; i < num.length(); i++) { + if (num.charAt(i)=='C' &&(num.charAt(i+1)=='D')) { + return 400; + }else return -1; + + + } + return -1; + } + public Object wahtIsCMis900(String num) { + for (int i = 0; i < num.length(); i++) { + if (num.charAt(i)=='C' &&(num.charAt(i+1)=='M')) { + return 900; + }else return -1; + + + } + return -1; } } diff --git a/tests/TestRomanNumerals.java b/tests/TestRomanNumerals.java index 5d1de75..f3baf24 100644 --- a/tests/TestRomanNumerals.java +++ b/tests/TestRomanNumerals.java @@ -4,9 +4,159 @@ public class TestRomanNumerals { + RomanNumerals romanNumerals= new RomanNumerals(); + @Test public void test() { - fail("Not yet implemented"); + int num= romanNumerals.convertToInteger("MCMLXXXIV"); + assertEquals(1984, num); + + } + + @Test + public void test_checkFor3I() { + //The symbols 'I', 'X', 'C', and 'M' can be repeated + // at most 3 times in a row. + String num="MCMLXXXIV"; + assertTrue(romanNumerals.checkFor3I(num)); + } + @Test + public void test_checkFor3X() { + //The symbols 'I', 'X', 'C', and 'M' can be repeated + // at most 3 times in a row. + String num="MCMLXXXIV"; + assertTrue(romanNumerals.checkFor3X(num)); + } + + @Test + public void test_checkFor3C() { + //The symbols 'I', 'X', 'C', and 'M' can be repeated + // at most 3 times in a row. + String num="MCMLXXXIV"; + assertTrue(romanNumerals.checkFor3C(num)); + } + @Test + public void test_checkFor3M() { + //The symbols 'I', 'X', 'C', and 'M' can be repeated + // at most 3 times in a row. + String num="MCMLXXXIV"; + assertTrue(romanNumerals.checkFor3M(num)); + } + + @Test + public void test_checkForNoV() { + // The symbols 'V', 'L', and 'D' can never be repeated. + String num="MCMLXXXIV"; + assertTrue(romanNumerals.checkForNorepeatV(num)); + } + + @Test + public void test_checkForNoL() { + // The symbols 'V', 'L', and 'D' can never be repeated. + String num="MCMLXXXIV"; + assertTrue(romanNumerals.checkForNorepeatL(num)); + } + @Test + public void test_checkForNoD() { + // The symbols 'V', 'L', and 'D' can never be repeated. + String num="MCMLXXXIV"; + assertTrue(romanNumerals.checkForNorepeatD(num)); + } + + + //rule 3 + + @Test + public void test_checkIfIVis4(){ + // The '1' symbols ('I', 'X', and 'C') can only be subtracted from the 2 next highest values ('IV' and + // 'IX', 'XL' and 'XC', 'CD' and 'CM'). + + String num="IV"; + assertEquals(4, (romanNumerals.wahtIsIVis4(num))); + } + @Test + public void test_checkIfIVis9(){ + // The '1' symbols ('I', 'X', and 'C') can only be subtracted from the 2 next highest values ('IV' and + // 'IX', 'XL' and 'XC', 'CD' and 'CM'). + + String num="IX"; + assertEquals(9, (romanNumerals.wahtIsIXis9(num))); } + /*@Test + public void test_checkIfIVis49(){ +// The '1' symbols ('I', 'X', and 'C') can only be subtracted from the 2 next highest values ('IV' and +// 'IX', 'XL' and 'XC', 'CD' and 'CM'). + + String num="IL"; + assertEquals(49, (romanNumerals.wahtIsILis49(num))); + } + @Test + public void test_checkIfIVis99(){ +// The '1' symbols ('I', 'X', and 'C') can only be subtracted from the 2 next highest values ('IV' and +// 'IX', 'XL' and 'XC', 'CD' and 'CM'). + + String num="IC"; + assertEquals(99, (romanNumerals.wahtIsICis99(num))); + } + @Test + public void test_checkIfIVis499(){ +// The '1' symbols ('I', 'X', and 'C') can only be subtracted from the 2 next highest values ('IV' and +// 'IX', 'XL' and 'XC', 'CD' and 'CM'). + + String num="ID"; + assertEquals(499, (romanNumerals.wahtIsIDis499(num))); + } + */ + + + + + + @Test + public void test_checkIfIVis40(){ + // The '1' symbols ('I', 'X', and 'C') can only be subtracted from the 2 next highest values ('IV' and + // 'IX', 'XL' and 'XC', 'CD' and 'CM'). + + String num="XL"; + assertEquals(40, (romanNumerals.wahtIsXLis40(num))); + } + @Test + public void test_checkIfIVis90(){ + // The '1' symbols ('I', 'X', and 'C') can only be subtracted from the 2 next highest values ('IV' and + // 'IX', 'XL' and 'XC', 'CD' and 'CM'). + + String num="XC"; + assertEquals(90, (romanNumerals.wahtIsXCis90(num))); + } + /* @Test + public void test_checkIfIVis490(){ +// The '1' symbols ('I', 'X', and 'C') can only be subtracted from the 2 next highest values ('IV' and +// 'IX', 'XL' and 'XC', 'CD' and 'CM'). + + String num="XD"; + assertEquals(490, (romanNumerals.wahtIsXDis490(num))); + }*/ + + @Test + public void test_checkIfCDis400(){ + // The '1' symbols ('I', 'X', and 'C') can only be subtracted from the 2 next highest values ('IV' and + // 'IX', 'XL' and 'XC', 'CD' and 'CM'). + + String num="CD"; + assertEquals(400, (romanNumerals.wahtIsCDis400(num))); + } + @Test + public void test_checkIfIVis900(){ + // The '1' symbols ('I', 'X', and 'C') can only be subtracted from the 2 next highest values ('IV' and + // 'IX', 'XL' and 'XC', 'CD' and 'CM'). + + String num="CM"; + assertEquals(900, (romanNumerals.wahtIsCMis900(num))); + } + //4 rule + + // Only one subtraction can + // be made per numeral ('XC' is allowed, 'XXC' is not). + }