aboutsummaryrefslogtreecommitdiffstatshomepage
path: root/OpenSim/Region/Framework
diff options
context:
space:
mode:
authorJustin Clark-Casey (justincc)2011-05-21 00:37:20 +0100
committerJustin Clark-Casey (justincc)2011-05-21 00:37:20 +0100
commit084059319c125983ac43534797282ddec394cb59 (patch)
treeeec520169cf04dc35a8931941372ec543eef3388 /OpenSim/Region/Framework
parentmove test task inventory notecard item creation into a new TastInventoryHelpe... (diff)
downloadopensim-SC-084059319c125983ac43534797282ddec394cb59.zip
opensim-SC-084059319c125983ac43534797282ddec394cb59.tar.gz
opensim-SC-084059319c125983ac43534797282ddec394cb59.tar.bz2
opensim-SC-084059319c125983ac43534797282ddec394cb59.tar.xz
refactor: move scene object item creation code into TaskInventoryHelpers
Diffstat (limited to 'OpenSim/Region/Framework')
-rw-r--r--OpenSim/Region/Framework/Scenes/Tests/TaskInventoryTests.cs10
1 files changed, 2 insertions, 8 deletions
diff --git a/OpenSim/Region/Framework/Scenes/Tests/TaskInventoryTests.cs b/OpenSim/Region/Framework/Scenes/Tests/TaskInventoryTests.cs
index 1c8f078..32bb068 100644
--- a/OpenSim/Region/Framework/Scenes/Tests/TaskInventoryTests.cs
+++ b/OpenSim/Region/Framework/Scenes/Tests/TaskInventoryTests.cs
@@ -66,15 +66,8 @@ namespace OpenSim.Region.Framework.Tests
66 66
67 // Create an object embedded inside the first 67 // Create an object embedded inside the first
68 UUID taskSceneObjectItemId = UUID.Parse("00000000-0000-0000-0000-100000000000"); 68 UUID taskSceneObjectItemId = UUID.Parse("00000000-0000-0000-0000-100000000000");
69
70 SceneObjectGroup taskSceneObject = SceneSetupHelpers.CreateSceneObject(1, UUID.Zero);
71 AssetBase taskSceneObjectAsset = AssetHelpers.CreateAsset(0x10, taskSceneObject);
72 scene.AssetService.Store(taskSceneObjectAsset);
73 TaskInventoryItem taskSceneObjectItem 69 TaskInventoryItem taskSceneObjectItem
74 = new TaskInventoryItem 70 = TaskInventoryHelpers.AddSceneObjectItem(scene, sop1, "tso", taskSceneObjectItemId);
75 { Name = "tso", AssetID = taskSceneObjectAsset.FullID, ItemID = taskSceneObjectItemId,
76 Type = (int)AssetType.Object, InvType = (int)InventoryType.Object };
77 sop1.Inventory.AddInventoryItem(taskSceneObjectItem, true);
78 71
79 scene.AddSceneObject(sog1); 72 scene.AddSceneObject(sog1);
80 73
@@ -114,6 +107,7 @@ namespace OpenSim.Region.Framework.Tests
114 SceneObjectGroup sog1 = SceneSetupHelpers.CreateSceneObject(1, user1.PrincipalID); 107 SceneObjectGroup sog1 = SceneSetupHelpers.CreateSceneObject(1, user1.PrincipalID);
115 SceneObjectPart sop1 = sog1.RootPart; 108 SceneObjectPart sop1 = sog1.RootPart;
116 TaskInventoryItem sopItem1 = TaskInventoryHelpers.AddNotecard(scene, sop1); 109 TaskInventoryItem sopItem1 = TaskInventoryHelpers.AddNotecard(scene, sop1);
110
117 InventoryFolderBase folder 111 InventoryFolderBase folder
118 = InventoryArchiveUtils.FindFolderByPath(scene.InventoryService, user1.PrincipalID, "Objects")[0]; 112 = InventoryArchiveUtils.FindFolderByPath(scene.InventoryService, user1.PrincipalID, "Objects")[0];
119 113