Skip to content

RUM-17613: timeseries [5/5] Add integration tests for timeseries collection - #3718

Merged
satween merged 1 commit into
feature/timeseriesfrom
tvaleev/feature/RUM-17613-4-integration-tests
Aug 18, 2026
Merged

RUM-17613: timeseries [5/5] Add integration tests for timeseries collection#3718
satween merged 1 commit into
feature/timeseriesfrom
tvaleev/feature/RUM-17613-4-integration-tests

Conversation

@satween

@satween satween commented Aug 14, 2026

Copy link
Copy Markdown
Contributor

What does this PR do?

Adds TimeseriesTrackingPlaygroundActivity and an instrumented TimeseriesCollectionTest that run
the 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 excludes
tools:unit, a JVM-only test module that must not land on the Android test classpath; gson and
jUnit4 are added as testFixturesImplementation so the androidTest consumer still has them at
runtime.

Requires a connected device or emulator on API 24+:
./gradlew :instrumented:integration:connectedDebugAndroidTest. Verified on API 28 — both tests
pass, three consecutive runs. The suite cannot run on API 23: every AssertJ assertion dies in
ConfigurationProvider.<clinit> with NoClassDefFoundError: Ljava/util/Spliterators;. That is not
specific to this PR — the pre-existing security.EncryptionTest fails identically on the same AVD.

Review checklist (to be filled by reviewers)

  • Feature or bugfix MUST have appropriate tests (unit, integration, e2e)
  • Make sure you discussed the feature or bugfix with the maintaining team in an Issue
  • Make sure each commit and the PR mention the Issue number (cf the CONTRIBUTING doc)

Ref: RUM-17613

@datadog-prod-us1-4

datadog-prod-us1-4 Bot commented Aug 14, 2026

Copy link
Copy Markdown

Tests

🎉 All green!

🧪 All tests passed
❄️ No new flaky tests detected

🎯 Code Coverage (details)
Patch Coverage: 100.00%
Overall Coverage: 72.82% (+0.00%)

This comment will be updated automatically if new data arrives.
🔗 Commit SHA: 77f6e7e | Docs | View more details | Give us feedback!

@codecov-commenter

codecov-commenter commented Aug 14, 2026

Copy link
Copy Markdown

Codecov Report

✅ All modified and coverable lines are covered by tests.
✅ Project coverage is 73.31%. Comparing base (d3594b5) to head (77f6e7e).

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     

see 41 files with indirect coverage changes

🚀 New features to boost your workflow:
  • ❄️ Test Analytics: Detect flaky tests, report on failures, and find test suite problems.

@satween
satween force-pushed the tvaleev/feature/RUM-17613-4-integration-tests branch from 94ca6d7 to b3faf94 Compare August 14, 2026 15:04
@satween
satween marked this pull request as ready for review August 14, 2026 15:21
@satween
satween requested review from a team as code owners August 14, 2026 15:21
@satween satween changed the title RUM-17613: Add integration tests for timeseries collection RUM-17613: timeseries [4/4] Add integration tests for timeseries collection Aug 14, 2026

@chatgpt-codex-connector chatgpt-codex-connector Bot left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

💡 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".

Comment thread instrumented/integration/build.gradle.kts Outdated
Comment on lines +29 to +30

@RunWith(AndroidJUnit4::class)

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

P2 Badge 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 👍 / 👎.

@satween
satween force-pushed the tvaleev/feature/RUM-17613-4-integration-tests branch from b3faf94 to 9d15921 Compare August 14, 2026 16:12
@satween satween changed the title RUM-17613: timeseries [4/4] Add integration tests for timeseries collection RUM-17613: timeseries [5/5] Add integration tests for timeseries collection Aug 14, 2026
@satween
satween changed the base branch from tvaleev/feature/RUM-17613-3-background-flush to tvaleev/feature/RUM-17613-3b-background-suspend August 14, 2026 16:13
@satween
satween force-pushed the tvaleev/feature/RUM-17613-4-integration-tests branch from 9d15921 to 7ddf0a4 Compare August 17, 2026 08:55

satween commented Aug 17, 2026

Copy link
Copy Markdown
Contributor Author

@satween
satween force-pushed the tvaleev/feature/RUM-17613-4-integration-tests branch from 7ddf0a4 to 73aeb50 Compare August 17, 2026 09:27

@chatgpt-codex-connector chatgpt-codex-connector Bot left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

💡 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".

@satween
satween force-pushed the tvaleev/feature/RUM-17613-4-integration-tests branch from 73aeb50 to 2952fba Compare August 17, 2026 10:45

@chatgpt-codex-connector chatgpt-codex-connector Bot left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

💡 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".

@satween
satween force-pushed the tvaleev/feature/RUM-17613-4-integration-tests branch from 2952fba to 7835320 Compare August 17, 2026 12:05
@satween
satween force-pushed the tvaleev/feature/RUM-17613-4-integration-tests branch from 7835320 to c9c08d3 Compare August 17, 2026 12:46
@satween
satween force-pushed the tvaleev/feature/RUM-17613-4-integration-tests branch from c9c08d3 to a5a624f Compare August 18, 2026 10:48
Base automatically changed from tvaleev/feature/RUM-17613-3b-background-suspend to feature/timeseries August 18, 2026 12:23
@satween
satween force-pushed the tvaleev/feature/RUM-17613-4-integration-tests branch from a5a624f to cfcd890 Compare August 18, 2026 12:23
Comment thread features/dd-sdk-android-rum/build.gradle.kts
Comment thread instrumented/integration/build.gradle.kts Outdated
@satween
satween force-pushed the tvaleev/feature/RUM-17613-4-integration-tests branch from cfcd890 to b9b52bb Compare August 18, 2026 15:20
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.
@satween
satween force-pushed the tvaleev/feature/RUM-17613-4-integration-tests branch from b9b52bb to 77f6e7e Compare August 18, 2026 15:22
android:windowSoftInputMode="adjustResize"/>
<activity
android:name=".rum.TimeseriesTrackingPlaygroundActivity"
android:label="RUM timeseries end-to-end" />

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

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")

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

is it still needed?

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

yes, as we merging timeseries with internal visibility

@satween
satween merged commit ff49591 into feature/timeseries Aug 18, 2026
23 checks passed
@satween
satween deleted the tvaleev/feature/RUM-17613-4-integration-tests branch August 18, 2026 16:49
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants