aboutsummaryrefslogtreecommitdiffstatshomepage
path: root/OpenSim/Region/ScriptEngine/Shared/Tests (unfollow)
Commit message (Collapse)AuthorFilesLines
2013-03-11minor: Remove mono compiler warnings from LSL_ApiHttpTestsJustin Clark-Casey (justincc)1-1/+0
2013-02-28Add regression tests for llGetNotecardLine()Justin Clark-Casey (justincc)3-3/+273
2013-02-27minor: remove some mono compiler warnings in script regression testsJustin Clark-Casey (justincc)1-1/+1
2013-02-27Add regression test for llReleaseUrl() (and for llRequestUrl)Justin Clark-Casey (justincc)1-0/+250
Forgot to add file for llRequestUrl() test in commit b8a7c8b
2013-01-16JustinCC's core re-mergeMelanie7-24/+32
2013-01-16Implement co-operative script termination if termination comes during a ↵Justin Clark-Casey (justincc)7-26/+23
script wait event (llSleep(), etc.) This makes use of EventWaitHandles since various web references indicate that Thread.Interrupt() can also cause runtime instability. If co-op termination is enabled, then termination sets the wait handle instead of waiting for a timeout before possibly aborting the thread. This allows the script to cleanly terminate if it's in a llSleep/LL function delay or the next time it enters such a wait without any timeout period. Co-op termination is not yet testable since checking for termination request within loops that never trigger a wait is not yet implemented. This commit, unlike 1b5c41c, passes the wait handle as an extra parameter through IScript.Initialize() instead of passing IScriptInstance itself.
2013-01-15Instead of passing separate engine, part and item components to script APIs, ↵Justin Clark-Casey (justincc)7-24/+35
pass down IScriptInstance instead. This is to allow the future co-operative script thread terminate feature to detect and act upon termination requests. This splits the assembly and state loading out from the ScriptInstance() constructor to a separate Load() method in order to facilititate continued script logic regression testing.
2012-12-05Remove some mono warnings in script tests, chiefly where SetUp() wasn't ↵Justin Clark-Casey (justincc)5-7/+13
properly calling to OpenSimTestCase.SetUp()
2012-11-24Consistenly make NUnit test cases inherit from OpenSimTestCase which ↵Justin Clark-Casey (justincc)9-9/+9
automatically turns off any logging enabled between tests
2012-11-15Revert "Merge master into teravuswork", it should have been avination, not ↵teravus3-316/+72
master. This reverts commit dfac269032300872c4d0dc507f4f9062d102b0f4, reversing changes made to 619c39e5144f15aca129d6d999bcc5c34133ee64.
2012-10-25Get osNpcCreate() and osNpcLoadAppearance() to generate a script error if ↵Justin Clark-Casey (justincc)1-6/+24
appearance notecard does not exist, rather than returning UUID.Zero or silently failing.
2012-10-25Make osNpcCreate() return UUID.Zero instead of throwing an exception if ↵Justin Clark-Casey (justincc)2-4/+56
notecard name is invalid. Make osNpcLoadAppearance() fail silently in same circumstance rather than throwing exception.
2012-10-25Add TestOsNpcLoadAppearance()Justin Clark-Casey (justincc)2-4/+45
2012-10-25Move npc creation tests involving appearance from OSSL_ApiAppearanceTest to ↵Justin Clark-Casey (justincc)2-70/+69
OSSL_ApiNpcTests This is a more intuitive location.
2012-09-22Fix llListFindList() returning no match when there is a match with a script ↵Justin Clark-Casey (justincc)1-0/+134
constant component in the source list. Adds regression test for this case. Based on http://opensimulator.org/mantis/view.php?id=6156 Thanks SignpostMarv.
2012-07-10Disable logging in regression test in OSSL_ApiAttachmentTestsJustin Clark-Casey (justincc)1-1/+1
2012-07-09This script allows an object to be attached directly from prim inventory to ↵Justin Clark-Casey (justincc)1-0/+53
another avatar in the scene. Very useful in serious game/environment scenarios where its only allowed for trusted creators. Threat level Severe
2012-07-07minor: remove some recent mono compiler warningsJustin Clark-Casey (justincc)1-1/+1
2012-07-07Remove redundant SetScene() function in Scene.AddSceneObject()Justin Clark-Casey (justincc)2-10/+10
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)4-5/+188
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-05-08Add automated TestllBreakLink()Justin Clark-Casey (justincc)1-0/+27
2012-05-08Add automated TestllCreateLink()Justin Clark-Casey (justincc)1-0/+112
2012-05-08refactor: Eliminate local id parameter from api initialize.Justin Clark-Casey (justincc)4-13/+12
This is always available from m_host.LocalId
2012-05-08Instead of constantly looking up unchanging self item in script code, pass ↵Justin Clark-Casey (justincc)4-13/+13
in self item on initialization.
2012-04-27Add regression test for teleporting an agent between separated regions on ↵Justin Clark-Casey (justincc)4-5/+5
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-03-22Fix llGiveInventory() so that it checks the destination part for ↵Justin Clark-Casey (justincc)1-1/+58
AllowInventoryDrop, not the source. This allows llAllowInventoryDrop() to work. Regression test added for this case.
2012-03-22Add llGiveInventory() test from object to object where both objects are ↵Justin Clark-Casey (justincc)1-0/+111
owned by the same user.
2012-03-06Get all test methods in OpenSim.Region.ScriptEngine.Tests.dll to report that ↵Justin Clark-Casey (justincc)6-25/+127
they're running
2012-01-12Add missing assert to confirm owner delete succeeded to the end of ↵Justin Clark-Casey (justincc)1-0/+2
TestOsNpcRemoveOwned()
2012-01-12Add api level test for removing an owned npcJustin Clark-Casey (justincc)1-2/+55
2012-01-12Add ossl level test for removing an unowned npcJustin Clark-Casey (justincc)1-0/+115
2012-01-06Fixed llAngleBetween() to allow denormal rotationsJohn Cochran1-15/+32
2012-01-06Add script instruction count back to llRot2Euler. Other minor ↵Justin Clark-Casey (justincc)1-14/+20
formatting/doc changes.
2012-01-06Replaced llRot2Euler function.John Cochran1-18/+79
The original function suffered from unexpected results due to rounding errors. An error of only 1 or 2 ulps would cause the code to not detect a singularity at Y rotation +/- PI/2 and take the non-singularity code path. The replacement code does not suffer from wildly inaccurate results at the +/- PI/2 singularity. The check in the code for the singularity isn't strictly needed, but gives more consistent results At the singularity, the X and Z rotations add. The if check simply forces the X rotation to be zero so the entirety of the X+Z rotation is carried by Z. Additionally, the test code has been updated to include test cases that caused the old code to fail. The test algorithm is also updated to perform a more meaningful test. The original code checked if the values against expected values. This could fail at +/- PI rotations since a rotation around an axis by PI causes the identical effect as a rotation by -PI. The new test code checks that the returned angles can be used to recreate a quaternion that causes the same rotation.
2012-01-06Replaced llRot2Euler function.John Cochran1-18/+79
The original function suffered from unexpected results due to rounding errors. An error of only 1 or 2 ulps would cause the code to not detect a singularity at Y rotation +/- PI/2 and take the non-singularity code path. The replacement code does not suffer from wildly inaccurate results at the +/- PI/2 singularity. The check in the code for the singularity isn't strictly needed, but gives more consistent results At the singularity, the X and Z rotations add. The if check simply forces the X rotation to be zero so the entirety of the X+Z rotation is carried by Z. Additionally, the test code has been updated to include test cases that caused the old code to fail. The test algorithm is also updated to perform a more meaningful test. The original code checked if the values against expected values. This could fail at +/- PI rotations since a rotation around an axis by PI causes the identical effect as a rotation by -PI. The new test code checks that the returned angles can be used to recreate a quaternion that causes the same rotation.
2011-09-09llSetPrimitiveParams Prim type params precision errorsMicheil Merlin1-25/+33
2011-08-25llSetPrimitiveParams correct prim hollow for cases where limit should be 70%.Micheil Merlin1-11/+64
Signed-off-by: BlueWall <jamesh@bluewallgroup.com>
2011-08-13llGetPrimitiveParams fix prim hollow/hole shape valueMicheil Merlin1-0/+175
2011-08-12Allow the osNpcCreate() function to accept a notecard name or asset for ↵Justin Clark-Casey (justincc)1-2/+2
initial appearance
2011-08-11Implement osAgentSaveAppearance() to save the appearance of an avatar in the ↵Justin Clark-Casey (justincc)1-0/+41
region to a notecard This is separate from osOwnerSaveAppearance() so that owner saves can be allowed without allowing arbitrary avatar saves
2011-08-11add regression test for osNpcCreate when cloning an in-region avatarJustin Clark-Casey (justincc)1-7/+72
2011-08-11Split out to-be-common setup stuff from TestOsOwnerSaveAppearance()Justin Clark-Casey (justincc)1-15/+33
2011-08-09Add osOwnerSaveAppearance() to help with setting up NPC appearances. Not ↵Justin Clark-Casey (justincc)1-0/+105
yet ready for user use. Adds regression test.
2011-08-06rename test SceneSetupHelpers -> SceneHelpers for consistencyJustin Clark-Casey (justincc)1-2/+2
2011-05-21Get rid of OpenSim.Tests.Common.Setup subpackage in favour of just ↵Justin Clark-Casey (justincc)1-1/+0
OpenSim.Tests.Common instead
2010-11-27llVecNorm nant testMicheil Merlin1-0/+24
2010-09-03llRot2Euler TestsMicheil Merlin1-0/+30
2009-08-16* ShortVersion, another attempt at fixing the test thread death that ↵Teravus Ovares (Dan Olivares)1-1/+2
randomly occurs. * LongVersion nIni may be causing the test thread death. Pausing OpenSimulator during startup causes a nIni error that makes debugging startup operations difficult for users. It might be because when it's in pause mode, something else reads from the nini config passed? If it is, it might not be fixable.. however, if it's concurrency that causes nini death it would make sense to give each section of the tests a new IConfigSource so that they don't read from the same configsource at the same time.
2009-06-12Give m_test* methods more reasonable namesMike Mazur1-13/+13
Changing the names of these methods because they were being picked up by nunit as tests even though they were marked private. Naming them Check* after the original Test*.
2009-06-07Rename private TestllAngleBetween methodMike Mazur1-13/+13
It seems overloading the method TestllAngleBetween confused nunit a bit and caused it to try running the private TestllAngleBetween method. The method's access modified prevented that from happening, and nunit complained.