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