This commit is contained in:
rm 2024-03-22 18:31:20 +08:00
parent 3b465b1c78
commit a3da445577
3 changed files with 16 additions and 3 deletions

View File

@ -207,7 +207,7 @@ http://pt.zhixing.bjtu.edu.cn/ | ZXPT【知行PT】
| https://pt.itzmx.com/ | ITZMX【PT分享站】 || | https://pt.itzmx.com/ | ITZMX【PT分享站】 ||
| https://pt.gtk.pw/ | PT GTK || | https://pt.gtk.pw/ | PT GTK ||
| https://www.skyey2.com/ | SkyeySnow【天雪论坛】 | 高清动漫 | | https://www.skyey2.com/ | SkyeySnow【天雪论坛】 | 高清动漫 |
| https://52pt.site/index.php | 我爱PT | 养生,无任务,佛系 | | https://52pt.site/index.php | 我爱PT (现在关闭注册了) | 养生,无任务,佛系 |
### 顶级外站18 ### 顶级外站18

View File

@ -59,7 +59,10 @@ class PtOperation:
url = url + "/attendance.php" url = url + "/attendance.php"
for _ in range(5): for _ in range(5):
try: try:
print(url)
response_result = requests.get(url, headers=self.headers) response_result = requests.get(url, headers=self.headers)
print(response_result.text)
print(response_result.status_code)
if response_result.status_code == 200: if response_result.status_code == 200:
res_txt = res_txt + '签到成功!' res_txt = res_txt + '签到成功!'
logger.info(res_txt) logger.info(res_txt)

View File

@ -4,6 +4,11 @@ from PT.pt_operation import PtOperation
def attendances_junit(name): def attendances_junit(name):
"""
PT签到测试
:param name:
:return:
"""
with open('../PT/pt_config.toml', 'r', encoding='utf-8') as file: with open('../PT/pt_config.toml', 'r', encoding='utf-8') as file:
config_data = toml.load(file) config_data = toml.load(file)
# 迭代每个 section # 迭代每个 section
@ -14,6 +19,11 @@ def attendances_junit(name):
def signup_junit(name): def signup_junit(name):
"""
PT开注测试
:param name:
:return:
"""
with open('../PT/pt_config.toml', 'r', encoding='utf-8') as file: with open('../PT/pt_config.toml', 'r', encoding='utf-8') as file:
config_data = toml.load(file) config_data = toml.load(file)
# 迭代每个 section # 迭代每个 section
@ -23,5 +33,5 @@ def signup_junit(name):
PtOperation().signup(section_name, section_data) PtOperation().signup(section_name, section_data)
# attendances_junit("icc2022") attendances_junit("btschool")
signup_junit("1PTBar/壹PT") # signup_junit("1PTBar/壹PT")