You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@submarine.apache.org by GitBox <gi...@apache.org> on 2021/06/30 08:21:20 UTC

[GitHub] [submarine] noidname01 opened a new pull request #625: SUBMARINE-881. Sidebar page component object for e2e-test

noidname01 opened a new pull request #625:
URL: https://github.com/apache/submarine/pull/625


   ### What is this PR for?
   Sidebar page component object for e2e-test
   -->
   
   ### What type of PR is it?
   [Improvement]
   
   ### Todos
   
   
   ### What is the Jira issue?
   
   https://issues.apache.org/jira/projects/SUBMARINE/issues/SUBMARINE-881
   
   ### How should this be tested?
   
   ```bash
   # Step1: Run Submarine workbench on 127.0.0.1:8080 by operator
   # Step2: Run testcase
   cd submarine-cloud-v2
   
   # Usage: ./hack/run_frontend_e2e.sh ${testcase}
   # Example: 
   ./hack/run_frontend_e2e.sh notebookIT
   ```
   
   ### Screenshots (if appropriate)
   
   ![image](https://user-images.githubusercontent.com/55401762/123927145-22289d00-d9bf-11eb-9570-2fadc87c2ac7.png)
   
   ### Questions:
   * Do the license files need updating? No
   * Are there breaking changes for older versions? No
   * Does this need new documentation? No
   


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: commits-unsubscribe@submarine.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org



[GitHub] [submarine] noidname01 commented on a change in pull request #625: SUBMARINE-881. Sidebar page component object for e2e-test

Posted by GitBox <gi...@apache.org>.
noidname01 commented on a change in pull request #625:
URL: https://github.com/apache/submarine/pull/625#discussion_r661426774



##########
File path: submarine-test/test-e2e/src/test/java/org/apache/submarine/integration/components/Sidebars.java
##########
@@ -0,0 +1,117 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one or more
+ * contributor license agreements.  See the NOTICE file distributed with
+ * this work for additional information regarding copyright ownership.
+ * The ASF licenses this file to You 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 org.apache.submarine.integration.components;
+
+import org.openqa.selenium.By;
+import org.apache.submarine.AbstractSubmarineIT;
+import org.openqa.selenium.WebDriver;
+import org.openqa.selenium.interactions.Actions;
+import org.openqa.selenium.support.PageFactory;
+import org.openqa.selenium.support.pagefactory.AjaxElementLocatorFactory;
+
+public class Sidebars extends AbstractSubmarineIT{
+
+    private String URL = getURL("http://127.0.0.1", 8080);
+
+    private By toNoteBook = By.xpath("//span[contains(text(), \"Notebook\")]");
+    private String noteBookURL = "/workbench/notebook";
+
+    private By toExperiment = By.xpath("//span[contains(text(), \"Experiment\")]");
+    private String experimentURL = "/workbench/experiment";
+
+    private By toTemplate = By.xpath("//span[contains(text(), \"Template\")]");
+    private String templateURL = "/workbench/template";
+
+    private By toEnvironment = By.xpath("//span[contains(text(), \"Environment\")]");
+    private String environmentURL = "/workbench/environment";
+
+    private By toManager = By.xpath("//span[contains(text(), \"Manager\")]");
+    private String managerURL = "/workbench/manager";
+
+    private By toDataDict = By.xpath("//a[@href='/workbench/manager/dataDict']");
+    private String dataDictURL = "/workbench/manager/dataDict";
+
+    private By toDepartment = By.xpath("//a[@href='/workbench/manager/department']");
+    private String departmentURL = "/workbench/manager/department";
+
+    private By toUser = By.xpath("//a[@href='/workbench/manager/user']");
+    private String userURL = "/workbench/manager/user";
+
+    private By toData = By.xpath("//span[contains(text(), \"Data\")]");
+    private String dataURL = "/workbench/data";
+
+    private By toWorkSpace = By.xpath("//span[contains(text(), \"Workspace\")]");
+    private String workSpaceURL = "/workbench/workspace";
+
+    private By toInterpreter = By.xpath("//span[contains(text(), \"Interpreter\")]");
+    private String interpreterURL = "/workbench/interpreter";
+
+    private Actions action;
+
+    public Sidebars(WebDriver driver) {
+        PageFactory.initElements(new AjaxElementLocatorFactory(driver, 10), this);
+        action = new Actions(driver);

Review comment:
       This is from previous one
   https://github.com/apache/submarine/blob/master/submarine-test/test-e2e/src/test/java/org/apache/submarine/integration/pages/ExperimentPage.java
   
   It seems that it also use the page object model, so I took the reference from it.
   But I found that it's a more enhanced design pattern
   
   https://www.seleniumeasy.com/selenium-tutorials/page-factory-pattern-in-selenium-webdriver
   
   But for now I remove this, because I think it's not necessary.




-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: commits-unsubscribe@submarine.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org



[GitHub] [submarine] kevin85421 commented on a change in pull request #625: SUBMARINE-881. Sidebar page component object for e2e-test

Posted by GitBox <gi...@apache.org>.
kevin85421 commented on a change in pull request #625:
URL: https://github.com/apache/submarine/pull/625#discussion_r661620494



##########
File path: submarine-test/test-e2e/src/test/java/org/apache/submarine/integration/components/Sidebars.java
##########
@@ -0,0 +1,114 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one or more
+ * contributor license agreements.  See the NOTICE file distributed with
+ * this work for additional information regarding copyright ownership.
+ * The ASF licenses this file to You 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 org.apache.submarine.integration.components;
+
+import org.openqa.selenium.By;
+import org.apache.submarine.AbstractSubmarineIT;
+import org.openqa.selenium.WebDriver;
+import org.openqa.selenium.interactions.Actions;
+import org.openqa.selenium.support.PageFactory;
+import org.openqa.selenium.support.pagefactory.AjaxElementLocatorFactory;
+
+public class Sidebars extends AbstractSubmarineIT{
+
+    private String URL = getURL("http://127.0.0.1", 8080);
+
+    private By toNoteBook = By.xpath("//span[contains(text(), \"Notebook\")]");
+    private String noteBookURL = "/workbench/notebook";
+
+    private By toExperiment = By.xpath("//span[contains(text(), \"Experiment\")]");
+    private String experimentURL = "/workbench/experiment";
+
+    private By toTemplate = By.xpath("//span[contains(text(), \"Template\")]");
+    private String templateURL = "/workbench/template";
+
+    private By toEnvironment = By.xpath("//span[contains(text(), \"Environment\")]");
+    private String environmentURL = "/workbench/environment";
+
+    private By toManager = By.xpath("//span[contains(text(), \"Manager\")]");
+    private String managerURL = "/workbench/manager";
+
+    private By toDataDict = By.xpath("//a[@href='/workbench/manager/dataDict']");
+    private String dataDictURL = "/workbench/manager/dataDict";
+
+    private By toDepartment = By.xpath("//a[@href='/workbench/manager/department']");
+    private String departmentURL = "/workbench/manager/department";
+
+    private By toUser = By.xpath("//a[@href='/workbench/manager/user']");
+    private String userURL = "/workbench/manager/user";
+
+    private By toData = By.xpath("//span[contains(text(), \"Data\")]");
+    private String dataURL = "/workbench/data";
+
+    private By toWorkSpace = By.xpath("//span[contains(text(), \"Workspace\")]");
+    private String workSpaceURL = "/workbench/workspace";
+
+    private By toInterpreter = By.xpath("//span[contains(text(), \"Interpreter\")]");
+    private String interpreterURL = "/workbench/interpreter";
+
+
+    public Sidebars(WebDriver driver) {

Review comment:
       I think this function can be removed because it does not do anything.




-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: commits-unsubscribe@submarine.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org



[GitHub] [submarine] noidname01 commented on a change in pull request #625: SUBMARINE-881. Sidebar page component object for e2e-test

Posted by GitBox <gi...@apache.org>.
noidname01 commented on a change in pull request #625:
URL: https://github.com/apache/submarine/pull/625#discussion_r661645817



##########
File path: submarine-test/test-e2e/src/test/java/org/apache/submarine/integration/components/Sidebars.java
##########
@@ -0,0 +1,114 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one or more
+ * contributor license agreements.  See the NOTICE file distributed with
+ * this work for additional information regarding copyright ownership.
+ * The ASF licenses this file to You 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 org.apache.submarine.integration.components;
+
+import org.openqa.selenium.By;
+import org.apache.submarine.AbstractSubmarineIT;
+import org.openqa.selenium.WebDriver;
+import org.openqa.selenium.interactions.Actions;
+import org.openqa.selenium.support.PageFactory;
+import org.openqa.selenium.support.pagefactory.AjaxElementLocatorFactory;
+
+public class Sidebars extends AbstractSubmarineIT{
+
+    private String URL = getURL("http://127.0.0.1", 8080);
+
+    private By toNoteBook = By.xpath("//span[contains(text(), \"Notebook\")]");
+    private String noteBookURL = "/workbench/notebook";
+
+    private By toExperiment = By.xpath("//span[contains(text(), \"Experiment\")]");
+    private String experimentURL = "/workbench/experiment";
+
+    private By toTemplate = By.xpath("//span[contains(text(), \"Template\")]");
+    private String templateURL = "/workbench/template";
+
+    private By toEnvironment = By.xpath("//span[contains(text(), \"Environment\")]");
+    private String environmentURL = "/workbench/environment";
+
+    private By toManager = By.xpath("//span[contains(text(), \"Manager\")]");
+    private String managerURL = "/workbench/manager";
+
+    private By toDataDict = By.xpath("//a[@href='/workbench/manager/dataDict']");
+    private String dataDictURL = "/workbench/manager/dataDict";
+
+    private By toDepartment = By.xpath("//a[@href='/workbench/manager/department']");
+    private String departmentURL = "/workbench/manager/department";
+
+    private By toUser = By.xpath("//a[@href='/workbench/manager/user']");
+    private String userURL = "/workbench/manager/user";
+
+    private By toData = By.xpath("//span[contains(text(), \"Data\")]");
+    private String dataURL = "/workbench/data";
+
+    private By toWorkSpace = By.xpath("//span[contains(text(), \"Workspace\")]");
+    private String workSpaceURL = "/workbench/workspace";
+
+    private By toInterpreter = By.xpath("//span[contains(text(), \"Interpreter\")]");
+    private String interpreterURL = "/workbench/interpreter";
+
+
+    public Sidebars(WebDriver driver) {

Review comment:
       Fixed




-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: commits-unsubscribe@submarine.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org



[GitHub] [submarine] kevin85421 commented on a change in pull request #625: SUBMARINE-881. Sidebar page component object for e2e-test

Posted by GitBox <gi...@apache.org>.
kevin85421 commented on a change in pull request #625:
URL: https://github.com/apache/submarine/pull/625#discussion_r661928223



##########
File path: submarine-test/test-e2e/src/test/java/org/apache/submarine/integration/dataIT.java
##########
@@ -48,7 +49,8 @@ public static void tearDown(){
 
   @Test
   public void dataNavigation() throws Exception {
-    String URL = getURL("http://127.0.0.1", 8080);
+

Review comment:
       empty line

##########
File path: submarine-test/test-e2e/src/test/java/org/apache/submarine/integration/components/Sidebars.java
##########
@@ -0,0 +1,110 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one or more
+ * contributor license agreements.  See the NOTICE file distributed with
+ * this work for additional information regarding copyright ownership.
+ * The ASF licenses this file to You 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 org.apache.submarine.integration.components;
+
+import org.openqa.selenium.By;
+import org.apache.submarine.AbstractSubmarineIT;
+import org.openqa.selenium.WebDriver;
+import org.openqa.selenium.interactions.Actions;
+import org.openqa.selenium.support.PageFactory;
+import org.openqa.selenium.support.pagefactory.AjaxElementLocatorFactory;
+
+public class Sidebars extends AbstractSubmarineIT{
+
+    private String URL = getURL("http://127.0.0.1", 8080);

Review comment:
       In my opinion, it is better to pass URL as a function argument. Any thoughts?

##########
File path: submarine-test/test-e2e/src/test/java/org/apache/submarine/integration/departmentIT.java
##########
@@ -46,20 +47,19 @@ public static void tearDown(){
 
   @Test
   public void dataNavigation() throws Exception {
-    String URL = getURL("http://127.0.0.1", 8080);
+

Review comment:
       empty line

##########
File path: submarine-test/test-e2e/src/test/java/org/apache/submarine/integration/interpreterIT.java
##########
@@ -46,17 +47,17 @@ public static void tearDown(){
 
   @Test
   public void workspaceNavigation() throws Exception {
-    String URL = getURL("http://127.0.0.1", 8080);
-    // Login
+

Review comment:
       empty line

##########
File path: submarine-test/test-e2e/src/test/java/org/apache/submarine/integration/notebookIT.java
##########
@@ -45,12 +46,13 @@ public static void tearDown(){
 
   @Test
   public void notebookNavigation() throws Exception {
-    String URL = getURL("http://127.0.0.1", 8080);
-    // Login
+

Review comment:
       empty line

##########
File path: submarine-test/test-e2e/src/test/java/org/apache/submarine/integration/workspaceIT.java
##########
@@ -48,7 +49,9 @@ public static void tearDown(){
 
   @Test
   public void workspaceNavigation() throws Exception {
-    String URL = getURL("http://127.0.0.1", 8080);
+

Review comment:
       empty line




-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: commits-unsubscribe@submarine.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org



[GitHub] [submarine] noidname01 commented on pull request #625: SUBMARINE-881. Sidebar page component object for e2e-test

Posted by GitBox <gi...@apache.org>.
noidname01 commented on pull request #625:
URL: https://github.com/apache/submarine/pull/625#issuecomment-871210492


   @kevin85421 


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: commits-unsubscribe@submarine.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org



[GitHub] [submarine] noidname01 commented on a change in pull request #625: SUBMARINE-881. Sidebar page component object for e2e-test

Posted by GitBox <gi...@apache.org>.
noidname01 commented on a change in pull request #625:
URL: https://github.com/apache/submarine/pull/625#discussion_r661421602



##########
File path: submarine-test/test-e2e/src/test/java/org/apache/submarine/integration/workspaceIT.java
##########
@@ -48,17 +49,18 @@ public static void tearDown(){
 
   @Test
   public void workspaceNavigation() throws Exception {
-    String URL = getURL("http://127.0.0.1", 8080);
-    // Login
+
+    Sidebars sidebars = new Sidebars(driver);
+
+      // Login

Review comment:
       Fixed




-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: commits-unsubscribe@submarine.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org



[GitHub] [submarine] noidname01 commented on a change in pull request #625: SUBMARINE-881. Sidebar page component object for e2e-test

Posted by GitBox <gi...@apache.org>.
noidname01 commented on a change in pull request #625:
URL: https://github.com/apache/submarine/pull/625#discussion_r661421491



##########
File path: submarine-test/test-e2e/src/test/java/org/apache/submarine/integration/datadictIT.java
##########
@@ -46,7 +47,9 @@ public static void tearDown(){
   // @Test TODO(kevin85421): Due to the undeterministic behavior of travis, I decide to comment it.
   public void dataDictTest() throws Exception {
     String URL = getURL("http://127.0.0.1", 8080);
-    // Login
+    Sidebars sidebars = new Sidebars(driver);
+
+      // Login

Review comment:
       Fixed




-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: commits-unsubscribe@submarine.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org



[GitHub] [submarine] asfgit closed pull request #625: SUBMARINE-881. Sidebar page component object for e2e-test

Posted by GitBox <gi...@apache.org>.
asfgit closed pull request #625:
URL: https://github.com/apache/submarine/pull/625


   


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: commits-unsubscribe@submarine.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org



[GitHub] [submarine] kevin85421 commented on a change in pull request #625: SUBMARINE-881. Sidebar page component object for e2e-test

Posted by GitBox <gi...@apache.org>.
kevin85421 commented on a change in pull request #625:
URL: https://github.com/apache/submarine/pull/625#discussion_r662711728



##########
File path: submarine-test/test-e2e/src/test/java/org/apache/submarine/integration/experimentIT.java
##########
@@ -46,16 +47,18 @@ public static void tearDown(){
   @Test
   public void experimentNavigation() throws Exception {
     String URL = getURL("http://127.0.0.1", 8080);
+
     LOG.info("[Test case]: experimentNavigation]");
     // Init the page object
     ExperimentPage experimentPage = new ExperimentPage(driver);
-    // Login
+    Sidebars sidebars = new Sidebars(URL);
+      // Login

Review comment:
       indentation

##########
File path: submarine-test/test-e2e/src/test/java/org/apache/submarine/integration/interpreterIT.java
##########
@@ -47,16 +48,16 @@ public static void tearDown(){
   @Test
   public void workspaceNavigation() throws Exception {
     String URL = getURL("http://127.0.0.1", 8080);
-    // Login
+    Sidebars sidebars = new Sidebars(URL);
+      // Login

Review comment:
       indentation




-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: commits-unsubscribe@submarine.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org



[GitHub] [submarine] kevin85421 commented on a change in pull request #625: SUBMARINE-881. Sidebar page component object for e2e-test

Posted by GitBox <gi...@apache.org>.
kevin85421 commented on a change in pull request #625:
URL: https://github.com/apache/submarine/pull/625#discussion_r661348025



##########
File path: submarine-test/test-e2e/src/test/java/org/apache/submarine/integration/components/Sidebars.java
##########
@@ -0,0 +1,117 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one or more
+ * contributor license agreements.  See the NOTICE file distributed with
+ * this work for additional information regarding copyright ownership.
+ * The ASF licenses this file to You 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 org.apache.submarine.integration.components;
+
+import org.openqa.selenium.By;
+import org.apache.submarine.AbstractSubmarineIT;
+import org.openqa.selenium.WebDriver;
+import org.openqa.selenium.interactions.Actions;
+import org.openqa.selenium.support.PageFactory;
+import org.openqa.selenium.support.pagefactory.AjaxElementLocatorFactory;
+
+public class Sidebars extends AbstractSubmarineIT{
+
+    private String URL = getURL("http://127.0.0.1", 8080);
+
+    private By toNoteBook = By.xpath("//span[contains(text(), \"Notebook\")]");
+    private String noteBookURL = "/workbench/notebook";
+
+    private By toExperiment = By.xpath("//span[contains(text(), \"Experiment\")]");
+    private String experimentURL = "/workbench/experiment";
+
+    private By toTemplate = By.xpath("//span[contains(text(), \"Template\")]");
+    private String templateURL = "/workbench/template";
+
+    private By toEnvironment = By.xpath("//span[contains(text(), \"Environment\")]");
+    private String environmentURL = "/workbench/environment";
+
+    private By toManager = By.xpath("//span[contains(text(), \"Manager\")]");
+    private String managerURL = "/workbench/manager";
+
+    private By toDataDict = By.xpath("//a[@href='/workbench/manager/dataDict']");
+    private String dataDictURL = "/workbench/manager/dataDict";
+
+    private By toDepartment = By.xpath("//a[@href='/workbench/manager/department']");
+    private String departmentURL = "/workbench/manager/department";
+
+    private By toUser = By.xpath("//a[@href='/workbench/manager/user']");
+    private String userURL = "/workbench/manager/user";
+
+    private By toData = By.xpath("//span[contains(text(), \"Data\")]");
+    private String dataURL = "/workbench/data";
+
+    private By toWorkSpace = By.xpath("//span[contains(text(), \"Workspace\")]");
+    private String workSpaceURL = "/workbench/workspace";
+
+    private By toInterpreter = By.xpath("//span[contains(text(), \"Interpreter\")]");
+    private String interpreterURL = "/workbench/interpreter";
+
+    private Actions action;
+
+    public Sidebars(WebDriver driver) {
+        PageFactory.initElements(new AjaxElementLocatorFactory(driver, 10), this);

Review comment:
       What is this for?

##########
File path: submarine-test/test-e2e/src/test/java/org/apache/submarine/integration/datadictIT.java
##########
@@ -46,7 +47,9 @@ public static void tearDown(){
   // @Test TODO(kevin85421): Due to the undeterministic behavior of travis, I decide to comment it.
   public void dataDictTest() throws Exception {
     String URL = getURL("http://127.0.0.1", 8080);
-    // Login
+    Sidebars sidebars = new Sidebars(driver);
+
+      // Login

Review comment:
       indentation

##########
File path: submarine-test/test-e2e/src/test/java/org/apache/submarine/integration/components/Sidebars.java
##########
@@ -0,0 +1,117 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one or more
+ * contributor license agreements.  See the NOTICE file distributed with
+ * this work for additional information regarding copyright ownership.
+ * The ASF licenses this file to You 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 org.apache.submarine.integration.components;
+
+import org.openqa.selenium.By;
+import org.apache.submarine.AbstractSubmarineIT;
+import org.openqa.selenium.WebDriver;
+import org.openqa.selenium.interactions.Actions;
+import org.openqa.selenium.support.PageFactory;
+import org.openqa.selenium.support.pagefactory.AjaxElementLocatorFactory;
+
+public class Sidebars extends AbstractSubmarineIT{
+
+    private String URL = getURL("http://127.0.0.1", 8080);
+
+    private By toNoteBook = By.xpath("//span[contains(text(), \"Notebook\")]");
+    private String noteBookURL = "/workbench/notebook";
+
+    private By toExperiment = By.xpath("//span[contains(text(), \"Experiment\")]");
+    private String experimentURL = "/workbench/experiment";
+
+    private By toTemplate = By.xpath("//span[contains(text(), \"Template\")]");
+    private String templateURL = "/workbench/template";
+
+    private By toEnvironment = By.xpath("//span[contains(text(), \"Environment\")]");
+    private String environmentURL = "/workbench/environment";
+
+    private By toManager = By.xpath("//span[contains(text(), \"Manager\")]");
+    private String managerURL = "/workbench/manager";
+
+    private By toDataDict = By.xpath("//a[@href='/workbench/manager/dataDict']");
+    private String dataDictURL = "/workbench/manager/dataDict";
+
+    private By toDepartment = By.xpath("//a[@href='/workbench/manager/department']");
+    private String departmentURL = "/workbench/manager/department";
+
+    private By toUser = By.xpath("//a[@href='/workbench/manager/user']");
+    private String userURL = "/workbench/manager/user";
+
+    private By toData = By.xpath("//span[contains(text(), \"Data\")]");
+    private String dataURL = "/workbench/data";
+
+    private By toWorkSpace = By.xpath("//span[contains(text(), \"Workspace\")]");
+    private String workSpaceURL = "/workbench/workspace";
+
+    private By toInterpreter = By.xpath("//span[contains(text(), \"Interpreter\")]");
+    private String interpreterURL = "/workbench/interpreter";
+
+    private Actions action;
+
+    public Sidebars(WebDriver driver) {
+        PageFactory.initElements(new AjaxElementLocatorFactory(driver, 10), this);
+        action = new Actions(driver);

Review comment:
       What is this for?

##########
File path: submarine-test/test-e2e/src/test/java/org/apache/submarine/integration/workspaceIT.java
##########
@@ -48,17 +49,18 @@ public static void tearDown(){
 
   @Test
   public void workspaceNavigation() throws Exception {
-    String URL = getURL("http://127.0.0.1", 8080);
-    // Login
+
+    Sidebars sidebars = new Sidebars(driver);
+
+      // Login

Review comment:
       indentation




-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: commits-unsubscribe@submarine.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org