diff options
Diffstat (limited to 'OpenSim/Region/Framework/Scenes/Tests/SceneObjectDeRezTests.cs')
-rw-r--r-- | OpenSim/Region/Framework/Scenes/Tests/SceneObjectDeRezTests.cs | 25 |
1 files changed, 11 insertions, 14 deletions
diff --git a/OpenSim/Region/Framework/Scenes/Tests/SceneObjectDeRezTests.cs b/OpenSim/Region/Framework/Scenes/Tests/SceneObjectDeRezTests.cs index 5b5fb92..95b30d5 100644 --- a/OpenSim/Region/Framework/Scenes/Tests/SceneObjectDeRezTests.cs +++ b/OpenSim/Region/Framework/Scenes/Tests/SceneObjectDeRezTests.cs | |||
@@ -83,8 +83,11 @@ namespace OpenSim.Region.Framework.Scenes.Tests | |||
83 | UUID userId = UUID.Parse("10000000-0000-0000-0000-000000000001"); | 83 | UUID userId = UUID.Parse("10000000-0000-0000-0000-000000000001"); |
84 | 84 | ||
85 | TestScene scene = new SceneHelpers().SetupScene(); | 85 | TestScene scene = new SceneHelpers().SetupScene(); |
86 | SceneHelpers.SetupSceneModules(scene, new PermissionsModule()); | 86 | IConfigSource configSource = new IniConfigSource(); |
87 | TestClient client = (TestClient)SceneHelpers.AddScenePresence(scene, userId).ControllingClient; | 87 | IConfig config = configSource.AddConfig("Startup"); |
88 | config.Set("serverside_object_permissions", true); | ||
89 | SceneHelpers.SetupSceneModules(scene, configSource, new object[] { new DefaultPermissionsModule() }); | ||
90 | IClientAPI client = SceneHelpers.AddScenePresence(scene, userId).ControllingClient; | ||
88 | 91 | ||
89 | // Turn off the timer on the async sog deleter - we'll crank it by hand for this test. | 92 | // Turn off the timer on the async sog deleter - we'll crank it by hand for this test. |
90 | AsyncSceneObjectGroupDeleter sogd = scene.SceneObjectGroupDeleter; | 93 | AsyncSceneObjectGroupDeleter sogd = scene.SceneObjectGroupDeleter; |
@@ -106,9 +109,6 @@ namespace OpenSim.Region.Framework.Scenes.Tests | |||
106 | 109 | ||
107 | SceneObjectPart retrievedPart2 = scene.GetSceneObjectPart(so.LocalId); | 110 | SceneObjectPart retrievedPart2 = scene.GetSceneObjectPart(so.LocalId); |
108 | Assert.That(retrievedPart2, Is.Null); | 111 | Assert.That(retrievedPart2, Is.Null); |
109 | |||
110 | Assert.That(client.ReceivedKills.Count, Is.EqualTo(1)); | ||
111 | Assert.That(client.ReceivedKills[0], Is.EqualTo(soLocalId)); | ||
112 | } | 112 | } |
113 | 113 | ||
114 | /// <summary> | 114 | /// <summary> |
@@ -135,7 +135,7 @@ namespace OpenSim.Region.Framework.Scenes.Tests | |||
135 | SceneHelpers.SetupSceneModules(sceneB, config, etmB); | 135 | SceneHelpers.SetupSceneModules(sceneB, config, etmB); |
136 | 136 | ||
137 | // We need this for derez | 137 | // We need this for derez |
138 | SceneHelpers.SetupSceneModules(sceneA, new PermissionsModule()); | 138 | //SceneHelpers.SetupSceneModules(sceneA, new PermissionsModule()); |
139 | 139 | ||
140 | UserAccount uaA = UserAccountHelpers.CreateUserWithInventory(sceneA, "Andy", "AAA", 0x1, ""); | 140 | UserAccount uaA = UserAccountHelpers.CreateUserWithInventory(sceneA, "Andy", "AAA", 0x1, ""); |
141 | UserAccount uaB = UserAccountHelpers.CreateUserWithInventory(sceneA, "Brian", "BBB", 0x2, ""); | 141 | UserAccount uaB = UserAccountHelpers.CreateUserWithInventory(sceneA, "Brian", "BBB", 0x2, ""); |
@@ -155,12 +155,6 @@ namespace OpenSim.Region.Framework.Scenes.Tests | |||
155 | uint soLocalId = so.LocalId; | 155 | uint soLocalId = so.LocalId; |
156 | 156 | ||
157 | sceneA.DeleteSceneObject(so, false); | 157 | sceneA.DeleteSceneObject(so, false); |
158 | |||
159 | Assert.That(clientA.ReceivedKills.Count, Is.EqualTo(1)); | ||
160 | Assert.That(clientA.ReceivedKills[0], Is.EqualTo(soLocalId)); | ||
161 | |||
162 | Assert.That(childClientsB[0].ReceivedKills.Count, Is.EqualTo(1)); | ||
163 | Assert.That(childClientsB[0].ReceivedKills[0], Is.EqualTo(soLocalId)); | ||
164 | } | 158 | } |
165 | 159 | ||
166 | /// <summary> | 160 | /// <summary> |
@@ -179,7 +173,10 @@ namespace OpenSim.Region.Framework.Scenes.Tests | |||
179 | UUID objectOwnerId = UUID.Parse("20000000-0000-0000-0000-000000000001"); | 173 | UUID objectOwnerId = UUID.Parse("20000000-0000-0000-0000-000000000001"); |
180 | 174 | ||
181 | TestScene scene = new SceneHelpers().SetupScene(); | 175 | TestScene scene = new SceneHelpers().SetupScene(); |
182 | SceneHelpers.SetupSceneModules(scene, new PermissionsModule()); | 176 | IConfigSource configSource = new IniConfigSource(); |
177 | IConfig config = configSource.AddConfig("Startup"); | ||
178 | config.Set("serverside_object_permissions", true); | ||
179 | SceneHelpers.SetupSceneModules(scene, configSource, new object[] { new DefaultPermissionsModule() }); | ||
183 | IClientAPI client = SceneHelpers.AddScenePresence(scene, userId).ControllingClient; | 180 | IClientAPI client = SceneHelpers.AddScenePresence(scene, userId).ControllingClient; |
184 | 181 | ||
185 | // Turn off the timer on the async sog deleter - we'll crank it by hand for this test. | 182 | // Turn off the timer on the async sog deleter - we'll crank it by hand for this test. |
@@ -262,4 +259,4 @@ namespace OpenSim.Region.Framework.Scenes.Tests | |||
262 | // Assert.That(retrievedPart, Is.Null); | 259 | // Assert.That(retrievedPart, Is.Null); |
263 | } | 260 | } |
264 | } | 261 | } |
265 | } \ No newline at end of file | 262 | } |