This test should probably be off by default (but on in continuous integration) since it requires an actual DataDog API key and app key, which probably shouldn’t be publicly available to all contributors.
The test account should probably be in US3 or Europe so we also exercise the apiHost option.
@dbader will need to set up the secrets for CI, since nobody else has access to the repo settings.
We should be able to use a free account for this. Free accounts can’t submit custom metrics, but I verified they can use the API to submit standard metrics (e.g. system.cpu.user). We just need to come up with a standard metric of each type to use. (That said, it looks like none of the standard metrics are distributions, so we might not be able to test those. 😕)
We should also test with a bad API key and make sure submission fails and calls the error handler.
We should have some tests that actually send a metric to Datadog, and then verify the submission by querying Datadog for the resulting timeseries points.
This test should probably be off by default (but on in continuous integration) since it requires an actual DataDog API key and app key, which probably shouldn’t be publicly available to all contributors.
apiHost
option.system.cpu.user
). We just need to come up with a standard metric of each type to use. (That said, it looks like none of the standard metrics are distributions, so we might not be able to test those. 😕)