2005-01-07 Marek Safar <marek.safar@seznam.cz>
[mono.git] / mcs / mbas / Test / tests / LikeOperator.vb
1 Imports System\r
2 \r
3 Module LikeOperator\r
4     Sub main()\r
5 \r
6         Dim a As Boolean\r
7 \r
8         a = "HELLO" Like "HELLO"\r
9         If a <> True Then\r
10             Console.WriteLine("#A1-LikeOperator:Failed")\r
11         End If\r
12 \r
13         a = "HELLO" Like "HEllO"\r
14         If a <> False Then\r
15             Console.WriteLine("#A2-LikeOperator:Failed")\r
16         End If\r
17 \r
18         a = "HELLO" Like "H*O"\r
19         If a <> True Then\r
20             Console.WriteLine("#A3-LikeOperator:Failed")\r
21         End If\r
22 \r
23         a = "HELLO" Like "H[A-Z][!M-P][!A-K]O"\r
24         If a <> True Then\r
25             Console.WriteLine("#A4-LikeOperator:Failed")\r
26         End If\r
27 \r
28         a = "HE12O" Like "H?##[L-P]"\r
29         If a <> True Then\r
30             Console.WriteLine("#A5-LikeOperator:Failed")\r
31         End If\r
32 \r
33         a = "HELLO123WORLD" Like "H?*#*"\r
34         If a <> True Then\r
35             Console.WriteLine("#A6-LikeOperator:Failed")\r
36         End If\r
37 \r
38         a = "HELLOworld" Like "B*O*d"\r
39         If a <> False Then\r
40             Console.WriteLine("#A7-LikeOperator:Failed")\r
41         End If\r
42 \r
43         a = "" Like ""\r
44         If a <> True Then\r
45             Console.WriteLine("#A8-LikeOperator:Failed")\r
46         End If\r
47 \r
48         a = "A" Like ""\r
49         If a <> False Then\r
50             Console.WriteLine("#A9-LikeOperator:Failed")\r
51         End If\r
52 \r
53         a = "" Like "A"\r
54         If a <> False Then\r
55             Console.WriteLine("#A10-LikeOperator:Failed")\r
56         End If\r
57 \r
58         a = "HELLO" Like "HELLO" & Nothing\r
59         If a <> True Then\r
60             Console.WriteLine("#A11-LikeOperator:Failed")\r
61         End If\r
62 \r
63 \r
64     End Sub\r
65 \r
66 End Module\r