trustgraph/tests/unit
cybermaggedon bb1109963c
Remove spurious workspace parameter from SPARQL algebra evaluator (#915)
Fix threading of workspace paramater:
- The SPARQL algebra evaluator was threading a workspace parameter
  through every function and passing it to TriplesClient.query(),
  which doesn't accept it. Workspace isolation is handled by pub/sub
  topic routing — the TriplesClient is already scoped to a
  workspace-specific flow, same as GraphRAG. Passing workspace
  explicitly was both incorrect and unnecessary.

Update tests:
- tests/unit/test_query/test_sparql_algebra.py (new) — Tests
  _query_pattern, _eval_bgp, and evaluate() with various algebra
  nodes. Key tests assert workspace is never in tc.query() kwargs,
  plus correctness tests for BGP, JOIN, UNION, SLICE, DISTINCT, and
  edge cases.
- tests/unit/test_retrieval/test_graph_rag.py — Added
  test_triples_query_never_passes_workspace (checks query()) and
  test_follow_edges_never_passes_workspace (checks query_stream()).
2026-05-14 12:03:43 +01:00
..
test_agent feat: workspace-based multi-tenancy, replacing user as tenancy axis (#840) 2026-04-21 23:23:01 +01:00
test_base Recent fixes -> release/v2.4 (#891) 2026-05-08 19:48:12 +01:00
test_chunking Per-flow librarian clients and per-workspace response queues (#865) 2026-05-06 12:01:01 +01:00
test_cli feat: workspace-based multi-tenancy, replacing user as tenancy axis (#840) 2026-04-21 23:23:01 +01:00
test_clients feat: workspace-based multi-tenancy, replacing user as tenancy axis (#840) 2026-04-21 23:23:01 +01:00
test_concurrency feat: workspace-based multi-tenancy, replacing user as tenancy axis (#840) 2026-04-21 23:23:01 +01:00
test_config Structure data mvp (#452) 2025-08-07 20:47:20 +01:00
test_cores Per-workspace queue routing for workspace-scoped services (#862) 2026-05-04 10:30:03 +01:00
test_decoding Per-flow librarian clients and per-workspace response queues (#865) 2026-05-06 12:01:01 +01:00
test_direct feat: workspace-based multi-tenancy, replacing user as tenancy axis (#840) 2026-04-21 23:23:01 +01:00
test_embeddings Fix Ollama async issue (#854) 2026-04-28 15:43:04 +01:00
test_extract test(ontology): harden domain/range validation + add missing tests (#848) 2026-04-28 16:37:42 +01:00
test_gateway Per-workspace queue routing for workspace-scoped services (#862) 2026-05-04 10:30:03 +01:00
test_knowledge_graph feat: workspace-based multi-tenancy, replacing user as tenancy axis (#840) 2026-04-21 23:23:01 +01:00
test_librarian Per-workspace queue routing for workspace-scoped services (#862) 2026-05-04 10:30:03 +01:00
test_provenance feat: workspace-based multi-tenancy, replacing user as tenancy axis (#840) 2026-04-21 23:23:01 +01:00
test_pubsub Test fixes for Kafka (#834) 2026-04-18 23:06:01 +01:00
test_query Remove spurious workspace parameter from SPARQL algebra evaluator (#915) 2026-05-14 12:03:43 +01:00
test_rdf Pub/sub abstraction: decouple from Pulsar (#751) 2026-04-01 20:16:53 +01:00
test_reliability Per-workspace queue routing for workspace-scoped services (#862) 2026-05-04 10:30:03 +01:00
test_retrieval Remove spurious workspace parameter from SPARQL algebra evaluator (#915) 2026-05-14 12:03:43 +01:00
test_rev_gateway Fix tests (#593) 2025-12-19 08:53:21 +00:00
test_storage Recent fixes -> release/v2.4 (#891) 2026-05-08 19:48:12 +01:00
test_structured_data feat: workspace-based multi-tenancy, replacing user as tenancy axis (#840) 2026-04-21 23:23:01 +01:00
test_tables feat: workspace-based multi-tenancy, replacing user as tenancy axis (#840) 2026-04-21 23:23:01 +01:00
test_text_completion Fixed document-rag workspace problem (#866) 2026-05-06 14:55:21 +01:00
test_translators Per-workspace queue routing for workspace-scoped services (#862) 2026-05-04 10:30:03 +01:00
__init__.py Test suite executed from CI pipeline (#433) 2025-07-14 14:57:44 +01:00
test_prompt_manager.py Feature/prompts jsonl (#619) 2026-01-26 17:38:00 +00:00
test_prompt_manager_edge_cases.py Update to enable knowledge extraction using the agent framework (#439) 2025-07-21 14:31:57 +01:00
test_python_api_client.py Add agent explainability instrumentation and unify envelope field naming (#795) 2026-04-13 16:16:42 +01:00