jesseduffield.lazygit/pkg/integration/components
Jesse Duffield 8c716184c1 Set working directory in lazygit test command
We need to fetch our list of tests both outside of our test binary and within. We need
to get the list from within so that we can run the code that drives the test and runs
assertions. To get the list of tests we need to know where the root of the lazygit repo
is, given that the tests live in files under that root.

So far, we've used this GetLazyRootDirectory() function for that, but it assumes that
we're not in a test directory (it just looks for the first .git dir it can find). Because
we didn't want to properly fix this before, we've been setting the working directory of
the test command to the lazygit root, and using the --path CLI arg to override it when
the test itself ran. This was a terrible hack.

Now, we're passing the lazygit root directory as an env var to the integration test, so
that we can set the working directory to the actual path of the test repo; removing the
need to use the --path arg.
2024-01-12 19:59:31 +11:00
..
alert_driver.go Support matchers on integers in integration tests 2023-06-03 15:32:23 +10:00
assertion_helper.go Remove retry logic in integration tests 2023-07-09 20:57:18 +10:00
commit_description_panel_driver.go Add test demonstrating a bug with preserving the commit message 2024-01-09 14:31:53 +01:00
commit_message_panel_driver.go Remove unused function 2024-01-09 14:31:53 +01:00
common.go Fix the title and text (and variable names) of the Discard Changes prompt 2023-06-26 08:15:35 +02:00
confirmation_driver.go Add demo for amending old commit 2023-08-02 22:32:51 +10:00
file_system.go Support matchers on integers in integration tests 2023-06-03 15:32:23 +10:00
git.go Allow deleting remote tags/branches from local tag/branch views (#2738) 2023-08-10 17:39:26 +10:00
int_matcher.go Add integration tests for searching/filtering 2023-07-03 12:54:14 +10:00
matcher.go Support matchers on integers in integration tests 2023-06-03 15:32:23 +10:00
menu_driver.go Allow deleting remote tags/branches from local tag/branch views (#2738) 2023-08-10 17:39:26 +10:00
paths.go Rename test/results to test/_results 2023-09-15 18:04:20 +02:00
popup.go Split commit message panel into commit summary and commit description panel 2023-04-30 13:19:53 +10:00
prompt_driver.go Support matchers on integers in integration tests 2023-06-03 15:32:23 +10:00
random.go Add commit graph demo 2023-08-12 16:16:03 +10:00
runner.go Set working directory in lazygit test command 2024-01-12 19:59:31 +11:00
search_driver.go Support matchers on integers in integration tests 2023-06-03 15:32:23 +10:00
shell.go Add integration test for remote branch sort order 2023-12-22 16:30:20 +09:00
test.go Set working directory in lazygit test command 2024-01-12 19:59:31 +11:00
test_driver.go Add a Click() primitive to the integration test library 2023-08-07 15:10:28 +01:00
test_test.go Add a Click() primitive to the integration test library 2023-08-07 15:10:28 +01:00
text_matcher.go Add DoesNotContainAnyOf matcher 2023-08-29 08:16:40 +02:00
view_driver.go Add a mechanism to insert non-model items into list contexts 2023-08-29 08:04:47 +02:00
views.go Allow deleting remote tags/branches from local tag/branch views (#2738) 2023-08-10 17:39:26 +10:00