Changeset 1821


Ignore:
Timestamp:
12/20/19 14:15:59 (4 years ago)
Author:
yushan
Message:

XIOS test suite : unit tests will not run if build failed. Catch the make_xios exit value as build status.

Location:
XIOS/trunk/xios_test_suite
Files:
5 edited

Legend:

Unmodified
Added
Removed
  • XIOS/trunk/xios_test_suite/COMPILE/config_compile.py

    r1816 r1821  
    6767             
    6868            f.write("add_test( NAME "+build_dir_name+'\n') 
    69             f.write("          COMMAND bash -c \"source ../ARCH/arch-"+configs_arg[0][i]+".env  && cd ../.. && ./make_xios --arch_path `pwd`/xios_test_suite/ARCH --arch "+configs_arg[0][i]+" --"+configs_arg[1][j]+" --job 16 --build_dir xios_test_suite/BUILD/build_"+build_dir_name+" | tail -n 1 >> xios_test_suite/COMPILE/build_"+revision+"_"+machine+"_"+build_dir_name+".txt\")\n\n") 
     69            f.write("          COMMAND bash -c \"source ../ARCH/arch-"+configs_arg[0][i]+".env  && cd ../.. && ./make_xios --arch_path `pwd`/xios_test_suite/ARCH --arch "+configs_arg[0][i]+" --"+configs_arg[1][j]+" --job 16 --build_dir xios_test_suite/BUILD/build_"+build_dir_name+" | echo $? >> xios_test_suite/COMPILE/build_"+revision+"_"+machine+"_"+build_dir_name+".txt\")\n\n") 
    7070            f.write("set_tests_properties( "+build_dir_name+" PROPERTIES\n") 
    7171            f.write("                      FAIL_REGULAR_EXPRESSION \"failed\")\n\n") 
  • XIOS/trunk/xios_test_suite/COMPILE/generate_compile.py

    r1805 r1821  
    8585                myBuild[3] = myText 
    8686 
    87             elif line.startswith("Build command"): 
    88                 myTexts = line.replace("Build command ", "").replace("\n", "").split(" ") 
    89                 if myTexts[0] == "finished" : 
     87            elif line[0].isdigit(): 
     88                myTexts = line.replace("\n", "") 
     89                if myTexts == "0" : 
    9090                    myBuild[4] = "✅"  
    9191                else : 
  • XIOS/trunk/xios_test_suite/HTML/generate_test_table.js

    r1814 r1821  
    189189  mySubTable.setAttribute("class", "test_sub_table") 
    190190  mySubTable.setAttribute("id", "test_sub_table_"+revision+"_"+machine+"_"+build_dir) 
     191 
     192  if(info_list.length == 0) 
     193  { 
     194    myRow = document.createElement("tr") 
     195    myRow.setAttribute("id","test_sub_table_row_"+revision+"_"+machine+"_"+build_dir) 
     196    myRow.setAttribute("class","test_sub_table_row_"+revision+"_"+machine) 
     197    myRow.classList.add("build_level") 
     198    myCell = document.createElement("td") 
     199    myCell.innerHTML = build_dir.replace("build_","")+" Build Failed" 
     200    myCell.style.color = "white" 
     201    myCell.style.fontWeight = "bold" 
     202    myRow.appendChild(myCell) 
     203    mySubTable.append(myRow) 
     204    return; 
     205  } 
    191206 
    192207  myRow = document.createElement("tr") 
  • XIOS/trunk/xios_test_suite/HTML/xios-style.css

    r1814 r1821  
    8686} 
    8787 
     88.showit  
     89{ 
     90    display: block; 
     91} 
    8892 
    8993.compile_table 
  • XIOS/trunk/xios_test_suite/TEST_SUITE/generate_test.py

    r1819 r1821  
    6363                if not relurl in relurl_list : 
    6464                    relurl_list.append(relurl) 
    65 #            elif line.startswith("#machine") : 
    66 #                machine = line.replace("\n","").split(" ")[1] 
    67 #                machine_name = machine_name_dict[machine] 
    68 #                if not machine in machine_list : 
    69 #                    machine_list.append(machine) 
    7065            elif line.startswith("#build_dir") : 
    7166                build_dir = line.replace("\n","").split(" ")[1] 
     
    126121                f.write("        [\'"+myReportDict[key][j][0]+"\', \'"+myReportDict[key][j][1]+"\', \'"+myReportDict[key][j][2]+"\', "+myReportDict[key][j][3]+"],\n") 
    127122            else : 
    128                 f.write("        [\'"+myReportDict[key][j][0]+"\', \'"+myReportDict[key][j][1]+"\', \'"+myReportDict[key][j][2]+"\', "+myReportDict[key][j][3]+"]]\n") 
    129         f.write("\n\n") 
     123                f.write("        [\'"+myReportDict[key][j][0]+"\', \'"+myReportDict[key][j][1]+"\', \'"+myReportDict[key][j][2]+"\', "+myReportDict[key][j][3]+"]") 
     124        f.write("]\n\n\n") 
    130125 
    131126    for revision in revision_list : 
Note: See TracChangeset for help on using the changeset viewer.