Skip to content

Commit 2c2d9b0

Browse files
author
Joshua Nelson
committed
add (failing) test for resizing the out_buffer
1 parent 0ccd7a2 commit 2c2d9b0

File tree

1 file changed

+3
-0
lines changed

1 file changed

+3
-0
lines changed

src/simple_api/mod.rs

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -2096,6 +2096,9 @@ pub(crate) mod tests {
20962096
let vars = vec!["hello"; YDB_MAX_NAMES as usize + 1];
20972097
let err = delete_excl_st(YDB_NOTTP, Vec::new(), &vars).unwrap_err();
20982098
assert_eq!(err.status, YDB_ERR_NAMECOUNT2HI);
2099+
2100+
// Passing a buffer that has insufficient capacity for an error should resize the buffer
2101+
delete_excl_st(YDB_NOTTP, Vec::with_capacity(1), &["^global"]).unwrap();
20992102
}
21002103

21012104
#[test]

0 commit comments

Comments
 (0)