Skip to main content

datacontract ci

Run tests for CI/CD pipelines. Emits GitHub Actions annotations and step summary.

datacontract ci [OPTIONS] [LOCATIONS]...
ArgumentDefaultDescription
[LOCATIONS]...The location(s) (url, s3 url, or local path) of the data contract yaml file(s).
OptionDefaultDescription
--json-schemaThe location (url or path) of the ODCS JSON Schema
--serverallThe server configuration to run the schema and quality tests. Use the key of the server object in the data contract yaml file to refer to a server, e.g., production, or all for all servers (default).
--publishThe url to publish the results after the test.
--outputSpecify the file path where the test results should be written to (e.g., './test-results/TEST-datacontract.xml').
--output-formatThe target format for the test results. Accepted values: json, junit.
--logs / --no-logs--no-logsPrint logs
--jsonoffPrint test results as JSON to stdout.
--fail-onerrorMinimum severity that causes a non-zero exit code.
--ssl-verification / --no-ssl-verification--ssl-verificationSSL verification when publishing the data contract.
--inline-references / --no-inline-references--inline-referencesResolve external references (currently: authoritativeDefinitions[type in {definition, semantics}]) in the contract and inline the fetched content from the configured entropy-data host.
--debug / --no-debugEnable debug logging
datacontract ci datacontract.yaml --output test-results.xml --output-format junit

Guide: Scheduling and CI/CD.