aboutsummaryrefslogtreecommitdiffstats
path: root/uitest/src/main/java/com/vaadin/tests/components/combobox/ComboboxPrimaryStyleNames.java
blob: a8090502c7c6158c06ece7e83af5e0f50b7dee1e (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
package com.vaadin.tests.components.combobox;

import com.vaadin.tests.components.TestBase;
import com.vaadin.ui.Button;
import com.vaadin.ui.ComboBox;

public class ComboboxPrimaryStyleNames extends TestBase {

    @Override
    protected void setup() {
        final ComboBox<String> box = new ComboBox();
        box.setItems("Value 1", "Value 2", "Value 3", "Value 4");
        box.setPrimaryStyleName("my-combobox");

        addComponent(box);
        addComponent(new Button("Set primary style",
                event -> box.setPrimaryStyleName("my-second-combobox")));

    }

    @Override
    protected String getDescription() {
        return "Combobox should work with primary stylenames both initially and dynamically";
    }

    @Override
    protected Integer getTicketNumber() {
        return 9901;
    }

}