Skip to content

Commit

Permalink
Fix cmts
Browse files Browse the repository at this point in the history
  • Loading branch information
yaqiangz committed Dec 6, 2024
1 parent bf7e715 commit 179b0da
Show file tree
Hide file tree
Showing 4 changed files with 25 additions and 1 deletion.
1 change: 1 addition & 0 deletions ansible/password.txt
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
abc
Empty file added ansible/secrets.json
Empty file.
23 changes: 23 additions & 0 deletions spytest/spytest/temp.py
Original file line number Diff line number Diff line change
@@ -0,0 +1,23 @@
import re

strs = """
ip prefix-list LOOPBACK0_V4 seq 15 permit 3.3.3.3/32
ip prefix-list RR-BLOCK-LIST-IPV4
seq 10 permit 1.1.1.1/32
seq 20 permit 2.2.2.2/32
seq 30 permit 0.0.0.0/32
sadfasdfasdf
asdfasdfasdf
ip prefix-list RR-BLOCK-LIST-IPV4 seq 5 permit 10.3.149.113/32
ip prefix-list RR-BLOCK-LIST-IPV4 seq 15 permit 4.4.4.4/32
"""

# res = re.findall(r"(ip prefix-list RR-BLOCK-LIST-IPV4)\n*(\s*seq \d+ permit (.*))*", strs)
# for line in res:
# print(line)
# print(line[2])
res = re.findall(r"((ip prefix-list RR-BLOCK-LIST-IPV4(\n\s*seq \d+ permit .*){1,})|ip prefix-list RR-BLOCK-LIST-IPV4.*)", strs)
for line in res:
new = re.findall(r"(\d+\..*)", line[0])
print(new)
2 changes: 1 addition & 1 deletion tests/dhcp_relay/conftest.py
Original file line number Diff line number Diff line change
Expand Up @@ -149,7 +149,7 @@ def validate_dut_routes_exist(duthosts, rand_one_dut_hostname, dut_dhcp_relay_da
py_assert(wait_until(120, 5, 0, check_routes_to_dhcp_server, duthosts[rand_one_dut_hostname],
dut_dhcp_relay_data),
"Packets relayed to DHCP server should go through default route via upstream neighbor, but now it's" +
" going through mgmt interface, which means device is in a unhealthy status")
" going through mgmt interface, which means device is in an unhealthy status")


@pytest.fixture(scope="module")
Expand Down

0 comments on commit 179b0da

Please sign in to comment.