aboutsummaryrefslogtreecommitdiffstatshomepage
path: root/OpenSim/Tests/Framework/UtilTest.cs
diff options
context:
space:
mode:
authorTeravus Ovares2008-09-06 07:52:41 +0000
committerTeravus Ovares2008-09-06 07:52:41 +0000
commit7d89e122930be39e84a6d174548fa2d12ac0484a (patch)
treee5aa5752f988a9aba2a969f49e5e208985eda80c /OpenSim/Tests/Framework/UtilTest.cs
parent* minor: speculatively try a change to bamboo.build to see if this generates ... (diff)
downloadopensim-SC_OLD-7d89e122930be39e84a6d174548fa2d12ac0484a.zip
opensim-SC_OLD-7d89e122930be39e84a6d174548fa2d12ac0484a.tar.gz
opensim-SC_OLD-7d89e122930be39e84a6d174548fa2d12ac0484a.tar.bz2
opensim-SC_OLD-7d89e122930be39e84a6d174548fa2d12ac0484a.tar.xz
* This is the fabled LibOMV update with all of the libOMV types from JHurliman
* This is a HUGE OMG update and will definitely have unknown side effects.. so this is really only for the strong hearted at this point. Regular people should let the dust settle. * This has been tested to work with most basic functions. However.. make sure you back up 'everything' before using this. It's that big! * Essentially we're back at square 1 in the testing phase.. so lets identify things that broke.
Diffstat (limited to 'OpenSim/Tests/Framework/UtilTest.cs')
-rw-r--r--OpenSim/Tests/Framework/UtilTest.cs24
1 files changed, 12 insertions, 12 deletions
diff --git a/OpenSim/Tests/Framework/UtilTest.cs b/OpenSim/Tests/Framework/UtilTest.cs
index 121ee93..a973ed2 100644
--- a/OpenSim/Tests/Framework/UtilTest.cs
+++ b/OpenSim/Tests/Framework/UtilTest.cs
@@ -25,7 +25,7 @@
25 * SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. 25 * SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
26 */ 26 */
27 27
28using libsecondlife; 28using OpenMetaverse;
29using NUnit.Framework; 29using NUnit.Framework;
30using NUnit.Framework.SyntaxHelpers; 30using NUnit.Framework.SyntaxHelpers;
31using OpenSim.Tests.Common; 31using OpenSim.Tests.Common;
@@ -38,15 +38,15 @@ namespace OpenSim.Framework.Tests
38 [Test] 38 [Test]
39 public void VectorOperationTests() 39 public void VectorOperationTests()
40 { 40 {
41 LLVector3 v1, v2; 41 Vector3 v1, v2;
42 double expectedDistance; 42 double expectedDistance;
43 double expectedMagnitude; 43 double expectedMagnitude;
44 double lowPrecisionTolerance = 0.001; 44 double lowPrecisionTolerance = 0.001;
45 45
46 //Lets test a simple case of <0,0,0> and <5,5,5> 46 //Lets test a simple case of <0,0,0> and <5,5,5>
47 { 47 {
48 v1 = new LLVector3(0, 0, 0); 48 v1 = new Vector3(0, 0, 0);
49 v2 = new LLVector3(5, 5, 5); 49 v2 = new Vector3(5, 5, 5);
50 expectedDistance = 8.66; 50 expectedDistance = 8.66;
51 Assert.That(Util.GetDistanceTo(v1, v2), 51 Assert.That(Util.GetDistanceTo(v1, v2),
52 new DoubleToleranceConstraint(expectedDistance, lowPrecisionTolerance), 52 new DoubleToleranceConstraint(expectedDistance, lowPrecisionTolerance),
@@ -65,9 +65,9 @@ namespace OpenSim.Framework.Tests
65 Assert.That(causesArgumentException, Is.True, 65 Assert.That(causesArgumentException, Is.True,
66 "Getting magnitude of null vector did not cause argument exception."); 66 "Getting magnitude of null vector did not cause argument exception.");
67 67
68 LLVector3 expectedNormalizedVector = new LLVector3(.577f, .577f, .577f); 68 Vector3 expectedNormalizedVector = new Vector3(.577f, .577f, .577f);
69 double expectedNormalizedMagnitude = 1; 69 double expectedNormalizedMagnitude = 1;
70 LLVector3 normalizedVector = Util.GetNormalizedVector(v2); 70 Vector3 normalizedVector = Util.GetNormalizedVector(v2);
71 Assert.That(normalizedVector, 71 Assert.That(normalizedVector,
72 new VectorToleranceConstraint(expectedNormalizedVector, lowPrecisionTolerance), 72 new VectorToleranceConstraint(expectedNormalizedVector, lowPrecisionTolerance),
73 "Normalized vector generated from vector was not what was expected."); 73 "Normalized vector generated from vector was not what was expected.");
@@ -78,8 +78,8 @@ namespace OpenSim.Framework.Tests
78 78
79 //Lets test a simple case of <0,0,0> and <0,0,0> 79 //Lets test a simple case of <0,0,0> and <0,0,0>
80 { 80 {
81 v1 = new LLVector3(0, 0, 0); 81 v1 = new Vector3(0, 0, 0);
82 v2 = new LLVector3(0, 0, 0); 82 v2 = new Vector3(0, 0, 0);
83 expectedDistance = 0; 83 expectedDistance = 0;
84 Assert.That(Util.GetDistanceTo(v1, v2), 84 Assert.That(Util.GetDistanceTo(v1, v2),
85 new DoubleToleranceConstraint(expectedDistance, lowPrecisionTolerance), 85 new DoubleToleranceConstraint(expectedDistance, lowPrecisionTolerance),
@@ -106,8 +106,8 @@ namespace OpenSim.Framework.Tests
106 106
107 //Lets test a simple case of <0,0,0> and <-5,-5,-5> 107 //Lets test a simple case of <0,0,0> and <-5,-5,-5>
108 { 108 {
109 v1 = new LLVector3(0, 0, 0); 109 v1 = new Vector3(0, 0, 0);
110 v2 = new LLVector3(-5, -5, -5); 110 v2 = new Vector3(-5, -5, -5);
111 expectedDistance = 8.66; 111 expectedDistance = 8.66;
112 Assert.That(Util.GetDistanceTo(v1, v2), 112 Assert.That(Util.GetDistanceTo(v1, v2),
113 new DoubleToleranceConstraint(expectedDistance, lowPrecisionTolerance), 113 new DoubleToleranceConstraint(expectedDistance, lowPrecisionTolerance),
@@ -126,9 +126,9 @@ namespace OpenSim.Framework.Tests
126 Assert.That(causesArgumentException, Is.True, 126 Assert.That(causesArgumentException, Is.True,
127 "Getting magnitude of null vector did not cause argument exception."); 127 "Getting magnitude of null vector did not cause argument exception.");
128 128
129 LLVector3 expectedNormalizedVector = new LLVector3(-.577f, -.577f, -.577f); 129 Vector3 expectedNormalizedVector = new Vector3(-.577f, -.577f, -.577f);
130 double expectedNormalizedMagnitude = 1; 130 double expectedNormalizedMagnitude = 1;
131 LLVector3 normalizedVector = Util.GetNormalizedVector(v2); 131 Vector3 normalizedVector = Util.GetNormalizedVector(v2);
132 Assert.That(normalizedVector, 132 Assert.That(normalizedVector,
133 new VectorToleranceConstraint(expectedNormalizedVector, lowPrecisionTolerance), 133 new VectorToleranceConstraint(expectedNormalizedVector, lowPrecisionTolerance),
134 "Normalized vector generated from vector was not what was expected."); 134 "Normalized vector generated from vector was not what was expected.");