diff options
author | Tom Grimshaw | 2010-05-29 01:07:19 -0700 |
---|---|---|
committer | Tom Grimshaw | 2010-05-29 01:07:19 -0700 |
commit | 3a5d379db840570b4a759afc1f51ff82e61a5887 (patch) | |
tree | bef5b2e8149a89d49e38e9e8cfbbb48e0fa0db29 /OpenSim/Tests/Common/Setup/SceneSetupHelpers.cs | |
parent | Stop IGridService from throwing a fatal exception when an IPEndPoint cannot b... (diff) | |
parent | Get the user's DOB back from the server response properly. (diff) | |
download | opensim-SC_OLD-3a5d379db840570b4a759afc1f51ff82e61a5887.zip opensim-SC_OLD-3a5d379db840570b4a759afc1f51ff82e61a5887.tar.gz opensim-SC_OLD-3a5d379db840570b4a759afc1f51ff82e61a5887.tar.bz2 opensim-SC_OLD-3a5d379db840570b4a759afc1f51ff82e61a5887.tar.xz |
Merge branch 'careminster-presence-refactor' of ssh://3dhosting.de/var/git/careminster into careminster-presence-refactor
Diffstat (limited to 'OpenSim/Tests/Common/Setup/SceneSetupHelpers.cs')
-rw-r--r-- | OpenSim/Tests/Common/Setup/SceneSetupHelpers.cs | 28 |
1 files changed, 27 insertions, 1 deletions
diff --git a/OpenSim/Tests/Common/Setup/SceneSetupHelpers.cs b/OpenSim/Tests/Common/Setup/SceneSetupHelpers.cs index 91cf323..2756324 100644 --- a/OpenSim/Tests/Common/Setup/SceneSetupHelpers.cs +++ b/OpenSim/Tests/Common/Setup/SceneSetupHelpers.cs | |||
@@ -42,6 +42,7 @@ using OpenSim.Region.Framework.Scenes; | |||
42 | using OpenSim.Region.CoreModules.Agent.Capabilities; | 42 | using OpenSim.Region.CoreModules.Agent.Capabilities; |
43 | using OpenSim.Region.CoreModules.Avatar.Gods; | 43 | using OpenSim.Region.CoreModules.Avatar.Gods; |
44 | using OpenSim.Region.CoreModules.ServiceConnectorsOut.Asset; | 44 | using OpenSim.Region.CoreModules.ServiceConnectorsOut.Asset; |
45 | using OpenSim.Region.CoreModules.ServiceConnectorsOut.Authentication; | ||
45 | using OpenSim.Region.CoreModules.ServiceConnectorsOut.Inventory; | 46 | using OpenSim.Region.CoreModules.ServiceConnectorsOut.Inventory; |
46 | using OpenSim.Region.CoreModules.ServiceConnectorsOut.Grid; | 47 | using OpenSim.Region.CoreModules.ServiceConnectorsOut.Grid; |
47 | using OpenSim.Region.CoreModules.ServiceConnectorsOut.UserAccounts; | 48 | using OpenSim.Region.CoreModules.ServiceConnectorsOut.UserAccounts; |
@@ -58,6 +59,7 @@ namespace OpenSim.Tests.Common.Setup | |||
58 | // These static variables in order to allow regions to be linked by shared modules and same | 59 | // These static variables in order to allow regions to be linked by shared modules and same |
59 | // CommunicationsManager. | 60 | // CommunicationsManager. |
60 | private static ISharedRegionModule m_assetService = null; | 61 | private static ISharedRegionModule m_assetService = null; |
62 | // private static ISharedRegionModule m_authenticationService = null; | ||
61 | private static ISharedRegionModule m_inventoryService = null; | 63 | private static ISharedRegionModule m_inventoryService = null; |
62 | private static ISharedRegionModule m_gridService = null; | 64 | private static ISharedRegionModule m_gridService = null; |
63 | private static ISharedRegionModule m_userAccountService = null; | 65 | private static ISharedRegionModule m_userAccountService = null; |
@@ -177,6 +179,9 @@ namespace OpenSim.Tests.Common.Setup | |||
177 | StartAssetService(testScene, true); | 179 | StartAssetService(testScene, true); |
178 | else | 180 | else |
179 | StartAssetService(testScene, false); | 181 | StartAssetService(testScene, false); |
182 | |||
183 | // For now, always started a 'real' authenication service | ||
184 | StartAuthenticationService(testScene, true); | ||
180 | 185 | ||
181 | if (realServices.Contains("inventory")) | 186 | if (realServices.Contains("inventory")) |
182 | StartInventoryService(testScene, true); | 187 | StartInventoryService(testScene, true); |
@@ -236,13 +241,34 @@ namespace OpenSim.Tests.Common.Setup | |||
236 | else | 241 | else |
237 | config.Configs["AssetService"].Set("LocalServiceModule", "OpenSim.Tests.Common.dll:MockAssetService"); | 242 | config.Configs["AssetService"].Set("LocalServiceModule", "OpenSim.Tests.Common.dll:MockAssetService"); |
238 | config.Configs["AssetService"].Set("StorageProvider", "OpenSim.Tests.Common.dll"); | 243 | config.Configs["AssetService"].Set("StorageProvider", "OpenSim.Tests.Common.dll"); |
239 | assetService.Initialise(config); | 244 | assetService.Initialise(config); |
240 | assetService.AddRegion(testScene); | 245 | assetService.AddRegion(testScene); |
241 | assetService.RegionLoaded(testScene); | 246 | assetService.RegionLoaded(testScene); |
242 | testScene.AddRegionModule(assetService.Name, assetService); | 247 | testScene.AddRegionModule(assetService.Name, assetService); |
243 | m_assetService = assetService; | 248 | m_assetService = assetService; |
244 | } | 249 | } |
245 | 250 | ||
251 | private static void StartAuthenticationService(Scene testScene, bool real) | ||
252 | { | ||
253 | ISharedRegionModule service = new LocalAuthenticationServicesConnector(); | ||
254 | IConfigSource config = new IniConfigSource(); | ||
255 | config.AddConfig("Modules"); | ||
256 | config.AddConfig("AuthenticationService"); | ||
257 | config.Configs["Modules"].Set("AuthenticationServices", "LocalAuthenticationServicesConnector"); | ||
258 | if (real) | ||
259 | config.Configs["AuthenticationService"].Set( | ||
260 | "LocalServiceModule", "OpenSim.Services.AuthenticationService.dll:PasswordAuthenticationService"); | ||
261 | else | ||
262 | config.Configs["AuthenticationService"].Set( | ||
263 | "LocalServiceModule", "OpenSim.Tests.Common.dll:MockuthenticationService"); | ||
264 | config.Configs["AuthenticationService"].Set("StorageProvider", "OpenSim.Data.Null.dll"); | ||
265 | service.Initialise(config); | ||
266 | service.AddRegion(testScene); | ||
267 | service.RegionLoaded(testScene); | ||
268 | testScene.AddRegionModule(service.Name, service); | ||
269 | //m_authenticationService = service; | ||
270 | } | ||
271 | |||
246 | private static void StartInventoryService(Scene testScene, bool real) | 272 | private static void StartInventoryService(Scene testScene, bool real) |
247 | { | 273 | { |
248 | ISharedRegionModule inventoryService = new LocalInventoryServicesConnector(); | 274 | ISharedRegionModule inventoryService = new LocalInventoryServicesConnector(); |