mirror of
https://github.com/JakeHillion/object-introspection.git
synced 2024-11-13 22:06:55 +00:00
35 lines
1.9 KiB
TOML
35 lines
1.9 KiB
TOML
# TODO deque capacity: https://github.com/facebookexperimental/object-introspection/issues/637
|
|
# 8 times the object size on 64-bit libstdc++; 16 times the object size or 4096 bytes, whichever is larger, on 64-bit libc++
|
|
includes = ["deque"]
|
|
[cases]
|
|
[cases.int_empty]
|
|
oil_skip = 'not implemented for treebuilder v2' # https://github.com/facebookexperimental/object-introspection/issues/316
|
|
param_types = ["const std::deque<int>&"]
|
|
setup = "return {};"
|
|
expect_json = '[{"staticSize":80, "dynamicSize":0, "length":0, "capacity":0, "elementStaticSize":4}]'
|
|
[cases.int_some]
|
|
oil_skip = 'not implemented for treebuilder v2' # https://github.com/facebookexperimental/object-introspection/issues/316
|
|
param_types = ["const std::deque<int>&"]
|
|
setup = "return {{1,2,3}};"
|
|
expect_json = '[{"staticSize":80, "dynamicSize":12, "length":3, "capacity":3, "elementStaticSize":4}]'
|
|
[cases.deque_int_empty]
|
|
oil_skip = 'not implemented for treebuilder v2' # https://github.com/facebookexperimental/object-introspection/issues/316
|
|
param_types = ["const std::deque<std::deque<int>>&"]
|
|
setup = "return {};"
|
|
expect_json = '[{"staticSize":80, "dynamicSize":0, "length":0, "capacity":0, "elementStaticSize":80}]'
|
|
[cases.deque_int_some]
|
|
oil_skip = 'not implemented for treebuilder v2' # https://github.com/facebookexperimental/object-introspection/issues/316
|
|
param_types = ["const std::deque<std::deque<int>>&"]
|
|
setup = "return {{{1,2,3},{},{4,5}}};"
|
|
expect_json = '''[{
|
|
"staticSize":80,
|
|
"dynamicSize":260,
|
|
"length":3,
|
|
"capacity":3,
|
|
"elementStaticSize":80,
|
|
"members":[
|
|
{"staticSize":80, "dynamicSize":12, "length":3, "capacity":3, "elementStaticSize":4},
|
|
{"staticSize":80, "dynamicSize":0, "length":0, "capacity":0, "elementStaticSize":4},
|
|
{"staticSize":80, "dynamicSize":8, "length":2, "capacity":2, "elementStaticSize":4}
|
|
]}]'''
|