MCPcopy Create free account
hub / github.com/apache/fory / test_encode

Function test_encode

python/pyfory/tests/profiling.py:32–38  ·  view source on GitHub ↗

add enable cython profile directive to lib.pxi for profiling

()

Source from the content-addressed store, hash-verified

30
31@pytest.mark.skip(reason="take too long")
32def test_encode():
33 """add enable cython profile directive to lib.pxi for profiling"""
34 encoder = fory.create_row_encoder(foo_schema())
35 foo = create_foo()
36 iter_nums = 100000
37 for _ in range(iter_nums):
38 encoder.to_row(foo)
39
40
41if __name__ == "__main__":

Callers 1

profiling.pyFile · 0.70

Calls 3

foo_schemaFunction · 0.90
create_fooFunction · 0.90
to_rowMethod · 0.45

Tested by

no test coverage detected