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

Ability to re-load a file from remote #8

Merged
merged 3 commits into from
Jul 7, 2020
Merged

Ability to re-load a file from remote #8

merged 3 commits into from
Jul 7, 2020

Conversation

bhakta0007
Copy link
Contributor

This pull request adds an option called "Reload From Remote" to the file context menu.
If the buffer is open, it will be closed (appropriate warning displayed if there are local changes).
Once close, the file will be opened again

Test-cases:

Test-case-1: Open remote tree view (but file is not yet opened), right click on file and "Reload From Remote"
Expected outcome: Since file is not open, nothing happens (i.e this will not result in opening the file)
Result: Pass

Test-case-2a: Open a remote file, then, without making any local change - do "Reload From Remote"
Expected outcome: File should reload
Result: Pass

Test-case-2b: Open a remote file, then make a change on remote. Don't make any local change - do "Reload From Remote"
Expected outcome: File should reload and the remote changed content should be visible
Result: Pass

Test-case-4a: Open a remote file, Make a local change - do "Reload From Remote". A dialog box will appear indicating that "you will lose your local changes if you reload from remote". Press No
Expected outcome: Nothing happens, the file is not reloaded the local buffer remains
Result: Pass

Test-case-4b: Open a remote file, Make a local change - do "Reload From Remote". A dialog box will appear indicating that "you will lose your local changes if you reload from remote". Press Yes
Expected outcome: Local buffer is closed (lost) and remote content is loaded.
Result: Pass

This pull request adds an option called "Reload From Remote" to the file context menu.
If the buffer is open, it will be closed (appropriate warning displayed if there are local changes).
Once close, the file will be opened again

Test-cases:

Test-case-1: Open remote tree view (but file is not yet opened), right click on file and "Reload From Remote"
Expected outcome: Since file is not open, nothing happens (i.e this will not result in opening the file)
Result: Pass

Test-case-2a: Open a remote file, then, without making any local change - do "Reload From Remote"
Expected outcome: File should reload
Result: Pass

Test-case-2b: Open a remote file, then make a change on remote. Don't make any local change - do "Reload From Remote"
Expected outcome: File should reload and the remote changed content should be visible
Result: Pass

Test-case-4a: Open a remote file, Make a local change - do "Reload From Remote". A dialog box will appear indicating that "you will lose your local changes if you reload from remote". Press No
Expected outcome: Nothing happens, the file is not reloaded the local buffer remains
Result: Pass

Test-case-4b: Open a remote file, Make a local change - do "Reload From Remote". A dialog box will appear indicating that "you will lose your local changes if you reload from remote". Press Yes
Expected outcome: Local buffer is closed (lost) and remote content is loaded.
Result: Pass
@vukbgit vukbgit merged commit 1620856 into vukbgit:master Jul 7, 2020
@bhakta0007 bhakta0007 deleted the reload-from-remote branch July 9, 2020 06:38
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants