mirror of
https://github.com/hanzoai/team.git
synced 2026-09-30 01:57:35 +00:00
12 lines
427 B
JavaScript
12 lines
427 B
JavaScript
// Copyright (c) 2015-present Mattermost, Inc. All Rights Reserved.
|
|
// See LICENSE.txt for license information.
|
|
|
|
import {getAdminAccount} from './env';
|
|
|
|
Cypress.Commands.add('externalActivateUser', (userId, active = true) => {
|
|
const baseUrl = Cypress.config('baseUrl');
|
|
const admin = getAdminAccount();
|
|
|
|
cy.externalRequest({user: admin, method: 'put', baseUrl, path: `users/${userId}/active`, data: {active}});
|
|
});
|