fix: Update parameter names in examples and tests for consistency with API specification
This commit is contained in:
parent
8d4fcc7d11
commit
9dce7787b1
2 changed files with 4 additions and 4 deletions
|
|
@ -98,7 +98,7 @@ def example_4_job_with_parameters():
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
additional_reference="example-import-en"
|
additional_reference="example-import-en"
|
||||||
)
|
) # Note: parameters is nested dict following API spec
|
||||||
|
|
||||||
print(f"Job started with parameters:")
|
print(f"Job started with parameters:")
|
||||||
print(f" Job Identifier: {result.jobIdentifier}")
|
print(f" Job Identifier: {result.jobIdentifier}")
|
||||||
|
|
@ -132,8 +132,8 @@ def example_5_queue_management():
|
||||||
result = client.control_job(
|
result = client.control_job(
|
||||||
job_id=123,
|
job_id=123,
|
||||||
action="start",
|
action="start",
|
||||||
queueId=queue_id,
|
queue_id=queue_id,
|
||||||
maxJobDurationSeconds=3600, # 1 hour timeout per job
|
max_job_duration_seconds=3600, # 1 hour timeout per job
|
||||||
parameters={
|
parameters={
|
||||||
"article_id": article["id"],
|
"article_id": article["id"],
|
||||||
"article_name": article["name"]
|
"article_name": article["name"]
|
||||||
|
|
|
||||||
|
|
@ -48,7 +48,7 @@ class TestRestApiAuth:
|
||||||
def test_api_token_auth_without_domain(self):
|
def test_api_token_auth_without_domain(self):
|
||||||
"""Test that API token auth requires a domain"""
|
"""Test that API token auth requires a domain"""
|
||||||
with pytest.raises(ValueError, match="Domain is required"):
|
with pytest.raises(ValueError, match="Domain is required"):
|
||||||
RestApiAuth.from_api_token("admin", "token123", None)
|
RestApiAuth.from_api_token("admin", "token123", None) # type: ignore
|
||||||
|
|
||||||
def test_json_body_params(self):
|
def test_json_body_params(self):
|
||||||
"""Test JSON body parameters"""
|
"""Test JSON body parameters"""
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue