com.atlassian.plugin
Class TestStateAware

java.lang.Object
  extended by junit.framework.Assert
      extended by junit.framework.TestCase
          extended by com.atlassian.plugin.TestStateAware
All Implemented Interfaces:
junit.framework.Test

public class TestStateAware
extends junit.framework.TestCase

Tests that the plugin manager properly notifies StateAware plugin modules of state transitions.


Constructor Summary
TestStateAware()
           
 
Method Summary
protected  void setUp()
           
 void testDisabledModuleDescriptorsAreEnabled()
          If a plugin is enabled, any modules that are currently enabled should be sent the enabled message, but modules which are disabled should not.
 void testStateAwareOnInit()
          Any StateAware plugin module that is active when the plugin manager is initialised should recieve an enabled message
 void testStateAwareOnPluginDisable()
          If a plugin is disabled, any modules that are currently enabled should be sent the disabled message
 void testStateAwareOnPluginModule()
          Any StateAware plugin moudle that is explicitly enabled or disabled through the plugin manager should receive the appropriate message
 
Methods inherited from class junit.framework.TestCase
countTestCases, createResult, getName, run, run, runBare, runTest, setName, tearDown, 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
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
 

Constructor Detail

TestStateAware

public TestStateAware()
Method Detail

setUp

protected void setUp()
              throws Exception
Overrides:
setUp in class junit.framework.TestCase
Throws:
Exception

testStateAwareOnInit

public void testStateAwareOnInit()
                          throws PluginParseException
Any StateAware plugin module that is active when the plugin manager is initialised should recieve an enabled message

Throws:
PluginParseException

testStateAwareOnPluginModule

public void testStateAwareOnPluginModule()
                                  throws PluginParseException
Any StateAware plugin moudle that is explicitly enabled or disabled through the plugin manager should receive the appropriate message

Throws:
PluginParseException

testStateAwareOnPluginDisable

public void testStateAwareOnPluginDisable()
                                   throws PluginParseException
If a plugin is disabled, any modules that are currently enabled should be sent the disabled message

Throws:
PluginParseException

testDisabledModuleDescriptorsAreEnabled

public void testDisabledModuleDescriptorsAreEnabled()
                                             throws PluginParseException
If a plugin is enabled, any modules that are currently enabled should be sent the enabled message, but modules which are disabled should not.

Throws:
PluginParseException


Copyright © 2010 Atlassian. All Rights Reserved.