MCPcopy Create free account
hub / github.com/microsoft/debugpy / test_or

Function test_or

tests/tests/test_timeline.py:311–347  ·  view source on GitHub ↗
(make_timeline)

Source from the content-addressed store, hash-verified

309
310
311def test_or(make_timeline):
312 eggs_exp = Mark("eggs")
313 ham_exp = Mark("ham")
314 cheese_exp = Mark("cheese")
315
316 timeline, _ = make_timeline()
317 t = timeline.beginning
318
319 with timeline.frozen():
320 assert t >> (eggs_exp | ham_exp) not in timeline
321 assert t >> (ham_exp | eggs_exp) not in timeline
322 assert t >> (cheese_exp | ham_exp | eggs_exp) not in timeline
323
324 timeline.mark("eggs")
325 with timeline.frozen():
326 assert t >> (eggs_exp | ham_exp) in timeline
327 assert t >> (ham_exp | eggs_exp) in timeline
328 assert t >> (cheese_exp | ham_exp | eggs_exp) in timeline
329
330 timeline.mark("cheese")
331 with timeline.frozen():
332 assert t >> (eggs_exp | ham_exp) in timeline
333 assert t >> (ham_exp | eggs_exp) in timeline
334 assert t >> (cheese_exp | ham_exp | eggs_exp) in timeline
335
336 timeline.mark("ham")
337 with timeline.frozen():
338 assert t >> (eggs_exp | ham_exp) in timeline
339 assert t >> (ham_exp | eggs_exp) in timeline
340 assert t >> (cheese_exp | ham_exp | eggs_exp) in timeline
341 t = timeline.last
342
343 timeline.mark("cheese")
344 with timeline.frozen():
345 assert t >> (eggs_exp | ham_exp) not in timeline
346 assert t >> (ham_exp | eggs_exp) not in timeline
347 assert t >> (cheese_exp | ham_exp | eggs_exp) in timeline
348
349
350def test_xor(make_timeline):

Callers

nothing calls this directly

Calls 4

MarkFunction · 0.90
make_timelineFunction · 0.85
frozenMethod · 0.80
markMethod · 0.80

Tested by

no test coverage detected

Used in the wild real call sites across dependent graphs

searching dependent graphs…