Skip to content

Commit 2b5855f

Browse files
committed
changed test file.
1 parent b5ecb6e commit 2b5855f

1 file changed

Lines changed: 22 additions & 10 deletions

File tree

tests/service_ep_flag_bd_check/test_service_ep_flag_bd_check.py

Lines changed: 22 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -20,57 +20,69 @@
2020
[
2121
# tversion missing
2222
(
23-
{vnsLIfCtx_api: read_data(dir, "vnsLIfCtx-na.json")},
23+
{
24+
vnsLIfCtx_api: read_data(dir, "vnsLIfCtx-na.json")
25+
},
2426
"5.2(8h)",
2527
None,
2628
script.MANUAL
2729
),
2830
# Version not affected (both new)
2931
(
30-
{vnsLIfCtx_api: read_data(dir, "vnsLIfCtx-pos.json")},
32+
{
33+
vnsLIfCtx_api: read_data(dir, "vnsLIfCtx-pos.json")
34+
},
3135
"6.0(8h)",
3236
"6.1(1g)",
3337
script.NA,
3438
),
3539
# Version not affected (both old)
3640
(
37-
{vnsLIfCtx_api: read_data(dir, "vnsLIfCtx-pos.json")},
41+
{
42+
vnsLIfCtx_api: read_data(dir, "vnsLIfCtx-pos.json")
43+
},
3844
"4.2(7s)",
3945
"5.2(4c)",
4046
script.NA,
4147
),
4248
# Version affected with L4L7 Interface connector without PBR
4349
(
44-
{vnsLIfCtx_api: read_data(dir, "vnsLIfCtx-pos.json")},
50+
{
51+
vnsLIfCtx_api: read_data(dir, "vnsLIfCtx-pos.json")
52+
},
4553
"5.2(8h)",
4654
"6.0(8e)",
4755
script.FAIL_O
4856
),
4957
# Version affected with L4L7 Interface connector without PBR
5058
(
51-
{vnsLIfCtx_api: read_data(dir, "vnsLIfCtx-pos.json")},
59+
{
60+
vnsLIfCtx_api: read_data(dir, "vnsLIfCtx-pos.json")
61+
},
5262
"5.2(8h)",
5363
"6.1(1f)",
5464
script.FAIL_O
5565
),
5666
# Version affected with L4L7 Interface connector without PBR
5767
(
58-
{vnsLIfCtx_api: read_data(dir, "vnsLIfCtx-neg.json")},
68+
{
69+
vnsLIfCtx_api: read_data(dir, "vnsLIfCtx-neg.json")
70+
},
5971
"5.2(8h)",
6072
"6.0(8e)",
6173
script.PASS
6274
),
6375
# Version affected with L4L7 Interface connector without PBR
6476
(
65-
{vnsLIfCtx_api: read_data(dir, "vnsLIfCtx-neg.json")},
77+
{
78+
vnsLIfCtx_api: read_data(dir, "vnsLIfCtx-neg.json")
79+
},
6680
"5.2(8h)",
6781
"6.1(1f)",
6882
script.PASS
6983
),
7084
],
7185
)
7286
def test_logic(mock_icurl, cversion, tversion, expected_result):
73-
cversion = script.AciVersion(cversion)
74-
tversion = script.AciVersion(tversion) if tversion else None
75-
result = script.service_ep_flag_bd_check(1, 1, cversion, tversion)
87+
result = script.service_ep_flag_bd_check(1, 1, script.AciVersion(cversion), script.AciVersion(tversion) if tversion else None)
7688
assert result == expected_result

0 commit comments

Comments
 (0)