diff options
author | Justin Clarke Casey | 2009-01-16 21:56:13 +0000 |
---|---|---|
committer | Justin Clarke Casey | 2009-01-16 21:56:13 +0000 |
commit | eca6442bae4093019bd221e87413c74c77c4ff5d (patch) | |
tree | e62245b1cf2a5f0afdde443fba38c2b62d401100 /OpenSim/Region/Environment/Scenes/Tests/StandaloneTeleportTests.cs | |
parent | * minor: Future archiver test stub (diff) | |
download | opensim-SC-eca6442bae4093019bd221e87413c74c77c4ff5d.zip opensim-SC-eca6442bae4093019bd221e87413c74c77c4ff5d.tar.gz opensim-SC-eca6442bae4093019bd221e87413c74c77c4ff5d.tar.bz2 opensim-SC-eca6442bae4093019bd221e87413c74c77c4ff5d.tar.xz |
* Rig up enough infrastructure to actually perform a successful 'standalone' teleport unit test with checks that the scene presence disappeared from sceneA and appeared in
sceneB
* However, I'm not convinced that the actual process in the test completely reflects reality, and a lot of stuff had to be rigged up (which should get resolved over time)
Diffstat (limited to 'OpenSim/Region/Environment/Scenes/Tests/StandaloneTeleportTests.cs')
-rw-r--r-- | OpenSim/Region/Environment/Scenes/Tests/StandaloneTeleportTests.cs | 10 |
1 files changed, 8 insertions, 2 deletions
diff --git a/OpenSim/Region/Environment/Scenes/Tests/StandaloneTeleportTests.cs b/OpenSim/Region/Environment/Scenes/Tests/StandaloneTeleportTests.cs index a3d116d..d7342de 100644 --- a/OpenSim/Region/Environment/Scenes/Tests/StandaloneTeleportTests.cs +++ b/OpenSim/Region/Environment/Scenes/Tests/StandaloneTeleportTests.cs | |||
@@ -27,6 +27,7 @@ | |||
27 | 27 | ||
28 | using Nini.Config; | 28 | using Nini.Config; |
29 | using NUnit.Framework; | 29 | using NUnit.Framework; |
30 | using NUnit.Framework.SyntaxHelpers; | ||
30 | using OpenMetaverse; | 31 | using OpenMetaverse; |
31 | using OpenSim.Framework; | 32 | using OpenSim.Framework; |
32 | using OpenSim.Framework.Communications; | 33 | using OpenSim.Framework.Communications; |
@@ -77,9 +78,14 @@ namespace OpenSim.Region.Environment.Scenes.Tests | |||
77 | 78 | ||
78 | TestClient client = SceneTestUtils.AddRootAgent(sceneA, agentId); | 79 | TestClient client = SceneTestUtils.AddRootAgent(sceneA, agentId); |
79 | 80 | ||
80 | client.Teleport(sceneB.RegionInfo.RegionHandle, new Vector3(100, 100, 100), new Vector3(40, 40, 40)); | 81 | // FIXME: This is a hack to get the test working - really the normal OpenSim mechanisms should be used. |
82 | client.TeleportTargetScene = sceneB; | ||
81 | 83 | ||
82 | // TODO: Check that everything is as it should be | 84 | client.Teleport(sceneB.RegionInfo.RegionHandle, new Vector3(100, 100, 100), new Vector3(40, 40, 40)); |
85 | Assert.That(sceneB.GetScenePresence(agentId), Is.Not.Null, "Client does not have an agent in sceneB"); | ||
86 | Assert.That(sceneA.GetScenePresence(agentId), Is.Null, "Client still had an agent in sceneA"); | ||
87 | |||
88 | // TODO: Check that more of everything is as it should be | ||
83 | 89 | ||
84 | // TODO: test what happens if we try to teleport to a region that doesn't exist | 90 | // TODO: test what happens if we try to teleport to a region that doesn't exist |
85 | } | 91 | } |