mesosphere / marathon-example-plugins

Example Plugins for Marathon Plugin Interface
Apache License 2.0
22 stars 29 forks source link

ROGER-864:Automated the testing of javaauth plugin #9

Closed 04msambit closed 8 years ago

04msambit commented 8 years ago

Automated the test cases which were executed manually.

Sample Output:

1 - Test1 : When no machines/environment are provided:

sambits-mbp:test sambitmishra$ python marathon_auth_plugin_test.py Please provide list of machines and retry. Exiting... sambits-mbp:test sambitmishra$

2 - Test2 : When a valid machine/environment is provided:

  python marathon_auth_plugin_test.py localmesos01

Executing Tests for environemnt : localmesos01

Executing Test: User with Root Access:

Create Test: Pass Read Test: Pass Update Test: Pass Delete Test: Pass

Executing Test: User with No Access:

Create Test: Pass Read Test: Pass Update Test: Pass Delete Test: Pass

Executing Test: User with Dev Access:

Create Test: Pass Read Test: Pass Update Test: Pass Delete Test: Pass

Executing Test: User with Shared Directory Access:

Create Test: Pass Read Test: Pass Update Test: Pass Delete Test: Pass

Executing Test: CRUD on Unauthorized Environment:

Create Test: Not Allowed to Create -- Result: Pass Read Test: Not Allowed to Read -- Result: Pass Update Test: Not Allowed to Update -- Result: Pass Delete Test: Not Allowed to Delete -- Result: Pass

3 - Test3 : When once of the machine is unreachable ( invalid machine or typo etc )

python marathon_auth_plugin_test.py localmesos01 localmesos02

Executing Tests for environemnt : localmesos01

Executing Test: User with Root Access:

Create Test: Pass Read Test: Pass Update Test: Pass Delete Test: Pass

Executing Test: User with No Access:

Create Test: Pass Read Test: Pass Update Test: Pass Delete Test: Pass

Executing Test: User with Dev Access:

Create Test: Pass Read Test: Pass Update Test: Pass Delete Test: Pass

Executing Test: User with Shared Directory Access:

Create Test: Pass Read Test: Pass Update Test: Pass Delete Test: Pass

Executing Test: CRUD on Unauthorized Environment:

Create Test: Not Allowed to Create -- Result: Pass Read Test: Not Allowed to Read -- Result: Pass Update Test: Not Allowed to Update -- Result: Pass Delete Test: Not Allowed to Delete -- Result: Pass

Environment localmesos02: Unreachable