mirror of
https://github.com/unicode-org/icu.git
synced 2025-04-10 07:39:16 +00:00
ICU-6955 Add new test code page and test cases.
X-SVN-Rev: 26148
This commit is contained in:
parent
e0df82e538
commit
771dda07f2
5 changed files with 53 additions and 5 deletions
2
icu4c/source/test/testdata/Makefile.in
vendored
2
icu4c/source/test/testdata/Makefile.in
vendored
|
@ -123,7 +123,7 @@ TESTDT=$(TESTDATA)
|
|||
TEST_DAT_FILES=$(TESTBUILDDIR)/test.icu
|
||||
TEST_SPP_FILES=$(TESTBUILDDIR)/nfscsi.spp $(TESTBUILDDIR)/nfscss.spp $(TESTBUILDDIR)/nfscis.spp $(TESTBUILDDIR)/nfsmxs.spp $(TESTBUILDDIR)/nfsmxp.spp
|
||||
|
||||
TEST_UCM_SOURCE= test1.ucm test1bmp.ucm test3.ucm test4.ucm test4x.ucm ibm9027.ucm
|
||||
TEST_UCM_SOURCE= test1.ucm test1bmp.ucm test3.ucm test4.ucm test4x.ucm test5.ucm ibm9027.ucm
|
||||
TEST_UCM_FILES=$(TEST_UCM_SOURCE:%=$(TESTSRCDATADIR)/data/%)
|
||||
TEST_CNV_FILES=$(TEST_UCM_SOURCE:%.ucm=$(TESTBUILDDIR)/%.cnv)
|
||||
|
||||
|
|
16
icu4c/source/test/testdata/conversion.txt
vendored
16
icu4c/source/test/testdata/conversion.txt
vendored
|
@ -871,6 +871,22 @@ conversion:table(nofallback) {
|
|||
:intvector{},
|
||||
:int{1}, :int{0}, "illegal", ".", :bin{ f2 }
|
||||
}
|
||||
|
||||
//Improve code coverage for MBCS
|
||||
{
|
||||
"*test5",
|
||||
:bin{ 0506 },
|
||||
"\ufffd\x06",
|
||||
:intvector{},
|
||||
:int{1}, :int{0}, "", "?", :bin{""}
|
||||
}
|
||||
{
|
||||
"ibm-1390,swaplfnl",
|
||||
:bin{ 430e4395ecc140400fc1e115 },
|
||||
"\uff63\u30C8\u30C8\u309A\u3000\x41\u20ac\x0a",
|
||||
:intvector{ 0, 2, 4, 4, 6, 9, 10, 11 },
|
||||
:int{1}, :int{0}, "", "?", :bin{""}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
|
|
27
icu4c/source/test/testdata/test5.ucm
vendored
Normal file
27
icu4c/source/test/testdata/test5.ucm
vendored
Normal file
|
@ -0,0 +1,27 @@
|
|||
# *******************************************************************************
|
||||
# * Copyright (C) 2009, International Business Machines
|
||||
# * Corporation and others. All Rights Reserved.
|
||||
# *******************************************************************************
|
||||
#
|
||||
# test5.ucm
|
||||
#
|
||||
# Test file for MBCS conversion with three-byte codepage data.
|
||||
# Also contains extension mappings (m:n).
|
||||
|
||||
<code_set_name> "test5"
|
||||
<mb_cur_max> 3
|
||||
<mb_cur_min> 1
|
||||
<uconv_class> "MBCS"
|
||||
<subchar> \xff
|
||||
<icu:state> 0, 1:1, 5-9, ff
|
||||
<icu:state> 2:2
|
||||
<icu:state> a-f.p
|
||||
|
||||
CHARMAP
|
||||
|
||||
<U0006> \x06 |0
|
||||
|
||||
# extensions
|
||||
<U00c0> \x05+\x01\x02\x0d |0
|
||||
|
||||
END CHARMAP
|
9
icu4c/source/test/testdata/testdata.mak
vendored
9
icu4c/source/test/testdata/testdata.mak
vendored
|
@ -1,5 +1,5 @@
|
|||
#**********************************************************************
|
||||
#* Copyright (C) 1999-2008, International Business Machines Corporation
|
||||
#* Copyright (C) 1999-2009, International Business Machines Corporation
|
||||
#* and others. All Rights Reserved.
|
||||
#**********************************************************************
|
||||
#
|
||||
|
@ -28,7 +28,7 @@ ALL : "$(TESTDATAOUT)\testdata.dat"
|
|||
|
||||
TEST_RES_FILES = $(TEST_RES_SOURCE:.txt=.res)
|
||||
|
||||
"$(TESTDATAOUT)\testdata.dat" : $(TEST_RES_FILES) "$(TESTDATABLD)\casing.res" "$(TESTDATABLD)\conversion.res" "$(TESTDATABLD)\icuio.res" "$(TESTDATABLD)\mc.res" "$(TESTDATABLD)\structLocale.res" "$(TESTDATABLD)\root.res" "$(TESTDATABLD)\sh.res" "$(TESTDATABLD)\sh_YU.res" "$(TESTDATABLD)\te.res" "$(TESTDATABLD)\te_IN.res" "$(TESTDATABLD)\te_IN_REVISED.res" "$(TESTDATABLD)\testaliases.res" "$(TESTDATABLD)\testtypes.res" "$(TESTDATABLD)\testempty.res" "$(TESTDATABLD)\iscii.res" "$(TESTDATABLD)\idna_rules.res" "$(TESTDATABLD)\DataDrivenCollationTest.res" "$(TESTDATABLD)\test.icu" "$(TESTDATABLD)\testtable32.res" "$(TESTDATABLD)\test1.cnv" "$(TESTDATABLD)\test1bmp.cnv" "$(TESTDATABLD)\test3.cnv" "$(TESTDATABLD)\test4.cnv" "$(TESTDATABLD)\test4x.cnv" "$(TESTDATABLD)\ibm9027.cnv" "$(TESTDATABLD)\nfscsi.spp" "$(TESTDATABLD)\nfscss.spp" "$(TESTDATABLD)\nfscis.spp" "$(TESTDATABLD)\nfsmxs.spp" "$(TESTDATABLD)\nfsmxp.spp"
|
||||
"$(TESTDATAOUT)\testdata.dat" : $(TEST_RES_FILES) "$(TESTDATABLD)\casing.res" "$(TESTDATABLD)\conversion.res" "$(TESTDATABLD)\icuio.res" "$(TESTDATABLD)\mc.res" "$(TESTDATABLD)\structLocale.res" "$(TESTDATABLD)\root.res" "$(TESTDATABLD)\sh.res" "$(TESTDATABLD)\sh_YU.res" "$(TESTDATABLD)\te.res" "$(TESTDATABLD)\te_IN.res" "$(TESTDATABLD)\te_IN_REVISED.res" "$(TESTDATABLD)\testaliases.res" "$(TESTDATABLD)\testtypes.res" "$(TESTDATABLD)\testempty.res" "$(TESTDATABLD)\iscii.res" "$(TESTDATABLD)\idna_rules.res" "$(TESTDATABLD)\DataDrivenCollationTest.res" "$(TESTDATABLD)\test.icu" "$(TESTDATABLD)\testtable32.res" "$(TESTDATABLD)\test1.cnv" "$(TESTDATABLD)\test1bmp.cnv" "$(TESTDATABLD)\test3.cnv" "$(TESTDATABLD)\test4.cnv" "$(TESTDATABLD)\test4x.cnv" "$(TESTDATABLD)\test5.cnv" "$(TESTDATABLD)\ibm9027.cnv" "$(TESTDATABLD)\nfscsi.spp" "$(TESTDATABLD)\nfscss.spp" "$(TESTDATABLD)\nfscis.spp" "$(TESTDATABLD)\nfsmxs.spp" "$(TESTDATABLD)\nfsmxp.spp"
|
||||
@echo Building test data
|
||||
@copy "$(TESTDATABLD)\te.res" "$(TESTDATAOUT)\$(TESTDT)\nam.typ"
|
||||
@copy "$(TESTDATA)\icu26_testtypes.res" "$(TESTDATABLD)"
|
||||
|
@ -58,6 +58,7 @@ test1bmp.cnv
|
|||
test3.cnv
|
||||
test4.cnv
|
||||
test4x.cnv
|
||||
test5.cnv
|
||||
ibm9027.cnv
|
||||
idna_rules.res
|
||||
nfscsi.spp
|
||||
|
@ -143,6 +144,10 @@ $(TEST_RES_FILES:.res =.res
|
|||
@echo Building $@
|
||||
@"$(ICUTOOLS)\makeconv\$(CFG)\makeconv" --small -d"$(TESTDATABLD)" $**
|
||||
|
||||
"$(TESTDATABLD)\test5.cnv": "$(TESTDATA)\test5.ucm"
|
||||
@echo Building $@
|
||||
@"$(ICUTOOLS)\makeconv\$(CFG)\makeconv" --small -d"$(TESTDATABLD)" $**
|
||||
|
||||
"$(TESTDATABLD)\ibm9027.cnv": "$(TESTDATA)\ibm9027.ucm"
|
||||
@echo Building $@
|
||||
@"$(ICUTOOLS)\makeconv\$(CFG)\makeconv" --small -d"$(TESTDATABLD)" $**
|
||||
|
|
|
@ -1,3 +1,3 @@
|
|||
version https://git-lfs.github.com/spec/v1
|
||||
oid sha256:6c64c04ade4d5e79eae19db5debe13914d6cb47cf36f20a5eb687d52f3cfdbde
|
||||
size 775547
|
||||
oid sha256:e0a6d624943d618593296da8962fe2e8a258a7bb431d452f99714189bf81a6f6
|
||||
size 773180
|
||||
|
|
Loading…
Add table
Reference in a new issue