includes = ["array", "cstdint", "vector"] [cases] [cases.uint64_length_0] oil_skip = 'needs updating for treebuilder v2' # https://github.com/facebookexperimental/object-introspection/issues/318 param_types = ["std::array&"] setup = "return {{}};" expect_json = ''' [ { "staticSize": 1, "dynamicSize": 0, "exclusiveSize": 1, "length": 0, "capacity": 0, "elementStaticSize": 8 } ] ''' [cases.uint64_length_1] oil_skip = 'needs updating for treebuilder v2' # https://github.com/facebookexperimental/object-introspection/issues/318 param_types = ["std::array&"] setup = "return {{1}};" expect_json = ''' [ { "staticSize": 8, "dynamicSize": 0, "exclusiveSize": 8, "length": 1, "capacity": 1, "elementStaticSize": 8 } ] ''' [cases.uint64_length_8] oil_skip = 'needs updating for treebuilder v2' # https://github.com/facebookexperimental/object-introspection/issues/318 param_types = ["std::array&"] setup = "return {{0,1,2,3,4,5,6,7}};" expect_json = ''' [ { "staticSize": 64, "dynamicSize": 0, "length": 8, "capacity": 8, "elementStaticSize": 8 } ] ''' [cases.vector_length_1] oil_skip = 'needs updating for treebuilder v2' # https://github.com/facebookexperimental/object-introspection/issues/318 param_types = ["std::array, 1>&"] setup = "return {{std::initializer_list({1,2,3,4,5})}};" expect_json = ''' [ { "staticSize": 24, "dynamicSize": 40, "length": 1, "capacity": 1, "elementStaticSize": 24, "members": [ { "staticSize": 24, "dynamicSize": 40 } ] } ] ''' [cases.vector_length_2] oil_skip = 'needs updating for treebuilder v2' # https://github.com/facebookexperimental/object-introspection/issues/318 param_types = ["std::array, 2>&"] setup = "return {{std::initializer_list({1,2,3,4,5}), std::initializer_list({6,7,8,9})}};" expect_json = ''' [ { "staticSize": 48, "dynamicSize": 72, "exclusiveSize": 0, "length": 2, "capacity": 2, "elementStaticSize": 24, "members": [ { "staticSize": 24, "dynamicSize": 40, "exclusiveSize": 64 }, { "staticSize": 24, "dynamicSize": 32, "exclusiveSize": 56 } ] } ] '''