Skip to content
Snippets Groups Projects
Commit d61add1d authored by tmortagne's avatar tmortagne
Browse files

XWIKI-11565: Wiki descriptors retrieved from the cache are the internal references

* so much for writing unit tests
parent edb89fdc
No related branches found
No related tags found
No related merge requests found
......@@ -300,7 +300,7 @@ public WikiDescriptor clone()
// Clone properties
descriptor.propertyGroups = new HashMap<>(this.propertyGroups.size());
for (WikiPropertyGroup group : this.propertyGroups.values()) {
propertyGroups.put(group.getId(), group.clone());
descriptor.propertyGroups.put(group.getId(), group.clone());
}
return descriptor;
......
......@@ -269,6 +269,7 @@ public void getMainWikiDescriptor() throws Exception
assertEquals(descriptor, this.mocker.getComponentUnderTest().getMainWikiDescriptor());
}
@Test
public void testCacheProtection() throws WikiManagerException, ComponentLookupException
{
DefaultWikiDescriptor descriptor = new DefaultWikiDescriptor("xwiki", "xwiki");
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment