Difference between revisions of "Team:HFUT-China/Unit Test"

Line 117: Line 117:
 
function showClassDetail1(cid, count) {
 
function showClassDetail1(cid, count) {
 
     var id_list = Array(count);
 
     var id_list = Array(count);
     var toHide = 1;
+
     var toHide1 = 1;
 
     for (var i = 0; i < count; i++) {
 
     for (var i = 0; i < count; i++) {
 
         tid0 = 'a' + cid.substr(1) + '.' + (i+1);
 
         tid0 = 'a' + cid.substr(1) + '.' + (i+1);
Line 128: Line 128:
 
         id_list[i] = tid;
 
         id_list[i] = tid;
 
         if (tr.className) {
 
         if (tr.className) {
             toHide = 0;
+
             toHide1 = 0;
 
         }
 
         }
 
     }
 
     }
 
     for (var i = 0; i < count; i++) {
 
     for (var i = 0; i < count; i++) {
 
         tid = id_list[i];
 
         tid = id_list[i];
         if (toHide) {
+
         if (toHide1) {
 
             document.getElementById('div_'+tid).style.display = 'none'
 
             document.getElementById('div_'+tid).style.display = 'none'
 
             document.getElementById(tid).className = 'hiddenRow';
 
             document.getElementById(tid).className = 'hiddenRow';
Line 145: Line 145:
 
function showClassDetail2(cid, count) {
 
function showClassDetail2(cid, count) {
 
     var id_list = Array(count);
 
     var id_list = Array(count);
     var toHide = 1;
+
     var toHide2 = 1;
 
     for (var i = 0; i < count; i++) {
 
     for (var i = 0; i < count; i++) {
 
         tid0 = 'b' + cid.substr(1) + '.' + (i+1);
 
         tid0 = 'b' + cid.substr(1) + '.' + (i+1);
Line 156: Line 156:
 
         id_list[i] = tid;
 
         id_list[i] = tid;
 
         if (tr.className) {
 
         if (tr.className) {
             toHide = 0;
+
             toHide2 = 0;
 
         }
 
         }
 
     }
 
     }
 
     for (var i = 0; i < count; i++) {
 
     for (var i = 0; i < count; i++) {
 
         tid = id_list[i];
 
         tid = id_list[i];
         if (toHide) {
+
         if (toHide2) {
 
             document.getElementById('div_'+tid).style.display = 'none'
 
             document.getElementById('div_'+tid).style.display = 'none'
 
             document.getElementById(tid).className = 'hiddenRow';
 
             document.getElementById(tid).className = 'hiddenRow';
Line 173: Line 173:
 
function showClassDetail3(cid, count) {
 
function showClassDetail3(cid, count) {
 
     var id_list = Array(count);
 
     var id_list = Array(count);
     var toHide = 1;
+
     var toHide3 = 1;
 
     for (var i = 0; i < count; i++) {
 
     for (var i = 0; i < count; i++) {
 
         tid0 = 'c' + cid.substr(1) + '.' + (i+1);
 
         tid0 = 'c' + cid.substr(1) + '.' + (i+1);
Line 184: Line 184:
 
         id_list[i] = tid;
 
         id_list[i] = tid;
 
         if (tr.className) {
 
         if (tr.className) {
             toHide = 0;
+
             toHide3 = 0;
 
         }
 
         }
 
     }
 
     }
 
     for (var i = 0; i < count; i++) {
 
     for (var i = 0; i < count; i++) {
 
         tid = id_list[i];
 
         tid = id_list[i];
         if (toHide) {
+
         if (toHide3) {
 
             document.getElementById('div_'+tid).style.display = 'none'
 
             document.getElementById('div_'+tid).style.display = 'none'
 
             document.getElementById(tid).className = 'hiddenRow';
 
             document.getElementById(tid).className = 'hiddenRow';
Line 201: Line 201:
 
function showClassDetail4(cid, count) {
 
function showClassDetail4(cid, count) {
 
     var id_list = Array(count);
 
     var id_list = Array(count);
     var toHide = 1;
+
     var toHide4 = 1;
 
     for (var i = 0; i < count; i++) {
 
     for (var i = 0; i < count; i++) {
 
         tid0 = 'd' + cid.substr(1) + '.' + (i+1);
 
         tid0 = 'd' + cid.substr(1) + '.' + (i+1);
Line 212: Line 212:
 
         id_list[i] = tid;
 
         id_list[i] = tid;
 
         if (tr.className) {
 
         if (tr.className) {
             toHide = 0;
+
             toHide4 = 0;
 
         }
 
         }
 
     }
 
     }
 
     for (var i = 0; i < count; i++) {
 
     for (var i = 0; i < count; i++) {
 
         tid = id_list[i];
 
         tid = id_list[i];
         if (toHide) {
+
         if (toHide4) {
 
             document.getElementById('div_'+tid).style.display = 'none'
 
             document.getElementById('div_'+tid).style.display = 'none'
 
             document.getElementById(tid).className = 'hiddenRow';
 
             document.getElementById(tid).className = 'hiddenRow';
Line 229: Line 229:
 
function showClassDetai5(cid, count) {
 
function showClassDetai5(cid, count) {
 
     var id_list = Array(count);
 
     var id_list = Array(count);
     var toHide = 1;
+
     var toHide5 = 1;
 
     for (var i = 0; i < count; i++) {
 
     for (var i = 0; i < count; i++) {
 
         tid0 = 'e' + cid.substr(1) + '.' + (i+1);
 
         tid0 = 'e' + cid.substr(1) + '.' + (i+1);
Line 240: Line 240:
 
         id_list[i] = tid;
 
         id_list[i] = tid;
 
         if (tr.className) {
 
         if (tr.className) {
             toHide = 0;
+
             toHide5 = 0;
 
         }
 
         }
 
     }
 
     }
 
     for (var i = 0; i < count; i++) {
 
     for (var i = 0; i < count; i++) {
 
         tid = id_list[i];
 
         tid = id_list[i];
         if (toHide) {
+
         if (toHide5) {
 
             document.getElementById('div_'+tid).style.display = 'none'
 
             document.getElementById('div_'+tid).style.display = 'none'
 
             document.getElementById(tid).className = 'hiddenRow';
 
             document.getElementById(tid).className = 'hiddenRow';

Revision as of 20:34, 25 October 2017

Team:HFUT-China

Unit Test 1

Start Time: 2017-10-05 23:50:48
Duration: 0:00:11.468128
Status: Pass 6
Show Summary Failed All
Test Group/Test case Count Pass Fail Error View
Test 6 6 0 0 Detail
test_randomPage
pass
test_randomPageWiththeme
pass
test_TurnPage
pass
test_getCache
pass
test_getDetailNone
pass
test_getDetail
pass
Total 6 6 0 0  
 

Unit Test 2

Start Time: 2017-10-05 23:50:53
Duration: 0:00:00.443314
Status: Pass 10
Show Summary Failed All
Test Group/Test case Count Pass Fail Error View
Test 10 10 0 0 Detail
test_getTeamIdExist
pass
test_getTeamIdNone
pass
test_getdetailbyidExist
pass
test_getdetailbyidFail
pass
test_getPartTeam1
pass
test_getPartTeam2
pass
test_getTeamWiki
pass
test_getTeamWikiFailOne
pass
test_getPartDetailExist
pass
test_getPartDetailNone
pass
Total 10 10 0 0  
 

Unit Test 3

Start Time: 2017-10-07 01:29:23
Duration: 0:00:08.978347
Status: Pass 3
Show Summary Failed All
Test Group/Test case Count Pass Fail Error View
Test 3 3 0 0 Detail
test_changePassword
pass
test_changePasswordError
pass
test_diffPassword
pass
Total 3 3 0 0  
 

Unit Test 4

Start Time: 2017-10-07 01:30:31
Duration: 0:00:09.161845
Status: Pass 9
Show Summary Failed All
Test Group/Test case Count Pass Fail Error View
Test 9 9 0 0 Detail
test_registerSucc
pass
test_registerNoUsername
pass
test_registerNoEmail
pass
test_registerUsername
pass
test_registerEmail
pass
test_passwordError
pass
test_rightLogin
pass
test_wrongUser
pass
test_loginFaile
pass
Total 9 9 0 0  
 

Unit Test 5

Start Time: 2017-10-09 02:23:46
Duration: 0:00:03.104095
Status: Pass 6
Show Summary Failed All
Test Group/Test case Count Pass Fail Error View
searchRelationTestCase 6 6 0 0 Detail
test_search_relation
pass
test_search_genes
pass
test_search_papers
pass
test_search_one_sentence
pass
test_search_three_sentence
pass
test_search_related_disease
pass
Total 6 6 0 0