]> git.saurik.com Git - apple/icu.git/blame_incremental - icuSources/test/intltest/ufltlgts.h
ICU-3.13.tar.gz
[apple/icu.git] / icuSources / test / intltest / ufltlgts.h
... / ...
CommitLineData
1/********************************************************************
2 * COPYRIGHT:
3 * Copyright (c) 1997-2001, International Business Machines Corporation and
4 * others. All Rights Reserved.
5 ********************************************************************
6************************************************************************
7* Date Name Description
8* 03/22/2000 Madhu Creation.
9************************************************************************/
10
11#ifndef UNIFLTLOGICTST_H
12#define UNIFLTLOGICTST_H
13
14#include "unicode/utypes.h"
15
16#if !UCONFIG_NO_TRANSLITERATION
17
18#include "unicode/translit.h"
19#include "unicode/unifltlg.h"
20#include "intltest.h"
21
22
23/**
24 * @test
25 * @summary General test of UnicodeFilterLogic API
26 */
27class UnicodeFilterLogicTest : public IntlTest {
28public:
29 void runIndexedTest(int32_t index, UBool exec, const char* &name, char* par=NULL);
30
31 /*Tests all the NOT, OR and AND filters */
32 void TestAll(void);
33
34 void TestNOT(Transliterator& t,
35 const UnicodeFilter* f1,
36 const UnicodeString& message,
37 const UnicodeString& source,
38 const UnicodeString& expected);
39
40 void TestAND(Transliterator& t,
41 const UnicodeFilter* f1,
42 const UnicodeFilter* f2,
43 const UnicodeString& message,
44 const UnicodeString& source,
45 const UnicodeString& expected);
46
47 void TestOR(Transliterator& t,
48 const UnicodeFilter* f1,
49 const UnicodeFilter* f2,
50 const UnicodeString& message,
51 const UnicodeString& source,
52 const UnicodeString& expected);
53
54 //support functions
55 void expect(const Transliterator& t,
56 const UnicodeString& message,
57 const UnicodeString& source,
58 const UnicodeString& expectedResult);
59
60 void expectAux(const UnicodeString& tag,
61 const UnicodeString& summary, UBool pass,
62 const UnicodeString& expectedResult);
63
64};
65
66#endif /* #if !UCONFIG_NO_TRANSLITERATION */
67
68#endif