MCPcopy Create free account
hub / github.com/GetStream/stream-cli / TestDeleteUser

Function TestDeleteUser

pkg/cmd/chat/user/user_test.go:52–59  ·  view source on GitHub ↗
(t *testing.T)

Source from the content-addressed store, hash-verified

50}
51
52func TestDeleteUser(t *testing.T) {
53 u := test.CreateUser()
54 cmd := test.GetRootCmdWithSubCommands(NewCmds()...)
55 cmd.SetArgs([]string{"delete-user", "-u", u, "--hard-delete", "--mark-messages-deleted", "--delete-conversations"})
56 _, err := cmd.ExecuteC()
57 require.NoError(t, err)
58 require.Contains(t, cmd.OutOrStdout().(*bytes.Buffer).String(), "Successfully initiated user deletion")
59}
60
61func TestDeleteMultipleUsers(t *testing.T) {
62 cmd := test.GetRootCmdWithSubCommands(NewCmds()...)

Callers

nothing calls this directly

Calls 4

CreateUserFunction · 0.92
StringMethod · 0.80
NewCmdsFunction · 0.70

Tested by

no test coverage detected