File: test_traceid.py

package info (click to toggle)
python-aws-xray-sdk 0.95-4
  • links: PTS, VCS
  • area: main
  • in suites: forky, sid, trixie
  • size: 792 kB
  • sloc: python: 3,006; makefile: 20
file content (11 lines) | stat: -rw-r--r-- 259 bytes parent folder | download | duplicates (4)
1
2
3
4
5
6
7
8
9
10
11
from aws_xray_sdk.core.models.traceid import TraceId


def test_id_format():
    trace_id = TraceId().to_id()
    assert len(trace_id) == 35

    parts = trace_id.split(TraceId.DELIMITER)
    assert parts[0] == '1'
    int(parts[1], 16)
    int(parts[2], 16)