aboutsummaryrefslogtreecommitdiffstatshomepage
path: root/OpenSim/Tests/Common/Helpers/SceneHelpers.cs (unfollow)
Commit message (Collapse)AuthorFilesLines
2012-03-07Stop individually deleting objects at the end of each ObjectTortureTest.Justin Clark-Casey (justincc)1-1/+1
We can now do this since the entire scene and all objects within it are now successfully gc'd at the end of these tests. This greatly improves the time taken to run each test (by reducing teardown time, not the time to actually do the test work that we're interested in). Slightly simplifies config read in Scene constructor to help facilitate this.
2012-03-01Use a fully stubbed out MockConsole for unit tests rather than inheriting ↵Justin Clark-Casey (justincc)1-1/+1
from CommandConsole. This is so that the static MainConsole.Instance doesn't retain references to methods registered by scene and other modules to service commands. This prevents the scene from being garbage collected at the end of a test. This is not the final thing preventing GC - next up is the timer started by SimStatsReporter that holds a reference to Scene that prevents end of test gc.
2012-02-07Add a regression test to compile and start a script. Remove ↵Justin Clark-Casey (justincc)1-3/+20
Path.GetDirectoryName when getting assembly loading path in Compiler.CompileFromDotNetText(). The Path.GetDirectoryName call in Compiler.CompileFromDotNetText is unnecessary since AppDomain.CurrentDomain.BaseDirectory is always a directory. Later path concatenation is already done by Path.Combine() which handles any trailing slash. Removing Path.GetDirectoryName() will not affect the runtime but allows NUnit to work since it doesn't add a trailing slash to AppDomain.CurrentDomain.BaseDirectory.
2011-12-03Split up test SceneHelpers to provide an AddChildScenePresence() callJustin Clark-Casey (justincc)1-10/+25
2011-12-03Add beginning of ScenePresenceAgentTests.TestCreateChildScenePresence()Justin Clark-Casey (justincc)1-0/+3
This required an option to be added to NullRegionData via ConnectionString for it to act as a non-static instance, so that regression tests (which only load this class once) don't get hopeless confused and complex to compensate. Normal standalone operation unaffected.
2011-10-15move see_into_this_sim_from_neighbor [Startup] flag parsing into Scene with ↵Justin Clark-Casey (justincc)1-1/+1
the others
2011-10-15fetch physical_prim switch from [Startup] config from inside scene, as is ↵Justin Clark-Casey (justincc)1-1/+1
done for most other scene config params
2011-08-31get rid of appearance null checks - this is never nullJustin Clark-Casey (justincc)1-0/+1
2011-08-30Fix bug in persisting saved appearances for npcsJustin Clark-Casey (justincc)1-5/+30
Assets have to be marked non-local as well as non-temporary to persist. This is now done. Hopefully addresses http://opensimulator.org/mantis/view.php?id=5660
2011-08-19Stop NPC's getting hypergrid like names in some circumstances.Justin Clark-Casey (justincc)1-0/+1
This meant punching in another AddUser() method in IUserManagement to do a direct name to UUID associated without the account check (since NPCs don't have accounts). May address http://opensimulator.org/mantis/view.php?id=5645
2011-08-18Don't try to save changed attachment states when an NPC with attachments is ↵Justin Clark-Casey (justincc)1-1/+1
removed from the scene. This is done by introducing a PresenceType enum into ScenePresence which currently has two values, User and Npc. This seems better than a SaveAttachments flag in terms of code comprehension, though I'm still slightly uneasy about introducing these semantics to core objects
2011-08-09When an NPC is created, stop telling neighbouring regions to expect a child ↵Justin Clark-Casey (justincc)1-1/+1
agent
2011-08-06refactor: Change SceneHelpers.AddClient() to AddScenePresence().Justin Clark-Casey (justincc)1-4/+4
This seems to make more sense as we can get SP.ControllingClient
2011-08-06rename test SceneSetupHelpers -> SceneHelpers for consistencyJustin Clark-Casey (justincc)1-1/+1
2011-07-09Rename SceneSetupHelpers.AddRootAgent to AddClient() to better represent its ↵Justin Clark-Casey (justincc)1-3/+3
effects and return object
2011-05-21Get rid of OpenSim.Tests.Common.Setup subpackage in favour of just ↵Justin Clark-Casey (justincc)1-1/+1
OpenSim.Tests.Common instead
2011-05-21rename test helpers enclosing package from Setup to HelpersJustin Clark-Casey (justincc)1-0/+0
2011-04-30Moved several cap-based-service-providing modules from where they were into ↵Diva Canto1-1/+0
a newly created CoreModules/Caps. Not all.
2011-04-15get rid of all traces of the now used mock service infrastructureJustin Clark-Casey (justincc)1-30/+2
2011-04-15remove old code for a mock grid service, which got removed some time backJustin Clark-Casey (justincc)1-8/+3
2011-04-15remove any reference to a mock authentication service since it doesn't exist ↵Justin Clark-Casey (justincc)1-12/+7
and we don't use it
2011-04-15remove mock asset service for tests in favour of always using the real oneJustin Clark-Casey (justincc)1-9/+5
2011-04-15Remove the mock inventory service for tests and just use the real one all ↵Justin Clark-Casey (justincc)1-13/+6
the time with an in-memory data plugin
2011-04-15Make all the objects in a coalescence reappears after being loaded from an ↵Justin Clark-Casey (justincc)1-2/+5
IAR. This still doesn't work proprerly since some required textures/contained item assets might be missing. From pure code inspection, it looks like the uuid gatherer may get most asset uuids because the scene object serializer naively pulls non-root parts from all contained scene objects into one mega-object. However, root part uuids may well still be missing, and there may be other odd artifacts from this bug. It appears that storing the size of the coalescence and the offsets is redundant, since one can work out this information from the position data already in the scene object groups.
2011-04-14Make scene object parts created by the test utils unit sized.Justin Clark-Casey (justincc)1-2/+2
2011-04-06Improve previous ILandObject method doc.Justin Clark-Casey (justincc)1-5/+11
For test code, take a part name prefix when creating objects, so that these can be more easily identified in the logs
2011-03-23Add PrimCountModuleTests.TestRemoveOwnerObject().Justin Clark-Casey (justincc)1-5/+22
Also adds SceneSetupHelpers methods to easily create sogs with different part UUIDs
2011-03-23refactor common sop setup parts into a single methodJustin Clark-Casey (justincc)1-17/+23
2011-03-23refactor: simplify part of AddSceneObject() test setup by moving sog ↵Justin Clark-Casey (justincc)1-0/+32
construction into SceneSetupHelpers.CreateSceneObject()
2011-03-09remove inventory service preserving code from SceneSetupHelpers tooJustin Clark-Casey (justincc)1-37/+10
2011-03-09Simplify SceneSetupHelpers class by removing all code which was originally ↵Justin Clark-Casey (justincc)1-53/+40
preserving service instances between tests. This wasn't being used anyway and just leads to hard to diagnose test failures.
2011-03-09Simplify TestLoadIarV0_1AbsentUsers() to use common IAR test setup. Make ↵Justin Clark-Casey (justincc)1-3/+3
static dictionaries on NullUserAccountData instance instead to stop user accounts being carried over between tests
2011-02-19Remove unused SceneSetupHelpers.DeleteObjectAsync().Justin Clark-Casey (justincc)1-19/+0
Calling async code in automated tests is never a good idea - things become very fragile very quickly
2011-02-19remove unused code to share services between scenes in SceneSetupHelpers - ↵Justin Clark-Casey (justincc)1-52/+16
this is done differently elsewhere
2011-02-18Put some CapabilitiesModule null checks in SceneJustin Clark-Casey (justincc)1-4/+4
Stop tests setting up a capabilities module by default
2011-02-18On SceneSetupHelpers, go back to calling ScenePresence.CompleteMovement() ↵Justin Clark-Casey (justincc)1-5/+3
for the last stage of AddRootAgent() instead of SP.MakeRootAgent() Going this extra step doesn't appear to cause any test failures. This is arguably better for test purposes, though at some stage another method may arise which does just call AddRootAgent().
2010-12-14Start implementing a test for 'share with group' object functionality. Not ↵Justin Clark-Casey (justincc)1-1/+4
yet complete. While implementing this, a bug was fixed in scene setup helpers where module RegionLoaded() was called immediately after AddRegion() instead of waiting for all AddRegions() to complete. Also, XmlRpcGroupsModule non-message functionality will now work without a message transfer module (as indicated in the comments but with a contradictory implementation)
2010-10-06Plumb the path for multiple object deletesMelanie1-1/+1
2010-10-06Plumb the path for multiple object deletesMelanie1-1/+1
2010-09-12Fix unit test SceneSetupHelpers to load the mock simulation data storeJohn Hurliman1-1/+1
2010-09-12* Added ISimulationDataService and IEstateDataServiceJohn Hurliman1-2/+3
* Removed StorageManager * CONFIG CHANGE: There are no more database settings in OpenSim.ini. Check the config-include configuration files for region store and estate store database settings
2010-09-12Formatting cleanup.Jeff Ames1-19/+18
2010-09-06Add test to check persistence of newly added pre-linked objectsJustin Clark-Casey (justincc)1-1/+1
Added a MockRegionDataPlugin to do in-memory persistence for tests since adding this to OpenSim.Data.Null.NullDataStore doesn't seem appropriate NullDataStore can do nothing because OpenSim only ever retrieve region objects from the database on startup. Adding an in-memory store here would be unecessary overhead.
2010-08-24Add automated test at the opensim 'api' level to check that a given item ↵Justin Clark-Casey (justincc)1-0/+6
goes to the correct directory Also removes some mono compiler warnings
2010-08-20Unit test breakage fix.Diva Canto1-8/+48
2010-06-04remove pointless mock user account service since the real one can now be ↵Justin Clark-Casey (justincc)1-13/+6
easily configured for test purposes
2010-06-04get TestSaveIarV0_1() working again by setting up an ↵Justin Clark-Casey (justincc)1-1/+1
OpenSim.Data.Null.UserAuthenticationData plugin additional tweaks to get this working properly
2010-05-28get TestSaveIarV0_1() uncommented but not running as a test yet since I ↵Justin Clark-Casey (justincc)1-1/+27
didn't get the authentication server to work and my brain is about to fizzle out my ears
2010-05-21extend TestAddSceneObject() to check Scene.AddNewSceneObject() return booleanJustin Clark-Casey (justincc)1-2/+0
improve test to retrieve object by known uuid rather than dynamically assigned local id
2010-05-04* This should fix the tests failing because of a MainConsole.Instance null ↵Teravus Ovares (Dan Olivares)1-2/+2
reference * Added a MockConsole that doesn't require a handle to System.Console