Welcome to mirror list, hosted at ThFree Co, Russian Federation.

coder_util_test.cpp « coding_tests « coding - github.com/mapsme/omim.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
blob: ff693e300982c6c1f14b998c48eb0691b0ad84b7 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
#include "testing/testing.hpp"

#include "coding/coder_util.hpp"
#include "base/logging.hpp"

//namespace
//{
//  size_t FixedDstSizeInfiniteMemoryEncode(char const *, size_t, char *, size_t /*dstSize*/)
//  {
//    // LOG(LINFO, ("DstSize", dstSize));
//    return -1U;
//  }
//}

/* Commented because takes too much time after memory upgrage :)
UNIT_TEST(FixedDstSizeCodeToStringInfiniteMemoryTest)
{
  bool thrownDstOutOfMemoryStringCodingException = false;
  try
  {
    char const src [] = "Test";
    string dst;
    FixedDstSizeCodeToString(&FixedDstSizeInfiniteMemoryEncode, src, 4, dst);
  }
  catch (DstOutOfMemoryStringCodingException & e)
  {
    thrownDstOutOfMemoryStringCodingException = true;
  }
  TEST(thrownDstOutOfMemoryStringCodingException, ());
}
*/