Skip to content

Commit

Permalink
Add sync marker coverage (#548)
Browse files Browse the repository at this point in the history
  • Loading branch information
gaogaotiantian authored Jan 29, 2025
1 parent cd54d11 commit 5ba4c64
Showing 1 changed file with 9 additions and 0 deletions.
9 changes: 9 additions & 0 deletions tests/test_basic.py
Original file line number Diff line number Diff line change
Expand Up @@ -166,6 +166,15 @@ def test_time_sanity(self):
self.assertAlmostEqual(time_events[0]["dur"], end - start, delta=0.003e6)
self.assertAlmostEqual(end - start, end_real - start_real, delta=0.003e6)

def test_sync_marker(self):
tracer = VizTracer()
tracer.start()
tracer.set_sync_marker()
fib(5)
tracer.stop()
tracer.parse()
self.assertIn("sync_marker", tracer.data["viztracer_metadata"])


class TestInstant(BaseTmpl):
def test_addinstant(self):
Expand Down

0 comments on commit 5ba4c64

Please sign in to comment.