Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

workspace: do not load an invalid workspace file #7922

Merged
merged 1 commit into from
Jun 2, 2020

Conversation

paul-marechal
Copy link
Member

The workspace service will fail to open a workspace when the specified
workspace file is not valid.

How to test

Try to open a workspace with a random file, it should prevent you from doing so.

Review checklist

Reminder for reviewers

@paul-marechal paul-marechal added bug bugs found in the application workspace issues related to the workspace labels May 28, 2020
Copy link
Contributor

@lmcbout lmcbout left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Tested electron, Chrome and Firefox on UBUNTU 18.04
Nice work
Work as expected

The workspace service will fail to open a workspace when the specified
workspace file is not actually one.

This commit prevents Theia from loading invalid workspace files.

Signed-off-by: Paul Maréchal <paul.marechal@ericsson.com>
Co-authored-by: Vincent Fugnitto <vincent.fugnitto@ericsson.com>
@vince-fugnitto
Copy link
Member

@marechal-p I've updated the test cases workspace-service.spec.ts:

  • updated the test-cases involving using workspace files
  • added small test-cases to verify the behavior of the new method isWorkspaceFile()

The CI is now green again 👍

@paul-marechal paul-marechal merged commit d5507de into master Jun 2, 2020
@paul-marechal paul-marechal deleted the mp/workspace-check branch June 2, 2020 14:29
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug bugs found in the application workspace issues related to the workspace
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants