fix: 判断公式和停闭前比较时先看停闭前是不是数值,避免空文本相减报错
This commit is contained in:
@@ -290,8 +290,8 @@ def test_write_pinduan_groups_neighbors_per_site():
|
||||
assert sheet.cell(first, 24).value == "站A"
|
||||
assert "不通过" in sheet.cell(first, 23).value and "拆除后再评估" in sheet.cell(first, 23).value
|
||||
# 每一项只在自己的停闭后数值存在时才比阈值,缺了显示「/」。
|
||||
assert sheet.cell(first, 19).value == f'=IF(ISNUMBER(L{first}),IF(L{first}>10,"N",IF(AND(ISNUMBER(E{first}),(L{first}-E{first})>5),"N","Y")),"/")'
|
||||
assert sheet.cell(first, 20).value == f'=IF(ISNUMBER(M{first}),IF(M{first}<97,"N",IF(AND(ISNUMBER(F{first}),(F{first}-M{first})>1),"N","Y")),"/")'
|
||||
assert sheet.cell(first, 19).value == f'=IF(ISNUMBER(L{first}),IF(L{first}>10,"N",IF(IF(ISNUMBER(E{first}),(L{first}-E{first})>5,FALSE),"N","Y")),"/")'
|
||||
assert sheet.cell(first, 20).value == f'=IF(ISNUMBER(M{first}),IF(M{first}<97,"N",IF(IF(ISNUMBER(F{first}),(F{first}-M{first})>1,FALSE),"N","Y")),"/")'
|
||||
assert sheet.cell(first, 21).value == f'=IF(ISNUMBER(N{first}),IF(N{first}<0.3,"Y","N"),"/")'
|
||||
assert sheet.cell(summary_a, 22).value == f'=IF(ISNUMBER(O{summary_a}),IF(O{summary_a}<0.3,"Y","N"),"/")'
|
||||
second = summary_a + 1
|
||||
|
||||
Reference in New Issue
Block a user