Commit graph

64 commits

Author SHA1 Message Date
yasserfaraazkhan 961deee365 add folder ID to save cycle separately 2024-02-09 02:43:39 +05:30
yasserfaraazkhan 675ec6d661
E2E: CI Improvements (#2918) 2023-12-13 14:24:16 +05:30
yasserfaraazkhan 932eff2ea9
feat(e2e): add a job to run e2e on linux os (#2796) 2023-10-25 02:01:36 +05:30
Devin Binnie 32223fa3e1
Fix app name test (#2824) 2023-09-06 16:01:06 -04:00
Devin Binnie 6fbb9234af
Update node-abi, remove Back button test (#2822) 2023-09-06 14:12:03 -04:00
Devin Binnie d4a4defaa3
[MM-53490] Reduce min window width to 600px (#2787) 2023-07-18 09:42:53 -04:00
Devin Binnie 1239add076
[MM-50352] Improve URL validation and add/edit server experience (#2720)
* [MM-50352] Improve URL validation and add/edit server experience

* Fix build

* Fix translations

* First pass of fixes

* Some changes to avoid 2 clicks, tests

* PR feedback

* Update translations

* PR feedback

* Fix translations

* PR feedback

* E2E test fixes
2023-05-24 09:04:38 -04:00
Devin Binnie 316beba950
[MM-14093] Rename 'team' to 'server' and 'tab' to 'view' in most cases, some additional cleanup (#2711)
* Rename MattermostTeam -> UniqueServer, MattermostTab -> UniqueView

* Rename 'team' to 'server'

* Some further cleanup

* Rename weirdly named function

* Rename 'tab' to 'view' in most instances

* Fix i18n

* PR feedback
2023-05-08 09:17:01 -04:00
Devin Binnie f4f4511cc7
Remove WindowManager, separate functionality into smaller modules (#2682)
* Move sendToRenderer to respective singletons

* Move to using ViewManager call for getting view by webContentsId

* Move show and create logic to main window, handle deep linking seperately

* Move resizing logic and event handing to mainWindow

* Move server switching logic to main/app

* Move tab switching logic to main/app, rely on showById for most usage

* Migrate remaining functions, remove windowManager objects, set up imports for self-contained singletons

* Fix E2E tests

* Update src/main/app/servers.ts

Co-authored-by: Elias Nahum <nahumhbl@gmail.com>

---------

Co-authored-by: Elias Nahum <nahumhbl@gmail.com>
2023-04-19 11:04:26 -04:00
Devin Binnie 686b4ac9f1
[MM-50485] Migrate app to ServerManager, remove view names and replace with IDs (#2672)
* Migrate app to ServerManager, remove view names and replace with IDs

* Fixed a test

* Fixed a bug when adding the initial server

* Merge'd

* Bug fixes and PR feedback
2023-04-12 12:52:34 -04:00
Devin Binnie cf6611cc87
[MM-50011] Disable popping the dialog box for uncaught exceptions (#2519) 2023-01-27 09:05:32 -05:00
Devin Binnie 59c98036ee
Add await to the dark mode toggle test for Linux (#2518) 2023-01-26 08:46:32 -05:00
Devin Binnie cf4cdf5c1c
Fixed full screen E2E test for smaller displays (#2517)
* Fixed full screen test for smaller displays

* Fix bork
2023-01-26 08:45:52 -05:00
Devin Binnie c8c88a274f
[MM-49724] More robust check for startup before starting E2E tests (#2504)
* [MM-49724] More robust check for startup before starting E2E tests

* Fix a few more tests
2023-01-18 12:11:11 +02:00
Devin Binnie 29f10f1467
Fixed some unit tests and add test step to run on Windows/Mac builds (#2466)
* Fixed some unit tests and add test step to run on Windows/Mac builds

* Update failing test

* Fix backlash

* Fix windows run

* Fix Windows again

Co-authored-by: Tasos Boulis <tboulis@hotmail.com>
Co-authored-by: Mattermod <mattermod@users.noreply.github.com>
2022-12-14 17:10:20 -04:00
Devin Binnie 865fd2522f
Fixed some E2E tests that broke on v5.2 (#2453)
* Fixing some E2E tests

* Fixed a couple flaky ones

* Fixed some issues on Windows
2022-12-06 14:40:56 +02:00
Pantelis Vratsalis 84ab14eabf
[MM-48685] Fix failing downloads dropdown items tests (#2431)
* [MM-48685] Fix failing downloads dropdown items tests

* Remove unused styles for Thumbnail
2022-11-30 17:43:55 +02:00
Tasos Boulis 0f51a628f0
[MM-47776] Reverse order of input fields in server welcome screen (#2309)
* Reverse order of inputs in Server modals (add/edit)

* Revert "Reverse order of inputs in Server modals (add/edit)"

This reverts commit f3d577dcd5c0e13d6d0e3c2cc4de588008f53e68.

* Update order of server fields in welcome screens

* Update server modal focus test

* Add margin between inputs
2022-10-24 10:59:09 -04:00
Tasos Boulis 131b5fa2ac
[MM-22239] Downloads dropdown (#2227)
* WIP: show/hide temp downloads dropdown

* WIP: Position downloads dropdown correctly under the button

* WIP: Use correct width for dropdown so that right radius and shadows are displayed

* WIP: Add items to download list after finished downloading

* WIP: Add download item base components

* Add "clear all" functionality

* Use type Record<> for downloads saved in config

* Add styling to files in the downloads dropdown

* Open file in folder when clicking it from downloads dropdown. Center svg in parent element

* Update scrollbar styling

* Update scrollbar styling

* Update state of downloaded items if deleted from folder

* Add progress bar in downloads

* Use "x-uncompressed-content-length" in file downloads.

* Keep downloads open when clicking outside their browserview

* Use correct color for downloads dropdown button

* Add better styling to downloads dropdown button

* Allow only 50 download files maximum. Oldest file is being removed if reached

* Autoclose downloads dropdown after 4s of download finish

* Add file thumbnails

* Dont show second dialog if first dismissed

* Add red badge when downloads running and dropdown closed

* Add menu item for Downloads

* Add support for more code file extensions

* Open downloads dropdown instead of folder from the menu

* Run lint:js and fix problems

* Add tests for utils

* Fix issue with dropdown not displaying

* Remove unecessary comment

* Move downloads to separate json file, outside Config

* Add downloads dropdown menu for the 3-dot button

* Dont show dev tools for downloads

* Add cancel download functionality

* Add dark mode styling

* Use View state for downloadsMenu open state

* Fix some style issues

* Add image preview for downloaded images

* Remove extra devTool in weback config

* Fix issue with paths on windows

* Align items left in downloads menu

* Use pretty-bytes for file sizes

* Show download remaining time

* Close downloads dropdown when clicking outside

* Show different units in received bytes when they are different from the total units (kb/mb)

* Dont hide downloads when mattermost view is clicked

* Keep downloads open if download button is clicked

* Use closest() to check for download clicks

* Fix unit tests.
Add tests for new Views and downloadManager
Add @types/jest as devDependency for intellisense

* Remove unecessary tsconfig for jest

* Fix types error

* Add all critical tests for downloadsManager

* WIP: add e2e tests for downloads

* WIP: add e2e tests for downloads

* Rename downloads spec file

* WIP: make vscode debugger work for e2e tests

* Remove unused mock

* Remove defaults for v4 config

* Use electron-mocha for e2e debugger

* Fix e2e tests spawning JsonFileManager twice

* Add async fs functions and add tests for download item UI

* Add async fs functions and add tests for download item UI

* Improve tests with "waitForSelector" to wait for visible elements

* Wait for page load before assertions

* Add tests for file uploads/downloads

* Dont show native notification for completed downloads if dropdown is open

* Increment filenames if file already exists

* Fix antializing in downloads dropdown

* Fix styling of downloads header

* Increase dimensions of green/red icons in downloads

* Fix styling of 3-dot button

* Fix unit tests

* Show 3-dot button only on hover or click

* PR review fixes

* Revert vscode debug fixes

* Mock fs.constants

* Mock fs instead of JsonFileManager in downlaods tests

* Mock fs instead of JsonFileManager in downlaods tests

* Add necessary mocks for downloads manager

* Mark file as deleted if user deleted it

* Fix min-height of downloads dropdown and 3-dot icon position

* Add more tests

* Make size of downloads dropdown dynamic based on content

* Combine log statements

* Close 3-dot menu if user clicks elsewhere

* Move application updates inside downloads dropdown

* Fix update issues

* Fix ipc event payload

* Add missing prop

* Remove unused translations

* Fix failing test

* Fix version unknown

* Remove commented out component
2022-10-07 11:40:27 +03:00
Devin Binnie 7c3b68fb68
[MM-46857] Remove misleading console error about tab status when servers don't exist (#2260) 2022-09-21 08:53:43 -04:00
Julian Mondragón c3493b09ff
MM-45981_Desktop: Add Server Screen: Improve Onboarding screens (#2243) 2022-09-16 10:35:37 -05:00
Devin Binnie 2837b764bd
E2E omnibus fixes (#2249)
* Add environment variable for E2E test server

* Fix auto updater test

* Kill macOS processes after test as well

* No dot

* Just do it for all of them

* Force focus of main window on tests

* Fix a focus issue, try win.show() instead

* Another windows hack

* Oops can't spell

Co-authored-by: Mattermod <mattermod@users.noreply.github.com>
2022-09-12 10:43:19 -04:00
Devin Binnie 86d35669be
[MM-46535] Fix E2E tests for reporting purposes (#2236) 2022-08-25 09:11:23 -04:00
Julian Mondragón faf2dae74b
MM-25003_Improve Onboarding screens for the desktop app - Intro Screen (#2220) 2022-08-16 12:33:03 -05:00
Devin Binnie 821112c038
[MM-45448] Force electron processes to close after every test on Windows (#2207) 2022-07-25 09:41:19 -04:00
Tasos Boulis aa21179f8f
[MM-44931] Allow zoom in/out when Shift is pressed (#2178)
* Add hidden menuitems for zoomIn zoomOut with shift

* Add e2e tests for zoom in/out with shift

* Fix e2e tests

* Add missing async

* Fix lint errors

* Put tests inside describes

* Fix lint errors

* Update e2e/specs/menu_bar/view_menu.test.js

Co-authored-by: Devin Binnie <52460000+devinbinnie@users.noreply.github.com>

* Update e2e/specs/menu_bar/view_menu.test.js

Co-authored-by: Devin Binnie <52460000+devinbinnie@users.noreply.github.com>

Co-authored-by: Devin Binnie <52460000+devinbinnie@users.noreply.github.com>
2022-06-30 14:14:47 -04:00
Devin Binnie 7440a73ca2
Fixes to E2E tests for v5.1.1 (#2169) 2022-06-22 12:43:24 -04:00
Devin Binnie 1c44c8527a
E2E test fixups (#2045)
* Reinstall reporter and re-enable skipped tests

* Fixups for Linux

* Mac fixes

* Windows fixes

* Use keyboard shortcuts instead of menu for most menu actions

* Couple fixes

* One more fix for now

* Windows fixes

* Lint fixes

* Change up developer tools tests to be more consistent

* Fix key for mac

* Couple fixes for flaky tests/to avoid crashes on unload
2022-04-19 09:56:41 -04:00
Devin Binnie ce2ddb6a6a
[MM-31547] Stop users from being able to enter the same server name or URL twice (#2049)
Co-authored-by: Mattermod <mattermod@users.noreply.github.com>
2022-04-19 09:31:04 -04:00
Devin Binnie bce2811dbc
[MM-39796][MM-39872][MM-T1659][MM-T2827] E2E Tests for Popups (#2047)
* [MM-39796] E2E Test: Copy and Paste when connecting plugin

* [MM-39872] E2E Test Prevent browser back/forward from firing in OAuth windows
2022-04-14 09:16:11 -04:00
Devin Binnie fdbb468e7f
[MM-39747][MM-T1315][MM-T1316][MM-T1317] E2E Test: Ensure focus is returned to Mattermost view (#2048) 2022-04-12 13:52:59 -04:00
Devin Binnie 3f614a7c6f
[MM-39794] E2E Test: Drag and Drop (#2044) 2022-04-11 10:16:18 -04:00
Devin Binnie 9b466b67f6
[MM-39793][MM-T2633] E2E Test: Use back button to return to the desktop app login - and fixes (#2043)
* [MM-39793][MM-T2633] E2E Test: Use back button to return to the desktop app login - and fixes

* Lint and test fixes
2022-04-08 15:04:00 -04:00
Devin Binnie dbe48e796c
[MM-39673][MM-T1288] E2E Test: Keyboard Shortcuts in Settings Page (#2041) 2022-04-08 09:56:13 -04:00
Ujjwal Sharma c48628413a
[MM-39661] MM-T827 Select Next/Previous Tab (#1964)
* MM-T827 added

* package.json revert

* robotjs taps induced

* Switched commands to ctrl-tab and ctrl-shift-tab

Co-authored-by: Devin Binnie <devin.binnie@mattermost.com>
2022-04-07 15:25:07 -04:00
Guillermo Vayá d2435a561c
[MM-18552] Autoupdater (#1714)
* wip

* background download

* various fixes

* wip

* wokring autoupgrade

* fix menu

* fix windows

* cleanup

* add publishername

* fix messages and titles

* Test updates

* Moved module and added functionality to click icon to install (instead of just download)

* Add auto update setting, update on close app if downloaded

* Tests, changes for security fixes, update version number

* Update E2E tests

* Lint fix

* Update to latest electron-updater

* Revert to stable electron-builder (only needed to update electron-updater)

* Fix package-lock

* skip flaky test

* Update package

* Fix E2E test

* Fixes for enabling/disabled autoupdater

* Fixed GPO definitions

* [MM-38300] Set localhost as the test server

* blank

* Switch to s3 bucket for testing

* Update icons to match spec

* Add menu items for download/update actions

* Type and test fixes

* Fix notification circle

* Fix macOS app not restarting on Restart/Update

* Update dialog box titles

* Turn off file system check for Linux

* Changes to support deployments

* Testing autoupdater deployments to s3

* disable tests for now

* asfrehwf

* fine no windows WHATEVER

* remove windows again

* Try universal all in one

* pffftttngggguhhhh

* make sure it's working

* Missed artifacts script

* Modify destination as well

* one more time!

* Update yml files

* Oops

* add yq manually

* oof

* Fix the script to work properly

* Fix release script

* Fix script again so it runs in time

* Build version 2

* Revert build specific changes

* Lint override

* Fix build apps for PR builds

* One more change

* Add file generation for .deb repo

* Deb repo test

* skip tests for now

* Fix artifact push

* Persist after repo creation

* Put tests back

* Fix unit tests

* Enable mac generated builds temp

* Temporarily disable tests

* Fix issue where notification doesn't pop dialog box

* Try version 2 again

* Put the version back

* Attempting to debug mac app path issue

* Fix issue where Mac app will quarantine itself after first update

* Lock versions of yq

* Fix yq for mac

* As usual, Mac is difficult :P

* Add quotes to anti-quarantine command

* Change to spawn to avoid command injection

* Oops

* Nightly deployment changes (#2005)

* Test nightly deploy

* I fixed a some things

* aaaaaaaaa

* Restore old bucket

* Added progress indicator via tooltip

* Ship nightly builds to main S3 bucket

* PR feedback

* Fix a couple security exploits

* Fix opacity on light mode button

* Use large app icon

* Resize icon for Windows

* Resize icon for Mac

* Update to electron-updater final

* Remove Mac support and deb repo

* Typo

* Remove deb script

* Remove checksum function

* Removed autoUpdateSettingsPath

* Update URL

Co-authored-by: = <=>
Co-authored-by: Devin Binnie <devin.binnie@mattermost.com>
Co-authored-by: Mattermod <mattermod@users.noreply.github.com>
Co-authored-by: Devin Binnie <52460000+devinbinnie@users.noreply.github.com>
2022-03-08 11:38:38 -05:00
chris-nee 062ca92f31
[MM-T820][MM-T821] Toggle developer Tools in the Menu Bar (#1990)
* test: MM-T820 MMT821 helper functions to be used by tests

* test: MM-T820 keyboard shortcut opens dev tools for Application Wrapper

* test: MM-T820 open dev tools for Application Wrapper through menu, Menu Dropdown > View > Developer Tools for Application Wrapper

* test: MM-T821 open dev tools for Current Server through menu, Menu Dropdown > View > Developer Tools for Current Server

* test: MM-T820 MMT821 scope tests in separate describe block

* test: MM-T820 MMT821 add help functions used for basic interactions with dev tools console

* test: MM-T820 MMT821 add constant setting values used to configure interactions with dev tools console

* test: MM-T820 check if dev tools is pointing to index.html file by sending alert dialogue from dev tool and detecting the dialog event on page, when opening dev tool using keyboard shortcut

* test: MM-T820 check if dev tools is pointing to index.html file by sending alert dialogue from dev tool and detecting the dialog event on page, when opening dev tool using menu

* test: MM-T821 check if dev tools is pointing to current application server by sending alert dialogue from dev tool and detecting the dialog event on page, when opening dev tool using menu

* test: MM-T820 MMT821 increase timeout value of test suite as more time is needed for dev tools to be ready for interaction

* test: MM-T820 MMT821 remove extra whitespace when sending command to dev tools console

* test: MM-T820 MMT821 split check for dev tools open and where dev tools
is pointing to as 2 different parts

test: MM-T820 MMT821 fix lint errors
2022-02-24 09:51:46 -05:00
Goh Yin Hao 88fd18ef02
[MM-T2637] add e2e test for minimize/maximize app when double click header (#1983) 2022-02-23 09:09:37 -05:00
Suneet Srivastava 54a1aefe52
test:MM-T809/MM-T810/MM-T811 Cut/Copy/Paste in the Menu Bar (#1978) 2022-02-08 09:31:13 -05:00
Profesor08 1c71579bbe
#1960 fix unexpected top menu focus (#1963)
* #1960 fix unexpected top menu focus

* #1960 test update

* #1960 improved test

* #1960 optimized algrithm to handle only Alt key to improve performance and avoid side effects

* #1960 tests update

* #1960 fixed 3 dit menu focus on workspace change with Alt+1, Alt+2

* #313 fix linter issue

* #1960 fix linter issue

* tests update
2022-02-08 09:23:51 -05:00
Suneet Srivastava e4394caf97
test:MM-T817/MM-T818/MM-T819 Zooming in the Menu Bar (#1979)
* test:MM-T817/MM-T818/MM-T819 Zooming in the Menu Bar

* test:MM-T818/T819 Zoom in zoom out in the menu bar
2022-02-03 11:04:53 -05:00
Suneet Srivastava 2e8a2b1330
test:MM-T816 Toggle Full Screen in the Menu Bar (#1976) 2022-02-02 16:02:45 -05:00
Suneet Srivastava 6682425587
test:MM-T1308 Check that external links dont open in the app (#1982) 2022-02-02 16:02:17 -05:00
Suneet Srivastava f7e2743b7e
test:MM-T808 Redo in the Menu Bar (#1977) 2022-02-02 12:33:40 -05:00
Rohitesh Gupta 6807019431
test:MM-T824/MM-T825 Minimize/Close in the Menu Bar (#1975)
* Added E2E test for Desktop - Minimize and Close

* Fixed padding blank lines

* Fixed test

* Changed robot keyTap

* Slight rework and fixes for flakiness

* Try sleeping longer

* Added .skip

* Fix linting error caused by merge

Co-authored-by: Devin Binnie <devin.binnie@mattermost.com>
Co-authored-by: Harrison Healey <harrisonmhealey@gmail.com>
2022-01-31 17:34:06 -05:00
Ujjwal Sharma c49aadc563
[MM-40051] MM-T4385 select tab from menu (#1962)
* MM-T4385 select tab from menu

* revert package-lock

* lint errors

* package revert

* test name corrected

* robot js keytap introduced

* package.json rever
2022-01-31 15:04:27 -05:00
Suneet Srivastava aa9e177895
test:MM-T812 Select All in the Menu Bar (#1973) 2022-01-31 12:32:03 -05:00
Md_ZubairAhmed 6702f41143
test: MM-T806 Exit in the Menu Bar (#1980) 2022-01-31 21:09:49 +05:30
Md_ZubairAhmed 5f489e28a0
test : MM-T2465 Linux Dark Mode Toggle (#1981) 2022-01-31 20:29:08 +05:30
Suneet Srivastava 88220bc1fd
test:Preferences in the Menu Bar opens the Settings page (#1959) 2022-01-31 09:20:52 -05:00