1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63
use super::parse; #[test] fn test_error_in_lineterminator() { let q = r#" select * from person CREATE person CONTENT { foo:'bar'}; "#; parse(q).unwrap_err(); } #[test] fn test_excessive_size() { let mut q = String::new(); q.reserve_exact(u32::MAX as usize + 40); for _ in 0..u32::MAX { q.push(' '); } q.push_str("RETURN 1;"); parse(&q).unwrap_err(); } #[test] fn empty_thing() { super::record_id("").unwrap_err(); } #[test] fn empty_block() { super::block("").unwrap_err(); } /* #[test] fn empty_range() { super::range("").unwrap_err(); } */ #[test] fn empty_duration() { super::duration("").unwrap_err(); } #[test] fn empty_datetime() { super::datetime("").unwrap_err(); } #[test] fn empty_idiom() { super::idiom("").unwrap_err(); } #[test] fn empty_expr() { super::expr("").unwrap_err(); } #[test] fn empty_json() { super::json("").unwrap_err(); }