Skip to content

Latest commit

 

History

History
42 lines (27 loc) · 1.8 KB

DEVELOPMENT.md

File metadata and controls

42 lines (27 loc) · 1.8 KB

Development

This repository contains code that is autogenerated via the generator package.

As such, this repository should only contain development for adding or fixing tests, for improving development tooling and documentation.

Testing

Prerequisite

Export the following environment variables:

  • DD_TEST_CLIENT_API_KEY: The Datadog API key to run integration tests against
  • DD_TEST_CLIENT_APP_KEY: The Datadog Application key to run integration tests against

IMPORTANT: Do not use production keys.

Commands

This project contains BDD tests. Never run the test suite against an organization with production data.

Tests can be executed via cucumber. You can optionally add features/v<NUMBER>/<FILENAME>.feature:<LINE_NUMBER> to filter individual tests.

By default integration tests use recorded API responses stored in cassettes. To record new API responses run the tests with RECORD=true. To run integration tests against API without recording cassettes, run the tests with RECORD=none.

IMPORTANT: When creating a PR that adds or updates a test, never commit generated code, only commit test files being updated and any updated cassettes.

CI

In rare ocassions, the test suite may fail due to a corrupted cache in ruby/setup-ruby action. Please update CACHE_VERSION secret in https://github.com/DataDog/datadog-api-client-ruby/settings/secrets/actions/CACHE_VERSION with a new unique value.