|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectorg.fest.swing.fixture.ComponentFixture<T>
org.fest.swing.fixture.ContainerFixture<JInternalFrame>
org.fest.swing.fixture.JInternalFrameFixture
public class JInternalFrameFixture
Understands functional testing of s:
JInternalFrame
| Field Summary |
|---|
| Fields inherited from class org.fest.swing.fixture.ComponentFixture |
|---|
BACKGROUND_PROPERTY, FONT_PROPERTY, FOREGROUND_PROPERTY, robot, target |
| Fields inherited from interface org.fest.swing.fixture.ComponentContainerFixture |
|---|
DEFAULT_DIALOG_LOOKUP_TIMEOUT |
| Constructor Summary | |
|---|---|
JInternalFrameFixture(Robot robot,
JInternalFrame target)
Creates a new . |
|
JInternalFrameFixture(Robot robot,
String internalFrameName)
Creates a new . |
|
| Method Summary | |
|---|---|
JInternalFrameFixture |
click()
Simulates a user clicking this fixture's . |
JInternalFrameFixture |
click(MouseButton button)
Simulates a user clicking this fixture's . |
JInternalFrameFixture |
click(MouseClickInfo mouseClickInfo)
Simulates a user clicking this fixture's . |
Object |
clientProperty(Object key)
Returns the client property stored in this fixture's , under the given key. |
void |
close()
Simulates a user closing this fixture's . |
JInternalFrameFixture |
deiconify()
Simulates a user deiconifying this fixture's . |
JInternalFrameFixture |
doubleClick()
Simulates a user double-clicking this fixture's . |
protected void |
driver(JInternalFrameDriver newDriver)
Sets the to be used by this fixture. |
JInternalFrameFixture |
focus()
Gives input focus to this fixture's . |
JInternalFrameFixture |
iconify()
Simulates a user iconifying this fixture's . |
JInternalFrameFixture |
maximize()
Simulates a user maximizing this fixture's , deconifying it first if it is
iconified. |
JInternalFrameFixture |
moveTo(Point p)
Simulates a user moving this fixture's to the given point. |
JInternalFrameFixture |
moveToBack()
Brings this fixture's to the back. |
JInternalFrameFixture |
moveToFront()
Brings this fixture's to the front. |
JInternalFrameFixture |
normalize()
Simulates a user normalizing this fixture's , deconifying it first if it is
iconified. |
JInternalFrameFixture |
pressAndReleaseKey(KeyPressInfo keyPressInfo)
Simulates a user pressing given key with the given modifiers on this fixture's . |
JInternalFrameFixture |
pressAndReleaseKeys(int... keyCodes)
Simulates a user pressing and releasing the given keys on this fixture's . |
JInternalFrameFixture |
pressKey(int keyCode)
Simulates a user pressing given key on this fixture's . |
JInternalFrameFixture |
releaseKey(int keyCode)
Simulates a user releasing the given key on this fixture's . |
JInternalFrameFixture |
requireDisabled()
Asserts that this fixture's is disabled. |
JInternalFrameFixture |
requireEnabled()
Asserts that this fixture's is enabled. |
JInternalFrameFixture |
requireEnabled(Timeout timeout)
Asserts that this fixture's is enabled. |
JInternalFrameFixture |
requireFocused()
Asserts that this fixture's has input focus. |
JInternalFrameFixture |
requireNotVisible()
Asserts that this fixture's is not visible. |
JInternalFrameFixture |
requireSize(Dimension size)
Asserts that the size of this fixture's is equal to given one. |
JInternalFrameFixture |
requireToolTip(Pattern pattern)
Asserts that the toolTip in this fixture's matches the given regular expression
pattern. |
JInternalFrameFixture |
requireToolTip(String expected)
Asserts that the toolTip in this fixture's matches the given value. |
JInternalFrameFixture |
requireVisible()
Asserts that this fixture's is visible. |
JInternalFrameFixture |
resizeHeightTo(int height)
Simulates a user resizing vertically this fixture's . |
JInternalFrameFixture |
resizeTo(Dimension size)
Simulates a user resizing this fixture's . |
JInternalFrameFixture |
resizeWidthTo(int width)
Simulates a user resizing horizontally this fixture's . |
JInternalFrameFixture |
rightClick()
Simulates a user right-clicking this fixture's . |
JPopupMenuFixture |
showPopupMenu()
Shows a pop-up menu using this fixture's as the invoker of the pop-up menu. |
JPopupMenuFixture |
showPopupMenuAt(Point p)
Shows a pop-up menu at the given point using this fixture's as the invoker of
the pop-up menu. |
| Methods inherited from class org.fest.swing.fixture.ContainerFixture |
|---|
button, button, button, checkBox, checkBox, checkBox, comboBox, comboBox, comboBox, dialog, dialog, dialog, dialog, dialog, dialog, fileChooser, fileChooser, fileChooser, fileChooser, fileChooser, fileChooser, find, findByName, findByType, finder, label, label, label, list, list, list, menuItem, menuItem, menuItemWithPath, optionPane, optionPane, panel, panel, panel, progressBar, progressBar, progressBar, radioButton, radioButton, radioButton, scrollBar, scrollBar, scrollBar, scrollPane, scrollPane, scrollPane, slider, slider, slider, spinner, spinner, spinner, splitPane, splitPane, splitPane, tabbedPane, tabbedPane, tabbedPane, table, table, table, textBox, textBox, textBox, toggleButton, toggleButton, toggleButton, toolBar, toolBar, toolBar, tree, tree, tree, with |
| Methods inherited from class org.fest.swing.fixture.ComponentFixture |
|---|
background, component, font, foreground, requireShowing, targetCastedTo, validateNotNull |
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Constructor Detail |
|---|
public JInternalFrameFixture(Robot robot,
String internalFrameName)
JInternalFrameFixture.
robot - performs simulation of user events on a JInternalFrame.internalFrameName - the name of the JInternalFrame to find using the given Robot.
NullPointerException - if robot is null.
ComponentLookupException - if a matching JInternalFrame could not be found.
ComponentLookupException - if more than one matching JInternalFrame is found.
public JInternalFrameFixture(Robot robot,
JInternalFrame target)
JInternalFrameFixture.
robot - performs simulation of user events on the given JInternalFrame.target - the JInternalFrame to be managed by this fixture.
NullPointerException - if robot is null.
NullPointerException - if target is null.| Method Detail |
|---|
protected final void driver(JInternalFrameDriver newDriver)
JInternalFrameDriver to be used by this fixture.
newDriver - the new JInternalFrameDriver.
NullPointerException - if the given driver is null.public JInternalFrameFixture moveToFront()
JInternalFrame to the front.
moveToFront in interface WindowLikeContainerFixturepublic JInternalFrameFixture moveToBack()
JInternalFrame to the back.
moveToBack in interface WindowLikeContainerFixturepublic JInternalFrameFixture deiconify()
JInternalFrame.
deiconify in interface FrameLikeFixtureActionFailedException - if the JInternalFrame vetoes the action.public JInternalFrameFixture iconify()
JInternalFrame.
iconify in interface FrameLikeFixtureActionFailedException - if the given JInternalFrame is not iconifiable.
ActionFailedException - if the JInternalFrame vetoes the action.public JInternalFrameFixture maximize()
JInternalFrame, deconifying it first if it is
iconified.
maximize in interface FrameLikeFixtureActionFailedException - if the given JInternalFrame is not maximizable.
ActionFailedException - if the JInternalFrame vetoes the action.public JInternalFrameFixture normalize()
JInternalFrame, deconifying it first if it is
iconified.
normalize in interface FrameLikeFixtureActionFailedException - if the JInternalFrame vetoes the action.public void close()
JInternalFrame.
close in interface WindowLikeContainerFixtureActionFailedException - if the JInternalFrame is not closable.public JInternalFrameFixture requireSize(Dimension size)
JInternalFrame is equal to given one.
requireSize in interface WindowLikeContainerFixturesize - the given size to match.
AssertionError - if the size of this fixture's JInternalFrame is not equal to the given size.public JInternalFrameFixture resizeWidthTo(int width)
JInternalFrame.
resizeWidthTo in interface WindowLikeContainerFixturewidth - the width that this fixture's JInternalFrame should have after being resized.
public JInternalFrameFixture resizeHeightTo(int height)
JInternalFrame.
resizeHeightTo in interface WindowLikeContainerFixtureheight - the height that this fixture's JInternalFrame should have after being resized.
public JInternalFrameFixture resizeTo(Dimension size)
JInternalFrame.
resizeTo in interface WindowLikeContainerFixturesize - the size that the target JInternalFrame should have after being resized.
public JInternalFrameFixture moveTo(Point p)
JInternalFrame to the given point.
moveTo in interface WindowLikeContainerFixturep - the point to move this fixture's JInternalFrame to.
public JInternalFrameFixture click()
JInternalFrame.
click in interface MouseInputSimulationFixturepublic JInternalFrameFixture click(MouseButton button)
JInternalFrame.
click in interface MouseInputSimulationFixturebutton - the button to click.
public JInternalFrameFixture click(MouseClickInfo mouseClickInfo)
JInternalFrame.
click in interface MouseInputSimulationFixturemouseClickInfo - specifies the button to click and the times the button should be clicked.
NullPointerException - if the given MouseClickInfo is null.public JInternalFrameFixture rightClick()
JInternalFrame.
rightClick in interface MouseInputSimulationFixturepublic JInternalFrameFixture doubleClick()
JInternalFrame.
doubleClick in interface MouseInputSimulationFixturepublic JInternalFrameFixture focus()
JInternalFrame.
focus in interface FocusableComponentFixturepublic JInternalFrameFixture pressAndReleaseKey(KeyPressInfo keyPressInfo)
JInternalFrame.
Modifiers is a mask from the available InputEvent masks.
pressAndReleaseKey in interface KeyboardInputSimulationFixturekeyPressInfo - specifies the key and modifiers to press.
NullPointerException - if the given KeyPressInfo is null.
IllegalArgumentException - if the given code is not a valid key code.KeyPressInfopublic JInternalFrameFixture pressAndReleaseKeys(int... keyCodes)
JInternalFrame .
pressAndReleaseKeys in interface KeyboardInputSimulationFixturekeyCodes - one or more codes of the keys to press.
NullPointerException - if the given array of codes is null.
IllegalArgumentException - if any of the given code is not a valid key code.KeyEventpublic JInternalFrameFixture pressKey(int keyCode)
JInternalFrame.
pressKey in interface KeyboardInputSimulationFixturekeyCode - the code of the key to press.
IllegalArgumentException - if any of the given code is not a valid key code.KeyEventpublic JInternalFrameFixture releaseKey(int keyCode)
JInternalFrame.
releaseKey in interface KeyboardInputSimulationFixturekeyCode - the code of the key to release.
IllegalArgumentException - if any of the given code is not a valid key code.KeyEventpublic JInternalFrameFixture requireFocused()
JInternalFrame has input focus.
requireFocused in interface FocusableComponentFixtureAssertionError - if this fixture's JInternalFrame does not have input focus.public JInternalFrameFixture requireEnabled()
JInternalFrame is enabled.
requireEnabled in interface StateVerificationFixtureAssertionError - if the managed JInternalFrame is disabled.public JInternalFrameFixture requireEnabled(Timeout timeout)
JInternalFrame is enabled.
requireEnabled in interface StateVerificationFixturetimeout - the time this fixture will wait for the component to be enabled.
WaitTimedOutError - if the managed JInternalFrame is never enabled.public JInternalFrameFixture requireDisabled()
JInternalFrame is disabled.
requireDisabled in interface StateVerificationFixtureAssertionError - if the managed JInternalFrame is enabled.public JInternalFrameFixture requireVisible()
JInternalFrame is visible.
requireVisible in interface StateVerificationFixtureAssertionError - if the managed JInternalFrame is not visible.public JInternalFrameFixture requireNotVisible()
JInternalFrame is not visible.
requireNotVisible in interface StateVerificationFixtureAssertionError - if the managed JInternalFrame is visible.public JInternalFrameFixture requireToolTip(String expected)
JInternalFrame matches the given value.
requireToolTip in interface ToolTipDisplayFixtureexpected - the given value. It can be a regular expression.
AssertionError - if the toolTip in this fixture's JInternalFrame does not match the given value.public JInternalFrameFixture requireToolTip(Pattern pattern)
JInternalFrame matches the given regular expression
pattern.
requireToolTip in interface ToolTipDisplayFixturepattern - the regular expression pattern to match.
NullPointerException - if the given regular expression pattern is null.
AssertionError - if the toolTip in this fixture's JInternalFrame does not match the given
regular expression.public Object clientProperty(Object key)
JInternalFrame, under the given key.
clientProperty in interface ClientPropertyStorageFixturekey - the key to use to retrieve the client property.
null if the property was
not found.
NullPointerException - if the given key is null.public JPopupMenuFixture showPopupMenu()
JInternalFrame as the invoker of the pop-up menu.
showPopupMenu in interface JPopupMenuInvokerFixtureIllegalStateException - if this fixture's JInternalFrame is disabled.
IllegalStateException - if this fixture's JInternalFrame is not showing on the screen.
ComponentLookupException - if a pop-up menu cannot be found.public JPopupMenuFixture showPopupMenuAt(Point p)
JInternalFrame as the invoker of
the pop-up menu.
showPopupMenuAt in interface JPopupMenuInvokerFixturep - the given point where to show the pop-up menu.
IllegalStateException - if this fixture's JInternalFrame is disabled.
IllegalStateException - if this fixture's JInternalFrame is not showing on the screen.
ComponentLookupException - if a pop-up menu cannot be found.
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||