aboutsummaryrefslogtreecommitdiffstats
path: root/server/src/test/java/com/vaadin/ui/TextAreaTest.java
blob: 820f133c4571bda03f78c96714dde597bd65c787 (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
package com.vaadin.ui;

import static org.junit.Assert.assertFalse;
import static org.junit.Assert.assertTrue;

import org.junit.Test;

public class TextAreaTest {
    @Test
    public void initiallyEmpty() {
        TextArea textArea = new TextArea();
        assertTrue(textArea.isEmpty());
    }

    @Test
    public void emptyAfterClear() {
        TextArea textArea = new TextArea();
        textArea.setValue("foobar");
        assertFalse(textArea.isEmpty());
        textArea.clear();
        assertTrue(textArea.isEmpty());
    }

}