#在Excel中记录结果
#we should keep the directory of project
#If we do not,we will accur some trouble
def WriteExcel(result, locator,sheetname):
book = load_workbook(autocase)
sheet = book.get_sheet_by_name(sheetname)
if result == True:
sheet.cell(locator).value = 'Pass'
elif result == False:
sheet.cell(locator).value = 'Fail'