Commit Graph

164 Commits (b490050165571bb9da87c3457db1a4b0b5c96dee)

Author SHA1 Message Date
Melanie e7819ce909 Port Avination's collision fixes to core. 2012-05-15 01:02:38 +01:00
Justin Clark-Casey (justincc) f0406f9fe2 Rename SOG.HasChildPrim(uint) to SOG.ContainsPart(uint) to match existing ContainsPart method and remove method duplication.
HasChildPrim is also misleading since the 'root' prim can also be returned.
2012-03-31 01:45:37 +01:00
Justin Clark-Casey (justincc) 55c6cbabfd refactor: change RezScriptFromAgentInventory(), RezNewScript() and AddInventoryItem() to accept an agent id rather than a full IClientAPI.
This stops some code having to make spurious client == null checks and reduces regression test complexity.
2012-01-26 00:10:37 +00:00
Dan Lake e2c51a977d Changes UpdateFlag in SOP to an enumeration of NONE, TERSE and FULL.
UpdateFlag is now referenced/used only within SOP and SOG. Outsiders are
using ScheduleFullUpdate, ScheduleTerseUpdate or ClearUpdateSchedule on
SOP consistently now. Also started working toward eliminating those
calls to ScheduleFullUpdate, ScheduleTerseUpdate or ClearUpdateSchedule
from outside SOP in favor of just setting properties on SOP and let SOP
decide if an update should be scheduled. This consolidates the update
policy within SOP and the client rather than everywhere that makes
changes to SOP. Some places forget to call update while others call it
multiple times, "just to be sure".

UpdateFlag and Schedule*Update will both be made private shortly.

UpdateFlag is intended to be transient and internal to SOP so it has
been removed from XML serializer for SOPs.
2011-11-02 14:59:00 -07:00
Justin Clark-Casey (justincc) 33a894f3d2 refactor: move SOP.IsAttachment and AttachmentPoint up into SOG to avoid pointless duplication of identical values 2011-08-27 00:15:21 +01:00
Justin Clark-Casey (justincc) dad1d6df18 rename TestHelper => TestHelpers for consistency 2011-08-06 00:31:03 +01:00
Justin Clark-Casey (justincc) fdcf910e00 Fix a bug in T015_LargeSceneObjects() where the large scene object was stored 31 times (1 time for each added part) instead of once at the end, even though only the largest 31 prim scene object was retrieved and tested.
This considerably speeds up the test, when on sqlite it now only takes 2 seconds rather than 30+
2011-03-14 23:35:03 +00:00
Justin Clark-Casey (justincc) 38c3be07b8 when retrieving a sog in database tests, don't bother adding the scene since this isn't used 2011-03-14 23:32:44 +00:00
Justin Clark-Casey (justincc) 8509678e48 Add method doc to T015_LargeSceneObjects() and slightly clean up formatting.
This test takes a considerable time on SQLite but should remain since it's testing storage and retrieval of a scene object with 31 parts.
2011-03-14 23:26:50 +00:00
Justin Clark-Casey (justincc) 48c62eb51b Add current method output to all persistence level tests so that we can track where we are in the test suite 2011-03-14 23:17:15 +00:00
Justin Clark-Casey (justincc) f6f8d124d1 minor: remove mono compiler warning 2011-03-12 00:52:43 +00:00
Justin Clark-Casey (justincc) 9456bb77fb Upgrade nunit.framework.dll to version 2.5.9. Fix up tests appropriately.
This version removes the NUnit.Framework.SyntaxHelpers namespace, so any modules with their own tests will need to delete this using statement.
2011-03-09 23:25:24 +00:00
Marck 7c02d5cec5 Another attempt at fixing failing test for creator info. 2010-11-26 23:04:31 +01:00
Diva Canto a4bf6c5343 Attempt at fixing failing test. 2010-11-23 07:44:42 -08:00
John Hurliman 860b2a502f Changed SceneObjectGroup to store parts with the fast and thread-safe MapAndArray collection 2010-09-16 17:30:46 -07:00
Jeff Ames f1f0bc23f4 Formatting cleanup. 2010-09-12 13:43:49 -04:00
Jeff Ames 20cd1da6bf Add copyright headers. 2010-09-12 12:54:31 -04:00
John Hurliman 109b517583 Fixed the naming mess around data connectors for simulation data 2010-09-11 20:43:06 -07:00
Justin Clark-Casey (justincc) 289c21099c Add automated test at the opensim 'api' level to check that a given item goes to the correct directory
Also removes some mono compiler warnings
2010-08-24 16:50:31 +01:00
Justin Clark-Casey (justincc) 39a748b47a refactor: Use SOP.Flags rather than SOP.ObjectFlags 2010-08-13 20:23:53 +01:00
Justin Clark-Casey (justincc) 5d83b3f991 comment out obsolete assert that 'item has been passed to another user since it was last set' perms flag was set when a prim item was added to a scene object 2010-07-14 17:53:43 +01:00
Melanie dd14016885 Revamp the permissions propagation. This MAY mess up. Please test.
Change the slam bit from 3 to 4. Assume the old slam bit is always set.
The new slam bit is a "changed owner" bit, correcting a bug where an item
passed from the creator to another with less than full perms, then back (sale
test) would arrive back full perm. Lots of in-code docs.
2010-07-13 20:45:16 +01:00
Justin Clark-Casey (justincc) 5c322335e5 add sqlite database back to database tests
this appears to be okay even though we reuse it between runs without deleting it first.
size of the database appears not to be changing though that could be deceptive
2010-06-04 18:27:16 +01:00
AlexRa 5d65ef2db3 Minor correction to AssetTests.cs
(forgot to change test descriptions, has no effect on running the tests)
2010-05-26 10:25:56 +03:00
AlexRa 57f4729eea Ensured that tests are skipped for wrong conn string, also m_log chng
The base test class now tries to connect to DB, ignores all tests in the
class if unable to.

Also m_log changed to instance field (which in this case shouldn't cause
any problems),  to avoid having to define it separately in each derived
class.  Here I touched things that I don't understand well (using log4net),
so please review this commit.
2010-05-23 12:46:33 +03:00
AlexRa 89b7c64b6f Various minor changes in the data tests 2010-05-23 11:48:22 +03:00
AlexRa 2537acc04d Unitests: Asset, Estate, Region (the "legacy" one), Inventory
The tests have been modified to work under NUnit 2.4.6
(the one currently used in the project).

They will also work with NUnit 2.5+ as is, but will look better
if you #define NUNIT25 for them.
2010-05-23 11:48:10 +03:00
AlexRa 330ad501a5 Added MS SQL test conn to INI - only as an example, modify before use!!!
NOTE that this INI file is currently loaded as a embedded RESOURCE, which is weird and has a
disadvantage of having to rebuild the Tests whenever the conn strings are changed.
The only reason is that I couldn't figure out a reliable way to put this INI into the correct
dir at runtime. If somebody can do it, that would be cool.
2010-05-23 11:48:08 +03:00
AlexRa b1e6e99506 BasicAssetTest.cs replaced by AssetTests.cs
AssetTests: The name has changed to reflect the fact it is no longer a base class,
but the complete asset test for all supported databases.

The test can also check storing of CreatorID, but the feature is
disabled at this commit!
2010-05-23 11:48:02 +03:00
AlexRa 749cf0f6eb Bugfix in tests (must clear db before migrations, not after) 2010-05-23 11:47:59 +03:00
AlexRa f527584ed3 EstateData tests passing on all DBs 2010-05-23 11:47:56 +03:00
AlexRa 94f4c20866 Corrections in RegionTests.cs. It now fully works!
The problem was that some tests relied on prior tests
to leave the DB in a particular state, but the test class
cleared the DB every time. The affected tests have been
merged into one to remove the dependencies.

tested on all 3 Dbs, all tests green.
2010-05-23 11:47:54 +03:00
AlexRa 6322a085b3 Minor corrections in BasicDataServiceTest.cs
(added more functions for cleaning up DB from the
derived tests)
2010-05-23 11:47:51 +03:00
AlexRa 7f70ae0ebd All data tests made DBMS-independent 2010-05-23 11:47:39 +03:00
AlexRa 91ad1f4ee7 Added generic base classes for testing database services
These are some generic classes that simplify writing tests
for any of the data connectors and databases. Among other
things, configuring the connection strings is done once,
in a separate resource file.

Tests based on the new BasicDataServiceTest class require
NUnit 2.5 or better.
2010-05-23 11:47:36 +03:00
AlexRa ce787a4c41 Series of patches to include creator ID in assets.
Contains a migration.

SQLite: May contain nuts.

The SQLite migration copies the entire asset table. Be prepared for quite a wait. Don't interrupt it. Back up your assets db.

BasicAssetTest checks CreatorID storage, new test for weird CreatorID

(now also checks that non-GUID or empty CreatorID gets stored correctly)

Signed-off-by: Melanie <melanie@t-data.com>
2010-05-20 11:01:51 +01:00
AlexRa d6a6668bd7 Scrambled asset type in BasicAssetTest.cs!
The asset type wasn't in the list of "DontScramble" fields,
so the test assets were stored with randomized type, which
caused exception on reading them.

Also the scrambler was moved from local var to the class level,
so it could be used in the new tests I've added (see the next commit).
2010-05-19 21:50:34 +03:00
Justin Clark-Casey (justincc) cc67de5b86 rename SQLiteNG to SQLite and SQLite to SQLiteLegacy
this seems the least evil way forward since mono 2.6 and later will see increasing usage, and this only works with what was SQLiteNG
MAC USERS WILL NEED TO CHANGE REFERENCES TO "OpenSim.Data.SQLite.dll" to "OpenSim.Data.SQLiteLegacy.dll" in OpenSim.ini and config-include/StandaloneCommon.ini (if using standalone)
See the OpenSim.ini.example and StandaloneCommon.ini.example files for more details
This commit also temporarily changes unsigned ParentEstateID values in the OpenSim.Data.Tests to signed temporarily, since the new plugin enforces creation of signed fields in the database (which is what the SQL actually specifies).  And change data columns in sqlite is a pita.
2010-04-30 17:45:00 +01:00
Melanie 70b0e07d1e Remove the reading of estate_settings.xml and the associated processing of
defaults. Adding code to facilitate estate creation / managemment as part of
first time start up
2010-03-22 18:49:56 +00:00
Diva Canto 763285aaf1 Fixed SQL tests. 2010-03-02 07:29:41 -08:00
John Hurliman df76e95aa2 Changed asset CreatorID to a string 2010-02-22 14:18:59 -08:00
John Hurliman 71c6559a91 Merge branch 'presence-refactor' of ssh://opensimulator.org/var/git/opensim into presence-refactor 2010-02-22 14:10:19 -08:00
John Hurliman 7665aad002 * Adds CreatorID to asset metadata. This is just the plumbing to support CreatorID, it doesn't modify database backends or OAR files to support storing/loading it 2010-02-22 13:27:17 -08:00
Melanie 1f45e6c649 Merge branch 'master' into presence-refactor
This brings presence-refactor up to master again
2010-02-22 03:00:59 +00:00
Diva Canto b92645ac56 MySQL tests pass, except T016_RandomSogWithSceneParts. Total mystery as to why that test doesn't show in panda. 2010-02-21 17:59:00 -08:00
Diva Canto bb171717ce Deleted obsolete files in the Data layer. Compiles. 2010-02-21 15:38:52 -08:00
Justin Clark-Casey (justincc) 4355bcc417 Disable Data.BasicRegioNTest.T016_RandomSogWithSceneParts() temporarily since it's making the tests fail but the cause is not obvious (wrapped up in layers of reflection) 2010-02-16 19:31:49 +00:00
Melanie 61f63fdc38 Put PassCollision on the ignore list for testing, since we don't save that
yet.
2009-12-31 23:51:53 +00:00
Kunnis 4c61fcfc40 Getting rid of the dead field RootInventoryFolderId on UserProfileData, It's not even stored in mysql.
Signed-off-by: Melanie <melanie@t-data.com>
2009-12-06 03:57:15 +00:00
Justin Clark-Casey (justincc) 0f745e928f Apply patch that fixes the failing T013_eStateSettingsRandomStorage test
See http://opensimulator.org/mantis/view.php?id=3993
Thanks Kunnis
2009-11-27 18:52:20 +00:00