use of org.xwiki.bridge.event.ActionExecutedEvent in project xwiki-platform by xwiki.
the class ActionExecutedEventTest method testConstructorWithActionName.
@Test
public void testConstructorWithActionName() {
ActionExecutedEvent event = new ActionExecutedEvent("something");
Assert.assertEquals("Action name was lost!", "something", event.getActionName());
}
use of org.xwiki.bridge.event.ActionExecutedEvent in project xwiki-platform by xwiki.
the class ActionExecutedEventTest method testMatchesSameAction.
@Test
public void testMatchesSameAction() {
ActionExecutedEvent event = new ActionExecutedEvent("something");
Assert.assertTrue("Same action wasn't matched!", event.matches(new ActionExecutedEvent("something")));
}
use of org.xwiki.bridge.event.ActionExecutedEvent in project xwiki-platform by xwiki.
the class ActionExecutedEventTest method testDoesntMatchDifferentAction.
@Test
public void testDoesntMatchDifferentAction() {
ActionExecutedEvent event = new ActionExecutedEvent("something");
Assert.assertFalse("A different action was matched!", event.matches(new ActionExecutedEvent("else")));
}
use of org.xwiki.bridge.event.ActionExecutedEvent in project xwiki-platform by xwiki.
the class ActionExecutedEventTest method testEqualsSameObject.
// Tests for equals(Object)
@Test
public void testEqualsSameObject() {
ActionExecutedEvent event = new ActionExecutedEvent("something");
Assert.assertTrue("Same object wasn't equal!", event.equals(event));
}
use of org.xwiki.bridge.event.ActionExecutedEvent in project xwiki-platform by xwiki.
the class ActionExecutedEventTest method testDoesntEqualDifferentCaseAction.
@Test
public void testDoesntEqualDifferentCaseAction() {
ActionExecutedEvent event = new ActionExecutedEvent("something");
Assert.assertFalse("Action equals comparison was case insensitive!", event.equals(new ActionExecutedEvent("SomeThing")));
}
Aggregations