1 /* 2 * Tests for the libxlsxwriter library. 3 * 4 * Copyright 2014-2021, John McNamara, jmcnamara@cpan.org 5 * 6 */ 7 8 #include "../ctest.h" 9 #include "../helper.h" 10 11 #include "../../../include/xlsxwriter/utility.h" 12 13 // Test lxw_utf8_strlen(). CTEST(utility,lxw_utf8_strlen)14CTEST(utility, lxw_utf8_strlen) { 15 16 ASSERT_EQUAL(0, lxw_utf8_strlen("")); 17 ASSERT_EQUAL(3, lxw_utf8_strlen("Foo")); 18 ASSERT_EQUAL(4, lxw_utf8_strlen("café")); 19 ASSERT_EQUAL(4, lxw_utf8_strlen("cake")); 20 ASSERT_EQUAL(21, lxw_utf8_strlen("Это фраза на русском!")); 21 22 } 23 24