Skip to content
Snippets Groups Projects
Commit ca0c74eb authored by Lluis Gifre Renom's avatar Lluis Gifre Renom
Browse files

Context:

- added missing requirement
- corrected unitary test Topology
parent dcd19e78
No related branches found
No related tags found
2 merge requests!54Release 2.0.0,!34Context Scalability extensions using CockroachDB + Removal of Stateful database inside Device + other
nats-py==2.2.0
psycopg2-binary==2.9.3 psycopg2-binary==2.9.3
SQLAlchemy==1.4.40 SQLAlchemy==1.4.40
sqlalchemy-cockroachdb==1.4.3 sqlalchemy-cockroachdb==1.4.3
......
...@@ -32,11 +32,13 @@ def test_topology(context_client : ContextClient) -> None: ...@@ -32,11 +32,13 @@ def test_topology(context_client : ContextClient) -> None:
time.sleep(3) # wait for the events collector to start time.sleep(3) # wait for the events collector to start
# ----- Prepare dependencies for the test and capture related events ----------------------------------------------- # ----- Prepare dependencies for the test and capture related events -----------------------------------------------
context_client.SetContext(Context(**CONTEXT)) response = context_client.SetContext(Context(**CONTEXT))
context_uuid = response.context_uuid.uuid
event = events_collector.get_event(block=True, timeout=1.0) event = events_collector.get_event(block=True, timeout=1.0)
assert isinstance(event, ContextEvent) assert isinstance(event, ContextEvent)
assert event.event.event_type == EventTypeEnum.EVENTTYPE_CREATE assert event.event.event_type == EventTypeEnum.EVENTTYPE_CREATE
assert event.context_id.context_uuid.uuid == context_uuid
# ----- Get when the object does not exist ------------------------------------------------------------------------- # ----- Get when the object does not exist -------------------------------------------------------------------------
topology_id = TopologyId(**TOPOLOGY_ID) topology_id = TopologyId(**TOPOLOGY_ID)
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment