Expand description
Shared test setup utilities for text-document crate tests.
Provides helpers to create an in-memory document with content,
export text, and traverse the entity tree. This crate depends only
on common and direct_access — it reimplements plain-text import
and export directly via entity controllers, so it does not depend
on document_io or any feature crate, breaking the circular
dev-dependency chain.
Modules§
Structs§
- Basic
Stats - Basic document statistics retrieved directly from entity data.
- Create
Block Dto - Create
Document Dto - Create
Frame Dto - Create
Inline Element Dto - Create
Root Dto
Enums§
Functions§
- export_
text - Export the current document as plain text by reading blocks and
concatenating their
plain_textfields with\nseparators. - get_
block_ ids - Get the first frame’s block IDs.
- get_
document_ stats - Get basic document statistics by reading the Document entity directly.
- get_
element_ ids - Get the element IDs for a given block.
- get_
first_ block_ element_ ids - Get the first block’s element IDs.
- get_
frame_ id - Get the first frame ID for the document.
- setup
- Create an in-memory database with a Root and empty Document.
- setup_
with_ text - Create an in-memory database with a Root, Document, and imported text content.