Skip to content

test(tree): Whole-document text test suite#27593

Open
brrichards wants to merge 3 commits into
microsoft:mainfrom
brrichards:text-profile
Open

test(tree): Whole-document text test suite#27593
brrichards wants to merge 3 commits into
microsoft:mainfrom
brrichards:text-profile

Conversation

@brrichards

@brrichards brrichards commented Jun 24, 2026

Copy link
Copy Markdown
Contributor

Description

Adds onto the testing suite for plain/formatted text in textDomain.integration.bench.ts. Includes helpers and setup for the 7 tests. Tests against multiple sized documents of N-character sizes. The tests include these performance and memory tests:

  1. Summary size
  2. Fresh document size (no edits/history)
  3. Forest footprint (chunked forest)
  4. full string read time
  5. editing time (done in middle of the doc)
  6. hydrated vs unhydrated views
  7. load time from summary

Reviewer Guidance

The review process is outlined on this wiki page.

@github-actions

github-actions Bot commented Jun 24, 2026

Copy link
Copy Markdown
Contributor

Hi! Thank you for opening this PR. Want me to review it?

Based on the diff (446 lines, 1 files), I've queued these reviewers:

  • Correctness — logic errors, race conditions, lifecycle issues
  • Security — vulnerabilities, secret exposure, injection
  • API Compatibility — breaking changes, release tags, type design
  • Performance — algorithmic regressions, memory leaks
  • Testing — coverage gaps, hollow tests

How this works

  • Adjust the reviewer set by ticking/unticking boxes above. Reviewer toggles alone don't trigger anything.

  • Tick Start review below to dispatch the review fleet.

  • After review finishes, tick Start review again to request another run — it auto-resets after each dispatch.

  • This comment updates as new commits land; your reviewer selections are preserved.

  • Start review

Copilot AI left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

Copilot reviewed 1 out of 1 changed files in this pull request and generated no comments.

Comment thread packages/dds/tree/src/test/shared-tree/textDomain.integration.bench.ts Outdated
Comment thread packages/dds/tree/src/test/shared-tree/textDomain.integration.bench.ts Outdated
Comment thread packages/dds/tree/src/test/shared-tree/textDomain.integration.bench.ts Outdated

/* The SharedTree factory the summary-size and load benchmarks build on. */
const wholeDocumentTreeFactory = configuredSharedTree({
forest: ForestTypeOptimized,

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

Would there be any value in running these benchmarks against both the optimized format and the object format?

@brrichards brrichards Jun 24, 2026

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.

I don't see a downside. Should we complete this work - comparison forest and then use it for this scenario?

Comment thread packages/dds/tree/src/test/shared-tree/textDomain.integration.bench.ts Outdated
@github-actions

Copy link
Copy Markdown
Contributor

Bundle size comparison

Base commit: 04b4f16219306a0e842275e9fc74aaf1ee2b1f07
Head commit: 41e27b7f43b98572b78a941996a8cd707a2cbc3c

Notable changes

  • 🟢 fluidFramework.js: parsed 400682 → 392090 (-8592), gzip 112426 → 111132 (-1294)
  • 🟢 sharedTree.js: parsed 390069 → 381470 (-8599), gzip 109845 → 108528 (-1317)
Per-bundle deltas

@fluid-example/bundle-size-tests

  • azureClient.js: parsed 618524 → 618989 (+465), gzip 164716 → 164838 (+122)
  • odspClient.js: parsed 591826 → 591823 (-3), gzip 158880 → 158923 (+43)
  • aqueduct.js: parsed 525444 → 525498 (+54), gzip 140676 → 140718 (+42)
  • 🟢 fluidFramework.js: parsed 400682 → 392090 (-8592), gzip 112426 → 111132 (-1294)
  • 🟢 sharedTree.js: parsed 390069 → 381470 (-8599), gzip 109845 → 108528 (-1317)
  • containerRuntime.js: parsed 303794 → 303827 (+33), gzip 83176 → 83197 (+21)
  • sharedString.js: parsed 175965 → 175991 (+26), gzip 49437 → 49453 (+16)
  • experimentalSharedTree.js: parsed 160779 → 160798 (+19), gzip 45795 → 45804 (+9)
  • matrix.js: parsed 159826 → 159852 (+26), gzip 45404 → 45418 (+14)
  • loader.js: parsed 145288 → 145235 (-53), gzip 39057 → 39067 (+10)
  • odspDriver.js: parsed 104404 → 104452 (+48), gzip 32635 → 32657 (+22)
  • directory.js: parsed 66597 → 66623 (+26), gzip 18525 → 18540 (+15)
  • 748.js: parsed 58793 → 58793 (0), gzip 17826 → 17826 (0)
  • map.js: parsed 46690 → 46716 (+26), gzip 14303 → 14318 (+15)
  • odspPrefetchSnapshot.js: parsed 45642 → 45664 (+22), gzip 15268 → 15284 (+16)
  • 594.js: parsed 44493 → 44493 (0), gzip 13744 → 13744 (0)
  • summarizerDelayLoadedModule.js: parsed 30753 → 30753 (0), gzip 7767 → 7767 (0)
  • socketModule.js: parsed 26416 → 26493 (+77), gzip 7866 → 7891 (+25)
  • createNewModule.js: parsed 12480 → 12480 (0), gzip 4786 → 4786 (0)
  • summaryModule.js: parsed 3797 → 3797 (0), gzip 1860 → 1860 (0)
  • connectionState.js: parsed 724 → 724 (0), gzip 429 → 429 (0)
  • sharedTreeAttributes.js: parsed 666 → 673 (+7), gzip 431 → 442 (+11)
  • debugAssert.js: parsed 429 → 429 (0), gzip 299 → 299 (0)
  • FluidFramework-HashFallback.js: parsed 422 → 422 (0), gzip 316 → 316 (0)

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