diff options
author | John Hurliman | 2010-09-12 15:04:51 -0700 |
---|---|---|
committer | John Hurliman | 2010-09-12 15:04:51 -0700 |
commit | 18a9ac6b39b91865c33eeffa1ef8ff3e8a847c1b (patch) | |
tree | fd29cce10b45c9ca2895a0fbd57fa854db81016c /OpenSim/Tests/Common/Mock | |
parent | Merged (diff) | |
download | opensim-SC-18a9ac6b39b91865c33eeffa1ef8ff3e8a847c1b.zip opensim-SC-18a9ac6b39b91865c33eeffa1ef8ff3e8a847c1b.tar.gz opensim-SC-18a9ac6b39b91865c33eeffa1ef8ff3e8a847c1b.tar.bz2 opensim-SC-18a9ac6b39b91865c33eeffa1ef8ff3e8a847c1b.tar.xz |
Fix unit test SceneSetupHelpers to load the mock simulation data store
Diffstat (limited to 'OpenSim/Tests/Common/Mock')
-rw-r--r-- | OpenSim/Tests/Common/Mock/MockRegionDataPlugin.cs | 75 |
1 files changed, 75 insertions, 0 deletions
diff --git a/OpenSim/Tests/Common/Mock/MockRegionDataPlugin.cs b/OpenSim/Tests/Common/Mock/MockRegionDataPlugin.cs index f453a4b..de6e815 100644 --- a/OpenSim/Tests/Common/Mock/MockRegionDataPlugin.cs +++ b/OpenSim/Tests/Common/Mock/MockRegionDataPlugin.cs | |||
@@ -35,6 +35,81 @@ using OpenSim.Region.Framework.Scenes; | |||
35 | 35 | ||
36 | namespace OpenSim.Data.Null | 36 | namespace OpenSim.Data.Null |
37 | { | 37 | { |
38 | public class NullDataService : ISimulationDataService | ||
39 | { | ||
40 | private NullDataStore m_store; | ||
41 | |||
42 | public NullDataService() | ||
43 | { | ||
44 | m_store = new NullDataStore(); | ||
45 | } | ||
46 | |||
47 | public void StoreObject(SceneObjectGroup obj, UUID regionUUID) | ||
48 | { | ||
49 | m_store.StoreObject(obj, regionUUID); | ||
50 | } | ||
51 | |||
52 | public void RemoveObject(UUID uuid, UUID regionUUID) | ||
53 | { | ||
54 | m_store.RemoveObject(uuid, regionUUID); | ||
55 | } | ||
56 | |||
57 | public void StorePrimInventory(UUID primID, ICollection<TaskInventoryItem> items) | ||
58 | { | ||
59 | m_store.StorePrimInventory(primID, items); | ||
60 | } | ||
61 | |||
62 | public List<SceneObjectGroup> LoadObjects(UUID regionUUID) | ||
63 | { | ||
64 | return m_store.LoadObjects(regionUUID); | ||
65 | } | ||
66 | |||
67 | public void StoreTerrain(double[,] terrain, UUID regionID) | ||
68 | { | ||
69 | m_store.StoreTerrain(terrain, regionID); | ||
70 | } | ||
71 | |||
72 | public double[,] LoadTerrain(UUID regionID) | ||
73 | { | ||
74 | return m_store.LoadTerrain(regionID); | ||
75 | } | ||
76 | |||
77 | public void StoreLandObject(ILandObject Parcel) | ||
78 | { | ||
79 | m_store.StoreLandObject(Parcel); | ||
80 | } | ||
81 | |||
82 | public void RemoveLandObject(UUID globalID) | ||
83 | { | ||
84 | m_store.RemoveLandObject(globalID); | ||
85 | } | ||
86 | |||
87 | public List<LandData> LoadLandObjects(UUID regionUUID) | ||
88 | { | ||
89 | return m_store.LoadLandObjects(regionUUID); | ||
90 | } | ||
91 | |||
92 | public void StoreRegionSettings(RegionSettings rs) | ||
93 | { | ||
94 | m_store.StoreRegionSettings(rs); | ||
95 | } | ||
96 | |||
97 | public RegionSettings LoadRegionSettings(UUID regionUUID) | ||
98 | { | ||
99 | return m_store.LoadRegionSettings(regionUUID); | ||
100 | } | ||
101 | |||
102 | public RegionLightShareData LoadRegionWindlightSettings(UUID regionUUID) | ||
103 | { | ||
104 | return m_store.LoadRegionWindlightSettings(regionUUID); | ||
105 | } | ||
106 | |||
107 | public void StoreRegionWindlightSettings(RegionLightShareData wl) | ||
108 | { | ||
109 | m_store.StoreRegionWindlightSettings(wl); | ||
110 | } | ||
111 | } | ||
112 | |||
38 | /// <summary> | 113 | /// <summary> |
39 | /// Mock region data plugin. This obeys the api contract for persistence but stores everything in memory, so that | 114 | /// Mock region data plugin. This obeys the api contract for persistence but stores everything in memory, so that |
40 | /// tests can check correct persistence. | 115 | /// tests can check correct persistence. |