aboutsummaryrefslogtreecommitdiffstatshomepage
path: root/OpenSim/Tests/Common/Helpers (unfollow)
Commit message (Collapse)AuthorFilesLines
2013-05-09Fix issue where objects removed via llDie() would not disappear for users ↵Justin Clark-Casey (justincc)2-52/+4
looking in from neighbouring sims. This was because this particular code path (unlike user delete) only sent kills to root presences, for no apparent good reason. Added regression test for this case. This fixes http://opensimulator.org/mantis/view.php?id=6627
2013-04-29Add TestRejectGivenFolder() and TestAcceptGivenFolder() regression testsJustin Clark-Casey (justincc)1-4/+37
2013-03-20Add file missing from last commit 36651beJustin Clark-Casey (justincc)1-0/+91
2013-03-20On the later forms of teleport failure, tell the user if this was because ↵Justin Clark-Casey (justincc)1-6/+31
viewer couldn't/didn't connect with destination or if destination didn't signal teleport completion. Also adds regression test for the case where the viewer couldn't connect with the destination region. Also refactoring of regression test support code associated with entity transfer in order to make this test possible and the code less obscure.
2013-02-28Add regression tests for llGetNotecardLine()Justin Clark-Casey (justincc)1-6/+26
2013-02-16Add regression test TestSaveNonRootFolderToIarJustin Clark-Casey (justincc)1-20/+89
2013-02-06Remove long unused Scene.DumpAssetsToFile boolean.Justin Clark-Casey (justincc)1-1/+1
2012-11-15Revert "Merge master into teravuswork", it should have been avination, not ↵teravus2-4/+2
master. This reverts commit dfac269032300872c4d0dc507f4f9062d102b0f4, reversing changes made to 619c39e5144f15aca129d6d999bcc5c34133ee64.
2012-11-13minor: Add some explanative method doc to SceneHelpers.SetupSceneModules()Justin Clark-Casey (justincc)1-0/+4
2012-11-12Remove the old style module loader and all references to itMelanie1-1/+1
2012-11-12Remove IRegionModule support from the test setup helperMelanie1-23/+5
2012-11-11Fix issues with the DynamicTextureModule and corresponding unit tests.Diva Canto1-5/+5
2012-11-10One more module converted: GodsModule.Diva Canto1-3/+3
2012-11-10Fix Unit tests -- the module contract was not being honored in the set up of ↵Diva Canto1-6/+6
scenes.
2012-08-29Fix regression introduced in a0d178b2 (Sat Aug 25 02:00:17 2012) where ↵Justin Clark-Casey (justincc)2-2/+4
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.
2012-07-24extend regression TestDetachScriptedAttachementToInventory() to check ↵Justin Clark-Casey (justincc)1-2/+20
correct running status on a re-rezzed attachment
2012-07-19Add EventManager.OnRegionLoginsStatusChange fired whenever logins are ↵Justin Clark-Casey (justincc)1-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.
2012-07-11Add regression TestDetachScriptedAttachmentToInventory()Justin Clark-Casey (justincc)1-1/+1
This currently only does a relatively crude check for a ScriptState node in the serialized xml
2012-07-11Add regression TestRezScriptedAttachmentsFromInventory() though this ↵Justin Clark-Casey (justincc)2-22/+59
currently only checks for the presence of script items, not for started scripts
2012-07-09Do not allow a script to attach a prim if its being sat upon.Justin Clark-Casey (justincc)2-17/+67
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.
2012-07-07Remove redundant SetScene() function in Scene.AddSceneObject()Justin Clark-Casey (justincc)1-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.
2012-07-05Add OSSL function osForceAttachToAvatarFromInventory()Justin Clark-Casey (justincc)2-10/+47
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.
2012-06-26refactor: Remove unnecessary AttachmentModuleTests.m_userId in favour of ↵Justin Clark-Casey (justincc)1-0/+5
local variables
2012-05-23Fix bug where an avatar that had an object they owned attached through ↵Justin Clark-Casey (justincc)1-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.
2012-05-15Fix issue where loading OARs could sometimes result in link numbers being ↵Justin Clark-Casey (justincc)1-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
2012-05-12Fix mono compiler warning.Justin Clark-Casey (justincc)1-1/+1
Last jenkins failure looked like a glitch.
2012-05-01Add regression test for teleporting between neighbouring regions on the same ↵Justin Clark-Casey (justincc)1-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.
2012-04-27Add regression test for teleporting an agent between separated regions on ↵Justin Clark-Casey (justincc)1-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.
2012-04-21Add TestSetPhysics() to SOP status testsJustin Clark-Casey (justincc)1-1/+1
2012-03-30Add simple login test with online friends. Add IFriendsModule.GrantRights() ↵Justin Clark-Casey (justincc)1-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.
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 TestAddTaskInventoryItem()Justin Clark-Casey (justincc)1-3/+9
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-22Get UUIDGatherer to scan notecards in the graph for asset uuids.Justin Clark-Casey (justincc)1-3/+14
This is to support npc baked texture saving in oars and iars. May address http://opensimulator.org/mantis/view.php?id=5743
2011-10-22redirect UserInventoryHelpers to use a different CreateNotecardAsset() so we ↵Justin Clark-Casey (justincc)2-12/+19
can comment out some inconsistency
2011-10-22correct misleading method doc on CreateNotecardAsset()Justin Clark-Casey (justincc)1-1/+1
2011-10-22in AssetHelpers, store the actual text passed in to the method, not the ↵Justin Clark-Casey (justincc)1-2/+2
string "data"
2011-10-22encode notecard assets in proper format for tests, rather than just using ↵Justin Clark-Casey (justincc)1-1/+6
whatever string is given
2011-10-22refactor: rename some AssetHelpers.CreateAsset() methods to ↵Justin Clark-Casey (justincc)2-5/+5
CreateNotecardAsset()
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-09-08Use scene presence agent id for rezzed object ownership rather than item owner.Justin Clark-Casey (justincc)1-2/+1
These should be identical. However, the item isn't available when rezzing npc attachments.
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-17Add new regression TestRezAttachmentsOnAvatarEntrance() to do simple ↵Justin Clark-Casey (justincc)2-9/+36
attachments check