focalboard/webapp/cypress/global.d.ts
kamre 7cb25b9e17
[GH-1826] Cypress test for group by different property (#1966)
* Cypress command for resetting boards added.

* Cypress test for group board by different property added:
 - using @testing-library/cypress
 - minor fixes for `PropertyMenu` and `Dialog` components
 - bug in `ViewHeaderGroupByMenu` fixed: use `groupByProperty` passed in props instead of one from active view

* Jest snapshots updated.

* Use only case-sensitive strings for names in Cypress test.

* Cypress commands for adding new board and new group added.

* Jest snapshot for new test updated.

Co-authored-by: Mattermod <mattermod@users.noreply.github.com>
2021-12-15 09:57:58 -07:00

24 lines
841 B
TypeScript

// Copyright (c) 2015-present Mattermost, Inc. All Rights Reserved.
// See LICENSE.txt for license information.
declare namespace Cypress {
type LoginData = {
username: string
password: string
}
type UserData = LoginData & {
email: string
}
interface Chainable {
apiRegisterUser: (data: UserData, token?: string, failOnError?: boolean) => Chainable
apiLoginUser: (data: LoginData) => Chainable
apiGetMe: () => Chainable<string>
apiChangePassword: (userId: string, oldPassword: string, newPassword: string) => Chainable
apiInitServer: () => Chainable
apiDeleteBlock: (id: string) => Chainable
apiResetBoards: () => Chainable
uiCreateNewBoard: (title?: string) => Chainable
uiAddNewGroup: (name?: string) => Chainable
}
}