tests: add tests to chat memory component (#3039)

* ♻️ (crud.py): refactor delete_vertex_builds_by_flow_id function to correctly delete vertex builds by flow_id using relationship attribute instead of column comparison.

* 📝 (generalBugs-shard-0.spec.ts): Remove unnecessary test case and add new test case for chat messages clearing functionality
✨ (generalBugs-shard-8.spec.ts): Add new test case for interacting with API request
✨ (generalBugs-shard-9.spec.ts): Add new test case for testing chat memory functionality
This commit is contained in:
Cristhian Zanforlin Lousa 2024-07-29 18:22:26 -03:00 • committed by GitHub
commit 1710bca2b6
No known key found for this signature in database
GPG key ID: B5690EEEBB952194
4 changed files with 226 additions and 41 deletions

View file

@ -32,5 +32,5 @@ def log_vertex_build(db: Session, vertex_build: VertexBuildBase) -> VertexBuildT
def delete_vertex_builds_by_flow_id(db: Session, flow_id: UUID) -> None:
delete(VertexBuildTable).where(col(VertexBuildTable.flow_id == flow_id))
delete(VertexBuildTable).where(VertexBuildTable.flow.has(id=flow_id)) # type: ignore
db.commit()