pub struct TestResult {
pub buffer_content: String,
pub cursor_line: u16,
pub cursor_column: u16,
pub mode_display: String,
pub edit_mode: String,
pub registers: HashMap<String, RegisterInfo>,
/* private fields */
}Expand description
Test result with assertion methods.
Fields§
§buffer_content: StringBuffer content after test.
cursor_line: u16Cursor line (0-indexed).
cursor_column: u16Cursor column (0-indexed).
mode_display: StringMode display name (e.g., “NORMAL”).
edit_mode: StringEdit mode string.
registers: HashMap<String, RegisterInfo>Register contents.
Implementations§
Source§impl TestResult
impl TestResult
Sourcepub fn log_path(&self) -> Option<&Path>
pub fn log_path(&self) -> Option<&Path>
Get the path to the server log file for debugging.
Returns None if log capture is not enabled.
Sourcepub fn assert_buffer_eq(&self, expected: &str)
pub fn assert_buffer_eq(&self, expected: &str)
Assert buffer equals expected (trimmed).
Sourcepub fn assert_buffer_contains(&self, expected: &str)
pub fn assert_buffer_contains(&self, expected: &str)
Assert buffer contains substring.
Sourcepub fn assert_cursor(&self, line: u16, col: u16)
pub fn assert_cursor(&self, line: u16, col: u16)
Assert cursor position (line, col) - 0-indexed.
Sourcepub fn assert_register(
&self,
reg: &str,
expected_content: &str,
expected_type: &str,
)
pub fn assert_register( &self, reg: &str, expected_content: &str, expected_type: &str, )
Assert register content and type.
Sourcepub fn assert_normal_mode(&self)
pub fn assert_normal_mode(&self)
Assert in normal mode.
Sourcepub fn assert_insert_mode(&self)
pub fn assert_insert_mode(&self)
Assert in insert mode.
Sourcepub fn assert_visual_mode(&self)
pub fn assert_visual_mode(&self)
Assert in visual mode.
Trait Implementations§
Auto Trait Implementations§
impl Freeze for TestResult
impl !RefUnwindSafe for TestResult
impl Send for TestResult
impl Sync for TestResult
impl Unpin for TestResult
impl UnsafeUnpin for TestResult
impl !UnwindSafe for TestResult
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more
Source§impl<T> Instrument for T
impl<T> Instrument for T
Source§fn instrument(self, span: Span) -> Instrumented<Self>
fn instrument(self, span: Span) -> Instrumented<Self>
Source§fn in_current_span(self) -> Instrumented<Self>
fn in_current_span(self) -> Instrumented<Self>
Source§impl<T> IntoRequest<T> for T
impl<T> IntoRequest<T> for T
Source§fn into_request(self) -> Request<T>
fn into_request(self) -> Request<T>
Wrap the input message
T in a tonic::Request