MCPcopy Create free account
hub / github.com/catboost/catboost / CrashTestPrefixGrouped

Method CrashTestPrefixGrouped

library/cpp/containers/comptrie/comptrie_ut.cpp:823–842  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

821}
822
823void TCompactTrieTest::CrashTestPrefixGrouped() {
824 TCompactTrieBuilder<char, ui32> builder(CTBF_PREFIX_GROUPED);
825 const char* data[] = {
826 "Fryazino",
827 "Fryanovo",
828 "Monino",
829 "",
830 "Fryazevo",
831 };
832 bool wasException = false;
833 try {
834 for (size_t i = 0; i < Y_ARRAY_SIZE(data); ++i) {
835 builder.Add(data[i], strlen(data[i]), i + 1);
836 }
837 } catch (const yexception& e) {
838 wasException = true;
839 UNIT_ASSERT(strstr(e.what(), "Bad input order - expected input strings to be prefix-grouped."));
840 }
841 UNIT_ASSERT_C(wasException, "CrashTestPrefixGrouped");
842}
843
844void TCompactTrieTest::TestMergeFromFile() {
845 {

Callers

nothing calls this directly

Calls 3

strstrFunction · 0.50
AddMethod · 0.45
whatMethod · 0.45

Tested by

no test coverage detected