2020-10-08 18:21:27 +02:00
|
|
|
{
|
2021-01-30 06:32:32 +02:00
|
|
|
"name": "focalboard",
|
2023-02-03 00:43:49 +02:00
|
|
|
"version": "7.9.0",
|
2020-10-08 18:21:27 +02:00
|
|
|
"private": true,
|
|
|
|
"description": "",
|
|
|
|
"scripts": {
|
2021-07-16 04:30:22 +02:00
|
|
|
"pack": "cross-env NODE_ENV=production webpack --config webpack.prod.js",
|
|
|
|
"packdev": "cross-env NODE_ENV=dev webpack --config webpack.dev.js",
|
2021-10-02 13:35:36 +02:00
|
|
|
"watchdev": "cross-env NODE_ENV=dev webpack --watch --progress --config webpack.dev.js",
|
2022-11-15 17:59:07 +02:00
|
|
|
"deveditor": "cross-env NODE_ENV=dev webpack server --config webpack.editor.js",
|
2020-10-15 01:02:41 +02:00
|
|
|
"test": "jest",
|
2021-05-26 12:44:09 +02:00
|
|
|
"updatesnapshot": "jest --updateSnapshot",
|
2021-08-26 11:25:25 +02:00
|
|
|
"check": "eslint --ext .tsx,.ts . --quiet --cache && stylelint **/*.scss",
|
|
|
|
"fix": "eslint --ext .tsx,.ts . --quiet --fix --cache && stylelint --fix **/*.scss",
|
2021-04-28 16:28:52 +02:00
|
|
|
"fix:scss": "prettier --write './src/**/*.scss'",
|
2022-11-07 23:19:54 +02:00
|
|
|
"i18n-extract": "formatjs extract \"../mattermost-plugin/webapp/src/**/*.{ts,tsx}\" \"src/**/*.{ts,tsx}\" --ignore \"**/*.d.ts\" \"../**/*.d.ts\" --out-file i18n/tmp.json && formatjs compile i18n/tmp.json --out-file i18n/en.json && npx rimraf i18n/tmp.json",
|
[GH-42] Cypress tests for login actions (#1679)
* Testing API added to server:
- registered only if `enableTestingAPI` is set to `true` in the config file
- has only one route `test/reset`
- reset clears the tables in db for blocks, users, sessions
- functions `DeleteAllBlocks` and `DeleteAllUsers` added to `Store` interface
- new functions implemented for `SQLStore`
* Cypress tests (initial version) for login actions added:
- redirect to login page,
- register user,
- test for loading home page deleted,
- allow js in `tsconfig.json` for cypress tests.
* Cypress tests for login actions:
- check that main page with workspace is visible after registration,
- initial version of test for login of register user.
* Cypress tests for login actions:
- function for checking that workspace is available added,
- functions for login and logout added,
- test for password change added,
- session parameters added to server config for cypress testing.
* Switch Cypress tests to typescript.
* Use ids for inputs instead of placeholder text.
* Use cypress request for login without loading login page.
* Cypress custom command for login added.
* Cypress tests fixed:
- new cypress commands for server reset, register/login user
- single test for "create and delete board/card"
- fixes for `BoardPage` component useEffect callbacks
- npm script `runserver-test` doesn't use single user mode
* Deletion of all blocks changed:
- also deletes blocks from history
- public function renamed to DeleteAllBlocksPermanently
- code for mocks and public methods generated
* Server tests for files fixed on windows.
* Cypress tests for the registration of second user via invite link added.
* Added `baseUrl` in main `tsconfig.json` (required by cypress configuration).
* Cypress test fixed. Comments as well as log messages added.
* Log a message if testing API is enabled.
* Single cypress test for register/login actions.
* Revert changes to server.
* More convenient cypress commands:
- all API calls made as separate commands
- declarations for commands moved to separate global.d.ts file
- utility functions moved after test actions in 'Login actions' test
2021-11-22 17:59:01 +02:00
|
|
|
"runserver-test": "cd cypress && \"../../bin/focalboard-server\"",
|
2020-12-10 23:45:56 +02:00
|
|
|
"cypress:ci": "start-server-and-test runserver-test http://localhost:8088 cypress:run",
|
2022-05-20 16:09:16 +02:00
|
|
|
"cypress:debug": "start-server-and-test runserver-test http://localhost:8088 cypress:open",
|
2020-12-11 00:31:20 +02:00
|
|
|
"cypress:run": "cypress run",
|
2021-01-07 02:09:36 +02:00
|
|
|
"cypress:run:chrome": "cypress run --browser chrome",
|
|
|
|
"cypress:run:firefox": "cypress run --browser firefox",
|
|
|
|
"cypress:run:edge": "cypress run --browser edge",
|
|
|
|
"cypress:run:electron": "cypress run --browser electron",
|
2022-01-07 20:58:28 +02:00
|
|
|
"cypress:open": "cypress open"
|
2021-01-07 02:09:36 +02:00
|
|
|
},
|
2020-10-08 18:21:27 +02:00
|
|
|
"dependencies": {
|
2022-03-26 01:07:49 +02:00
|
|
|
"@draft-js-plugins/editor": "^4.1.2",
|
|
|
|
"@draft-js-plugins/emoji": "^4.6.0",
|
|
|
|
"@draft-js-plugins/mention": "^5.1.2",
|
|
|
|
"@fullcalendar/core": "^5.10.1",
|
|
|
|
"@fullcalendar/daygrid": "^5.10.1",
|
|
|
|
"@fullcalendar/interaction": "^5.10.1",
|
|
|
|
"@fullcalendar/react": "^5.10.1",
|
2022-10-11 17:19:25 +02:00
|
|
|
"@mattermost/compass-icons": "^0.1.28",
|
2022-03-26 01:07:49 +02:00
|
|
|
"@reduxjs/toolkit": "^1.8.0",
|
2022-03-02 23:00:33 +02:00
|
|
|
"@tippyjs/react": "4.2.6",
|
2022-03-26 01:07:49 +02:00
|
|
|
"color": "^4.2.1",
|
2021-11-25 22:10:39 +02:00
|
|
|
"draft-js": "^0.11.7",
|
2021-03-25 20:40:50 +02:00
|
|
|
"emoji-mart": "^3.0.1",
|
2022-02-02 15:36:49 +02:00
|
|
|
"fstream": "^1.0.12",
|
2022-03-26 01:07:49 +02:00
|
|
|
"fullcalendar": "^5.10.2",
|
2021-05-27 14:33:28 +02:00
|
|
|
"imagemin-gifsicle": "^7.0.0",
|
2022-03-26 01:07:49 +02:00
|
|
|
"imagemin-mozjpeg": "^10.0.0",
|
2021-05-27 14:33:28 +02:00
|
|
|
"imagemin-optipng": "^8.0.0",
|
|
|
|
"imagemin-pngquant": "^9.0.2",
|
2022-03-26 01:07:49 +02:00
|
|
|
"imagemin-svgo": "^10.0.1",
|
2022-02-02 15:36:49 +02:00
|
|
|
"imagemin-webp": "^7.0.0",
|
2021-06-07 13:25:25 +02:00
|
|
|
"lodash": "^4.17.21",
|
2022-01-31 19:37:32 +02:00
|
|
|
"marked": "^4.0.12",
|
2022-03-26 01:07:49 +02:00
|
|
|
"mini-create-react-context": "^0.4.1",
|
2021-05-20 14:58:19 +02:00
|
|
|
"moment": "^2.29.1",
|
2021-03-25 20:40:50 +02:00
|
|
|
"nanoevents": "^5.1.13",
|
2022-08-17 22:22:35 +02:00
|
|
|
"react": "^16.13.0",
|
2022-12-14 10:51:53 +02:00
|
|
|
"react-beautiful-dnd": "^13.1.1",
|
2021-05-10 07:46:07 +02:00
|
|
|
"react-day-picker": "^7.4.10",
|
2021-04-07 15:51:19 +02:00
|
|
|
"react-dnd": "^14.0.2",
|
|
|
|
"react-dnd-html5-backend": "^14.0.0",
|
2022-01-07 20:58:28 +02:00
|
|
|
"react-dnd-scrolling": "^1.2.1",
|
2021-04-08 10:40:57 +02:00
|
|
|
"react-dnd-touch-backend": "^14.0.0",
|
2022-08-17 22:22:35 +02:00
|
|
|
"react-dom": "^16.13.0",
|
2022-03-26 01:07:49 +02:00
|
|
|
"react-hot-keys": "^2.7.1",
|
|
|
|
"react-hotkeys-hook": "^3.4.4",
|
2022-08-17 22:22:35 +02:00
|
|
|
"react-intl": "^5.20.0",
|
|
|
|
"react-redux": "^7.2.0",
|
|
|
|
"react-router-dom": "^5.2.0",
|
2022-03-29 10:14:57 +02:00
|
|
|
"react-select": "^5.2.2",
|
2022-02-02 15:36:49 +02:00
|
|
|
"trim-newlines": "^4.0.2"
|
2020-10-08 18:21:27 +02:00
|
|
|
},
|
2020-10-14 08:51:37 +02:00
|
|
|
"jest": {
|
2021-03-25 19:47:02 +02:00
|
|
|
"moduleNameMapper": {
|
2021-10-25 17:44:46 +02:00
|
|
|
"\\.(jpg|jpeg|png|gif|eot|otf|webp|svg|ttf|woff|woff2|mp4|webm|wav|mp3|m4a|aac|oga)$": "<rootDir>/__mocks__/fileMock.js",
|
2021-06-18 16:52:36 +02:00
|
|
|
"\\.(scss|css)$": "<rootDir>/__mocks__/styleMock.js"
|
2021-03-25 19:47:02 +02:00
|
|
|
},
|
2021-01-07 02:09:36 +02:00
|
|
|
"globals": {
|
|
|
|
"ts-jest": {
|
2021-06-18 18:08:15 +02:00
|
|
|
"tsconfig": "./src/tsconfig.json"
|
2021-01-07 02:09:36 +02:00
|
|
|
}
|
|
|
|
},
|
|
|
|
"transform": {
|
2022-03-26 01:07:49 +02:00
|
|
|
"^.+\\.tsx?$": "@swc/jest"
|
2020-12-01 21:31:20 +02:00
|
|
|
},
|
2022-03-26 01:07:49 +02:00
|
|
|
"transformIgnorePatterns": [
|
|
|
|
"/nanoevents/"
|
|
|
|
],
|
|
|
|
"maxWorkers": "50%",
|
|
|
|
"testEnvironment": "jsdom",
|
2020-12-08 00:50:22 +02:00
|
|
|
"collectCoverage": true,
|
|
|
|
"collectCoverageFrom": [
|
2020-12-10 23:45:56 +02:00
|
|
|
"src/**/*.{ts,tsx,js,jsx}",
|
|
|
|
"!src/test/**"
|
2020-12-08 00:50:22 +02:00
|
|
|
]
|
|
|
|
},
|
2020-10-08 18:21:27 +02:00
|
|
|
"devDependencies": {
|
2022-03-26 01:07:49 +02:00
|
|
|
"@formatjs/cli": "^4.8.2",
|
|
|
|
"@formatjs/ts-transformer": "^3.9.2",
|
|
|
|
"@swc/jest": "^0.2.20",
|
2021-12-15 18:57:58 +02:00
|
|
|
"@testing-library/cypress": "^8.0.2",
|
2022-03-26 01:07:49 +02:00
|
|
|
"@testing-library/dom": "^8.11.4",
|
|
|
|
"@testing-library/jest-dom": "^5.16.3",
|
2021-03-25 20:40:50 +02:00
|
|
|
"@testing-library/react": "^11.2.5",
|
2022-03-26 01:07:49 +02:00
|
|
|
"@testing-library/user-event": "^13.5.0",
|
|
|
|
"@types/color": "^3.0.3",
|
|
|
|
"@types/draft-js": "^0.11.9",
|
|
|
|
"@types/emoji-mart": "^3.0.9",
|
|
|
|
"@types/jest": "^27.4.1",
|
|
|
|
"@types/marked": "^4.0.3",
|
2020-10-28 18:56:27 +02:00
|
|
|
"@types/nanoevents": "^1.0.0",
|
2022-03-26 01:07:49 +02:00
|
|
|
"@types/react": "^17.0.43",
|
2022-12-14 10:51:53 +02:00
|
|
|
"@types/react-beautiful-dnd": "^13.1.2",
|
2022-03-26 01:07:49 +02:00
|
|
|
"@types/react-dom": "^17.0.14",
|
2020-10-24 10:08:22 +02:00
|
|
|
"@types/react-intl": "^3.0.0",
|
2022-03-26 01:07:49 +02:00
|
|
|
"@types/react-redux": "^7.1.23",
|
|
|
|
"@types/react-router-dom": "^5.3.3",
|
2022-03-29 10:14:57 +02:00
|
|
|
"@types/react-select": "^5.0.0",
|
2021-07-14 21:22:40 +02:00
|
|
|
"@types/redux-mock-store": "^1.0.3",
|
2022-03-26 01:07:49 +02:00
|
|
|
"@typescript-eslint/eslint-plugin": "^5.16.0",
|
|
|
|
"@typescript-eslint/parser": "^5.16.0",
|
|
|
|
"copy-webpack-plugin": "^10.2.4",
|
2021-07-16 04:30:22 +02:00
|
|
|
"cross-env": "^7.0.3",
|
2022-03-26 01:07:49 +02:00
|
|
|
"css-loader": "^6.7.1",
|
|
|
|
"cypress": "^9.5.2",
|
|
|
|
"cypress-failed-log": "^2.9.5",
|
|
|
|
"cypress-real-events": "^1.7.0",
|
|
|
|
"eslint": "^8.11.0",
|
|
|
|
"eslint-import-resolver-webpack": "0.13.2",
|
2021-03-26 12:51:01 +02:00
|
|
|
"eslint-plugin-babel": "^5.3.1",
|
2022-03-26 01:07:49 +02:00
|
|
|
"eslint-plugin-cypress": "2.12.1",
|
2021-03-25 20:40:50 +02:00
|
|
|
"eslint-plugin-header": "3.1.1",
|
2022-03-26 01:07:49 +02:00
|
|
|
"eslint-plugin-import": "2.25.4",
|
2020-10-15 01:02:41 +02:00
|
|
|
"eslint-plugin-jquery": "1.5.1",
|
2022-09-14 15:11:50 +02:00
|
|
|
"eslint-plugin-mattermost": "github:mattermost/eslint-plugin-mattermost#23abcf9988f7fa00d26929f11841aab7ccb16b2b",
|
2022-03-26 01:07:49 +02:00
|
|
|
"eslint-plugin-no-only-tests": "2.6.0",
|
|
|
|
"eslint-plugin-react": "7.29.4",
|
2021-05-25 11:56:20 +02:00
|
|
|
"fetch-mock-jest": "^1.5.1",
|
2021-03-25 20:40:50 +02:00
|
|
|
"file-loader": "^6.2.0",
|
2022-03-26 01:07:49 +02:00
|
|
|
"html-webpack-plugin": "^5.5.0",
|
2022-02-02 15:36:49 +02:00
|
|
|
"image-webpack-loader": "^8.1.0",
|
2020-12-08 00:50:22 +02:00
|
|
|
"isomorphic-fetch": "^3.0.0",
|
2022-03-26 01:07:49 +02:00
|
|
|
"jest": "^27.5.1",
|
|
|
|
"jest-mock": "^27.5.1",
|
|
|
|
"prettier": "^2.6.1",
|
2021-07-14 21:22:40 +02:00
|
|
|
"redux-mock-store": "^1.5.4",
|
2022-03-26 01:07:49 +02:00
|
|
|
"sass": "^1.49.9",
|
|
|
|
"sass-loader": "^12.6.0",
|
|
|
|
"start-server-and-test": "^1.14.0",
|
|
|
|
"style-loader": "^3.3.1",
|
|
|
|
"stylelint": "^14.6.1",
|
|
|
|
"stylelint-config-sass-guidelines": "^9.0.1",
|
|
|
|
"terser-webpack-plugin": "^5.3.1",
|
|
|
|
"ts-jest": "^27.1.4",
|
|
|
|
"ts-loader": "^9.2.8",
|
|
|
|
"typescript": "^4.6.3",
|
|
|
|
"webpack": "^5.70.0",
|
|
|
|
"webpack-cli": "^4.9.2",
|
2022-11-15 17:59:07 +02:00
|
|
|
"webpack-dev-server": "^4.11.1",
|
2022-03-26 01:07:49 +02:00
|
|
|
"webpack-merge": "^5.8.0"
|
2021-01-07 02:09:36 +02:00
|
|
|
},
|
|
|
|
"optionalDependencies": {
|
2022-03-26 01:07:49 +02:00
|
|
|
"cypress": "^9.5.2"
|
2020-10-08 18:21:27 +02:00
|
|
|
}
|
|
|
|
}
|