aboutsummaryrefslogtreecommitdiffstatshomepage
path: root/OpenSim/Region/Framework/Scenes/Tests/UuidGathererTests.cs
diff options
context:
space:
mode:
Diffstat (limited to '')
-rw-r--r--OpenSim/Region/Framework/Scenes/Tests/UuidGathererTests.cs39
1 files changed, 38 insertions, 1 deletions
diff --git a/OpenSim/Region/Framework/Scenes/Tests/UuidGathererTests.cs b/OpenSim/Region/Framework/Scenes/Tests/UuidGathererTests.cs
index 4ae27d7..0b41039 100644
--- a/OpenSim/Region/Framework/Scenes/Tests/UuidGathererTests.cs
+++ b/OpenSim/Region/Framework/Scenes/Tests/UuidGathererTests.cs
@@ -89,7 +89,7 @@ namespace OpenSim.Region.Framework.Scenes.Tests
89 { 89 {
90 TestHelpers.InMethod(); 90 TestHelpers.InMethod();
91// TestHelpers.EnableLogging(); 91// TestHelpers.EnableLogging();
92 92
93 UUID ownerId = TestHelpers.ParseTail(0x10); 93 UUID ownerId = TestHelpers.ParseTail(0x10);
94 UUID embeddedId = TestHelpers.ParseTail(0x20); 94 UUID embeddedId = TestHelpers.ParseTail(0x20);
95 UUID secondLevelEmbeddedId = TestHelpers.ParseTail(0x21); 95 UUID secondLevelEmbeddedId = TestHelpers.ParseTail(0x21);
@@ -120,5 +120,42 @@ namespace OpenSim.Region.Framework.Scenes.Tests
120 Assert.That(m_uuidGatherer.GatheredUuids.ContainsKey(embeddedId)); 120 Assert.That(m_uuidGatherer.GatheredUuids.ContainsKey(embeddedId));
121 Assert.That(m_uuidGatherer.GatheredUuids.ContainsKey(secondLevelEmbeddedId)); 121 Assert.That(m_uuidGatherer.GatheredUuids.ContainsKey(secondLevelEmbeddedId));
122 } 122 }
123
124 [Test]
125 public void TestTaskItem()
126 {
127 TestHelpers.InMethod();
128 TestHelpers.EnableLogging();
129
130 UUID ownerId = TestHelpers.ParseTail(0x10);
131 UUID embeddedId = TestHelpers.ParseTail(0x20);
132 UUID secondLevelEmbeddedId = TestHelpers.ParseTail(0x21);
133 UUID missingEmbeddedId = TestHelpers.ParseTail(0x22);
134 UUID ncAssetId = TestHelpers.ParseTail(0x30);
135
136 AssetBase ncAsset
137 = AssetHelpers.CreateNotecardAsset(
138 ncAssetId, string.Format("Hello{0}World{1}", embeddedId, missingEmbeddedId));
139 m_assetService.Store(ncAsset);
140
141 AssetBase embeddedAsset
142 = AssetHelpers.CreateNotecardAsset(embeddedId, string.Format("{0} We'll meet again.", secondLevelEmbeddedId));
143 m_assetService.Store(embeddedAsset);
144
145 AssetBase secondLevelEmbeddedAsset
146 = AssetHelpers.CreateNotecardAsset(secondLevelEmbeddedId, "Don't know where, don't know when.");
147 m_assetService.Store(secondLevelEmbeddedAsset);
148
149 m_uuidGatherer.AddForInspection(ncAssetId);
150 m_uuidGatherer.GatherAll();
151
152 // foreach (UUID key in m_uuidGatherer.GatheredUuids.Keys)
153 // System.Console.WriteLine("key : {0}", key);
154
155 Assert.That(m_uuidGatherer.GatheredUuids.Count, Is.EqualTo(3));
156 Assert.That(m_uuidGatherer.GatheredUuids.ContainsKey(ncAssetId));
157 Assert.That(m_uuidGatherer.GatheredUuids.ContainsKey(embeddedId));
158 Assert.That(m_uuidGatherer.GatheredUuids.ContainsKey(secondLevelEmbeddedId));
159 }
123 } 160 }
124} \ No newline at end of file 161} \ No newline at end of file