Add tests for persisting changed branches and committed changes in pipeline editor
This MR !62275 (merged) fixes two bugs by setting the fetch policy when fetching the file content to network-only
(instead of consulting the apollo cache):
- Fixes bug where the branch in the commit form is not updated when user switches between branches
- Fixes bug where committed changes do not persist when user switches between branches
This is a follow-up issue that explores creating tests for the bug fixes. For reference, we've tried approaching this with capybara in this commit, although we haven't found a solution as to why the tests are failing.
It may also be that the answer is we should write E2E tests for it, or that we might not necessarily want to test a fetch policy change as it's an internal behavior that apollo should already have covered (and caching problems are tricky to debug and test in general)
Edited by Mireya Andres