import it.projectAdministration.BackgroundTasksTest;
import it.projectAdministration.BulkDeletionTest;
import it.projectAdministration.ProjectAdministrationTest;
-import it.projectServices.ProjectCodeTest;
-import it.projectServices.ProjectOverviewTest;
+import it.projectServices.*;
import it.qualityGate.QualityGateNotificationTest;
import it.qualityGate.QualityGateTest;
import it.qualityGate.QualityGateUiTest;
// project pages
ProjectOverviewTest.class,
ProjectCodeTest.class,
+ ProjectDrilldownTest.class,
+ ProjectComparisonTest.class,
+ AllProjectsTest.class,
+ ProjectWidgetsTest.class,
// settings
PropertySetsTest.class,
SubCategoriesTest.class,
+++ /dev/null
-/*
- * SonarQube
- * Copyright (C) 2009-2016 SonarSource SA
- * mailto:contact AT sonarsource DOT com
- *
- * This program is free software; you can redistribute it and/or
- * modify it under the terms of the GNU Lesser General Public
- * License as published by the Free Software Foundation; either
- * version 3 of the License, or (at your option) any later version.
- *
- * This program is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
- * Lesser General Public License for more details.
- *
- * You should have received a copy of the GNU Lesser General Public License
- * along with this program; if not, write to the Free Software Foundation,
- * Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
- */
-package it.projectComparison;
-
-public class ToDoTest {
-}
--- /dev/null
+/*
+ * Copyright (C) 2009-2014 SonarSource SA
+ * All rights reserved
+ * mailto:contact AT sonarsource DOT com
+ */
+package it.projectServices;
+
+import com.sonar.orchestrator.Orchestrator;
+import com.sonar.orchestrator.build.SonarRunner;
+import com.sonar.orchestrator.selenium.Selenese;
+import it.Category1Suite;
+import org.junit.BeforeClass;
+import org.junit.ClassRule;
+import org.junit.Test;
+import util.selenium.SeleneseTest;
+
+import static util.ItUtils.projectDir;
+
+public class AllProjectsTest {
+
+ @ClassRule
+ public static Orchestrator orchestrator = Category1Suite.ORCHESTRATOR;
+
+ @BeforeClass
+ public static void inspectProject() {
+ orchestrator.executeBuild(
+ SonarRunner.create(projectDir("shared/xoo-sample"))
+ .setProjectKey("all-project-test-project")
+ .setProjectName("AllProjectsTest Project")
+ );
+ }
+
+ @Test
+ public void test_all_projects_page() {
+ Selenese selenese = Selenese.builder().setHtmlTestsInClasspath("test_all_projects_page",
+ "/projectServices/AllProjectsTest/test_all_projects_page.html"
+ ).build();
+ new SeleneseTest(selenese).runOn(orchestrator);
+ }
+
+}
--- /dev/null
+/*
+ * Copyright (C) 2009-2014 SonarSource SA
+ * All rights reserved
+ * mailto:contact AT sonarsource DOT com
+ */
+package it.projectServices;
+
+import com.sonar.orchestrator.Orchestrator;
+import com.sonar.orchestrator.build.SonarRunner;
+import com.sonar.orchestrator.selenium.Selenese;
+import it.Category1Suite;
+import org.junit.BeforeClass;
+import org.junit.ClassRule;
+import org.junit.Ignore;
+import org.junit.Test;
+import util.selenium.SeleneseTest;
+
+import static util.ItUtils.projectDir;
+
+public class ProjectComparisonTest {
+
+ @ClassRule
+ public static Orchestrator orchestrator = Category1Suite.ORCHESTRATOR;
+
+ @BeforeClass
+ public static void inspectProject() {
+ orchestrator.executeBuild(
+ SonarRunner.create(projectDir("shared/xoo-sample"))
+ .setProjectKey("project-comparison-test-project")
+ .setProjectName("ProjectComparisonTest Project")
+ );
+ }
+
+ @Test
+ @Ignore("need to find a way to type into invisible input fields")
+ public void test_project_comparison_service() {
+ Selenese selenese = Selenese.builder().setHtmlTestsInClasspath("test_project_comparison_service",
+ "/projectServices/ProjectComparisonTest/should-display-basic-set-of-metrics.html",
+ "/projectServices/ProjectComparisonTest/should-add-projects.html",
+ "/projectServices/ProjectComparisonTest/should-move-and-remove-projects.html",
+ "/projectServices/ProjectComparisonTest/should-add-metrics.html",
+ "/projectServices/ProjectComparisonTest/should-not-add-differential-metrics.html",
+ "/projectServices/ProjectComparisonTest/should-move-and-remove-metrics.html"
+ ).build();
+ new SeleneseTest(selenese).runOn(orchestrator);
+ }
+
+}
--- /dev/null
+/*
+ * Copyright (C) 2009-2014 SonarSource SA
+ * All rights reserved
+ * mailto:contact AT sonarsource DOT com
+ */
+package it.projectServices;
+
+import com.sonar.orchestrator.Orchestrator;
+import com.sonar.orchestrator.build.SonarRunner;
+import com.sonar.orchestrator.selenium.Selenese;
+import it.Category1Suite;
+import org.junit.BeforeClass;
+import org.junit.ClassRule;
+import org.junit.Test;
+import org.sonar.wsclient.Sonar;
+import org.sonar.wsclient.services.Resource;
+import org.sonar.wsclient.services.ResourceQuery;
+import util.selenium.SeleneseTest;
+
+import java.util.List;
+
+import static util.ItUtils.projectDir;
+
+public class ProjectDrilldownTest {
+
+ @ClassRule
+ public static Orchestrator orchestrator = Category1Suite.ORCHESTRATOR;
+
+ @BeforeClass
+ public static void inspectProject() {
+ orchestrator.executeBuild(
+ SonarRunner.create(projectDir("shared/xoo-sample"))
+ .setProjectKey("project-drilldown-test-project")
+ .setProjectName("ProjectDrilldownTest Project")
+ );
+ }
+
+ @Test
+ public void should_display_measure_drilldown() {
+ Selenese selenese = Selenese.builder().setHtmlTestsInClasspath("should_display_measure_drilldown",
+ "/projectServices/ProjectDrilldownTest/should_display_measure_drilldown.html"
+ ).build();
+ new SeleneseTest(selenese).runOn(orchestrator);
+ }
+
+}
new SeleneseTest(selenese).runOn(orchestrator);
}
+ @Test
+ public void should_display_a_nice_error_when_requesting_unknown_project() {
+ Selenese selenese = Selenese.builder().setHtmlTestsInClasspath("should_display_a_nice_error_when_requesting_unknown_project",
+ "/projectServices/ProjectOverviewTest/should-display-nice-error-on-unknown-project.html").build();
+ orchestrator.executeSelenese(selenese);
+ }
+
private void executeBuild(String projectLocation, String projectKey, String projectName) {
orchestrator.executeBuild(
SonarRunner.create(projectDir(projectLocation))
--- /dev/null
+/*
+ * Copyright (C) 2009-2014 SonarSource SA
+ * All rights reserved
+ * mailto:contact AT sonarsource DOT com
+ */
+package it.projectServices;
+
+import com.sonar.orchestrator.Orchestrator;
+import com.sonar.orchestrator.build.SonarRunner;
+import com.sonar.orchestrator.selenium.Selenese;
+import it.Category1Suite;
+import org.junit.BeforeClass;
+import org.junit.ClassRule;
+import org.junit.Ignore;
+import org.junit.Test;
+import org.sonar.wsclient.services.ResourceQuery;
+import util.selenium.SeleneseTest;
+
+import static util.ItUtils.projectDir;
+
+public class ProjectWidgetsTest {
+
+ @ClassRule
+ public static Orchestrator orchestrator = Category1Suite.ORCHESTRATOR;
+
+ @BeforeClass
+ public static void inspectProject() {
+ orchestrator.executeBuild(
+ SonarRunner.create(projectDir("shared/xoo-sample"))
+ .setProjectKey("project-widgets-test-project")
+ .setProjectName("ProjectWidgetsTest Project")
+ );
+ }
+
+ @Test
+ public void hotspots() {
+ Selenese selenese = Selenese.builder().setHtmlTestsInClasspath("hotspots",
+ "/projectServices/ProjectWidgetsTest/hotspots/hotspot-metric-widget.html",
+ "/projectServices/ProjectWidgetsTest/hotspots/hide-if-no-measures.html"
+ ).build();
+ new SeleneseTest(selenese).runOn(orchestrator);
+ }
+
+ @Test
+ public void complexity() {
+ Selenese selenese = Selenese.builder().setHtmlTestsInClasspath("complexity",
+ "/projectServices/ProjectWidgetsTest/complexity/complexity-widget.html"
+ ).build();
+ new SeleneseTest(selenese).runOn(orchestrator);
+ }
+
+ @Test
+ public void description() {
+ long projectId = orchestrator.getServer().getWsClient()
+ .find(ResourceQuery.create("project-widgets-test-project")).getId();
+ long qualityGateId = orchestrator.getServer().adminWsClient().qualityGateClient().show("SonarQube way").id();
+ orchestrator.getServer().adminWsClient().qualityGateClient().selectProject(qualityGateId, projectId);
+
+ Selenese selenese = Selenese.builder().setHtmlTestsInClasspath("description",
+ "/projectServices/ProjectWidgetsTest/description/description-widget.html"
+ ).build();
+ new SeleneseTest(selenese).runOn(orchestrator);
+ }
+
+ @Test
+ @Ignore
+ public void custom_measures() {
+ Selenese selenese = Selenese.builder().setHtmlTestsInClasspath("custom_measures",
+ "/projectServices/ProjectWidgetsTest/custom_measures/should-exclude-new-metrics.html"
+ ).build();
+ new SeleneseTest(selenese).runOn(orchestrator);
+ }
+
+}
--- /dev/null
+<?xml version="1.0" encoding="UTF-8"?>
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml" xml:lang="en" lang="en">
+<head profile="http://selenium-ide.openqa.org/profiles/test-case">
+ <meta http-equiv="Content-Type" content="text/html; charset=UTF-8"/>
+ <title>should-display-all-projects-page</title>
+</head>
+<body>
+<table cellpadding="1" cellspacing="1" border="1">
+<tbody>
+<tr>
+ <td>open</td>
+ <td>/all_projects?qualifier=TRK</td>
+ <td></td>
+</tr>
+<tr>
+ <td>waitForText</td>
+ <td>id=content</td>
+ <td>*All Projects*</td>
+</tr>
+<tr>
+ <td>waitForText</td>
+ <td>id=content</td>
+ <td>*Name*</td>
+</tr>
+<tr>
+ <td>waitForText</td>
+ <td>id=content</td>
+ <td>*AllProjectsTest Project*</td>
+</tr>
+</tbody>
+</table>
+</body>
+</html>
--- /dev/null
+<?xml version="1.0" encoding="UTF-8"?>
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml" xml:lang="en" lang="en">
+<head profile="http://selenium-ide.openqa.org/profiles/test-case">
+ <meta http-equiv="Content-Type" content="text/html; charset=UTF-8"/>
+ <title>should-add-metrics</title>
+</head>
+<body>
+<table cellpadding="1" cellspacing="1" border="1">
+ <tbody>
+ <tr>
+ <td>open</td>
+ <td>/comparison/index</td>
+ <td></td>
+ </tr>
+ <tr>
+ <td>assertNotText</td>
+ <td>comparison-page</td>
+ <td>*Major issues*</td>
+ </tr>
+ <tr>
+ <td>waitForElementPresent</td>
+ <td>new_metric</td>
+ <td></td>
+ </tr>
+ <tr>
+ <td>typeAndWait</td>
+ <td>new_metric</td>
+ <td>major_violations</td>
+ </tr>
+ <tr>
+ <td>assertText</td>
+ <td>comparison-page</td>
+ <td>*Lines of code*Complexity*Comments (%)*Duplicated lines (%)*Issues*Coverage*Major issues*</td>
+ </tr>
+ </tbody>
+</table>
+</body>
+</html>
--- /dev/null
+<?xml version="1.0" encoding="UTF-8"?>
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml" xml:lang="en" lang="en">
+<head profile="http://selenium-ide.openqa.org/profiles/test-case">
+ <meta http-equiv="Content-Type" content="text/html; charset=UTF-8"/>
+ <title>should-add-projects</title>
+</head>
+<body>
+<table cellpadding="1" cellspacing="1" border="1">
+ <tbody>
+ <tr>
+ <td>open</td>
+ <td>/comparison/index</td>
+ <td></td>
+</tr>
+<tr>
+ <td>waitForElementPresent</td>
+ <td>new_resource</td>
+ <td></td>
+</tr>
+<tr>
+ <td>type</td>
+ <td>new_resource</td>
+ <td>project-comparison-test-project</td>
+</tr>
+<tr>
+ <td>waitForElementPresent</td>
+ <td>//option[text()='1.0-SNAPSHOT']</td>
+ <td></td>
+</tr>
+<tr>
+ <td>selectAndWait</td>
+ <td>new_version</td>
+ <td>1.0-SNAPSHOT</td>
+</tr>
+<tr>
+ <td>waitForText</td>
+ <td>id=content</td>
+ <td>*ProjectComparisonTest Project*1.0-SNAPSHOT*</td>
+</tr>
+</tbody>
+</table>
+</body>
+</html>
--- /dev/null
+<?xml version="1.0" encoding="UTF-8"?>
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml" xml:lang="en" lang="en">
+<head profile="http://selenium-ide.openqa.org/profiles/test-case">
+ <meta http-equiv="Content-Type" content="text/html; charset=UTF-8"/>
+ <title>should-display-basic-set-of-metrics</title>
+</head>
+<body>
+<table cellpadding="1" cellspacing="1" border="1">
+ <tbody>
+ <tr>
+ <td>open</td>
+ <td>/comparison/index</td>
+ <td></td>
+</tr>
+<tr>
+ <td>waitForText</td>
+ <td>id=content</td>
+ <td>*Lines of code*Complexity*Comments (%)*Duplicated lines (%)*Issues*Coverage*</td>
+</tr>
+</tbody>
+</table>
+</body>
+</html>
--- /dev/null
+<?xml version="1.0" encoding="UTF-8"?>
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml" xml:lang="en" lang="en">
+<head profile="http://selenium-ide.openqa.org/profiles/test-case">
+ <meta http-equiv="Content-Type" content="text/html; charset=UTF-8"/>
+ <title>should-move-and-remove-metrics</title>
+</head>
+<body>
+<table cellpadding="1" cellspacing="1" border="1">
+ <tbody>
+ <tr>
+ <td>open</td>
+ <td>/comparison/index</td>
+ <td></td>
+</tr>
+<tr>
+ <td>assertText</td>
+ <td>comparison-page</td>
+ <td>*Lines of code*Complexity*Comments (%)*Duplicated lines (%)*Issues*Coverage*</td>
+</tr>
+<tr>
+ <td>clickAndWait</td>
+ <td>down-0</td>
+ <td></td>
+</tr>
+<tr>
+ <td>assertText</td>
+ <td>comparison-page</td>
+ <td>*Complexity*Lines of code*Comments (%)*Duplicated lines (%)*Issues*Coverage*</td>
+</tr>
+<tr>
+ <td>clickAndWait</td>
+ <td>up-5</td>
+ <td></td>
+</tr>
+<tr>
+ <td>assertText</td>
+ <td>comparison-page</td>
+ <td>*Complexity*Lines of code*Comments (%)*Duplicated lines (%)*Coverage*Issues*</td>
+</tr>
+<tr>
+ <td>assertText</td>
+ <td>comparison-page</td>
+ <td>*%*</td>
+</tr>
+<tr>
+ <td>clickAndWait</td>
+ <td>del-m-2</td>
+ <td></td>
+</tr>
+<tr>
+ <td>clickAndWait</td>
+ <td>del-m-2</td>
+ <td></td>
+</tr>
+<tr>
+ <td>assertText</td>
+ <td>comparison-page</td>
+ <td>*Complexity*Lines of code*Coverage*Issues*</td>
+</tr>
+<tr>
+ <td>assertNotText</td>
+ <td>comparison-page</td>
+ <td>*%*</td>
+</tr>
+</tbody>
+</table>
+</body>
+</html>
--- /dev/null
+<?xml version="1.0" encoding="UTF-8"?>
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml" xml:lang="en" lang="en">
+<head profile="http://selenium-ide.openqa.org/profiles/test-case">
+ <meta http-equiv="Content-Type" content="text/html; charset=UTF-8"/>
+ <title>should-move-and-remove-projects</title>
+</head>
+<body>
+<table cellpadding="1" cellspacing="1" border="1">
+ <tbody>
+ <tr>
+ <td>open</td>
+ <td>/comparison/index</td>
+ <td></td>
+</tr>
+<tr>
+ <td>waitForElementPresent</td>
+ <td>new_resource</td>
+ <td></td>
+</tr>
+<tr>
+ <td>type</td>
+ <td>new_resource</td>
+ <td>project-comparison-test-project</td>
+</tr>
+<tr>
+ <td>waitForElementPresent</td>
+ <td>//option[text()='1.0-SNAPSHOT']</td>
+ <td></td>
+</tr>
+<tr>
+ <td>selectAndWait</td>
+ <td>new_version</td>
+ <td>1.0-SNAPSHOT</td>
+</tr>
+<tr>
+ <td>waitForText</td>
+ <td>id=content</td>
+ <td>*ProjectComparisonTest Project*1.0-SNAPSHOT*</td>
+</tr>
+<tr>
+ <td>clickAndWait</td>
+ <td>del-r-0</td>
+ <td></td>
+</tr>
+<tr>
+ <td>assertNotText</td>
+ <td>id=content</td>
+ <td>*Sample*</td>
+</tr>
+</tbody>
+</table>
+</body>
+</html>
--- /dev/null
+<?xml version="1.0" encoding="UTF-8"?>
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml" xml:lang="en" lang="en">
+<head profile="http://selenium-ide.openqa.org/profiles/test-case">
+ <meta http-equiv="Content-Type" content="text/html; charset=UTF-8"/>
+ <title>should-not-add-differential-metrics</title>
+</head>
+<body>
+<table cellpadding="1" cellspacing="1" border="1">
+ <tbody>
+ <tr>
+ <td>open</td>
+ <td>/comparison/index</td>
+ <td></td>
+ </tr>
+ <tr>
+ <td>assertText</td>
+ <td>comparison-page</td>
+ <td>*Lines of code*Complexity*Comments (%)*Duplicated lines (%)*Issues*Coverage*</td>
+ </tr>
+ <tr>
+ <td>waitForElementPresent</td>
+ <td>new_metric</td>
+ <td></td>
+ </tr>
+ <tr>
+ <td>typeAndWait</td>
+ <td>new_metric</td>
+ <td>new_violations</td>
+ </tr>
+ <tr>
+ <td>assertText</td>
+ <td>comparison-page</td>
+ <td>*Lines of code*Complexity*Comments (%)*Duplicated lines (%)*Issues*Coverage*</td>
+ </tr>
+ <tr>
+ <td>assertNotText</td>
+ <td>comparison-page</td>
+ <td>*New Issues*</td>
+ </tr>
+ </tbody>
+</table>
+</body>
+</html>
--- /dev/null
+<?xml version="1.0" encoding="UTF-8"?>
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml" xml:lang="en" lang="en">
+<head profile="http://selenium-ide.openqa.org/profiles/test-case">
+ <meta http-equiv="Content-Type" content="text/html; charset=UTF-8"/>
+ <title>should_display_measure_drilldown</title>
+</head>
+<body>
+<table cellpadding="1" cellspacing="1" border="1">
+ <tbody>
+ <tr>
+ <td>open</td>
+ <td>/drilldown/measures?id=project-drilldown-test-project&metric=ncloc</td>
+ <td></td>
+</tr>
+<tr>
+ <td>waitForElementPresent</td>
+ <td>css=a[data-key="project-drilldown-test-project:src/main/xoo/sample/Sample.xoo"]</td>
+ <td></td>
+</tr>
+<tr>
+ <td>click</td>
+ <td>css=a[data-key="project-drilldown-test-project:src/main/xoo/sample/Sample.xoo"]</td>
+ <td></td>
+</tr>
+<tr>
+ <td>waitForElementPresent</td>
+ <td>css=.source-viewer</td>
+ <td></td>
+</tr>
+<tr>
+ <td>waitForText</td>
+ <td>css=.source-viewer</td>
+ <td>*src/main/xoo/sample/*Sample.xoo*</td>
+</tr>
+<tr>
+ <td>waitForText</td>
+ <td>css=.source-viewer</td>
+ <td>*public class Sample {*</td>
+</tr>
+</tbody>
+</table>
+</body>
+</html>
--- /dev/null
+<?xml version="1.0" encoding="UTF-8"?>
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml" xml:lang="en" lang="en">
+<head profile="http://selenium-ide.openqa.org/profiles/test-case">
+ <meta http-equiv="Content-Type" content="text/html; charset=UTF-8"/>
+ <title>static-files</title>
+</head>
+<body>
+<table cellpadding="1" cellspacing="1" border="1">
+<tbody>
+<tr>
+ <td>open</td>
+ <td>/dashboard/index?id=unknown</td>
+ <td></td>
+</tr>
+<tr>
+ <td>waitForText</td>
+ <td>error</td>
+ <td>*The requested project does not exist. Either it has never been analyzed successfully or it has been deleted.*</td>
+</tr>
+</tbody>
+</table>
+</body>
+</html>
--- /dev/null
+<?xml version="1.0" encoding="UTF-8"?>
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml" xml:lang="en" lang="en">
+<head profile="http://selenium-ide.openqa.org/profiles/test-case">
+ <meta http-equiv="Content-Type" content="text/html; charset=UTF-8"/>
+ <title>complexity</title>
+</head>
+<body>
+<table cellpadding="1" cellspacing="1" border="1">
+ <thead>
+ <tr>
+ <td rowspan="1" colspan="3">complexity</td>
+ </tr>
+ </thead>
+ <tbody>
+ <tr>
+ <td>open</td>
+ <td>/widget?id=complexity&resource=project-widgets-test-project&metric1=complexity&metric2=ncloc&chartTitle=MyWidget</td>
+ <td></td>
+</tr>
+<tr>
+ <td>assertText</td>
+ <td>block_1</td>
+ <td>*Complexity*</td>
+</tr>
+<tr>
+ <td>assertText</td>
+ <td>m_class_complexity</td>
+ <td>3.0</td>
+</tr>
+<tr>
+ <td>assertText</td>
+ <td>m_file_complexity</td>
+ <td>3.0</td>
+</tr>
+<tr>
+ <td>assertText</td>
+ <td>m_complexity</td>
+ <td>3</td>
+</tr>
+</tbody>
+</table>
+</body>
+</html>
--- /dev/null
+<?xml version="1.0" encoding="UTF-8"?>
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml" xml:lang="en" lang="en">
+<head profile="http://selenium-ide.openqa.org/profiles/test-case">
+ <meta http-equiv="Content-Type" content="text/html; charset=UTF-8"/>
+ <title>should-exclude-new-metrics</title>
+</head>
+<body>
+<table cellpadding="1" cellspacing="1" border="1">
+ <thead>
+ <tr>
+ <td rowspan="1" colspan="3">should-exclude-new-metrics</td>
+ </tr>
+ </thead>
+ <tbody>
+ <tr>
+ <td>open</td>
+ <td>/sessions/new</td>
+ <td></td>
+ </tr>
+ <tr>
+ <td>type</td>
+ <td>login</td>
+ <td>admin</td>
+ </tr>
+ <tr>
+ <td>type</td>
+ <td>password</td>
+ <td>admin</td>
+ </tr>
+ <tr>
+ <td>clickAndWait</td>
+ <td>commit</td>
+ <td></td>
+ </tr>
+ <tr>
+ <td>clickAndWait</td>
+ <td>link=Configure widgets</td>
+ <td></td>
+ </tr>
+ <tr>
+ <td>waitForText</td>
+ <td>id=content</td>
+ <td>*History Table*</td>
+ </tr>
+ <tr>
+ <td>clickAndWait</td>
+ <td>id=add-widget-custom_measures</td>
+ <td></td>
+ </tr>
+ <tr>
+ <td>waitForText</td>
+ <td>id=content</td>
+ <td>*Metric 1*</td>
+ </tr>
+ <tr>
+ <td>assertElementPresent</td>
+ <td>//div[@class='widget_props' and @style='']//option[text()='Overall condition coverage']</td>
+ <td></td>
+ </tr>
+ <tr>
+ <td>assertElementNotPresent</td>
+ <td>//div[@class='widget_props' and @style='']//option[text()='Overall new condition coverage']</td>
+ <td></td>
+ </tr>
+ <tr>
+ <td>click</td>
+ <td>link=Delete</td>
+ <td></td>
+ </tr>
+ </tbody>
+</table>
+</body>
+</html>
--- /dev/null
+<?xml version="1.0" encoding="UTF-8"?>
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml" xml:lang="en" lang="en">
+<head profile="http://selenium-ide.openqa.org/profiles/test-case">
+ <meta http-equiv="Content-Type" content="text/html; charset=UTF-8"/>
+ <title>description-widget</title>
+</head>
+<body>
+<table cellpadding="1" cellspacing="1" border="1">
+ <thead>
+ <tr>
+ <td rowspan="1" colspan="3">description-widget</td>
+ </tr>
+ </thead>
+ <tbody>
+ <tr>
+ <td>open</td>
+ <td>/widget?id=description&resource=project-widgets-test-project</td>
+ <td></td>
+</tr>
+<tr>
+ <td>assertText</td>
+ <td>block_1</td>
+ <td>*ProjectWidgetsTest Project*project-widgets-test-project*Profiles:*Basic*Quality Gate*SonarQube way*</td>
+</tr>
+</tbody>
+</table>
+</body>
+</html>
--- /dev/null
+<?xml version="1.0" encoding="UTF-8"?>
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml" xml:lang="en" lang="en">
+<head profile="http://selenium-ide.openqa.org/profiles/test-case">
+ <meta http-equiv="Content-Type" content="text/html; charset=UTF-8"/>
+ <title>hide-if-no-measures</title>
+</head>
+<body>
+<table cellpadding="1" cellspacing="1" border="1">
+ <tbody>
+ <tr>
+ <td>open</td>
+ <td>/widget?id=hotspot_metric&resource=project-widgets-test-project&metric=dit</td>
+ <td></td>
+</tr>
+<tr>
+ <td>assertElementPresent</td>
+ <td>block_1</td>
+ <td></td>
+</tr>
+<tr>
+ <td>assertNotText</td>
+ <td>block_1</td>
+ <td>*Depth*</td>
+</tr>
+</tbody>
+</table>
+</body>
+</html>
--- /dev/null
+<?xml version="1.0" encoding="UTF-8"?>
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml" xml:lang="en" lang="en">
+<head profile="http://selenium-ide.openqa.org/profiles/test-case">
+ <meta http-equiv="Content-Type" content="text/html; charset=UTF-8"/>
+ <title>hotspot_metric</title>
+</head>
+<body>
+<table cellpadding="1" cellspacing="1" border="1">
+ <thead>
+ <tr>
+ <td rowspan="1" colspan="3">hotspot_metric</td>
+ </tr>
+ </thead>
+ <tbody>
+ <tr>
+ <td>open</td>
+ <td>/widget?id=hotspot_metric&resource=project-widgets-test-project&metric=ncloc&title=NewTitle</td>
+ <td></td>
+</tr>
+<tr>
+ <td>assertText</td>
+ <td>class=hotspot_metric</td>
+ <td>*NewTitle*Sample.xoo*</td>
+</tr>
+<tr>
+ <td>assertElementPresent</td>
+ <td>link=Sample.xoo</td>
+ <td></td>
+</tr>
+</tbody>
+</table>
+</body>
+</html>