()
| 1383 | |
| 1384 | #[test] |
| 1385 | fn config_search_defaults_off_until_enabled() { |
| 1386 | let cfg = S3BackendConfig::new("bucket", "ws", "AK", "SK"); |
| 1387 | assert!(!cfg.search_enabled); |
| 1388 | assert!(cfg.max_objects_scanned.is_none()); |
| 1389 | assert!(cfg.max_grep_bytes_per_object.is_none()); |
| 1390 | |
| 1391 | let cfg = cfg |
| 1392 | .enable_search(true) |
| 1393 | .max_objects_scanned(50) |
| 1394 | .max_grep_bytes_per_object(256 * 1024); |
| 1395 | assert!(cfg.search_enabled); |
| 1396 | assert_eq!(cfg.max_objects_scanned, Some(50)); |
| 1397 | assert_eq!(cfg.max_grep_bytes_per_object, Some(256 * 1024)); |
| 1398 | } |
| 1399 | |
| 1400 | #[test] |
| 1401 | fn backend_applies_search_defaults_when_config_omits_them() { |
nothing calls this directly
no test coverage detected