RUM-17613: timeseries [5/5] Add integration tests for timeseries collection - #3718
Conversation
🎉 All green!🧪 All tests passed 🎯 Code Coverage (details) 🔗 Commit SHA: 77f6e7e | Docs | View more details | Give us feedback! |
Codecov Report✅ All modified and coverable lines are covered by tests. Additional details and impacted files@@ Coverage Diff @@
## feature/timeseries #3718 +/- ##
======================================================
- Coverage 73.38% 73.31% -0.07%
======================================================
Files 1012 1012
Lines 37045 37045
Branches 6385 6385
======================================================
- Hits 27184 27159 -25
- Misses 8033 8056 +23
- Partials 1828 1830 +2 🚀 New features to boost your workflow:
|
94ca6d7 to
b3faf94
Compare
timeseries [4/4] Add integration tests for timeseries collection
There was a problem hiding this comment.
💡 Codex Review
Here are some automated review suggestions for this pull request.
Reviewed commit: b3faf94903
ℹ️ About Codex in GitHub
Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you
- Open a pull request for review
- Mark a draft as ready
- Comment "@codex review".
If Codex has suggestions, it will comment; otherwise it will react with 👍.
Codex can also answer questions or update the PR. Try commenting "@codex address that feedback".
|
|
||
| @RunWith(AndroidJUnit4::class) |
There was a problem hiding this comment.
Skip these AssertJ tests on unsupported API 23 runs
When this module's tests run on its declared minimum SDK of API 23 without the optional Java backport property, the AssertJ calls used throughout this class fail while initializing ConfigurationProvider because java.util.Spliterators is unavailable. Since @LargeTest does not impose an SDK floor, the runner still executes both tests; add an API-24 @SdkSuppress (or ensure the backport is always enabled) so the documented integration command does not add guaranteed failures on a supported test device.
Useful? React with 👍 / 👎.
b3faf94 to
9d15921
Compare
timeseries [4/4] Add integration tests for timeseries collectiontimeseries [5/5] Add integration tests for timeseries collection
9d15921 to
7ddf0a4
Compare
This stack of pull requests is managed by Graphite. Learn more about stacking. |
7ddf0a4 to
73aeb50
Compare
There was a problem hiding this comment.
💡 Codex Review
Here are some automated review suggestions for this pull request.
Reviewed commit: 73aeb50622
ℹ️ About Codex in GitHub
Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you
- Open a pull request for review
- Mark a draft as ready
- Comment "@codex review".
If Codex has suggestions, it will comment; otherwise it will react with 👍.
Codex can also answer questions or update the PR. Try commenting "@codex address that feedback".
73aeb50 to
2952fba
Compare
There was a problem hiding this comment.
💡 Codex Review
Here are some automated review suggestions for this pull request.
Reviewed commit: 2952fba4d1
ℹ️ About Codex in GitHub
Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you
- Open a pull request for review
- Mark a draft as ready
- Comment "@codex review".
If Codex has suggestions, it will comment; otherwise it will react with 👍.
Codex can also answer questions or update the PR. Try commenting "@codex address that feedback".
2952fba to
7835320
Compare
7835320 to
c9c08d3
Compare
c9c08d3 to
a5a624f
Compare
a5a624f to
cfcd890
Compare
cfcd890 to
b9b52bb
Compare
Add a playground activity and an instrumented test that assert CPU and memory timeseries are collected, flushed on backgrounding and resumed on return to foreground.
b9b52bb to
77f6e7e
Compare
| android:windowSoftInputMode="adjustResize"/> | ||
| <activity | ||
| android:name=".rum.TimeseriesTrackingPlaygroundActivity" | ||
| android:label="RUM timeseries end-to-end" /> |
There was a problem hiding this comment.
very nit: worth extracting to strings.xml for the consistency with other lines in the manifest
| * This product includes software developed at Datadog (https://www.datadoghq.com/). | ||
| * Copyright 2016-Present Datadog, Inc. | ||
| */ | ||
| @file:Suppress("INVISIBLE_MEMBER", "INVISIBLE_REFERENCE", "CheckInternal") |
There was a problem hiding this comment.
yes, as we merging timeseries with internal visibility

What does this PR do?
Adds
TimeseriesTrackingPlaygroundActivityand an instrumentedTimeseriesCollectionTestthat runthe real collection pipeline against the mock RUM server: CPU and memory batches are emitted with
the expected sample counts, leaving the foreground flushes the pending batch, nothing is collected
while backgrounded, and collection resumes on return to the foreground.
Additional Notes
The integration module consumes
testFixtures(project(":features:dd-sdk-android-rum"))and excludestools:unit, a JVM-only test module that must not land on the Android test classpath;gsonandjUnit4are added astestFixturesImplementationso the androidTest consumer still has them atruntime.
Requires a connected device or emulator on API 24+:
./gradlew :instrumented:integration:connectedDebugAndroidTest. Verified on API 28 — both testspass, three consecutive runs. The suite cannot run on API 23: every AssertJ assertion dies in
ConfigurationProvider.<clinit>withNoClassDefFoundError: Ljava/util/Spliterators;. That is notspecific to this PR — the pre-existing
security.EncryptionTestfails identically on the same AVD.Review checklist (to be filled by reviewers)
Ref: RUM-17613