Skip to content
Snippets Groups Projects
Commit 587aaf1e authored by Michael Hamann's avatar Michael Hamann
Browse files

[Misc] Fix compilation of flavor tests

parent ed12e755
No related branches found
No related tags found
No related merge requests found
......@@ -101,7 +101,7 @@ public void testRollback() throws Exception
@Test
public void testSaveOfThreeHundredKilobyteDocument() throws Exception
{
final String content = secure().nextAlphanumeric(300000);
final String content = RandomStringUtils.secure().nextAlphanumeric(300000);
final HttpMethod ret =
this.doPostAsAdmin(this.spaceName, this.pageName, null, "save", null,
new HashMap<String, String>() {{
......
......@@ -19,6 +19,7 @@
*/
package org.xwiki.test.ui;
import org.apache.commons.lang3.RandomStringUtils;
import org.junit.Assert;
import org.junit.Rule;
import org.junit.Test;
......@@ -54,7 +55,7 @@ public void testEditButtonTriggersInlineEditing()
@Test
public void testInlineEditCanChangeTitle()
{
String title = secure().nextAlphanumeric(4);
String title = RandomStringUtils.secure().nextAlphanumeric(4);
getUtil().gotoPage(getTestClassName(), getTestMethodName(), "edit", "editor=inline&title=" + title);
InlinePage inlinePage = new InlinePage();
// Check if the title specified on the request is properly displayed.
......@@ -88,7 +89,7 @@ public void testInlineEditCanChangeParent()
@IgnoreBrowser(value = "internet.*", version = "9\\.*", reason="See https://jira.xwiki.org/browse/XE-1177")
public void testInlineEditPreservesTitle()
{
String title = secure().nextAlphanumeric(4);
String title = RandomStringUtils.secure().nextAlphanumeric(4);
getUtil().gotoPage(getTestClassName(), getTestMethodName(), "save", "title=" + title);
ViewPage vp = new ViewPage();
Assert.assertEquals(title, vp.getDocumentTitle());
......@@ -134,8 +135,8 @@ public void testInlineEditPreservesParent()
@IgnoreBrowser(value = "internet.*", version = "9\\.*", reason="See https://jira.xwiki.org/browse/XE-1177")
public void testInlineEditPreservesTags()
{
String tag1 = secure().nextAlphanumeric(4);
String tag2 = secure().nextAlphanumeric(4);
String tag1 = RandomStringUtils.secure().nextAlphanumeric(4);
String tag2 = RandomStringUtils.secure().nextAlphanumeric(4);
getUtil().gotoPage(getTestClassName(), getTestMethodName(), "save", "tags=" + tag1 + "%7C" + tag2);
TaggablePage taggablePage = new TaggablePage();
Assert.assertTrue(taggablePage.hasTag(tag1));
......
......@@ -19,8 +19,8 @@
*/
package org.xwiki.test.ui;
import org.junit.Assert;
import org.apache.commons.lang3.RandomStringUtils;
import org.junit.Assert;
import org.junit.Before;
import org.junit.Rule;
import org.junit.Test;
......@@ -101,7 +101,7 @@ public void testSwitchToWysiwygWithAdvancedContent()
@IgnoreBrowser(value = "internet.*", version = "8\\.*", reason="See https://jira.xwiki.org/browse/XE-1146")
public void testPreviewDisplaysPageTitle()
{
String title = secure().nextAlphanumeric(3);
String title = RandomStringUtils.secure().nextAlphanumeric(3);
this.editPage.setTitle(title);
this.editPage.clickPreview();
// The preview page has the action buttons but otherwise it is similar to a view page.
......
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