extend initial rez regression test to check that attachment is phantom

bulletsim
Justin Clark-Casey (justincc) 2011-08-24 22:25:23 +01:00
parent 73d913dad2
commit 21f1b68fdf
1 changed files with 14 additions and 9 deletions

View File

@ -95,18 +95,17 @@ namespace OpenSim.Region.CoreModules.Avatar.Attachments.Tests
m_attMod.AttachObject(presence.ControllingClient, so, (uint)AttachmentPoint.Chest, false); m_attMod.AttachObject(presence.ControllingClient, so, (uint)AttachmentPoint.Chest, false);
SceneObjectGroup attSo = scene.GetSceneObjectGroup(so.UUID);
Assert.That(attSo.IsAttachment);
Assert.That(attSo.IsPhantom);
Assert.That(attSo.UsesPhysics, Is.False);
Assert.That(attSo.IsTemporary, Is.False);
// Check status on scene presence // Check status on scene presence
Assert.That(presence.HasAttachments(), Is.True); Assert.That(presence.HasAttachments(), Is.True);
List<SceneObjectGroup> attachments = presence.Attachments; List<SceneObjectGroup> attachments = presence.Attachments;
Assert.That(attachments.Count, Is.EqualTo(1)); Assert.That(attachments.Count, Is.EqualTo(1));
Assert.That(attachments[0].Name, Is.EqualTo(attName)); SceneObjectGroup attSo = attachments[0];
Assert.That(attachments[0].GetAttachmentPoint(), Is.EqualTo((byte)AttachmentPoint.Chest)); Assert.That(attSo.Name, Is.EqualTo(attName));
Assert.That(attSo.GetAttachmentPoint(), Is.EqualTo((byte)AttachmentPoint.Chest));
Assert.That(attSo.IsAttachment);
Assert.That(attSo.IsPhantom);
Assert.That(attSo.UsesPhysics, Is.False);
Assert.That(attSo.IsTemporary, Is.False);
// Check item status // Check item status
Assert.That(presence.Appearance.GetAttachpoint( Assert.That(presence.Appearance.GetAttachpoint(
@ -204,7 +203,13 @@ namespace OpenSim.Region.CoreModules.Avatar.Attachments.Tests
List<SceneObjectGroup> attachments = presence.Attachments; List<SceneObjectGroup> attachments = presence.Attachments;
Assert.That(attachments.Count, Is.EqualTo(1)); Assert.That(attachments.Count, Is.EqualTo(1));
Assert.That(attachments[0].Name, Is.EqualTo(attName)); SceneObjectGroup attSo = attachments[0];
Assert.That(attSo.Name, Is.EqualTo(attName));
Assert.That(attSo.GetAttachmentPoint(), Is.EqualTo((byte)AttachmentPoint.Chest));
Assert.That(attSo.IsAttachment);
Assert.That(attSo.IsPhantom);
Assert.That(attSo.UsesPhysics, Is.False);
Assert.That(attSo.IsTemporary, Is.False);
} }
// I'm commenting this test because scene setup NEEDS InventoryService to // I'm commenting this test because scene setup NEEDS InventoryService to