com.atlassian.confluence.selenium
Class ViewSpaceTest

java.lang.Object
  extended by junit.framework.Assert
      extended by junit.framework.TestCase
          extended by com.atlassian.confluence.selenium.AbstractSeleniumTest
              extended by com.atlassian.confluence.selenium.ViewSpaceTest
All Implemented Interfaces:
junit.framework.Test

public class ViewSpaceTest
extends AbstractSeleniumTest

Encapsulates tests related to accessing and viewing a Space at its root level.


Field Summary
 
Fields inherited from class com.atlassian.confluence.selenium.AbstractSeleniumTest
adminUser, assertThat, client, rpc, screenShotIndex, suite, testBlogPost, testComment, testData, testGroup, testImage, testImage2, testPage, testSpace, testUser, testUserWithApostrophe, userHelper, users
 
Constructor Summary
ViewSpaceTest()
           
 
Method Summary
protected  void createTestData(ConfluenceRpc adminRpc)
          Overrides createTestData in AbstractSeleniumTest in order to create an additional test Space with a Space Name that contains a potential XSS vulnerability.
 void testSpaceNameContainingXss_DefaultTheme()
          CONF-20667 - Tests that JavaScript injected into the Space title is properly escaped before being rendered in the \ element of every child content page.
 void testSpaceNameContainingXss_DocumentationTheme()
          Tests the fix for CONF-20667 when the documentation theme is enabled (see DOC-70).
 void testSpaceNameContainingXss_EasyReaderTheme()
          Tests the fix for CONF-20667 when the "Easy Reader" theme is enabled.
 
Methods inherited from class com.atlassian.confluence.selenium.AbstractSeleniumTest
captureScreenShot, runBare, runTest, setAjsLogRendered, setAjsLogVisible, setUp, tearDown
 
Methods inherited from class junit.framework.TestCase
countTestCases, createResult, getName, run, run, setName, toString
 
Methods inherited from class junit.framework.Assert
assertEquals, assertEquals, assertEquals, assertEquals, assertEquals, assertEquals, assertEquals, assertEquals, assertEquals, assertEquals, assertEquals, assertEquals, assertEquals, assertEquals, assertEquals, assertEquals, assertEquals, assertEquals, assertEquals, assertEquals, assertFalse, assertFalse, assertNotNull, assertNotNull, assertNotSame, assertNotSame, assertNull, assertNull, assertSame, assertSame, assertTrue, assertTrue, fail, fail, failNotEquals, failNotSame, failSame, format
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
 

Constructor Detail

ViewSpaceTest

public ViewSpaceTest()
Method Detail

createTestData

protected void createTestData(ConfluenceRpc adminRpc)
Overrides createTestData in AbstractSeleniumTest in order to create an additional test Space with a Space Name that contains a potential XSS vulnerability.

Overrides:
createTestData in class AbstractSeleniumTest
Parameters:
adminRpc - The client interface for issuing commands to the Confluence RPC plugin.

testSpaceNameContainingXss_DefaultTheme

public void testSpaceNameContainingXss_DefaultTheme()
CONF-20667 - Tests that JavaScript injected into the Space title is properly escaped before being rendered in the \ element of every child content page.


testSpaceNameContainingXss_DocumentationTheme

public void testSpaceNameContainingXss_DocumentationTheme()
Tests the fix for CONF-20667 when the documentation theme is enabled (see DOC-70).


testSpaceNameContainingXss_EasyReaderTheme

public void testSpaceNameContainingXss_EasyReaderTheme()
Tests the fix for CONF-20667 when the "Easy Reader" theme is enabled. Note that the Easy Reader theme is not specifically exploitable as it does not override main.vmd from the default theme. Providing this test for completeness/peace-of-mind.



Copyright © 2003-2012 Atlassian. All Rights Reserved.