[runtime] Fix "make distcheck"
[mono-project.git] / mono / tests / hash-table.cs
blob6043aa880b817de9790487f1a9f3a237412eeff3
1 using System.Collections;
3 namespace Test {
4 public class Test {
5 public static int Main () {
6 string[] names = {
7 "one", "two", "three", "four"
8 };
9 Hashtable hash = new Hashtable ();
11 for (int i=0; i < names.Length; ++i) {
12 hash.Add (names [i], i);
14 if ((int)hash ["one"] != 0)
15 return 1;
16 if ((int)hash ["two"] != 1)
17 return 2;
18 if ((int)hash ["three"] != 2)
19 return 3;
20 if ((int)hash ["four"] != 3)
21 return 4;
22 if (hash.Contains("urka"))
23 return 5;
24 return 0;