+// © 2016 and later: Unicode, Inc. and others.
+// License & terms of use: http://www.unicode.org/copyright.html
/********************************************************************
* COPYRIGHT:
- * Copyright (c) 1997-2008, International Business Machines Corporation and
+ * Copyright (c) 1997-2016, International Business Machines Corporation and
* others. All Rights Reserved.
+ ********************************************************************
+ *
+ * File CMSGTST.C
+ *
+ * Modification History:
+ * Name Description
+ * Madhu Katragadda Creation
********************************************************************/
-/********************************************************************************
-*
-* File CMSGTST.C
-*
-* Modification History:
-* Name Description
-* Madhu Katragadda Creation
-*********************************************************************************
-*/
/* C API TEST FOR MESSAGE FORMAT */
#include "unicode/utypes.h"
#include "cintltst.h"
#include "cmsgtst.h"
#include "cformtst.h"
+#include "cmemory.h"
static const char* const txt_testCasePatterns[] = {
"Quotes '', '{', a {0,number,integer} '{'0}",
"Quotes ', {, a 1 {0}",
"Quotes ', {, a 1 {0}",
"You deposited 1 times an amount of $3,456.00 on 1/12/70",
- "{2,time,full}, for 3,456, 1 is 5:46:40 AM PT and full date is Monday, January 12, 1970",
+ "{2,time,full}, for 3,456, 1 is 5:46:40 AM Pacific Standard Time and full date is Monday, January 12, 1970",
"{1,number,percent} for 1 is 345,600%"
};
strings_initialized = FALSE;
}
+#if (U_PLATFORM == U_PF_LINUX) /* add platforms here .. */
+/* Keep the #if above in sync with the one below that has the same "add platforms here .." comment. */
+#else
/* Platform dependent test to detect if this type will return NULL when interpreted as a pointer. */
static UBool returnsNullForType(int firstParam, ...) {
UBool isNULL;
va_end(marker);
return isNULL;
}
+#endif
/* Test u_formatMessage() with various test patterns() */
static void MessageFormatTest( void )
&status, 1, 3456.00, d1);
}
if(U_FAILURE(status)){
- log_err("ERROR: failure in message format on testcase %d: %s\n", i, myErrorName(status) );
+ log_data_err("ERROR: failure in message format on testcase %d: %s (Are you missing data?)\n", i, myErrorName(status) );
continue;
}
if(u_strcmp(result, testResultStrings[i])==0){
&status, 1, 3456.00, d1);
}
if(U_FAILURE(status)){
- log_err("ERROR: failure in message format on testcase %d: %s\n", i, myErrorName(status) );
+ log_data_err("ERROR: failure in message format on testcase %d: %s (Are you missing data?)\n", i, myErrorName(status) );
continue;
}
if(u_strcmp(result, testResultStrings[i])==0){
UMessageFormat formatter = umsg_open(testCasePatterns[0],patternLength,"en_US",NULL,&ec);
if(U_FAILURE(ec)){
- log_err("umsg_open() failed for testCasePattens[%d].\n",i);
+ log_data_err("umsg_open() failed for testCasePattens[0]. -> %s (Are you missing data?)\n", u_errorName(ec));
return;
}
for(i = 0;i<cnt_testCases; i++){
UDate d2=0;
result=NULL;
- patternLength = u_strlen(testCasePatterns[i]);
-
+ // Alternate between specifying the length and using NUL-termination.
+ patternLength = ((i & 1) == 0) ? u_strlen(testCasePatterns[i]) : -1;
+
umsg_applyPattern(formatter,testCasePatterns[i],patternLength,&parseError,&ec);
if(U_FAILURE(ec)){
log_err("umsg_applyPattern() failed for testCasePattens[%d].\n",i);
austrdup(result), austrdup(testResultStrings[i]) );
}
+#if (U_PLATFORM == U_PF_LINUX) /* add platforms here .. */
+ log_verbose("Skipping potentially crashing test for mismatched varargs.\n");
+#else
+ log_verbose("Note: the next is a platform dependent test. If it crashes, add an exclusion for your platform near %s:%d\n", __FILE__, __LINE__);
+
if (returnsNullForType(1, (double)2.0)) {
/* HP/UX and possibly other platforms don't properly check for this case.
We pass in a UDate, but the function expects a UDate *. When va_arg is used,
most compilers will return NULL, but HP-UX won't do that and will return 2
- in this case. This is a platform dependent test.
+ in this case. This is a platform dependent test. It crashes on some systems.
+
+ If you get a crash here, see the definition of returnsNullForType.
This relies upon "undefined" behavior, as indicated by C99 7.15.1.1 paragraph 2
*/
else {
log_verbose("Warning: Returning NULL for a mismatched va_arg type isn't supported on this platform.\n", i);
}
+#endif
umsg_parse(formatter,result,resultLength,&count,&ec,&one,&two,&d2);
if(U_FAILURE(ec)){
u_formatMessage( "en_US", pattern, u_strlen(pattern), result, resultlength, &status, str, d);
}
if(U_FAILURE(status)){
- log_err("Error: failure in message format on test#1: %s\n", myErrorName(status));
+ log_data_err("Error: failure in message format on test#1: %s (Are you missing data?)\n", myErrorName(status));
}
else if(u_strcmp(result, expected)==0)
log_verbose("PASS: MessagFormat successful on test#1\n");
u_formatMessage( "en_US", pattern, u_strlen(pattern), result, resultlength, &status, str, 23);
}
if(U_FAILURE(status)){
- log_err("Error: failure in message format on test#2 : %s\n", myErrorName(status));
+ log_data_err("Error: failure in message format on test#2 : %s (Are you missing data?)\n", myErrorName(status));
}
else if(u_strcmp(result, expected)==0)
log_verbose("PASS: MessagFormat successful on test#2\n");
u_formatMessage( "en_US", pattern, u_strlen(pattern), result, resultlength, &status, str, 500.00);
}
if(U_FAILURE(status)){
- log_err("Error: failure in message format on test#3 : %s\n", myErrorName(status));
+ log_data_err("Error: failure in message format on test#3 : %s (Are you missing data?)\n", myErrorName(status));
}
else if(u_strcmp(result, expected)==0)
log_verbose("PASS: MessagFormat successful on test#3\n");
static void TestNewFormatAndParseAPI(void)
{
- UChar *result, tzID[4], str[25];
+ UChar *result = NULL, tzID[4], str[25];
UChar pattern[100];
UChar expected[100];
int32_t resultLengthOut, resultlength;
UCalendar *cal;
UDate d1,d;
- UDateFormat *def1;
+ UDateFormat *def1 = NULL;
UErrorCode status = U_ZERO_ERROR;
int32_t value = 0;
UChar ret[30];
u_uastrcpy(tzID, "PST");
cal=ucal_open(tzID, u_strlen(tzID), "en_US", UCAL_TRADITIONAL, &status);
if(U_FAILURE(status)){
- log_err("error in ucal_open caldef : %s\n", myErrorName(status) );
- return;
+ log_data_err("error in ucal_open caldef : %s - (Are you missing data?)\n", myErrorName(status) );
+ goto cleanup;
}
ucal_setDateTime(cal, 1999, UCAL_MARCH, 18, 0, 0, 0, &status);
d1=ucal_getMillis(cal, &status);
if(U_FAILURE(status)){
- log_err("Error: failure in get millis: %s\n", myErrorName(status) );
- return;
+ log_err("Error: failure in get millis: %s\n", myErrorName(status) );
}
log_verbose("\nTesting with pattern test#4");
resultlength=1;
fmt = umsg_open(pattern,u_strlen(pattern),"en_US",&parseError,&status);
if(U_FAILURE(status)){
- log_err("error in umsg_open : %s\n", u_errorName(status) );
- return;
+ log_data_err("error in umsg_open : %s (Are you missing data?)\n", u_errorName(status) );
+ goto cleanup;
}
result=(UChar*)malloc(sizeof(UChar) * resultlength);
austrdup(myDateFormat(def1,d)), austrdup(myDateFormat(def1,d1)) );
}
}
+cleanup:
umsg_close(fmt);
udat_close(def1);
ucal_close(cal);
int32_t resultLengthOut, resultlength;
UCalendar *cal;
UDate d1,d;
- UDateFormat *def1;
+ UDateFormat *def1 = NULL;
UErrorCode status = U_ZERO_ERROR;
int32_t value = 0;
UChar ret[30];
u_uastrcpy(tzID, "PST");
cal=ucal_open(tzID, u_strlen(tzID), "en_US", UCAL_TRADITIONAL, &status);
if(U_FAILURE(status)){
- log_err("error in ucal_open caldef : %s\n", myErrorName(status) );
+ log_data_err("error in ucal_open caldef : %s - (Are you missing data?)\n", myErrorName(status) );
}
ucal_setDateTime(cal, 1999, UCAL_MARCH, 18, 0, 0, 0, &status);
d1=ucal_getMillis(cal, &status);
if(U_FAILURE(status)){
- log_err("Error: failure in get millis: %s\n", myErrorName(status) );
+ log_data_err("Error: failure in get millis: %s - (Are you missing data?)\n", myErrorName(status) );
}
log_verbose("\nTesting with pattern test#4");
}
if(U_FAILURE(status)){
- log_err("ERROR: failure in message format test#4: %s\n", myErrorName(status));
+ log_data_err("ERROR: failure in message format test#4: %s (Are you missing data?)\n", myErrorName(status));
+ goto cleanup;
}
else if(u_strcmp(result, expected)==0)
log_verbose("PASS: MessagFormat successful on test#4\n");
u_parseMessageWithError("en_US", pattern, u_strlen(pattern), result, u_strlen(result), &parseError,&status, &d, ret, &value);
if(U_FAILURE(status)){
- log_err("ERROR: error in parsing: test#5: %s\n", myErrorName(status));
+ log_data_err("ERROR: error in parsing: test#5: %s (Are you missing data?)\n", myErrorName(status));
}
else if(value!=7 && u_strcmp(str,ret)!=0)
log_err("FAIL: Error in parseMessage on test#5 \n");
def1 = udat_open(UDAT_DEFAULT,UDAT_DEFAULT ,NULL, NULL, 0, NULL,0,&status);
if(U_FAILURE(status))
{
- log_err("error in creating the dateformat using short date and time style:\n %s\n", myErrorName(status));
+ log_data_err("error in creating the dateformat using short date and time style: %s (Are you missing data?)\n", myErrorName(status));
}else{
if(u_strcmp(myDateFormat(def1, d), myDateFormat(def1, d1))==0)
austrdup(myDateFormat(def1,d)), austrdup(myDateFormat(def1,d1)) );
}
}
+cleanup:
udat_close(def1);
ucal_close(cal);
u_uastrcpy(tzID, "PST");
cal=ucal_open(tzID, u_strlen(tzID), "en_US", UCAL_TRADITIONAL, &status);
if(U_FAILURE(status)){
- log_err("error in ucal_open caldef : %s\n", myErrorName(status) );
+ log_data_err("error in ucal_open caldef : %s - (Are you missing data?)\n", myErrorName(status) );
+ return;
}
ucal_setDateTime(cal, 1999, UCAL_MARCH, 18, 0, 0, 0, &status);
d1=ucal_getMillis(cal, &status);
if(U_FAILURE(status)){
- log_err("Error: failure in get millis: %s\n", myErrorName(status) );
+ log_data_err("Error: failure in get millis: %s - (Are you missing data?)\n", myErrorName(status) );
}
log_verbose("\nTesting with pattern test#4");
}
if(U_FAILURE(status)){
- log_err("ERROR: failure in message format test#4: %s\n", myErrorName(status));
+ log_data_err("ERROR: failure in message format test#4: %s (Are you missing data?)\n", myErrorName(status));
+ return;
}
else if(u_strcmp(result, expected)==0)
log_verbose("PASS: MessagFormat successful on test#4\n");
u_parseMessage("en_US", pattern, u_strlen(pattern), result, u_strlen(result), &status, &d, ret, &value);
if(U_FAILURE(status)){
- log_err("ERROR: error in parsing: test#5: %s\n", myErrorName(status));
+ log_data_err("ERROR: error in parsing: test#5: %s (Are you missing data?)\n", myErrorName(status));
}
else if(value!=7 && u_strcmp(str,ret)!=0)
log_err("FAIL: Error in parseMessage on test#5 \n");
def1 = udat_open(UDAT_DEFAULT,UDAT_DEFAULT ,NULL, NULL, 0, NULL,0,&status);
if(U_FAILURE(status))
{
- log_err("error in creating the dateformat using short date and time style:\n %s\n", myErrorName(status));
+ log_data_err("error in creating the dateformat using short date and time style: %s (Are you missing data?)\n", myErrorName(status));
}else{
if(u_strcmp(myDateFormat(def1, d), myDateFormat(def1, d1))==0)
ctest_resetTimeZone();
}
+/* Test message format with a Select option */
+static void TestMsgFormatSelect(void)
+{
+ UChar* str;
+ UChar* str1;
+ UErrorCode status = U_ZERO_ERROR;
+ UChar *result;
+ UChar pattern[100];
+ UChar expected[100];
+ int32_t resultlength,resultLengthOut;
+
+ str=(UChar*)malloc(sizeof(UChar) * 25);
+ u_uastrcpy(str, "Kirti");
+ str1=(UChar*)malloc(sizeof(UChar) * 25);
+ u_uastrcpy(str1, "female");
+ log_verbose("Testing message format with Select test #1\n:");
+ u_uastrcpy(pattern, "{0} est {1, select, female {all\\u00E9e} other {all\\u00E9}} \\u00E0 Paris.");
+ u_uastrcpy(expected, "Kirti est all\\u00E9e \\u00E0 Paris.");
+ resultlength=0;
+ resultLengthOut=u_formatMessage( "fr", pattern, u_strlen(pattern), NULL, resultlength, &status, str , str1);
+ if(status==U_BUFFER_OVERFLOW_ERROR)
+ {
+ status=U_ZERO_ERROR;
+ resultlength=resultLengthOut+1;
+ result=(UChar*)malloc(sizeof(UChar) * resultlength);
+ u_formatMessage( "fr", pattern, u_strlen(pattern), result, resultlength, &status, str , str1);
+ if(u_strcmp(result, expected)==0)
+ log_verbose("PASS: MessagFormat successful on Select test#1\n");
+ else{
+ log_err("FAIL: Error in MessageFormat on Select test#1\n GOT %s EXPECTED %s\n", austrdup(result),
+ austrdup(expected) );
+ }
+ free(result);
+ }
+ if(U_FAILURE(status)){
+ log_data_err("ERROR: failure in message format on Select test#1 : %s \n", myErrorName(status));
+ }
+ free(str);
+ free(str1);
+
+ /*Test a nested pattern*/
+ str=(UChar*)malloc(sizeof(UChar) * 25);
+ u_uastrcpy(str, "Noname");
+ str1=(UChar*)malloc(sizeof(UChar) * 25);
+ u_uastrcpy(str1, "other");
+ log_verbose("Testing message format with Select test #2\n:");
+ u_uastrcpy(pattern, "{0} est {1, select, female {{2,number,integer} all\\u00E9e} other {all\\u00E9}} \\u00E0 Paris.");
+ u_uastrcpy(expected, "Noname est all\\u00E9 \\u00E0 Paris.");
+ resultlength=0;
+ resultLengthOut=u_formatMessage( "fr", pattern, u_strlen(pattern), NULL, resultlength, &status, str , str1,6);
+ if(status==U_BUFFER_OVERFLOW_ERROR)
+ {
+ status=U_ZERO_ERROR;
+ resultlength=resultLengthOut+1;
+ result=(UChar*)malloc(sizeof(UChar) * resultlength);
+ u_formatMessage( "fr", pattern, u_strlen(pattern), result, resultlength, &status, str , str1, 6);
+ if(u_strcmp(result, expected)==0)
+ log_verbose("PASS: MessagFormat successful on Select test#2\n");
+ else{
+ log_err("FAIL: Error in MessageFormat on Select test#2\n GOT %s EXPECTED %s\n", austrdup(result),
+ austrdup(expected) );
+ }
+ free(result);
+ }
+ if(U_FAILURE(status)){
+ log_data_err("ERROR: failure in message format on Select test#2 : %s \n", myErrorName(status));
+ }
+ free(str);
+ free(str1);
+}
+
/* test message format with a choice option */
static void TestMsgFormatChoice(void)
{
str=(UChar*)malloc(sizeof(UChar) * 25);
u_uastrcpy(str, "MyDisk");
log_verbose("Testing message format with choice test #6\n:");
- /*There {0,choice,0#are no files|1#is one file|1<are {0,number,integer} files}.*/
- u_uastrcpy(pattern, "The disk {1} contains {0,choice,0#no files|1#one file|1<{0,number,integer} files}");
+ /*
+ * Before ICU 4.8, umsg_xxx() did not detect conflicting argument types,
+ * and this pattern had {0,number,integer} as the inner argument.
+ * The choice argument has kDouble type while {0,number,integer} has kLong (int32_t).
+ * ICU 4.8 and above detects this as an error.
+ * We changed this pattern to work as intended.
+ */
+ u_uastrcpy(pattern, "The disk {1} contains {0,choice,0#no files|1#one file|1<{0,number} files}");
u_uastrcpy(expected, "The disk MyDisk contains 100 files");
resultlength=0;
resultLengthOut=u_formatMessage( "en_US", pattern, u_strlen(pattern), NULL, resultlength, &status, 100., str);
free(result);
}
if(U_FAILURE(status)){
- log_err("ERROR: failure in message format on test#6 : %s\n", myErrorName(status));
+ log_data_err("ERROR: failure in message format on test#6 : %s (Are you missing data?)\n", myErrorName(status));
}
log_verbose("Testing message format with choice test #7\n:");
free(result);
}
if(U_FAILURE(status)){
- log_err("ERROR: failure in message format on test#7 : %s\n", myErrorName(status));
+ log_data_err("ERROR: failure in message format on test#7 : %s (Are you missing data?)\n", myErrorName(status));
}
log_verbose("Testing message format with choice test #8\n:");
free(result);
}
if(U_FAILURE(status)){
- log_err("ERROR: failure in message format on test#8 : %s\n", myErrorName(status));
+ log_data_err("ERROR: failure in message format on test#8 : %s (Are you missing data?)\n", myErrorName(status));
}
free(str);
u_parseMessage( "en_US", pattern, u_strlen(pattern), source, u_strlen(source), &status, str, &value);
if(U_FAILURE(status)){
- log_err("ERROR: failure in parse Message on test#9: %s\n", myErrorName(status));
+ log_data_err("ERROR: failure in parse Message on test#9: %s (Are you missing data?)\n", myErrorName(status));
}
else if(value==500.00 && u_strcmp(str,res)==0)
log_verbose("PASS: parseMessage successful on test#9\n");
u_parseMessage( "en_US", pattern, u_strlen(pattern), source, u_strlen(source), &status, &value, str);
if(U_FAILURE(status)){
- log_err("ERROR: failure in parse Message on test#10: %s\n", myErrorName(status));
+ log_data_err("ERROR: failure in parse Message on test#10: %s (Are you missing data?)\n", myErrorName(status));
}
else if(value==123.00 && u_strcmp(str,res)==0)
log_verbose("PASS: parseMessage successful on test#10\n");
else
log_err("FAIL: Error in parseMessage on test#10 \n");
-
-
-
}
static int32_t CallFormatMessage(const char* locale, UChar* testCasePattern, int32_t patternLength,
&status, 1, 3456.00, d1);
}
if(U_FAILURE(status)){
- log_err("ERROR: failure in message format on testcase %d: %s\n", i, myErrorName(status) );
+ log_data_err("ERROR: failure in message format on testcase %d: %s (Are you missing data?)\n", i, myErrorName(status) );
}
else if(u_strcmp(result, testResultStrings[i])==0){
log_verbose("PASS: MessagFormat successful on testcase : %d\n", i);
CallParseMessage( "en_US", pattern, u_strlen(pattern), source, u_strlen(source), &status, str, &value);
if(U_FAILURE(status)){
- log_err("ERROR: failure in parse Message on test#9: %s\n", myErrorName(status));
+ log_data_err("ERROR: failure in parse Message on test#9: %s (Are you missing data?)\n", myErrorName(status));
}
- if(value==500.00 && u_strcmp(str,res)==0)
+ else if(value==500.00 && u_strcmp(str,res)==0)
log_verbose("PASS: parseMessage successful on test#9\n");
else
- log_err("FAIL: Error in parseMessage on test#9 \n");
+ log_err("FAIL: Error in parseMessage on test#9\n");
log_verbose("\nTesting a sample for parse Message test#10\n");
CallParseMessage( "en_US", pattern, u_strlen(pattern), source, u_strlen(source), &status, &value, str);
if(U_FAILURE(status)){
- log_err("ERROR: failure in parse Message on test#10: %s\n", myErrorName(status));
+ log_data_err("ERROR: failure in parse Message on test#10: %s (Are you missing data?)\n", myErrorName(status));
}
else if(value==123.00 && u_strcmp(str,res)==0)
log_verbose("PASS: parseMessage successful on test#10\n");
result, 256, &status,
string, 1/7.0,
789.0+1000*(56+60*(34+60*12)));
+ (void)length; /* Suppress set but not used warning. */
u_austrncpy(cresult, result, sizeof(cresult));
if (strcmp(cresult, EXP) == 0) {
log_verbose("Ok: \"%s\"\n", cresult);
} else {
- log_err("FAIL: got \"%s\", expected \"%s\"\n", cresult, EXP);
+ log_data_err("FAIL: got \"%s\", expected \"%s\" -> %s (Are you missing data?)\n", cresult, EXP, u_errorName(status));
}
ctest_resetTimeZone();
int32_t length=0;
UErrorCode status = U_ZERO_ERROR;
- u_uastrncpy(pattern, PAT, sizeof(pattern)/sizeof(pattern[0]));
+ u_uastrncpy(pattern, PAT, UPRV_LENGTHOF(pattern));
/* Test umsg_open */
f1 = umsg_open(pattern,length,NULL,NULL,&status);
umsg_applyPattern(f1,pattern,(int32_t)strlen(PAT),NULL,&status);
if(U_FAILURE(status))
{
- log_err("umsg_applyPattern failed. Error %s \n",u_errorName(status));
+ log_data_err("umsg_applyPattern failed. Error %s (Are you missing data?)\n",u_errorName(status));
}
/* Test umsg_toPattern */
umsg_toPattern(f1,result,256,&status);
if(U_FAILURE(status) ){
- log_err("umsg_toPattern method failed. Error: %s \n",u_errorName(status));
+ log_data_err("umsg_toPattern method failed. Error: %s (Are you missing data?)\n",u_errorName(status));
} else {
if(u_strcmp(result,pattern)!=0){
u_UCharsToChars(result,cresult,256);
UChar result[128] = {0};
UChar expected[sizeof(expectedChars)];
- u_uastrncpy(pattern, patChars, sizeof(pattern)/sizeof(pattern[0]));
- u_uastrncpy(expected, expectedChars, sizeof(expected)/sizeof(expected[0]));
+ u_uastrncpy(pattern, patChars, UPRV_LENGTHOF(pattern));
+ u_uastrncpy(expected, expectedChars, UPRV_LENGTHOF(expected));
- u_formatMessage("en_US", pattern, 6, result, sizeof(result)/sizeof(result[0]), &status, arg);
+ u_formatMessage("en_US", pattern, 6, result, UPRV_LENGTHOF(result), &status, arg);
if (U_FAILURE(status)) {
log_err("u_formatMessage method failed. Error: %s \n",u_errorName(status));
}
}
}
+static void TestMessageWithUnusedArgNumber(void) {
+ UErrorCode errorCode = U_ZERO_ERROR;
+ U_STRING_DECL(pattern, "abc {1} def", 11);
+ UChar x[2] = { 0x78, 0 }; // "x"
+ UChar y[2] = { 0x79, 0 }; // "y"
+ U_STRING_DECL(expected, "abc y def", 9);
+ UChar result[20];
+ int32_t length;
+
+ U_STRING_INIT(pattern, "abc {1} def", 11);
+ U_STRING_INIT(expected, "abc y def", 9);
+ length = u_formatMessage("en", pattern, -1, result, UPRV_LENGTHOF(result), &errorCode, x, y);
+ if (U_FAILURE(errorCode) || length != u_strlen(expected) || u_strcmp(result, expected) != 0) {
+ log_err("u_formatMessage(pattern with only {1}, 2 args) failed: result length %d, UErrorCode %s \n",
+ (int)length, u_errorName(errorCode));
+ }
+}
+
static void TestErrorChaining(void) {
UErrorCode status = U_USELESS_COLLATOR_ERROR;
addTest(root, &TestParseMessageWithValist, "tsformat/cmsgtst/TestParseMessageWithValist");
addTest(root, &TestJ904, "tsformat/cmsgtst/TestJ904");
addTest(root, &MessageLength, "tsformat/cmsgtst/MessageLength");
+ addTest(root, &TestMessageWithUnusedArgNumber, "tsformat/cmsgtst/TestMessageWithUnusedArgNumber");
addTest(root, &TestErrorChaining, "tsformat/cmsgtst/TestErrorChaining");
+ addTest(root, &TestMsgFormatSelect, "tsformat/cmsgtst/TestMsgFormatSelect");
}
#endif /* #if !UCONFIG_NO_FORMATTING */