diff options
Diffstat (limited to 'OpenSim/Region/Framework/Scenes/Tests/TaskInventoryTests.cs')
-rw-r--r-- | OpenSim/Region/Framework/Scenes/Tests/TaskInventoryTests.cs | 26 |
1 files changed, 26 insertions, 0 deletions
diff --git a/OpenSim/Region/Framework/Scenes/Tests/TaskInventoryTests.cs b/OpenSim/Region/Framework/Scenes/Tests/TaskInventoryTests.cs index ed2f324..da8199d 100644 --- a/OpenSim/Region/Framework/Scenes/Tests/TaskInventoryTests.cs +++ b/OpenSim/Region/Framework/Scenes/Tests/TaskInventoryTests.cs | |||
@@ -95,6 +95,32 @@ namespace OpenSim.Region.Framework.Tests | |||
95 | /// </summary> | 95 | /// </summary> |
96 | /// This should place it in the most suitable user folder. | 96 | /// This should place it in the most suitable user folder. |
97 | [Test] | 97 | [Test] |
98 | public void TestMoveTaskInventoryItem() | ||
99 | { | ||
100 | TestHelper.InMethod(); | ||
101 | // log4net.Config.XmlConfigurator.Configure(); | ||
102 | |||
103 | Scene scene = SceneSetupHelpers.SetupScene("inventory"); | ||
104 | UserAccount user1 = CreateUser(scene); | ||
105 | SceneObjectGroup sog1 = CreateSO1(scene, user1.PrincipalID); | ||
106 | SceneObjectPart sop1 = sog1.RootPart; | ||
107 | TaskInventoryItem sopItem1 = CreateSOItem1(scene, sop1); | ||
108 | InventoryFolderBase folder | ||
109 | = InventoryArchiveUtils.FindFolderByPath(scene.InventoryService, user1.PrincipalID, "Objects")[0]; | ||
110 | |||
111 | // Perform test | ||
112 | scene.MoveTaskInventoryItem(user1.PrincipalID, folder.ID, sop1, sopItem1.ItemID); | ||
113 | |||
114 | InventoryItemBase ncUserItem | ||
115 | = InventoryArchiveUtils.FindItemByPath(scene.InventoryService, user1.PrincipalID, "Objects/ncItem"); | ||
116 | Assert.That(ncUserItem, Is.Not.Null, "Objects/ncItem was not found"); | ||
117 | } | ||
118 | |||
119 | /// <summary> | ||
120 | /// Test MoveTaskInventoryItem where the item has no parent folder assigned. | ||
121 | /// </summary> | ||
122 | /// This should place it in the most suitable user folder. | ||
123 | [Test] | ||
98 | public void TestMoveTaskInventoryItemNoParent() | 124 | public void TestMoveTaskInventoryItemNoParent() |
99 | { | 125 | { |
100 | TestHelper.InMethod(); | 126 | TestHelper.InMethod(); |