(
shared: &Arc<SharedState>,
cache: &Arc<PlanCache>,
entry: CatalogEntry,
label: &str,
)
| 140 | // require pages of boilerplate without adding behavioral coverage. |
| 141 | |
| 142 | fn assert_noop( |
| 143 | shared: &Arc<SharedState>, |
| 144 | cache: &Arc<PlanCache>, |
| 145 | entry: CatalogEntry, |
| 146 | label: &str, |
| 147 | ) { |
| 148 | // Plant a sentinel for "sentinel_col" and assert it survives. |
| 149 | let key = plant_sentinel(cache, "sentinel_col"); |
| 150 | let size_before = cache.len(); |
| 151 | |
| 152 | invalidate_gateway_cache_for_entry(&entry, shared); |
| 153 | |
| 154 | assert_eq!(cache.len(), size_before, "{label}: cache must not change"); |
| 155 | assert!( |
| 156 | cache.get(&key).is_some(), |
| 157 | "{label}: sentinel entry must survive" |
| 158 | ); |
| 159 | // Remove sentinel to keep cache clean for next assertion. |
| 160 | cache.invalidate_descriptor("sentinel_col", 0); |
| 161 | } |
| 162 | |
| 163 | #[tokio::test] |
| 164 | async fn no_op_variants_do_not_evict_plan_cache() { |
no test coverage detected