MCPcopy Create free account
hub / github.com/GraphLite-AI/GraphLite / test_function_planning

Function test_function_planning

graphlite/tests/function_tests.rs:507–527  ·  view source on GitHub ↗
()

Source from the content-addressed store, hash-verified

505
506#[test]
507fn test_function_planning() {
508 let fixture = TestFixture::new().expect("Failed to create test fixture");
509 // Setup fresh graph for this test to avoid interference
510 fixture
511 .setup_graph("test_function_planning")
512 .expect("Failed to setup graph");
513 // Re-insert fraud data since we have a fresh graph
514 fixture
515 .insert_fraud_data()
516 .expect("Failed to insert fraud data");
517
518 // Test query with function using fraud data
519 let _ = fixture.assert_query_succeeds("MATCH (a:Account) RETURN COUNT(a.id) as account_count");
520
521 // Verify we get the expected count from fraud data (50 accounts)
522 fixture.assert_first_value(
523 "MATCH (a:Account) RETURN COUNT(a.id) as account_count",
524 "account_count",
525 Value::Number(50.0),
526 );
527}
528
529#[test]
530fn test_multiple_functions_planning() {

Callers

nothing calls this directly

Calls 4

setup_graphMethod · 0.80
insert_fraud_dataMethod · 0.80
assert_first_valueMethod · 0.80
assert_query_succeedsMethod · 0.45

Tested by

no test coverage detected