MCPcopy Create free account
hub / github.com/apache/datafusion / test_insert_all

Function test_insert_all

datafusion/optimizer/src/join_key_set.rs:255–271  ·  view source on GitHub ↗
()

Source from the content-addressed store, hash-verified

253
254 #[test]
255 fn test_insert_all() {
256 let mut set = JoinKeySet::new();
257
258 // insert (a=b), (b=c), (b=a)
259 set.insert_all(vec![
260 &(col("a"), col("b")),
261 &(col("b"), col("c")),
262 &(col("b"), col("a")),
263 ]);
264 assert_eq!(set.len(), 2);
265 assert!(set.contains(&col("a"), &col("b")));
266 assert!(set.contains(&col("b"), &col("c")));
267 assert!(set.contains(&col("b"), &col("a")));
268
269 // should not contain (a=c)
270 assert!(!set.contains(&col("a"), &col("c")));
271 }
272
273 #[test]
274 fn test_insert_all_owned() {

Callers

nothing calls this directly

Calls 2

newFunction · 0.85
insert_allMethod · 0.80

Tested by

no test coverage detected

Used in the wild real call sites across dependent graphs

searching dependent graphs…