configModelTestRun
Requires permission biddesk:assembly:read.
Runs every saved test case of a configuration model version: passed or failed, the expected and actual bill-of-materials hashes, whether engineering is needed, the engine's violations and errors and, when the model has a released version, how each case's bill of materials differs from it, with names and units. Writes nothing. Requires Bid Desk with engineered products and permission to read assemblies.
Errors: a failed call returns a GraphQL errors entry, not a field on the result, and data may be null or partial. Read the entry's extensions.code and message; every shape and code is in the Error reference.
Example:
- GraphQL
- cURL
query ConfigModelTestRun($modelVersionId: ID!) {
configModelTestRun(modelVersionId: $modelVersionId) {
comparedToVersionNo
definitionHash
failed
modelVersionId
passed
total
cases {
name
actualBomHash
engineered
errors
expectedBomHash
key
}
}
}
curl -X POST "https://<api-host>/graphql" \
-H "Content-Type: application/json" \
-H "Authorization: Bearer $ACCESS_TOKEN" \
--data @- <<'EOF'
{
"query": "query ConfigModelTestRun($modelVersionId: ID!) {\n configModelTestRun(modelVersionId: $modelVersionId) {\n comparedToVersionNo\n definitionHash\n failed\n modelVersionId\n passed\n total\n cases {\n name\n actualBomHash\n engineered\n errors\n expectedBomHash\n key\n }\n }\n}",
"variables": {
"modelVersionId": "id"
}
}
EOF
Variables:
{
"modelVersionId": "id"
}
Response:
{
"data": {
"configModelTestRun": {
"comparedToVersionNo": 0,
"definitionHash": "string",
"failed": 0,
"modelVersionId": "id",
"passed": 0,
"total": 0,
"cases": [
{
"name": "string",
"actualBomHash": "string",
"engineered": true,
"errors": {},
"expectedBomHash": "string",
"key": "string"
}
]
}
}
}
configModelTestRun(
modelVersionId: ID!
): ConfigModelTestRun!
Arguments
configModelTestRun.modelVersionId ● ID! non-null scalar
The configuration model version.
Type
ConfigModelTestRun object
Every saved test case of a configuration model version, run on its saved definition. Reads only.