Skip to content
Snippets Groups Projects
Commit 3d204784 authored by Thomas Mortagne's avatar Thomas Mortagne
Browse files

XWIKI-14591: Discourage or prevent users to move/rename pages from Extensions

* fix tests
parent 4a2f3c40
No related branches found
No related tags found
No related merge requests found
......@@ -38,6 +38,7 @@
import org.xwiki.test.mockito.MockitoComponentMockingRule;
import static org.mockito.ArgumentMatchers.any;
import static org.mockito.Mockito.atLeastOnce;
import static org.mockito.Mockito.mock;
import static org.mockito.Mockito.never;
import static org.mockito.Mockito.times;
......@@ -124,7 +125,7 @@ public void deleteSpaceHomeDeep() throws Throwable
run(request);
// We only verify if the job fetches the documents from the space. The rest of the test is in #deleteSpace()
verify(this.modelBridge).getDocumentReferences(documentReference.getLastSpaceReference());
verify(this.modelBridge, atLeastOnce()).getDocumentReferences(documentReference.getLastSpaceReference());
}
@Test
......
......@@ -103,7 +103,7 @@ public void renameSpaceHomeDeep() throws Throwable
run(request);
// We verify that job fetches the space children.
verify(this.modelBridge).getDocumentReferences(aliceReference.getLastSpaceReference());
verify(this.modelBridge, atLeastOnce()).getDocumentReferences(aliceReference.getLastSpaceReference());
}
@Test
......@@ -115,7 +115,7 @@ public void renameSpace() throws Throwable
run(createRequest(aliceReference, bobReference));
// We verify that job fetches the space children.
verify(this.modelBridge).getDocumentReferences(aliceReference);
verify(this.modelBridge, atLeastOnce()).getDocumentReferences(aliceReference);
}
@Test
......
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