aboutsummaryrefslogtreecommitdiffstatshomepage
path: root/OpenSim/Tests/Common/Helpers/SceneHelpers.cs (follow)
Commit message (Collapse)AuthorAgeFilesLines
* One more module converted: GodsModule.Diva Canto2012-11-101-3/+3
|
* Fix Unit tests -- the module contract was not being honored in the set up of ↵Diva Canto2012-11-101-6/+6
| | | | scenes.
* Fix regression introduced in a0d178b2 (Sat Aug 25 02:00:17 2012) where ↵Justin Clark-Casey (justincc)2012-08-291-1/+1
| | | | | | | | | | | folders with asset type of 'Folder' and 'Unknown' were accidentally treated as system folders. This prevented more than one additional ordinary folder from being created in the base "My Inventory" user folder. Added regression test for this case. Switched tests to use XInventoryService with mostly implemented TestXInventoryDataPlugin rather than InventoryService Disabled TestLoadIarV0_1SameNameCreator() since this has not been working for a very long time (ever since XInventoryService) started being used since it doesnt' preserve creator data in the same way as InventoryService did and so effectively lost the OSPAs. However, nobody noticed/complained about this issue and OSPAs have been superseded by HG like creator information via the --home save oar/iar switch.
* Add EventManager.OnRegionLoginsStatusChange fired whenever logins are ↵Justin Clark-Casey (justincc)2012-07-191-1/+1
| | | | | | | enabled or disabled at any point, not just during initial startup. This replaces EventManager.OnLoginsEnabled which only fired when logins were first enabled and was affected by a bug where it would never fire if the region started with logins disabled.
* Do not allow a script to attach a prim if its being sat upon.Justin Clark-Casey (justincc)2012-07-091-17/+58
| | | | | | This prevents a stack overflow where a get position on the avatar will refer to the attachment which will in turn refer back to the avatar. This required recording of all sitting avatars on a prim which is done separately from recording the sit target avatar. Recording HashSet is null if there are no sitting avatars in order to save memory.
* Remove redundant SetScene() function in Scene.AddSceneObject()Justin Clark-Casey (justincc)2012-07-071-3/+20
| | | | | This is always done later on in SceneGraph.AddSceneObject() if the call hasn't failed due to sanity checks. There's no other purpose for this method to exist and it's dangerous/pointless to call in other conditions.
* Add OSSL function osForceAttachToAvatarFromInventory()Justin Clark-Casey (justincc)2012-07-051-5/+5
| | | | | | | This works like osForceAttachToAvatar() but allows an object to be directly specified from the script object's inventory rather than forcing it to be rezzed in the scene first. Still only attaches objects to the owner of the script. This allows one to bypass the complicated co-ordination of first rezzing objects in the scene before attaching them. Threat level high.
* Fix bug where an avatar that had an object they owned attached through ↵Justin Clark-Casey (justincc)2012-05-231-3/+4
| | | | | | | llAttachToAvatar() or osForceAttachToAvatar() would wrongly have next permissions come into play when they detached that object and rezzed it in scene. This is because the attachments module code was setting the 'object slam' bit by using PermissionMask.All Solution here is to route the attachment item creation call through the existing inventory code in BasicInventoryAccessModule rather than copy/pasted code in AttachmentsModule itself.
* Fix issue where loading OARs could sometimes result in link numbers being ↵Justin Clark-Casey (justincc)2012-05-151-4/+4
| | | | | | | | | | reordered. This was because the parts in scene objects were sometimes not serialized in link order. This is perfectly fine since the parts still have the right link numbers, but an extra fix to adjust for this had not been done in the SerialiserModule methods that OAR loading used. Add regression test for same. Addresses http://opensimulator.org/mantis/view.php?id=5948, http://opensimulator.org/mantis/view.php?id=5749
* Fix mono compiler warning.Justin Clark-Casey (justincc)2012-05-121-1/+1
| | | | Last jenkins failure looked like a glitch.
* Add regression test for teleporting between neighbouring regions on the same ↵Justin Clark-Casey (justincc)2012-05-011-4/+68
| | | | | | | simulator This adds a non-advertised wait_for_callback option in [EntityTransfer]. Default is always true. Teleport tests disable the wait for callback from the destination region in order to run within a single thread.
* Add regression test for teleporting an agent between separated regions on ↵Justin Clark-Casey (justincc)2012-04-271-90/+128
| | | | | | | | the same simulator. This involves a large amount of change in test scene setup code to allow test scenes to share shared modules SetupScene is now an instance method that requires an instantiation of SceneHelpers, though other SceneHelpers methods are still static May split these out into separate classes in the future.
* Add TestSetPhysics() to SOP status testsJustin Clark-Casey (justincc)2012-04-211-1/+1
|
* Add simple login test with online friends. Add IFriendsModule.GrantRights() ↵Justin Clark-Casey (justincc)2012-03-301-3/+9
| | | | | | | for granting rights via a module call. Rename IFriendsModule.GetFriendPerms() -> GetRightsGrantedByFriend() to be more self-documenting and consistent with friends module terminology. Add some method doc.
* Stop individually deleting objects at the end of each ObjectTortureTest.Justin Clark-Casey (justincc)2012-03-071-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.
* Use a fully stubbed out MockConsole for unit tests rather than inheriting ↵Justin Clark-Casey (justincc)2012-03-011-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.
* Add a regression test to compile and start a script. Remove ↵Justin Clark-Casey (justincc)2012-02-071-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.
* Split up test SceneHelpers to provide an AddChildScenePresence() callJustin Clark-Casey (justincc)2011-12-031-10/+25
|
* Add beginning of ScenePresenceAgentTests.TestCreateChildScenePresence()Justin Clark-Casey (justincc)2011-12-031-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.
* move see_into_this_sim_from_neighbor [Startup] flag parsing into Scene with ↵Justin Clark-Casey (justincc)2011-10-151-1/+1
| | | | the others
* fetch physical_prim switch from [Startup] config from inside scene, as is ↵Justin Clark-Casey (justincc)2011-10-151-1/+1
| | | | done for most other scene config params
* get rid of appearance null checks - this is never nullJustin Clark-Casey (justincc)2011-08-311-0/+1
|
* Fix bug in persisting saved appearances for npcsJustin Clark-Casey (justincc)2011-08-301-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
* Stop NPC's getting hypergrid like names in some circumstances.Justin Clark-Casey (justincc)2011-08-191-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
* Don't try to save changed attachment states when an NPC with attachments is ↵Justin Clark-Casey (justincc)2011-08-181-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
* When an NPC is created, stop telling neighbouring regions to expect a child ↵Justin Clark-Casey (justincc)2011-08-091-1/+1
| | | | agent
* refactor: Change SceneHelpers.AddClient() to AddScenePresence().Justin Clark-Casey (justincc)2011-08-061-4/+4
| | | | This seems to make more sense as we can get SP.ControllingClient
* rename test SceneSetupHelpers -> SceneHelpers for consistencyJustin Clark-Casey (justincc)2011-08-061-0/+483