Update tests/test_utils_elog.py
Run CI Tests / test (push) Successful in 1m25s

This commit is contained in:
2025-08-07 01:13:30 +02:00
parent eeb9c89816
commit 00d2cfba90
+2 -11
View File
@@ -26,16 +26,6 @@ def get_default_elog_password(url, **kwargs):
kwargs["password"] = pw
return kwargs["password"]
def test_check_required_attributes():
url = "http://localhost:8080/demo?cmd=Config"
response = requests.get(url, auth=("robot", "testpassword"))
print("AAAAAAAAAAAAAAAAAAAAA : ", response.text, file=sys.__stdout__) # Cherchez "Required Attributes" dans l'output
def test_post():
logbook = elog.open('localhost', 'demo', port=8080, use_ssl=False)
new_msg_id = logbook.post('This is message text', author='me', type='Routine')
print("BBBBBBBBBBBBBBBBBBBBB : ", new_msg_id, file=sys.__stdout__)
# Connexion basique avec credentials connus
def get_test_elog():
return Elog("http://localhost:8080/demo", user="robot", password="testpassword")
@@ -115,7 +105,8 @@ def test_post():
print("RRRRRRRRRRRRRRRRRRR : ", resp, file=sys.__stdout__)
assert resp is not None
url = f"http://localhost:8080/demo/{resp}"
base_url = "http://localhost:8080/demo"
url = f"{base_url}?cmd=Submit"
html = requests.get(url).text
assert text in html, "Message not found"