Example usage for com.vaadin.testbench.elements NotificationElement getCaption

List of usage examples for com.vaadin.testbench.elements NotificationElement getCaption

Introduction

In this page you can find the example usage for com.vaadin.testbench.elements NotificationElement getCaption.

Prototype

public String getCaption() 

Source Link

Document

Returns the caption of the Notification element.

Usage

From source file:com.piccritic.website.PicCriticIT.java

License:Open Source License

public void hasUserException() throws UserException {
    if ($(NotificationElement.class).exists()) {
        NotificationElement msg = $(NotificationElement.class).first();
        if (msg.getType().equals("warning") && !msg.getCaption().isEmpty()) {
            throw new UserException(msg.getCaption());
        }//w  w  w  .  j  a v a  2  s . c om
    }
}