aboutsummaryrefslogtreecommitdiffstatshomepage
path: root/OpenSim
diff options
context:
space:
mode:
Diffstat (limited to 'OpenSim')
-rw-r--r--OpenSim/Region/CoreModules/Avatar/Attachments/Tests/AttachmentsModuleTests.cs4
-rw-r--r--OpenSim/Region/Framework/Scenes/SceneObjectGroup.cs2
-rw-r--r--OpenSim/Region/Framework/Scenes/Tests/SceneObjectBasicTests.cs11
3 files changed, 10 insertions, 7 deletions
diff --git a/OpenSim/Region/CoreModules/Avatar/Attachments/Tests/AttachmentsModuleTests.cs b/OpenSim/Region/CoreModules/Avatar/Attachments/Tests/AttachmentsModuleTests.cs
index 2ef86c9..10b2ff6 100644
--- a/OpenSim/Region/CoreModules/Avatar/Attachments/Tests/AttachmentsModuleTests.cs
+++ b/OpenSim/Region/CoreModules/Avatar/Attachments/Tests/AttachmentsModuleTests.cs
@@ -721,13 +721,13 @@ namespace OpenSim.Region.CoreModules.Avatar.Attachments.Tests
721 acd.Appearance.SetAttachment((int)AttachmentPoint.Chest, attItem.ID, attItem.AssetID); 721 acd.Appearance.SetAttachment((int)AttachmentPoint.Chest, attItem.ID, attItem.AssetID);
722 ScenePresence presence = SceneHelpers.AddScenePresence(scene, acd); 722 ScenePresence presence = SceneHelpers.AddScenePresence(scene, acd);
723 723
724 SceneObjectGroup rezzedAtt = presence.GetAttachments()[0]; 724 UUID rezzedAttID = presence.GetAttachments()[0].UUID;
725 725
726 m_numberOfAttachEventsFired = 0; 726 m_numberOfAttachEventsFired = 0;
727 scene.CloseAgent(presence.UUID, false); 727 scene.CloseAgent(presence.UUID, false);
728 728
729 // Check that we can't retrieve this attachment from the scene. 729 // Check that we can't retrieve this attachment from the scene.
730 Assert.That(scene.GetSceneObjectGroup(rezzedAtt.UUID), Is.Null); 730 Assert.That(scene.GetSceneObjectGroup(rezzedAttID), Is.Null);
731 731
732 // Check events 732 // Check events
733 Assert.That(m_numberOfAttachEventsFired, Is.EqualTo(0)); 733 Assert.That(m_numberOfAttachEventsFired, Is.EqualTo(0));
diff --git a/OpenSim/Region/Framework/Scenes/SceneObjectGroup.cs b/OpenSim/Region/Framework/Scenes/SceneObjectGroup.cs
index 473c802..ee0f674 100644
--- a/OpenSim/Region/Framework/Scenes/SceneObjectGroup.cs
+++ b/OpenSim/Region/Framework/Scenes/SceneObjectGroup.cs
@@ -4851,7 +4851,7 @@ namespace OpenSim.Region.Framework.Scenes
4851 { 4851 {
4852 m_parts.Clear(); 4852 m_parts.Clear();
4853 m_sittingAvatars.Clear(); 4853 m_sittingAvatars.Clear();
4854 m_rootPart = null; 4854// m_rootPart = null;
4855 4855
4856 m_PlaySoundMasterPrim = null; 4856 m_PlaySoundMasterPrim = null;
4857 m_PlaySoundSlavePrims.Clear(); 4857 m_PlaySoundSlavePrims.Clear();
diff --git a/OpenSim/Region/Framework/Scenes/Tests/SceneObjectBasicTests.cs b/OpenSim/Region/Framework/Scenes/Tests/SceneObjectBasicTests.cs
index 098f1b4..ac8c32d 100644
--- a/OpenSim/Region/Framework/Scenes/Tests/SceneObjectBasicTests.cs
+++ b/OpenSim/Region/Framework/Scenes/Tests/SceneObjectBasicTests.cs
@@ -171,11 +171,14 @@ namespace OpenSim.Region.Framework.Scenes.Tests
171 // Test that we don't get back an object for a local id that doesn't exist 171 // Test that we don't get back an object for a local id that doesn't exist
172 Assert.That(scene.GetGroupByPrim(999), Is.Null); 172 Assert.That(scene.GetGroupByPrim(999), Is.Null);
173 173
174 uint soid = so.LocalId;
175 uint spid = parts[partsToTestCount - 1].LocalId;
176
174 // Now delete the scene object and check again 177 // Now delete the scene object and check again
175 scene.DeleteSceneObject(so, false); 178 scene.DeleteSceneObject(so, false);
176 179
177 Assert.That(scene.GetGroupByPrim(so.LocalId), Is.Null); 180 Assert.That(scene.GetGroupByPrim(soid), Is.Null);
178 Assert.That(scene.GetGroupByPrim(parts[partsToTestCount - 1].LocalId), Is.Null); 181 Assert.That(scene.GetGroupByPrim(spid), Is.Null);
179 } 182 }
180 183
181 /// <summary> 184 /// <summary>
@@ -194,12 +197,12 @@ namespace OpenSim.Region.Framework.Scenes.Tests
194 SceneObjectGroup so = SceneHelpers.AddSceneObject(scene); 197 SceneObjectGroup so = SceneHelpers.AddSceneObject(scene);
195 198
196 Assert.That(so.IsDeleted, Is.False); 199 Assert.That(so.IsDeleted, Is.False);
200 uint retrievedPartID = so.LocalId;
197 201
198 scene.DeleteSceneObject(so, false); 202 scene.DeleteSceneObject(so, false);
199 203
200 Assert.That(so.IsDeleted, Is.True); 204 SceneObjectPart retrievedPart = scene.GetSceneObjectPart(retrievedPartID);
201 205
202 SceneObjectPart retrievedPart = scene.GetSceneObjectPart(so.LocalId);
203 Assert.That(retrievedPart, Is.Null); 206 Assert.That(retrievedPart, Is.Null);
204 } 207 }
205 208