RUM-5445: Revive Session Replay instrumentation tests#2965
Merged
jonathanmos merged 11 commits intoNov 23, 2025
Merged
Conversation
|
🎯 Code Coverage 🔗 Commit SHA: 35dcb23 | Docs | Datadog PR Page | Was this helpful? Give us feedback! |
Codecov Report✅ All modified and coverable lines are covered by tests. Additional details and impacted files@@ Coverage Diff @@
## develop #2965 +/- ##
===========================================
+ Coverage 70.79% 70.84% +0.05%
===========================================
Files 829 829
Lines 30384 30383 -1
Branches 5184 5184
===========================================
+ Hits 21510 21524 +14
+ Misses 7392 7374 -18
- Partials 1482 1485 +3
🚀 New features to boost your workflow:
|
d1e3d5b to
495db93
Compare
495db93 to
7145153
Compare
0xnm
reviewed
Nov 13, 2025
0xnm
left a comment
Member
There was a problem hiding this comment.
🚀
I left some comments, but looks good!
581ade8 to
43fd4c2
Compare
e30e333 to
e21f118
Compare
0xnm
previously approved these changes
Nov 20, 2025
0xnm
left a comment
Member
There was a problem hiding this comment.
It would be nice to have one more pair of eyes reviewing this PR.
| appendLine() | ||
|
|
||
| // Record type constants | ||
| recordTypes.forEach { (className, value) -> |
Member
There was a problem hiding this comment.
normally it is better to use KotlinPoet to generate classes, but we can keep it like that as well
0xnm
approved these changes
Nov 20, 2025
ambushwork
approved these changes
Nov 20, 2025
aleksandr-gringauz
approved these changes
Nov 20, 2025
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
What does this PR do?
This pr is a proof of concept for reviving the session replay instrumentation tests and adding the missing tests for image, text and touch privacy.
The core change here is to move from a system where we verify the individual fields in the json against "golden files", to one where we verify the existence of whole components in the output wireframe (such as the existence or absence of a placeholder) in a way that is more behavioral testing. This will make the tests device agnostic and considerably less flaky, and we would no longer need to modify the snapshots as we did before.
The test suite takes 6 minutes and 15 seconds to run locally. This seems to be mainly due to the time it takes to parse the jsons, but we could improve on this if we were able to parallelize the tests. The suite would run as part of the test pyramids.
Note: resurrecting these tests exposed a bug in checkbox rendering so in the meantime I've removed checkbox tests. This will be handled in another pr and those tests will be restored.
Motivation
Working instrumentation tests for session replay.
Additional Notes
Anything else we should know when reviewing?
Review checklist (to be filled by reviewers)