GitHub user soralee reopened a pull request:

    https://github.com/apache/zeppelin/pull/2438

    [ZEPPELIN-2693] Test: interpreter mode action test

    ### What is this PR for?
    Adding to interpreter mode (globally shared mode, Per user/Scoped mode, Per 
user/isolated mode) action case on Selenium test.
    Here is for checking scenario.
    
    #### 1.  globally in shared mode
    ```
    admin : set 'globally in shared' mode of python interpreter
    
    User 1: create new note
    User 1: Code “%python user = user1” in the first paragraph
    User 1: Code “%python print user” in the second paragraph and run it
    User 1: Check if the result is user1 in the second paragraph
    System: Check if the number of python interpreter process is 1
    System: Check if the number of python process is 1
    
    User 2: create new note
    User 2: Code “%python user = user2” in the first paragraph
    User 2: Code “%python print user” in the second paragraph and run it
    User 2: Check if the result is user2 in the second paragraph
    System: Check if the number of python interpreter process is 1
    System: Check if the number of python process is 1
    
    User 1: Run the second paragraph again.
    User 1: Check if the result is user2 in the second paragraph
    User 1: Restart python interpreter in the note.
    System: Check if the number of python interpreter and python process is 0
    ```
    
    #### 2. Per user in scoped mode
    ```
    admin : set 'Per user in scoped' mode of python interpreter
    
    User 1: create new note
    User 1: Code “%python user = user1” in the first paragraph
    User 1: Code “%python print user” in the second paragraph and run it
    User 1: Check if the result is user1 in the second paragraph
    System: Check if the number of python interpreter process is 1
    System: Check if the number of python process is 1
    
    User 2: create new note
    User 2: Code “%python user = user2” in the first paragraph
    User 2: Code “%python print user” in the second paragraph and run it
    User 2: Check if the result is user2 in the second paragraph
    System: Check if the number of python interpreter process is 1
    System: Check if the number of python process is 2
    
    User 1: Run the second paragraph again.
    User 1: Check if the result is user1 in the second paragraph
    User 1: Restart python interpreter in the note.
    System: Check if the number of python interpreter process is 1
    System: Check if the number of python process is 1
    
    User 2: Restart python interpreter in the note.
    System: Check if the number of python interpreter process is 0
    System: Check if the number of python process is 0
    
    User 1: Run the first paragraph
    User 2: Run the first paragraph
    System: Check if the number of python interpreter process is 1
    System: Check if the number of python process is 2
    
    admin: Restart python interpreter in interpreter tab
    System: Check if the number of python interpreter process is 0
    System: Check if the number of python process is 0
    ```
    
    #### 2. Per user in isolated mode
    ```
    admin : set 'Per user in isolated' mode of python interpreter
    
    User 1: create new note
    User 1: Code “%python user = user1” in the first paragraph
    User 1: Code “%python print user” in the second paragraph and run it
    User 1: Check if the result is user1 in the second paragraph
    System: Check if the number of python interpreter process is 1
    System: Check if the number of python process is 1
    
    User 2: create new note
    User 2: Code “%python user = user2” in the first paragraph
    User 2: Code “%python print user" in the second paragraph and run it
    User 2: Check if the result is user 2 in the second paragraph
    System: Check if the number of python interpreter process is 2
    System: Check if the number of python process is 2
    
    User 1: Run the second paragraph again.
    User 1: Check if the result is user1 in the second paragraph
    User 1: Restart python interpreter in the note.
    System: Check if the number of python interpreter process is 1
    System: Check if the number of python process is 1
    
    User 2: Restart python interpreter in the note.
    System: Check if the number of python interpreter process is 0
    System: Check if the number of python process is 0
    
    User 1: Run the first paragraph
    User 2: Run the first paragraph
    System: Check if the number of python interpreter process is 2
    System: Check if the number of python process is 2
    
    admin : Restart python interpreter in interpreter tab
    System: Check if the number of python interpreter process is 0
    System: Check if the number of python process is 0
    ```
    
    ### What type of PR is it?
    [ Test ]
    
    ### Todos
     - * [x] - add logic to check process - interpreter process and python 
process
     - * [x] - add logic to restart python interpreter button in note
     - * [x] - add logic to restart python interpreter in interpreter tab
    
    1. * [x] - update and complete `Globally in shared mode` scenario
    2. * [x] - make and complete `Per user in scoped mode` scenario
    3. * [x] - make and complete `Per user in isolated mode` scenario
    
    ### What is the Jira issue?
    * [adding Interpreter mode 
test](https://issues.apache.org/jira/browse/ZEPPELIN-2693)
    
    ### How should this be tested?
    
    1. build zeppelin with `mvn clean package -DskipTests`
    
    2.1. total test : run `TEST_SELENIUM='true' mvn test -pl 'zeppelin-server' 
--am -DfailIfNoTests=false -Dtest=InterpreterModeActionsIT`
    
    2.2.  globally mode -
    `TEST_SELENIUM='true' mvn test -pl 'zeppelin-server' --am 
-DfailIfNoTests=false -Dtest=InterpreterModeActionsIT#testGloballyAction`
    
    2.3.  Per user in scoped mode -
    `TEST_SELENIUM='true' mvn test -pl 'zeppelin-server' --am 
-DfailIfNoTests=false -Dtest=InterpreterModeActionsIT#testPerUserScopedAction`
    
    2.4. Per user in isolated mode -
    `TEST_SELENIUM='true' mvn test -pl 'zeppelin-server' --am 
-DfailIfNoTests=false -Dtest=InterpreterModeActionsIT#testPerUserIsolatedAction`
    
    ### Questions:
    * Does the licenses files need update? No
    * Is there breaking changes for older versions? No
    * Does this needs documentation? No


You can merge this pull request into a Git repository by running:

    $ git pull https://github.com/soralee/zeppelin 
ZEPPELIN-2693_adding_Interpreter_mode_test

Alternatively you can review and apply these changes as the patch at:

    https://github.com/apache/zeppelin/pull/2438.patch

To close this pull request, make a commit to your master/trunk branch
with (at least) the following in the commit message:

    This closes #2438
    
----
commit 8a1e81165bcb374d6f5fac13f437375f8b1216de
Author: soralee <sora0...@zepl.com>
Date:   2017-06-26T15:19:55Z

    Test: adding initial interpreter mode action test

commit b3e3bf93eeda84227a43b717161268b0c412a42b
Author: soralee <sora0...@zepl.com>
Date:   2017-06-26T16:08:40Z

    fix: add permission to user1 and user2, add todo annotation

commit edb41a727ad851887a16023b19c65e4362f7fdf8
Author: soralee <sora0...@zepl.com>
Date:   2017-06-29T17:05:10Z

    fix: complete 1.globally in shared mode scenario

commit 52aa05a2d6bed3cfe46006fcc5898e6ce22d5366
Author: soralee <sora0...@zepl.com>
Date:   2017-06-29T20:03:41Z

    fix: complete 2.Per user in scoped mode scenario

commit 38e27f38942675eba3a1ee09acbd663ba935ddc4
Author: soralee <sora0...@zepl.com>
Date:   2017-06-29T20:28:07Z

    fix: improve code

commit 40ecbe91e2bc34af07a4646cf9cdc339fa032bdb
Author: soralee <sora0...@zepl.com>
Date:   2017-06-29T21:57:51Z

    fix: complete 3.Per user in isolated mode scenario

commit 1bca7f4e9e7df30d8692153eff2f259d1867c7a1
Author: soralee <sora0...@zepl.com>
Date:   2017-06-30T01:20:50Z

    fix: fix typo

----


---
If your project is set up for it, you can reply to this email and have your
reply appear on GitHub as well. If your project does not have this feature
enabled and wishes so, or if the feature is enabled but not working, please
contact infrastructure at infrastruct...@apache.org or file a JIRA ticket
with INFRA.
---

Reply via email to