1 // Web service test for WSDL document:
2 // http://localhost:8080/DuplicateArrayTest.asmx?wsdl
6 using DuplicateArrayTestTests.Soap;
8 namespace Localhost.DuplicateArrayTestTests
11 public class DuplicateArrayTestTest: WebServiceTest
14 public void TestService ()
16 DuplicateArrayTest s = new DuplicateArrayTest();
18 string title = "hello";
20 correctionsCorrection c = new correctionsCorrection();
22 c.suggestions = new string[]{"end","test"};
23 correctionsCorrection[] arr = new correctionsCorrection[2]{c,c};
24 arr = s.SpellCheck(ref title,ref url,arr);
26 Assert.AreEqual (2, arr.Length, "t1");
28 for (int i =0; i< arr.Length ; i++)
31 Assert.IsNotNull (c, "t2."+i);
32 Assert.AreEqual ("bye", c.word, "t3."+i);
33 Assert.IsNotNull (c.suggestions, "t4."+i);
34 Assert.AreEqual (2, c.suggestions.Length, "t5."+i);
35 Assert.AreEqual ("end", c.suggestions[0], "t6."+i);
36 Assert.AreEqual ("test", c.suggestions[1], "t7."+i);
38 Assert.AreEqual ("hello", title, "t8");
39 Assert.AreEqual ("tmp", url, "t9");