MCPcopy Create free account
hub / github.com/KhronosGroup/KTX-Software / constructList

Method constructList

tests/unittests/unittests.cc:898–914  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

896 HashListTest() : writerVal("HashListTest"), orientationVal("ruo") { }
897
898 void constructList(bool sort) {
899 KTX_error_code result;
900
901 ktxHashList_Construct(&head);
902 result = ktxHashList_AddKVPair(&head, KTX_WRITER_KEY,
903 (ktx_uint32_t)writerVal.length() + 1,
904 writerVal.c_str());
905 EXPECT_EQ(result, KTX_SUCCESS);
906 result = ktxHashList_AddKVPair(&head, KTX_ORIENTATION_KEY,
907 (ktx_uint32_t)orientationVal.length() + 1,
908 orientationVal.c_str());
909 EXPECT_EQ(result, KTX_SUCCESS);
910 if (sort) {
911 ktxHashList_Sort(&head);
912 sorted = true;
913 }
914 }
915
916 void checkList() {
917 compareList(head, sorted);

Callers

nothing calls this directly

Calls 5

ktxHashList_ConstructFunction · 0.85
ktxHashList_AddKVPairFunction · 0.85
ktxHashList_SortFunction · 0.85
lengthMethod · 0.45
c_strMethod · 0.45

Tested by

no test coverage detected