From 04a07daa5b4a19d61d70d63e32818ac65a322167 Mon Sep 17 00:00:00 2001 From: Justin Clarke Casey Date: Thu, 11 Dec 2008 18:56:04 +0000 Subject: minor: Add request inventory test --- .../Tests/Cache/UserProfileCacheServiceTests.cs | 23 +++++++++++++++++++++- OpenSim/Framework/Tests/LocationTest.cs | 2 -- 2 files changed, 22 insertions(+), 3 deletions(-) (limited to 'OpenSim/Framework') diff --git a/OpenSim/Framework/Communications/Tests/Cache/UserProfileCacheServiceTests.cs b/OpenSim/Framework/Communications/Tests/Cache/UserProfileCacheServiceTests.cs index e496e45..6fd9440 100644 --- a/OpenSim/Framework/Communications/Tests/Cache/UserProfileCacheServiceTests.cs +++ b/OpenSim/Framework/Communications/Tests/Cache/UserProfileCacheServiceTests.cs @@ -61,6 +61,27 @@ namespace OpenSim.Framework.Communications.Tests lus.AddUser("Bill", "Bailey", "troll", "bill@bailey.com", 1000, 1000, existingUserId); CachedUserInfo existingUserInfo = commsManager.UserProfileCacheService.GetUserDetails(existingUserId); Assert.That(existingUserInfo, Is.Not.Null, "Existing user info unexpectedly not found"); - } + } + + /// + /// Test moving a folder + /// + [Test] + public void TestRequestInventoryForUser() + { + UUID userId = UUID.Parse("00000000-0000-0000-0000-000000000003"); + + CommunicationsManager commsManager = new TestCommunicationsManager(); + LocalUserServices lus = (LocalUserServices)commsManager.UserService; + lus.AddPlugin(new TestUserDataPlugin()); + ((LocalInventoryService)commsManager.InventoryService).AddPlugin(new TestInventoryDataPlugin()); + + lus.AddUser("Bill", "Bailey", "troll", "bill@bailey.com", 1000, 1000, userId); + + commsManager.UserProfileCacheService.RequestInventoryForUser(userId); + + CachedUserInfo userInfo = commsManager.UserProfileCacheService.GetUserDetails(userId); + Assert.That(userInfo.HasReceivedInventory, Is.True); + } } } diff --git a/OpenSim/Framework/Tests/LocationTest.cs b/OpenSim/Framework/Tests/LocationTest.cs index 118ec94..5617e2b 100644 --- a/OpenSim/Framework/Tests/LocationTest.cs +++ b/OpenSim/Framework/Tests/LocationTest.cs @@ -28,7 +28,6 @@ using OpenMetaverse; using NUnit.Framework; using NUnit.Framework.SyntaxHelpers; -using OpenSim.Tests.Common; namespace OpenSim.Framework.Tests { @@ -38,7 +37,6 @@ namespace OpenSim.Framework.Tests [Test] public void locationRegionHandleRegionHandle() { - //1099511628032000 // 256000 // 256000 -- cgit v1.1