This repository was archived by the owner on Apr 1, 2020. It is now read-only.
-
Notifications
You must be signed in to change notification settings - Fork 299
Explorer: Locate Current Buffer (II) #2456
Closed
feltech
wants to merge
15
commits into
onivim:master
from
feltech:feature/locate_current_buffer_in_explorer
Closed
Explorer: Locate Current Buffer (II) #2456
feltech
wants to merge
15
commits into
onivim:master
from
feltech:feature/locate_current_buffer_in_explorer
Conversation
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Add command palette option "Explorer: Locate Current Buffer" that will expand directories down to the current buffer, then select the corresponding file/directory.
Prevent sending pointless `SELECT_FILE_SUCCESS` actions if we're not actually in the process of selecting a file (or haven't selected the file we expect yet).
* Keep `registerCommand` calls together in the `index.tsx` and unify their style. * Use the `SidebarManager` to first ensure the Explorer is shown, before then locating the file in the `ExplorerSplit`.
* Strangely, `SidebarManager.setActiveEntry` will close the sidebar if the Explorer is already open and you try to open it again. * So only trigger opening the Explorer if it's not already visible.
* `epicMiddleware.replaceEpic` internally dispatches a `@@redux-observable/EPIC_END` action, which gets saved to the `mockStore`'s actions list. Every test case's `afterEach` thus adds an additional action to this actions list. This pollutes all subsequent stores created via the `mockStore` factory, which is odd. * This was accounted for in the YANK_AND_PASTE_EPICS test by assuming "an init action is sent first", which is not the case. * So move the setup that is only for the SET_ROOT_DIRECTORY test inside it's own `describe` block, remove the unnecessary `replaceEpic` call, and fix the test for expected number of actions.
locate_buffer_in_explorer # Conflicts: # browser/test/Services/Explorer/ExplorerStoreTests.ts
# Conflicts: # browser/src/Services/Explorer/index.tsx
Contributor
Author
|
I hope that by merging in master I haven't ended up in the same back and forth with flaky integration tests. |
Codecov Report
@@ Coverage Diff @@
## master #2456 +/- ##
==========================================
+ Coverage 43.27% 43.69% +0.42%
==========================================
Files 341 341
Lines 13425 13461 +36
Branches 1765 1771 +6
==========================================
+ Hits 5809 5882 +73
+ Misses 7340 7321 -19
+ Partials 276 258 -18
Continue to review full report at Codecov.
|
Contributor
Author
|
Closing this as the more advanced PR #2429 is now passing. |
Sign up for free
to subscribe to this conversation on GitHub.
Already have an account?
Sign in.
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Add "Explorer: Locate Current Buffer" command palette item.
Split from #2429 at the last point that CI tests were passing, plus a merge of master.
This means there is a missing fix for symlinked files that are detected as outside the workspace when they're actually within it, as well as a few missing additional tests.