Add test_query_error_does_not_oob
This commit is contained in:
parent
2a9d951cd6
commit
67f4f2328c
1 changed files with 16 additions and 0 deletions
|
|
@ -4575,3 +4575,19 @@ fn test_query_max_start_depth() {
|
|||
}
|
||||
});
|
||||
}
|
||||
|
||||
#[test]
|
||||
fn test_query_error_does_not_oob() {
|
||||
let language = get_language("javascript");
|
||||
|
||||
assert_eq!(
|
||||
Query::new(language, "(clas").unwrap_err(),
|
||||
QueryError {
|
||||
row: 0,
|
||||
offset: 1,
|
||||
column: 1,
|
||||
kind: QueryErrorKind::NodeType,
|
||||
message: "clas".to_string()
|
||||
}
|
||||
);
|
||||
}
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue