Skip to content
Merged
Changes from 1 commit
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Prev Previous commit
Add test for nickname creating user
  • Loading branch information
ernilambar committed Apr 26, 2024
commit 18976c988c825b526d32ac5a28bf4c69c240b45f
21 changes: 21 additions & 0 deletions features/user.feature
Original file line number Diff line number Diff line change
Expand Up @@ -708,3 +708,24 @@ Feature: Manage WordPress users
Then STDOUT should be a table containing rows:
| Field | Value |
| user_url | http://www.testsite.com |

Scenario: Support nickname creating and updating user
Given a WP install

When I run `wp user create testuser testuser@example.com --nickname=customtestuser --porcelain`
Then STDOUT should be a number
And save STDOUT as {USER_ID}

When I run `wp user meta get {USER_ID} nickname`
Then STDOUT should be:
"""
customtestuser
"""

When I run `wp user update {USER_ID} --nickname=newtestuser`
And I run `wp user meta get {USER_ID} nickname`
Then STDOUT should be:
"""
newtestuser
"""