()
| 289 | |
| 290 | #[tokio::test] |
| 291 | async fn sqlite_get_by_name() { |
| 292 | let store = test_store().await; |
| 293 | |
| 294 | store |
| 295 | .put("sandbox", "id-1", "my-sandbox", b"payload", None) |
| 296 | .await |
| 297 | .unwrap(); |
| 298 | |
| 299 | let record = store |
| 300 | .get_by_name("sandbox", "my-sandbox") |
| 301 | .await |
| 302 | .unwrap() |
| 303 | .unwrap(); |
| 304 | assert_eq!(record.id, "id-1"); |
| 305 | assert_eq!(record.name, "my-sandbox"); |
| 306 | assert_eq!(record.payload, b"payload"); |
| 307 | |
| 308 | let missing = store.get_by_name("sandbox", "no-such-name").await.unwrap(); |
| 309 | assert!(missing.is_none()); |
| 310 | } |
| 311 | |
| 312 | #[tokio::test] |
| 313 | async fn sqlite_get_message_by_name() { |
nothing calls this directly
no test coverage detected