mirror of
https://github.com/mirror/wget.git
synced 2025-03-23 00:00:14 +08:00
create mode 100644 testenv/conf/__init__.py create mode 100644 testenv/conf/authentication.py create mode 100644 testenv/conf/expect_header.py create mode 100644 testenv/conf/expected_files.py create mode 100644 testenv/conf/expected_ret_code.py create mode 100644 testenv/conf/files_crawled.py create mode 100644 testenv/conf/hook_sample.py create mode 100644 testenv/conf/local_files.py create mode 100644 testenv/conf/reject_header.py create mode 100644 testenv/conf/response.py create mode 100644 testenv/conf/rule_sample.py create mode 100644 testenv/conf/send_header.py create mode 100644 testenv/conf/server_conf.py create mode 100644 testenv/conf/server_files.py create mode 100644 testenv/conf/urls.py create mode 100644 testenv/conf/wget_commands.py
14 lines
420 B
Python
14 lines
420 B
Python
from exc.test_failed import TestFailed
|
|
from conf import hook
|
|
|
|
|
|
@hook(alias='ExpectedRetcode')
|
|
class ExpectedRetCode:
|
|
def __init__(self, retcode):
|
|
self.retcode = retcode
|
|
|
|
def __call__(self, test_obj):
|
|
if test_obj.act_retcode != self.retcode:
|
|
pr = "Return codes do not match.\nExpected: " + str(self.retcode) + "\nActual: " + str(test_obj.act_retcode)
|
|
raise TestFailed (pr)
|