From 48c62eb51bdf475303ee3007354b98fd6fd4fc05 Mon Sep 17 00:00:00 2001 From: Justin Clark-Casey (justincc) Date: Mon, 14 Mar 2011 23:17:15 +0000 Subject: Add current method output to all persistence level tests so that we can track where we are in the test suite --- OpenSim/Data/Tests/InventoryTests.cs | 27 +++++++++++++++++++++++++++ 1 file changed, 27 insertions(+) (limited to 'OpenSim/Data/Tests/InventoryTests.cs') diff --git a/OpenSim/Data/Tests/InventoryTests.cs b/OpenSim/Data/Tests/InventoryTests.cs index 6cf7e20..cf3bac1 100644 --- a/OpenSim/Data/Tests/InventoryTests.cs +++ b/OpenSim/Data/Tests/InventoryTests.cs @@ -30,6 +30,7 @@ using log4net.Config; using NUnit.Framework; using OpenMetaverse; using OpenSim.Framework; +using OpenSim.Tests.Common; using log4net; using System.Reflection; using System.Data.Common; @@ -113,6 +114,8 @@ namespace OpenSim.Data.Tests [Test] public void T001_LoadEmpty() { + TestHelper.InMethod(); + Assert.That(db.getInventoryFolder(zero), Is.Null); Assert.That(db.getInventoryFolder(folder1), Is.Null); Assert.That(db.getInventoryFolder(folder2), Is.Null); @@ -131,6 +134,8 @@ namespace OpenSim.Data.Tests [Test] public void T010_FolderNonParent() { + TestHelper.InMethod(); + InventoryFolderBase f1 = NewFolder(folder2, folder1, owner1, name2); // the folder will go in db.addInventoryFolder(f1); @@ -141,6 +146,8 @@ namespace OpenSim.Data.Tests [Test] public void T011_FolderCreate() { + TestHelper.InMethod(); + InventoryFolderBase f1 = NewFolder(folder1, zero, owner1, name1); // TODO: this is probably wrong behavior, but is what we have // db.updateInventoryFolder(f1); @@ -164,6 +171,8 @@ namespace OpenSim.Data.Tests [Test] public void T012_FolderList() { + TestHelper.InMethod(); + InventoryFolderBase f2 = NewFolder(folder3, folder1, owner1, name3); db.addInventoryFolder(f2); @@ -178,6 +187,8 @@ namespace OpenSim.Data.Tests [Test] public void T013_FolderHierarchy() { + TestHelper.InMethod(); + int n = db.getFolderHierarchy(zero).Count; // (for dbg - easier to see what's returned) Assert.That(n, Is.EqualTo(0), "Assert.That(db.getFolderHierarchy(zero).Count, Is.EqualTo(0))"); n = db.getFolderHierarchy(folder1).Count; @@ -191,6 +202,8 @@ namespace OpenSim.Data.Tests [Test] public void T014_MoveFolder() { + TestHelper.InMethod(); + InventoryFolderBase f2 = db.getInventoryFolder(folder2); f2.ParentID = folder3; db.moveInventoryFolder(f2); @@ -205,6 +218,8 @@ namespace OpenSim.Data.Tests [Test] public void T015_FolderHierarchy() { + TestHelper.InMethod(); + Assert.That(db.getFolderHierarchy(zero).Count, Is.EqualTo(0), "Assert.That(db.getFolderHierarchy(zero).Count, Is.EqualTo(0))"); Assert.That(db.getFolderHierarchy(folder1).Count, Is.EqualTo(2), "Assert.That(db.getFolderHierarchy(folder1).Count, Is.EqualTo(2))"); Assert.That(db.getFolderHierarchy(folder2).Count, Is.EqualTo(0), "Assert.That(db.getFolderHierarchy(folder2).Count, Is.EqualTo(0))"); @@ -216,6 +231,8 @@ namespace OpenSim.Data.Tests [Test] public void T100_NoItems() { + TestHelper.InMethod(); + Assert.That(db.getInventoryInFolder(zero).Count, Is.EqualTo(0), "Assert.That(db.getInventoryInFolder(zero).Count, Is.EqualTo(0))"); Assert.That(db.getInventoryInFolder(folder1).Count, Is.EqualTo(0), "Assert.That(db.getInventoryInFolder(folder1).Count, Is.EqualTo(0))"); Assert.That(db.getInventoryInFolder(folder2).Count, Is.EqualTo(0), "Assert.That(db.getInventoryInFolder(folder2).Count, Is.EqualTo(0))"); @@ -228,6 +245,8 @@ namespace OpenSim.Data.Tests [Test] public void T101_CreatItems() { + TestHelper.InMethod(); + db.addInventoryItem(NewItem(item1, folder3, owner1, iname1, asset1)); db.addInventoryItem(NewItem(item2, folder3, owner1, iname2, asset2)); db.addInventoryItem(NewItem(item3, folder3, owner1, iname3, asset3)); @@ -237,6 +256,8 @@ namespace OpenSim.Data.Tests [Test] public void T102_CompareItems() { + TestHelper.InMethod(); + InventoryItemBase i1 = db.getInventoryItem(item1); InventoryItemBase i2 = db.getInventoryItem(item2); InventoryItemBase i3 = db.getInventoryItem(item3); @@ -254,6 +275,8 @@ namespace OpenSim.Data.Tests [Test] public void T103_UpdateItem() { + TestHelper.InMethod(); + // TODO: probably shouldn't have the ability to have an // owner of an item in a folder not owned by the user @@ -272,6 +295,8 @@ namespace OpenSim.Data.Tests [Test] public void T104_RandomUpdateItem() { + TestHelper.InMethod(); + PropertyScrambler folderScrambler = new PropertyScrambler() .DontScramble(x => x.Owner) @@ -329,6 +354,8 @@ namespace OpenSim.Data.Tests [Test] public void T999_StillNull() { + TestHelper.InMethod(); + // After all tests are run, these should still return no results Assert.That(db.getInventoryFolder(zero), Is.Null); Assert.That(db.getInventoryItem(zero), Is.Null); -- cgit v1.1