Package ru.yandex.qatools.htmlelements.element

Examples of ru.yandex.qatools.htmlelements.element.Radio


public class HasSelectedRadioButtonTest {
    private static final String SELECTED_BUTTON_VALUE = "some value";

    @Test
    public void hasSelectedOptionTest() {
        Radio radio = MockFactory.mockRadio(SELECTED_BUTTON_VALUE);
        assertThat(radio, hasSelectedRadioButton(hasValue(SELECTED_BUTTON_VALUE)));
    }
View Full Code Here


        when(selectedOption.getAttribute("value")).thenReturn(selectedOptionValue);
        return select;
    }

    public static Radio mockRadio(String selectedButtonValue) {
        Radio radio = mock(Radio.class);
        WebElement selectedButton = mock(WebElement.class);
        when(radio.hasSelectedButton()).thenReturn(true);
        when(radio.getSelectedButton()).thenReturn(selectedButton);
        when(selectedButton.getAttribute("value")).thenReturn(selectedButtonValue);
        return radio;
    }
View Full Code Here

TOP

Related Classes of ru.yandex.qatools.htmlelements.element.Radio

Copyright © 2018 www.massapicom. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.