mirror of
https://github.com/All-Hands-AI/OpenHands.git
synced 2026-01-09 14:57:59 -05:00
(test) enhance conftest to lessen false positives in integration tests (#3512)
* conftest: also mask size=xxx parameter in integration tests * mask random poetry path part * make regex more flexible
This commit is contained in:
@@ -50,6 +50,16 @@ def filter_out_symbols(input):
|
||||
# openhands@379c7fce40b4:/workspace $
|
||||
input = re.sub(r'(openhands|root)@.*(:/.*)', r'\1[DUMMY_HOSTNAME]\2', input)
|
||||
|
||||
# mask the specific part in a poetry path
|
||||
input = re.sub(
|
||||
r'(/open[a-z]{5}/poetry/open[a-z]{5}-)[a-zA-Z0-9-]+(-py3\.\d+/bin/python)',
|
||||
r'\1[DUMMY_STRING]\2',
|
||||
input,
|
||||
)
|
||||
|
||||
# handle size param
|
||||
input = re.sub(r' size=\d+ ', ' size=[DUMMY_SIZE] ', input)
|
||||
|
||||
# handle sha256 hashes
|
||||
# sha256=4ecf8be428f55981e2a188f510ba5f9022bed88f5fb404d7d949f44382201e3d
|
||||
input = re.sub(r'sha256=[a-z0-9]+', 'sha256=[DUMMY_HASH]', input)
|
||||
|
||||
Reference in New Issue
Block a user