A RetroSearch Logo

Home - News ( United States | United Kingdom | Italy | Germany ) - Football scores

Search Query:

Showing content from https://github.com/assertj/assertj-swing/issues/229 below:

AssertJ not clicking boxes - Java 11 · Issue #229 · assertj/assertj-swing · GitHub

Summary

I’m not able to use basic click functionalities with AssertJ (basically everything related to activating buttons)

Opened a thread about it in STO as well -

I’m not sure if it’s a regression or if I’m just missing out something obvious… the example here - Example is not working on my env as well (Java 11)

Example

The GUI is a JPanel and I use Containers.showInFrame to display it.

The panel has some text fields, JCheckboxes and JComboboxes.

I'm able to set text in the text fields, but I am not able to check/select the boxes. Been breaking my head but couldn't figure out what is missing...

Working:

frame.textBox("example").setText(result).requireText(result);

Not working:

frame.checkBox("exampleCheckBox").uncheck().requireNotSelected(); 
frame.checkBox("example2CheckBox").check().requireSelected();
panel.comboBox("exampleComboBox").selectItem(2);

The component description that I get for a checkbox is:

[javax.swing.JCheckBox[name='exampleCheckBox', text='Mandatory', selected=true, enabled=true, visible=true, showing=true] - property:'selected']

Using Java 11, Gradle build, latest assertj-swing-junit and assertj-core.

Would highly appreciate any leads!
Thank you


RetroSearch is an open source project built by @garambo | Open a GitHub Issue

Search and Browse the WWW like it's 1997 | Search results from DuckDuckGo

HTML: 3.2 | Encoding: UTF-8 | Version: 0.7.4