• 设为首页
  • 点击收藏
  • 手机版
    手机扫一扫访问
    迪恩网络手机版
  • 关注官方公众号
    微信扫一扫关注
    迪恩网络公众号

Java GuiActionRunner类代码示例

原作者: [db:作者] 来自: [db:来源] 收藏 邀请

本文整理汇总了Java中org.assertj.swing.edt.GuiActionRunner的典型用法代码示例。如果您正苦于以下问题:Java GuiActionRunner类的具体用法?Java GuiActionRunner怎么用?Java GuiActionRunner使用的例子?那么恭喜您, 这里精选的类代码示例或许可以为您提供帮助。



GuiActionRunner类属于org.assertj.swing.edt包,在下文中一共展示了GuiActionRunner类的20个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于我们的系统推荐出更棒的Java代码示例。

示例1: testSaveSettingsWithoutParse

import org.assertj.swing.edt.GuiActionRunner; //导入依赖的package包/类
@Test
public void testSaveSettingsWithoutParse() {
    GuiActionRunner.execute(() -> {
        frame.spinner("count").target().setValue(642);
        frame.radioButton("bracketsCurly").target().setSelected(true);
        frame.radioButton("separatorSemicolon").target().setSelected(true);
        frame.checkBox("spaceAfterSeparator").target().setSelected(false);
    });

    arraySettingsDialog.saveSettings();

    assertThat(arraySettings.getCount()).isEqualTo(642);
    assertThat(arraySettings.getBrackets()).isEqualTo("{}");
    assertThat(arraySettings.getSeparator()).isEqualTo(";");
    assertThat(arraySettings.isSpaceAfterSeparator()).isEqualTo(false);
}
 
开发者ID:FWDekker,项目名称:intellij-randomness,代码行数:17,代码来源:ArraySettingsDialogTest.java


示例2: testSaveSettingsWithoutParse

import org.assertj.swing.edt.GuiActionRunner; //导入依赖的package包/类
@Test
public void testSaveSettingsWithoutParse() {
    final Set<Alphabet> newAlphabets = createAlphabetSet(Alphabet.DIGITS, Alphabet.LOWERCASE, Alphabet.SPECIAL);

    GuiActionRunner.execute(() -> {
        frame.spinner("minLength").target().setValue(445);
        frame.spinner("maxLength").target().setValue(803);
        frame.radioButton("enclosureBacktick").target().setSelected(true);
        frame.list("alphabets").target().setSelectedIndices(toIndexForEach(newAlphabets));
    });

    stringSettingsDialog.saveSettings();

    assertThat(stringSettings.getMinLength()).isEqualTo(445);
    assertThat(stringSettings.getMaxLength()).isEqualTo(803);
    assertThat(stringSettings.getEnclosure()).isEqualTo("`");
    assertThat(stringSettings.getAlphabets()).isEqualTo(newAlphabets);
}
 
开发者ID:FWDekker,项目名称:intellij-randomness,代码行数:19,代码来源:StringSettingsDialogTest.java


示例3: testSaveSettingsWithoutParse

import org.assertj.swing.edt.GuiActionRunner; //导入依赖的package包/类
@Test
public void testSaveSettingsWithoutParse() {
    GuiActionRunner.execute(() -> {
        frame.spinner("minValue").target().setValue(112.54);
        frame.spinner("maxValue").target().setValue(644.74);
        frame.spinner("decimalCount").target().setValue(485);
        frame.radioButton("groupingSeparatorUnderscore").target().setSelected(true);
        frame.radioButton("decimalSeparatorComma").target().setSelected(true);
    });

    decimalSettingsDialog.saveSettings();

    assertThat(decimalSettings.getMinValue()).isEqualTo(112.54);
    assertThat(decimalSettings.getMaxValue()).isEqualTo(644.74);
    assertThat(decimalSettings.getDecimalCount()).isEqualTo(485);
    assertThat(decimalSettings.getGroupingSeparator()).isEqualTo('_');
    assertThat(decimalSettings.getDecimalSeparator()).isEqualTo(',');
}
 
开发者ID:FWDekker,项目名称:intellij-randomness,代码行数:19,代码来源:DecimalSettingsDialogTest.java


示例4: testSaveSettingsWithoutParse

import org.assertj.swing.edt.GuiActionRunner; //导入依赖的package包/类
@Test
public void testSaveSettingsWithoutParse() {
    GuiActionRunner.execute(() -> {
        frame.spinner("minLength").target().setValue(840);
        frame.spinner("maxLength").target().setValue(861);
        frame.radioButton("enclosureSingle").target().setSelected(true);
        frame.radioButton("capitalizationLower").target().setSelected(true);
    });

    wordSettingsDialog.saveSettings();

    assertThat(wordSettings.getMinLength()).isEqualTo(840);
    assertThat(wordSettings.getMaxLength()).isEqualTo(861);
    assertThat(wordSettings.getEnclosure()).isEqualTo("'");
    assertThat(wordSettings.getCapitalization()).isEqualTo(CapitalizationMode.LOWER);
}
 
开发者ID:FWDekker,项目名称:intellij-randomness,代码行数:17,代码来源:WordSettingsDialogTest.java


示例5: setUp

import org.assertj.swing.edt.GuiActionRunner; //导入依赖的package包/类
@Before
public void setUp() throws Exception {
	DBKS.getDBKS().konektatu(DBKS.getDBKS().getDefaultPath());
	DBKS.getDBKS().aginduaExekutatu(
			"INSERT OR REPLACE INTO Jokalaria(Izena, AzkenData, IrabaziKop, GalduKop) VALUES ('Test', '01-01-2010', 10,20 )");
	AlKaboom.getAlKaboom().setDatubasePath(DBKS.getDBKS().getDefaultPath());
	UI frame = GuiActionRunner.execute(new GuiQuery<UI>() {
		@Override
		protected UI executeInEDT() {
			UI oraingoUI = new UI();
			oraingoUI.dekorazioGabeHasieratu();
			oraingoUI.kautotuHasieratu();
			AlKaboom.getAlKaboom().setUI(oraingoUI);
			return oraingoUI;
		}
	});
	window = new FrameFixture(frame);
	window.show();
}
 
开发者ID:Porobu,项目名称:Al-kaboom,代码行数:20,代码来源:KautotuTest.java


示例6: setUp

import org.assertj.swing.edt.GuiActionRunner; //导入依赖的package包/类
@Before
public void setUp() throws Exception {
    final IdeaTestFixtureFactory ideaFixtureFactory = IdeaTestFixtureFactory.getFixtureFactory();
    testFixture = ideaFixtureFactory.createBareFixture();
    testFixture.setUp();
    application = ApplicationManager.getApplication();
    underTest = GuiActionRunner.execute(SettingsPanel::new);
    window = Containers.showInFrame(underTest.getComponent());
}
 
开发者ID:t28hub,项目名称:json2java4idea,代码行数:10,代码来源:SettingsPanelTest.java


示例7: onSetUp

import org.assertj.swing.edt.GuiActionRunner; //导入依赖的package包/类
@Override
@SuppressWarnings("unchecked")
protected void onSetUp() {
    arraySettings = new ArraySettings();
    arraySettingsDialog = GuiActionRunner.execute(() -> new ArraySettingsDialog(arraySettings));
    frame = showInFrame(robot(), arraySettingsDialog.createCenterPanel());
}
 
开发者ID:FWDekker,项目名称:intellij-randomness,代码行数:8,代码来源:ArraySettingsDialogTest.java


示例8: testValidateCountNegative

import org.assertj.swing.edt.GuiActionRunner; //导入依赖的package包/类
@Test
public void testValidateCountNegative() {
    GuiActionRunner.execute(() -> frame.spinner("count").target().setValue(-172));

    final ValidationInfo validationInfo = arraySettingsDialog.doValidate();

    assertThat(validationInfo).isNotNull();
    assertThat(validationInfo.component).isEqualTo(frame.spinner("count").target());
    assertThat(validationInfo.message).isEqualTo("Please enter a value greater than or equal to 1.");
}
 
开发者ID:FWDekker,项目名称:intellij-randomness,代码行数:11,代码来源:ArraySettingsDialogTest.java


示例9: testValidateCountOverflow

import org.assertj.swing.edt.GuiActionRunner; //导入依赖的package包/类
@Test
public void testValidateCountOverflow() {
    GuiActionRunner.execute(() -> frame.spinner("count").target().setValue((long) Integer.MAX_VALUE + 2L));

    final ValidationInfo validationInfo = arraySettingsDialog.doValidate();

    assertThat(validationInfo).isNotNull();
    assertThat(validationInfo.component).isEqualTo(frame.spinner("count").target());
    assertThat(validationInfo.message).isEqualTo("Please enter a value less than or equal to 2147483647.");
}
 
开发者ID:FWDekker,项目名称:intellij-randomness,代码行数:11,代码来源:ArraySettingsDialogTest.java


示例10: onSetUp

import org.assertj.swing.edt.GuiActionRunner; //导入依赖的package包/类
@Override
protected void onSetUp() {
    integerSettings = new IntegerSettings();
    integerSettings.setMinValue(DEFAULT_MIN_VALUE);
    integerSettings.setMaxValue(DEFAULT_MAX_VALUE);

    integerSettingsDialog = GuiActionRunner.execute(() -> new IntegerSettingsDialog(integerSettings));
    frame = showInFrame(robot(), integerSettingsDialog.createCenterPanel());
}
 
开发者ID:FWDekker,项目名称:intellij-randomness,代码行数:10,代码来源:IntegerSettingsDialogTest.java


示例11: testValidateMaxValueGreaterThanMinValue

import org.assertj.swing.edt.GuiActionRunner; //导入依赖的package包/类
@Test
public void testValidateMaxValueGreaterThanMinValue() {
    GuiActionRunner.execute(() -> frame.spinner("maxValue").target().setValue(DEFAULT_MIN_VALUE - 1));

    final ValidationInfo validationInfo = integerSettingsDialog.doValidate();

    assertThat(validationInfo).isNotNull();
    assertThat(validationInfo.component).isEqualTo(frame.spinner("maxValue").target());
    assertThat(validationInfo.message).isEqualTo("The maximum should be no smaller than the minimum.");
}
 
开发者ID:FWDekker,项目名称:intellij-randomness,代码行数:11,代码来源:IntegerSettingsDialogTest.java


示例12: testValidateValueRange

import org.assertj.swing.edt.GuiActionRunner; //导入依赖的package包/类
@Test
public void testValidateValueRange() {
    GuiActionRunner.execute(() -> {
        frame.spinner("minValue").target().setValue(Long.MIN_VALUE);
        frame.spinner("maxValue").target().setValue(Long.MAX_VALUE);
    });

    final ValidationInfo validationInfo = integerSettingsDialog.doValidate();

    assertThat(validationInfo).isNotNull();
    assertThat(validationInfo.component).isEqualTo(frame.spinner("maxValue").target());
    assertThat(validationInfo.message).isEqualTo("The range should not exceed 9.223372036854776E18.");
}
 
开发者ID:FWDekker,项目名称:intellij-randomness,代码行数:14,代码来源:IntegerSettingsDialogTest.java


示例13: testSaveSettingsWithoutParse

import org.assertj.swing.edt.GuiActionRunner; //导入依赖的package包/类
@Test
public void testSaveSettingsWithoutParse() {
    GuiActionRunner.execute(() -> {
        frame.spinner("minValue").target().setValue((long) Integer.MAX_VALUE + 1L);
        frame.spinner("maxValue").target().setValue((long) Integer.MAX_VALUE + 2L);

        integerSettingsDialog.saveSettings();
    });

    assertThat(integerSettings.getMinValue()).isEqualTo(2147483648L);
    assertThat(integerSettings.getMaxValue()).isEqualTo(2147483649L);
}
 
开发者ID:FWDekker,项目名称:intellij-randomness,代码行数:13,代码来源:IntegerSettingsDialogTest.java


示例14: testSaveSettingsWithParse

import org.assertj.swing.edt.GuiActionRunner; //导入依赖的package包/类
@Test
public void testSaveSettingsWithParse() {
    frame.spinner("minValue").enterTextAndCommit("2147483648");
    frame.spinner("maxValue").enterTextAndCommit("2147483649");

    GuiActionRunner.execute(() -> integerSettingsDialog.saveSettings());

    assertThat(integerSettings.getMinValue()).isEqualTo(2147483648L);
    assertThat(integerSettings.getMaxValue()).isEqualTo(2147483649L);
}
 
开发者ID:FWDekker,项目名称:intellij-randomness,代码行数:11,代码来源:IntegerSettingsDialogTest.java


示例15: onSetUp

import org.assertj.swing.edt.GuiActionRunner; //导入依赖的package包/类
@Override
protected void onSetUp() {
    stringSettings = new StringSettings();
    stringSettings.setMinLength(DEFAULT_MIN_VALUE);
    stringSettings.setMaxLength(DEFAULT_MAX_VALUE);
    stringSettings.setEnclosure(DEFAULT_ENCLOSURE);
    stringSettings.setAlphabets(DEFAULT_ALPHABETS);

    stringSettingsDialog = GuiActionRunner.execute(() -> new StringSettingsDialog(stringSettings));
    frame = showInFrame(robot(), stringSettingsDialog.createCenterPanel());
}
 
开发者ID:FWDekker,项目名称:intellij-randomness,代码行数:12,代码来源:StringSettingsDialogTest.java


示例16: testValidateMinLengthNegative

import org.assertj.swing.edt.GuiActionRunner; //导入依赖的package包/类
@Test
public void testValidateMinLengthNegative() {
    GuiActionRunner.execute(() -> frame.spinner("minLength").target().setValue(-161));

    final ValidationInfo validationInfo = stringSettingsDialog.doValidate();

    assertThat(validationInfo).isNotNull();
    assertThat(validationInfo.component).isEqualTo(frame.spinner("minLength").target());
    assertThat(validationInfo.message).isEqualTo("Please enter a value greater than or equal to 1.");
}
 
开发者ID:FWDekker,项目名称:intellij-randomness,代码行数:11,代码来源:StringSettingsDialogTest.java


示例17: testValidateMaxLengthOverflow

import org.assertj.swing.edt.GuiActionRunner; //导入依赖的package包/类
@Test
public void testValidateMaxLengthOverflow() {
    GuiActionRunner.execute(() -> frame.spinner("maxLength").target().setValue((long) Integer.MAX_VALUE + 2L));

    final ValidationInfo validationInfo = stringSettingsDialog.doValidate();

    assertThat(validationInfo).isNotNull();
    assertThat(validationInfo.component).isEqualTo(frame.spinner("maxLength").target());
    assertThat(validationInfo.message).isEqualTo("Please enter a value less than or equal to 2147483647.");
}
 
开发者ID:FWDekker,项目名称:intellij-randomness,代码行数:11,代码来源:StringSettingsDialogTest.java


示例18: testValidateMaxLengthGreaterThanMinLength

import org.assertj.swing.edt.GuiActionRunner; //导入依赖的package包/类
@Test
public void testValidateMaxLengthGreaterThanMinLength() {
    GuiActionRunner.execute(() -> frame.spinner("maxLength").target().setValue(DEFAULT_MIN_VALUE - 1));

    final ValidationInfo validationInfo = stringSettingsDialog.doValidate();

    assertThat(validationInfo).isNotNull();
    assertThat(validationInfo.component).isEqualTo(frame.spinner("maxLength").target());
    assertThat(validationInfo.message).isEqualTo("The maximum should be no smaller than the minimum.");
}
 
开发者ID:FWDekker,项目名称:intellij-randomness,代码行数:11,代码来源:StringSettingsDialogTest.java


示例19: testValidateEmptyAlphabetSelection

import org.assertj.swing.edt.GuiActionRunner; //导入依赖的package包/类
@Test
public void testValidateEmptyAlphabetSelection() {
    GuiActionRunner.execute(() -> frame.list("alphabets").target().clearSelection());

    final ValidationInfo validationInfo = stringSettingsDialog.doValidate();

    assertThat(validationInfo).isNotNull();
    assertThat(validationInfo.component).isEqualTo(frame.list("alphabets").target());
    assertThat(validationInfo.message).isEqualTo("Please select at least one option.");
}
 
开发者ID:FWDekker,项目名称:intellij-randomness,代码行数:11,代码来源:StringSettingsDialogTest.java


示例20: onSetUp

import org.assertj.swing.edt.GuiActionRunner; //导入依赖的package包/类
@Override
protected void onSetUp() {
    decimalSettings = new DecimalSettings();
    decimalSettings.setMinValue(DEFAULT_MIN_VALUE);
    decimalSettings.setMaxValue(DEFAULT_MAX_VALUE);
    decimalSettings.setDecimalCount(DEFAULT_DECIMAL_COUNT);

    decimalSettingsDialog = GuiActionRunner.execute(() -> new DecimalSettingsDialog(decimalSettings));
    frame = showInFrame(robot(), decimalSettingsDialog.createCenterPanel());
}
 
开发者ID:FWDekker,项目名称:intellij-randomness,代码行数:11,代码来源:DecimalSettingsDialogTest.java



注:本文中的org.assertj.swing.edt.GuiActionRunner类示例整理自Github/MSDocs等源码及文档管理平台,相关代码片段筛选自各路编程大神贡献的开源项目,源码版权归原作者所有,传播和使用请参考对应项目的License;未经允许,请勿转载。


鲜花

握手

雷人

路过

鸡蛋
该文章已有0人参与评论

请发表评论

全部评论

专题导读
上一篇:
Java FloatBinding类代码示例发布时间:2022-05-22
下一篇:
Java Pressure类代码示例发布时间:2022-05-22
热门推荐
阅读排行榜

扫描微信二维码

查看手机版网站

随时了解更新最新资讯

139-2527-9053

在线客服(服务时间 9:00~18:00)

在线QQ客服
地址:深圳市南山区西丽大学城创智工业园
电邮:jeky_zhao#qq.com
移动电话:139-2527-9053

Powered by 互联科技 X3.4© 2001-2213 极客世界.|Sitemap