Test results - Get multiple
- TypeScript
- Python
The function getTestResults()
retrieves a list of test results for a pipeline.
The function get_test_results()
retrieves a list of test results for a pipeline.
Arguments
Return value
This endpoint returns an array of TestResult
objects for the provided pipeline. View the types list above for the
full property breakdown of a TestResult
object.
caution
The objects returned by this endpoint are thin representations of test results. The type of these objects is TestResult
.
They do not contain the same level of depth as the deeply-nested object returned by the getTestResult
endpoint.
To get a deeply-nested object, use the getTestResult
function after retrieving the list of test results.
Example
typescript
import {init ,getTestResults } from "@gentrace/core";consttestResults = awaitgetTestResults ("my-pipeline");
python
import osimport gentracegentrace.init(api_key=os.getenv("GENTRACE_API_KEY"))results = gentrace.get_test_results(pipeline_slug="example-pipeline")for result in results:print(result.get("id"))