Пример #1
0
 def test_attNameStrange_timdelta_zero_timeRespecting_returnsTrue(self):
     G1 = self.provide_g1_topology()
     temporal_name = 'strange_name'
     G1 = put_same_time(G1, temporal_name)
     G2 = self.provide_g2_path_3edges()
     d = timedelta()
     gm = iso.TimeRespectingGraphMatcher(G1, G2, temporal_name, d)
     assert gm.subgraph_is_isomorphic()
Пример #2
0
 def test_notTimeRespecting_returnsFalse(self):
     G1 = self.provide_g1_topology()
     temporal_name = 'date'
     G1 = put_sequence_time(G1, temporal_name)
     G2 = self.provide_g2_path_3edges()
     d = timedelta()
     gm = iso.TimeRespectingGraphMatcher(G1, G2, temporal_name, d)
     assert not gm.subgraph_is_isomorphic()
Пример #3
0
 def test_timdelta_one_config1_returns_four_embedding(self):
     G1 = self.provide_g1_topology()
     temporal_name = 'date'
     G1 = put_time_config_1(G1, temporal_name)
     G2 = self.provide_g2_path_3edges()
     d = timedelta(days=1)
     gm = iso.TimeRespectingGraphMatcher(G1, G2, temporal_name, d)
     count_match = len(list(gm.subgraph_isomorphisms_iter()))
     assert count_match == 4