void () { MyInspection inspection = new MyInspection(); JComponent component = render(inspection); // Number var textFields = UIUtil.findComponentsOfType(component, JBTextField.class); textFields.get(0).setText("2"); assertEquals(2, inspection.myInt); textFields.get(1).setText("1.25"); assertEquals(1.25, inspection.myDouble); // String textFields.get(2).setText("foo"); assertEquals("foo", inspection.myString); // CheckBox var checkBox = UIUtil.findComponentOfType(component, JCheckBox.class); checkBox.setSelected(true); assertTrue(inspection.myBoolean); // Dropdown var dropDown = UIUtil.findComponentOfType(component, ComboBox.class); dropDown.getModel().setSelectedItem("o2"); assertEquals("o2", inspection.myOption); }