root/maint/gnulib/tests/unictype/test-combiningclass_byname.c

/* [previous][next][first][last][top][bottom][index][help] */

DEFINITIONS

This source file includes following definitions.
  1. main

   1 /* Test the Unicode character Arabic joining group functions.
   2    Copyright (C) 2011 Free Software Foundation, Inc.
   3    Written by Bruno Haible <bruno@clisp.org>, 2011.
   4 
   5    This program is free software: you can redistribute it and/or modify it
   6    under the terms of the GNU Lesser General Public License as published
   7    by the Free Software Foundation; either version 3 of the License, or
   8    (at your option) any later version.
   9 
  10    This program is distributed in the hope that it will be useful,
  11    but WITHOUT ANY WARRANTY; without even the implied warranty of
  12    MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
  13    Lesser General Public License for more details.
  14 
  15    You should have received a copy of the GNU Lesser General Public License
  16    along with this program.  If not, see <https://www.gnu.org/licenses/>.  */
  17 
  18 #include <config.h>
  19 
  20 /* Specification.  */
  21 #include "unictype.h"
  22 
  23 #include <string.h>
  24 
  25 #include "macros.h"
  26 
  27 int
  28 main ()
     /* [previous][next][first][last][top][bottom][index][help] */
  29 {
  30   ASSERT (uc_combining_class_byname ("NR") == UC_CCC_NR);
  31   ASSERT (uc_combining_class_byname ("OV") == UC_CCC_OV);
  32   ASSERT (uc_combining_class_byname ("NK") == UC_CCC_NK);
  33   ASSERT (uc_combining_class_byname ("KV") == UC_CCC_KV);
  34   ASSERT (uc_combining_class_byname ("VR") == UC_CCC_VR);
  35   ASSERT (uc_combining_class_byname ("ATBL") == UC_CCC_ATBL);
  36   ASSERT (uc_combining_class_byname ("ATB") == UC_CCC_ATB);
  37   ASSERT (uc_combining_class_byname ("ATA") == UC_CCC_ATA);
  38   ASSERT (uc_combining_class_byname ("ATAR") == UC_CCC_ATAR);
  39   ASSERT (uc_combining_class_byname ("BL") == UC_CCC_BL);
  40   ASSERT (uc_combining_class_byname ("B") == UC_CCC_B);
  41   ASSERT (uc_combining_class_byname ("BR") == UC_CCC_BR);
  42   ASSERT (uc_combining_class_byname ("L") == UC_CCC_L);
  43   ASSERT (uc_combining_class_byname ("R") == UC_CCC_R);
  44   ASSERT (uc_combining_class_byname ("AL") == UC_CCC_AL);
  45   ASSERT (uc_combining_class_byname ("A") == UC_CCC_A);
  46   ASSERT (uc_combining_class_byname ("AR") == UC_CCC_AR);
  47   ASSERT (uc_combining_class_byname ("DB") == UC_CCC_DB);
  48   ASSERT (uc_combining_class_byname ("DA") == UC_CCC_DA);
  49   ASSERT (uc_combining_class_byname ("IS") == UC_CCC_IS);
  50 
  51   ASSERT (uc_combining_class_byname ("NOT REORDERED") == UC_CCC_NR);
  52   ASSERT (uc_combining_class_byname ("Not Reordered") == UC_CCC_NR);
  53   ASSERT (uc_combining_class_byname ("Not_Reordered") == UC_CCC_NR);
  54   ASSERT (uc_combining_class_byname ("NotReordered") == UC_CCC_NR);
  55   ASSERT (uc_combining_class_byname ("OVERLAY") == UC_CCC_OV);
  56   ASSERT (uc_combining_class_byname ("Overlay") == UC_CCC_OV);
  57   ASSERT (uc_combining_class_byname ("NUKTA") == UC_CCC_NK);
  58   ASSERT (uc_combining_class_byname ("Nukta") == UC_CCC_NK);
  59   ASSERT (uc_combining_class_byname ("KANA VOICING") == UC_CCC_KV);
  60   ASSERT (uc_combining_class_byname ("Kana Voicing") == UC_CCC_KV);
  61   ASSERT (uc_combining_class_byname ("Kana_Voicing") == UC_CCC_KV);
  62   ASSERT (uc_combining_class_byname ("KanaVoicing") == UC_CCC_KV);
  63   ASSERT (uc_combining_class_byname ("VIRAMA") == UC_CCC_VR);
  64   ASSERT (uc_combining_class_byname ("Virama") == UC_CCC_VR);
  65   ASSERT (uc_combining_class_byname ("ATTACHED BELOW LEFT") == UC_CCC_ATBL);
  66   ASSERT (uc_combining_class_byname ("Attached Below Left") == UC_CCC_ATBL);
  67   ASSERT (uc_combining_class_byname ("Attached_Below_Left") == UC_CCC_ATBL);
  68   ASSERT (uc_combining_class_byname ("AttachedBelowLeft") == UC_CCC_ATBL);
  69   ASSERT (uc_combining_class_byname ("ATTACHED BELOW") == UC_CCC_ATB);
  70   ASSERT (uc_combining_class_byname ("Attached Below") == UC_CCC_ATB);
  71   ASSERT (uc_combining_class_byname ("Attached_Below") == UC_CCC_ATB);
  72   ASSERT (uc_combining_class_byname ("AttachedBelow") == UC_CCC_ATB);
  73   ASSERT (uc_combining_class_byname ("ATTACHED ABOVE") == UC_CCC_ATA);
  74   ASSERT (uc_combining_class_byname ("Attached Above") == UC_CCC_ATA);
  75   ASSERT (uc_combining_class_byname ("Attached_Above") == UC_CCC_ATA);
  76   ASSERT (uc_combining_class_byname ("AttachedAbove") == UC_CCC_ATA);
  77   ASSERT (uc_combining_class_byname ("ATTACHED ABOVE RIGHT") == UC_CCC_ATAR);
  78   ASSERT (uc_combining_class_byname ("Attached Above Right") == UC_CCC_ATAR);
  79   ASSERT (uc_combining_class_byname ("Attached_Above_Right") == UC_CCC_ATAR);
  80   ASSERT (uc_combining_class_byname ("AttachedAboveRight") == UC_CCC_ATAR);
  81   ASSERT (uc_combining_class_byname ("BELOW LEFT") == UC_CCC_BL);
  82   ASSERT (uc_combining_class_byname ("Below Left") == UC_CCC_BL);
  83   ASSERT (uc_combining_class_byname ("Below_Left") == UC_CCC_BL);
  84   ASSERT (uc_combining_class_byname ("BelowLeft") == UC_CCC_BL);
  85   ASSERT (uc_combining_class_byname ("BELOW") == UC_CCC_B);
  86   ASSERT (uc_combining_class_byname ("Below") == UC_CCC_B);
  87   ASSERT (uc_combining_class_byname ("BELOW RIGHT") == UC_CCC_BR);
  88   ASSERT (uc_combining_class_byname ("Below Right") == UC_CCC_BR);
  89   ASSERT (uc_combining_class_byname ("Below_Right") == UC_CCC_BR);
  90   ASSERT (uc_combining_class_byname ("BelowRight") == UC_CCC_BR);
  91   ASSERT (uc_combining_class_byname ("LEFT") == UC_CCC_L);
  92   ASSERT (uc_combining_class_byname ("Left") == UC_CCC_L);
  93   ASSERT (uc_combining_class_byname ("RIGHT") == UC_CCC_R);
  94   ASSERT (uc_combining_class_byname ("Right") == UC_CCC_R);
  95   ASSERT (uc_combining_class_byname ("ABOVE LEFT") == UC_CCC_AL);
  96   ASSERT (uc_combining_class_byname ("Above Left") == UC_CCC_AL);
  97   ASSERT (uc_combining_class_byname ("Above_Left") == UC_CCC_AL);
  98   ASSERT (uc_combining_class_byname ("AboveLeft") == UC_CCC_AL);
  99   ASSERT (uc_combining_class_byname ("ABOVE") == UC_CCC_A);
 100   ASSERT (uc_combining_class_byname ("ABOVE RIGHT") == UC_CCC_AR);
 101   ASSERT (uc_combining_class_byname ("Above Right") == UC_CCC_AR);
 102   ASSERT (uc_combining_class_byname ("Above_Right") == UC_CCC_AR);
 103   ASSERT (uc_combining_class_byname ("AboveRight") == UC_CCC_AR);
 104   ASSERT (uc_combining_class_byname ("DOUBLE BELOW") == UC_CCC_DB);
 105   ASSERT (uc_combining_class_byname ("Double Below") == UC_CCC_DB);
 106   ASSERT (uc_combining_class_byname ("Double_Below") == UC_CCC_DB);
 107   ASSERT (uc_combining_class_byname ("DoubleBelow") == UC_CCC_DB);
 108   ASSERT (uc_combining_class_byname ("DOUBLE ABOVE") == UC_CCC_DA);
 109   ASSERT (uc_combining_class_byname ("Double Above") == UC_CCC_DA);
 110   ASSERT (uc_combining_class_byname ("Double_Above") == UC_CCC_DA);
 111   ASSERT (uc_combining_class_byname ("DoubleAbove") == UC_CCC_DA);
 112   ASSERT (uc_combining_class_byname ("IOTA SUBSCRIPT") == UC_CCC_IS);
 113   ASSERT (uc_combining_class_byname ("Iota Subscript") == UC_CCC_IS);
 114   ASSERT (uc_combining_class_byname ("Iota_Subscript") == UC_CCC_IS);
 115   ASSERT (uc_combining_class_byname ("IotaSubscript") == UC_CCC_IS);
 116 
 117   return 0;
 118 }

/* [previous][next][first][last][top][bottom][index][help] */