Code example for RadioButton

Methods: toggle

0
    public void testShouldConvertMillilitresToDrams() throws Exception { 
        _activity.runOnUiThread(
                new Runnable() {
                    @Override 
                    public void run() { 
                        _toDramsRadioButton.toggle();
                        _inputVolumeEdit.setText("30");
                        _convertVolumeButton.performClick();
                    } 
                } 
        ); 
        getInstrumentation().waitForIdleSync();
        assertThat(_convertedResults.getText().toString(), equalTo("8.1 drams."));
    } 
 
    @Test 
    public void testShouldConvertDramsToMillilitres() throws Exception { 
        _activity.runOnUiThread(
                new Runnable() {
                    @Override 
                    public void run() {