From dffa6567e80446199ee672a5e7c7865a573b73b5 Mon Sep 17 00:00:00 2001 From: Melanie Thielker Date: Tue, 23 Sep 2008 12:17:21 +0000 Subject: Alter tests to match up with the results after tyre's patch --- .../ScriptEngine/Common/Tests/LSL_TypesTestList.cs | 36 +++++++++++----------- 1 file changed, 18 insertions(+), 18 deletions(-) (limited to 'OpenSim/Region/ScriptEngine/Common/Tests/LSL_TypesTestList.cs') diff --git a/OpenSim/Region/ScriptEngine/Common/Tests/LSL_TypesTestList.cs b/OpenSim/Region/ScriptEngine/Common/Tests/LSL_TypesTestList.cs index e63200e..500d19a 100644 --- a/OpenSim/Region/ScriptEngine/Common/Tests/LSL_TypesTestList.cs +++ b/OpenSim/Region/ScriptEngine/Common/Tests/LSL_TypesTestList.cs @@ -45,17 +45,17 @@ namespace OpenSim.Region.ScriptEngine.Common.Tests public void TestConcatenateString() { LSL_Types.list testList = new LSL_Types.list(1, 'a', "test"); - testList += "addition"; + testList += new LSL_Types.LSLString("addition"); Assert.AreEqual(4, testList.Length); - Assert.AreEqual("addition", testList.Data[3]); - Assert.AreEqual(typeof(System.String), testList.Data[3].GetType()); + Assert.AreEqual(new LSL_Types.LSLString("addition"), testList.Data[3]); + Assert.AreEqual(typeof(LSL_Types.LSLString), testList.Data[3].GetType()); - LSL_Types.list secondTestList = testList + "more"; + LSL_Types.list secondTestList = testList + new LSL_Types.LSLString("more"); Assert.AreEqual(5, secondTestList.Length); - Assert.AreEqual("more", secondTestList.Data[4]); - Assert.AreEqual(typeof(System.String), secondTestList.Data[4].GetType()); + Assert.AreEqual(new LSL_Types.LSLString("more"), secondTestList.Data[4]); + Assert.AreEqual(typeof(LSL_Types.LSLString), secondTestList.Data[4].GetType()); } /// @@ -65,17 +65,17 @@ namespace OpenSim.Region.ScriptEngine.Common.Tests public void TestConcatenateInteger() { LSL_Types.list testList = new LSL_Types.list(1, 'a', "test"); - testList += 20; + testList += new LSL_Types.LSLInteger(20); Assert.AreEqual(4, testList.Length); - Assert.AreEqual(20, testList.Data[3]); - Assert.AreEqual(typeof(int), testList.Data[3].GetType()); + Assert.AreEqual(new LSL_Types.LSLInteger(20), testList.Data[3]); + Assert.AreEqual(typeof(LSL_Types.LSLInteger), testList.Data[3].GetType()); - LSL_Types.list secondTestList = testList + 2; + LSL_Types.list secondTestList = testList + new LSL_Types.LSLInteger(2); Assert.AreEqual(5, secondTestList.Length); - Assert.AreEqual(2, secondTestList.Data[4]); - Assert.AreEqual(typeof(int), secondTestList.Data[4].GetType()); + Assert.AreEqual(new LSL_Types.LSLInteger(2), secondTestList.Data[4]); + Assert.AreEqual(typeof(LSL_Types.LSLInteger), secondTestList.Data[4].GetType()); } /// @@ -85,17 +85,17 @@ namespace OpenSim.Region.ScriptEngine.Common.Tests public void TestConcatenateDouble() { LSL_Types.list testList = new LSL_Types.list(1, 'a', "test"); - testList += 2.0; + testList += new LSL_Types.LSLFloat(2.0); Assert.AreEqual(4, testList.Length); - Assert.AreEqual(2.0, testList.Data[3]); - Assert.AreEqual(typeof(double), testList.Data[3].GetType()); + Assert.AreEqual(new LSL_Types.LSLFloat(2.0), testList.Data[3]); + Assert.AreEqual(typeof(LSL_Types.LSLFloat), testList.Data[3].GetType()); - LSL_Types.list secondTestList = testList + 0.04; + LSL_Types.list secondTestList = testList + new LSL_Types.LSLFloat(0.04); Assert.AreEqual(5, secondTestList.Length); - Assert.AreEqual(0.04, secondTestList.Data[4]); - Assert.AreEqual(typeof(double), secondTestList.Data[4].GetType()); + Assert.AreEqual(new LSL_Types.LSLFloat(0.04), secondTestList.Data[4]); + Assert.AreEqual(typeof(LSL_Types.LSLFloat), secondTestList.Data[4].GetType()); } } } -- cgit v1.1