aboutsummaryrefslogtreecommitdiffstatshomepage
path: root/OpenSim/Tests/Permissions/Common.cs
diff options
context:
space:
mode:
authorDiva Canto2017-05-01 16:49:42 -0700
committerDiva Canto2017-05-01 16:49:42 -0700
commit9c82ff76730c9eff80cace1ddece0148d8d0a7ee (patch)
tree0dda87eac67e84218d16a66f137459e1b2d1bf84 /OpenSim/Tests/Permissions/Common.cs
parentAdded some indirect transfer tests -- Take Copy by another avatar (diff)
downloadopensim-SC-9c82ff76730c9eff80cace1ddece0148d8d0a7ee.zip
opensim-SC-9c82ff76730c9eff80cace1ddece0148d8d0a7ee.tar.gz
opensim-SC-9c82ff76730c9eff80cace1ddece0148d8d0a7ee.tar.bz2
opensim-SC-9c82ff76730c9eff80cace1ddece0148d8d0a7ee.tar.xz
Shuffle some code around
Diffstat (limited to 'OpenSim/Tests/Permissions/Common.cs')
-rw-r--r--OpenSim/Tests/Permissions/Common.cs20
1 files changed, 20 insertions, 0 deletions
diff --git a/OpenSim/Tests/Permissions/Common.cs b/OpenSim/Tests/Permissions/Common.cs
index e62991b..f93c120 100644
--- a/OpenSim/Tests/Permissions/Common.cs
+++ b/OpenSim/Tests/Permissions/Common.cs
@@ -286,6 +286,26 @@ namespace OpenSim.Tests.Permissions
286 return clone; 286 return clone;
287 } 287 }
288 288
289 public void DeleteObjectsFolders()
290 {
291 // Delete everything in A2 and A3's Objects folders, so we can restart
292 for (int i = 1; i < 3; i++)
293 {
294 InventoryFolderBase objsFolder = UserInventoryHelpers.GetInventoryFolder(Common.TheScene.InventoryService, Common.TheAvatars[i].UUID, "Objects");
295 Assert.That(objsFolder, Is.Not.Null);
296
297 List<InventoryItemBase> items = Common.TheScene.InventoryService.GetFolderItems(Common.TheAvatars[i].UUID, objsFolder.ID);
298 List<UUID> ids = new List<UUID>();
299 foreach (InventoryItemBase it in items)
300 ids.Add(it.ID);
301
302 Common.TheScene.InventoryService.DeleteItems(Common.TheAvatars[i].UUID, ids);
303 items = Common.TheScene.InventoryService.GetFolderItems(Common.TheAvatars[i].UUID, objsFolder.ID);
304 Assert.That(items.Count, Is.EqualTo(0), "A" + (i + 1));
305 }
306
307 }
308
289 public string IdStr(InventoryItemBase item) 309 public string IdStr(InventoryItemBase item)
290 { 310 {
291 return item.Owner.ToString().Substring(34) + " : " + item.Name; 311 return item.Owner.ToString().Substring(34) + " : " + item.Name;