• Home
  • Line#
  • Scopes#
  • Navigate#
  • Raw
  • Download
1#
2# test_codecmaps_cn.py
3#   Codec mapping tests for PRC encodings
4#
5
6from test import test_support
7from test import multibytecodec_support
8import unittest
9
10class TestGB2312Map(multibytecodec_support.TestBase_Mapping,
11                   unittest.TestCase):
12    encoding = 'gb2312'
13    mapfileurl = 'http://www.pythontest.net/unicode/EUC-CN.TXT'
14
15class TestGBKMap(multibytecodec_support.TestBase_Mapping,
16                   unittest.TestCase):
17    encoding = 'gbk'
18    mapfileurl = 'http://www.pythontest.net/unicode/CP936.TXT'
19
20class TestGB18030Map(multibytecodec_support.TestBase_Mapping,
21                     unittest.TestCase):
22    encoding = 'gb18030'
23    mapfileurl = 'http://www.pythontest.net/unicode/gb-18030-2000.xml'
24
25
26def test_main():
27    test_support.run_unittest(__name__)
28
29if __name__ == "__main__":
30    test_main()
31