aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--server/sonar-qa-util/src/main/java/org/sonarqube/qa/util/pageobjects/SourceViewer.java14
1 files changed, 14 insertions, 0 deletions
diff --git a/server/sonar-qa-util/src/main/java/org/sonarqube/qa/util/pageobjects/SourceViewer.java b/server/sonar-qa-util/src/main/java/org/sonarqube/qa/util/pageobjects/SourceViewer.java
index 5da34d9c7fd..78ed2c8a146 100644
--- a/server/sonar-qa-util/src/main/java/org/sonarqube/qa/util/pageobjects/SourceViewer.java
+++ b/server/sonar-qa-util/src/main/java/org/sonarqube/qa/util/pageobjects/SourceViewer.java
@@ -37,4 +37,18 @@ public class SourceViewer {
return $(".bubble-popup").shouldBe(visible);
}
+ public SourceViewer shouldHaveNewLines(int ...lines) {
+ for (int line : lines) {
+ this.el.$(".source-line-filtered[data-line-number=\"" + line + "\"").shouldBe(visible);
+ }
+ return this;
+ }
+
+ public SourceViewer shouldNotHaveNewLines(int ...lines) {
+ for (int line : lines) {
+ this.el.$(".source-line-filtered[data-line-number=\"" + line + "\"").shouldNotBe(visible);
+ }
+ return this;
+ }
+
}