Skip to content

Commit

Permalink
Add tests for creating internal users
Browse files Browse the repository at this point in the history
Signed-off-by: Zelin Hao <zelinhao@amazon.com>
  • Loading branch information
zelinh committed Jan 28, 2025
1 parent 90e8a74 commit 2cd1b1c
Showing 1 changed file with 16 additions and 3 deletions.
19 changes: 16 additions & 3 deletions tests/default/security/api/internalusers.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -12,18 +12,31 @@ chapters:
method: GET
response:
status: 200
- synopsis: Create internal user for first time.
path: /_plugins/_security/api/internalusers/{username}
method: PUT
parameters:
username: test
request:
payload:
password: myWeakPassword123!
opendistro_security_roles: []
backend_roles: []
attributes: {}
response:
status: 201
- synopsis: Patch internal users bulk.
path: /_plugins/_security/api/internalusers
method: PATCH
request:
payload:
payload:
- op: add
path: /test
value:
value:
backend_roles: [admin]
response:
status: 200
- synopsis: Create internal user.
- synopsis: Create internal user with existing name.
path: /_plugins/_security/api/internalusers/{username}
method: PUT
parameters:
Expand Down

0 comments on commit 2cd1b1c

Please sign in to comment.