()
| 388 | |
| 389 | #[test] |
| 390 | fn test_lpad_rpad() { |
| 391 | let conn = Connection::open_in_memory().unwrap(); |
| 392 | register_string_functions(&conn).unwrap(); |
| 393 | |
| 394 | let result: String = conn.query_row( |
| 395 | "SELECT lpad('hello', 8, 'x')", |
| 396 | [], |
| 397 | |row| row.get(0) |
| 398 | ).unwrap(); |
| 399 | assert_eq!(result, "xxxhello"); |
| 400 | |
| 401 | let result: String = conn.query_row( |
| 402 | "SELECT rpad('hello', 8, 'x')", |
| 403 | [], |
| 404 | |row| row.get(0) |
| 405 | ).unwrap(); |
| 406 | assert_eq!(result, "helloxxx"); |
| 407 | } |
| 408 | } |
nothing calls this directly
no test coverage detected