Repository navigation
Commit e10d9d6
test(u5): name the interloper's editor and directories instead of an empty slot
The takeover cases proved that a recovery which no longer owns the edit does not roll back
the other target, and they asserted the shape of the provider afterwards through fields that
read as absence: an empty editor slot, an empty directory list. An assertion of absence passes
for the wrong reason - it cannot tell a slot the other edit filled from a slot this recovery
cleared on its way out, and it cannot tell directories that were never this edit's from
directories this edit overwrote with its own.
The interloping edit now installs its own editor and its own created directories, and the
assertions are identity assertions: the editor in the slot is the other edit's editor object,
the directory list is the array the other edit made. The rejection case gets the same
treatment, which is where the directories matter most - putting the captured fields back after
a rejection is the half that used to write over a live edit's state unconditionally.
Verification at this change (node v22.23.4, test-only - no production file changed):
- focused DiffViewProvider spec: 103 passed (103); integrations/editor directory: 2 files,
111 passed (111)
- control with the production file restored byte-for-byte from 23f42de (rejection-path guard
absent): 2 failed | 101 passed - the rejection case and the tab-closing case
- control with it restored from 22969c6 (before the settled-path guard): 4 failed | 99 passed
- the takeover case reports the recovery returning true over the other edit, the cleared-again
case reports an editor installed into a slot that should have stayed empty (expected {…} to be
undefined), and the rejection and tab cases fail as above; the file was written back and
compared equal after each run, no stash used
- eslint --max-warnings=0 on both files: clean; prettier --check: clean1 parent 60f91cd commit e10d9d6
1 file changed
Lines changed: 38 additions & 8 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
2622 | 2622 | | |
2623 | 2623 | | |
2624 | 2624 | | |
| 2625 | + | |
| 2626 | + | |
| 2627 | + | |
| 2628 | + | |
| 2629 | + | |
| 2630 | + | |
| 2631 | + | |
| 2632 | + | |
| 2633 | + | |
| 2634 | + | |
2625 | 2635 | | |
2626 | 2636 | | |
2627 | 2637 | | |
2628 | 2638 | | |
2629 | 2639 | | |
2630 | | - | |
| 2640 | + | |
2631 | 2641 | | |
| 2642 | + | |
2632 | 2643 | | |
2633 | 2644 | | |
2634 | 2645 | | |
| |||
2643 | 2654 | | |
2644 | 2655 | | |
2645 | 2656 | | |
2646 | | - | |
2647 | | - | |
| 2657 | + | |
| 2658 | + | |
| 2659 | + | |
| 2660 | + | |
| 2661 | + | |
2648 | 2662 | | |
2649 | 2663 | | |
2650 | 2664 | | |
2651 | 2665 | | |
2652 | | - | |
| 2666 | + | |
| 2667 | + | |
2653 | 2668 | | |
2654 | 2669 | | |
2655 | 2670 | | |
| |||
2669 | 2684 | | |
2670 | 2685 | | |
2671 | 2686 | | |
| 2687 | + | |
| 2688 | + | |
| 2689 | + | |
| 2690 | + | |
| 2691 | + | |
| 2692 | + | |
| 2693 | + | |
| 2694 | + | |
| 2695 | + | |
| 2696 | + | |
2672 | 2697 | | |
2673 | 2698 | | |
2674 | 2699 | | |
2675 | 2700 | | |
2676 | 2701 | | |
2677 | | - | |
| 2702 | + | |
2678 | 2703 | | |
| 2704 | + | |
2679 | 2705 | | |
2680 | 2706 | | |
2681 | 2707 | | |
| |||
2688 | 2714 | | |
2689 | 2715 | | |
2690 | 2716 | | |
2691 | | - | |
2692 | | - | |
| 2717 | + | |
| 2718 | + | |
| 2719 | + | |
| 2720 | + | |
| 2721 | + | |
2693 | 2722 | | |
2694 | 2723 | | |
2695 | 2724 | | |
2696 | 2725 | | |
2697 | | - | |
| 2726 | + | |
| 2727 | + | |
2698 | 2728 | | |
2699 | 2729 | | |
2700 | 2730 | | |
| |||
0 commit comments