From 99c7d0b3cde116bf31b00bd31f62f9f4920b1762 Mon Sep 17 00:00:00 2001 From: denisanisimov Date: Fri, 2 Aug 2013 14:32:47 +0300 Subject: Show tooltips for ordered layout captions (#10046) Change-Id: I80cb1cbd573d7e0de8aa200a4513dc32984ba9f5 --- .../components/orderedlayout/ErrorIndicator.html | 82 ++++++++++++++++++++++ .../components/orderedlayout/ErrorIndicator.java | 79 +++++++++++++++++++++ 2 files changed, 161 insertions(+) create mode 100644 uitest/src/com/vaadin/tests/components/orderedlayout/ErrorIndicator.html create mode 100644 uitest/src/com/vaadin/tests/components/orderedlayout/ErrorIndicator.java (limited to 'uitest/src/com/vaadin/tests') diff --git a/uitest/src/com/vaadin/tests/components/orderedlayout/ErrorIndicator.html b/uitest/src/com/vaadin/tests/components/orderedlayout/ErrorIndicator.html new file mode 100644 index 0000000000..81da3b897e --- /dev/null +++ b/uitest/src/com/vaadin/tests/components/orderedlayout/ErrorIndicator.html @@ -0,0 +1,82 @@ + + + + + + +Required error tootlip + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
Required error tooltip
open/run/com.vaadin.tests.components.orderedlayout.ErrorIndicator?restartApplication
showTooltip//div[@id='gwt-uid-4']/span43,4
screenCapturetooltipVertivcalCaption
waitForVaadin
showTooltip//div[@id='gwt-uid-4']/span[2]3,6
screenCapturetooltipVertivcalRequiredIndicator
waitForVaadin
showTooltip//div[@id='gwt-uid-6']/span38,11
screenCapturetooltipHorizontalCaption
waitForVaadin
showTooltip//div[@id='gwt-uid-6']/span[2]3,4
screenCapturetooltipHorizontalRequiredIndicator
waitForVaadin
+ + diff --git a/uitest/src/com/vaadin/tests/components/orderedlayout/ErrorIndicator.java b/uitest/src/com/vaadin/tests/components/orderedlayout/ErrorIndicator.java new file mode 100644 index 0000000000..9964e1ee78 --- /dev/null +++ b/uitest/src/com/vaadin/tests/components/orderedlayout/ErrorIndicator.java @@ -0,0 +1,79 @@ +/* + * Copyright 2000-2013 Vaadin Ltd. + * + * Licensed under the Apache License, Version 2.0 (the "License"); you may not + * use this file except in compliance with the License. You may obtain a copy of + * the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, WITHOUT + * WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the + * License for the specific language governing permissions and limitations under + * the License. + */ + +/** + * + */ +package com.vaadin.tests.components.orderedlayout; + +import com.vaadin.server.VaadinRequest; +import com.vaadin.tests.components.AbstractTestUI; +import com.vaadin.ui.HorizontalLayout; +import com.vaadin.ui.TextField; +import com.vaadin.ui.VerticalLayout; + +public class ErrorIndicator extends AbstractTestUI { + + /* + * (non-Javadoc) + * + * @see com.vaadin.tests.components.AbstractTestUI#setup(com.vaadin.server. + * VaadinRequest) + */ + @Override + protected void setup(VaadinRequest request) { + VerticalLayout layout = new VerticalLayout(); + + TextField inVertical = new TextField(); + inVertical.setRequired(true); + inVertical.setRequiredError("Vertical layout tooltip"); + inVertical.setCaption("Vertical layout caption"); + + layout.addComponent(inVertical); + addComponent(layout); + + HorizontalLayout horizontalLayout = new HorizontalLayout(); + + TextField inHorizontal = new TextField(); + inHorizontal.setRequired(true); + inHorizontal.setRequiredError("Horizontal layout tooltip"); + inHorizontal.setCaption("Horizontal layout caption"); + + horizontalLayout.addComponent(inHorizontal); + layout.addComponent(horizontalLayout); + } + + /* + * (non-Javadoc) + * + * @see com.vaadin.tests.components.AbstractTestUI#getTestDescription() + */ + @Override + protected String getTestDescription() { + return "Show tooltip for caption and required indicator"; + } + + /* + * (non-Javadoc) + * + * @see com.vaadin.tests.components.AbstractTestUI#getTicketNumber() + */ + @Override + protected Integer getTicketNumber() { + return 10046; + } + +} -- cgit v1.2.3