- 17 Jan, 2022 40 commits
-
-
Toon Claes authored
The workhorse integration tests for Gitaly need to have a Gitaly process running. It uses scripts/setup-test-env to build Gitaly, but it used a home-grown solution to start the process. This change switches to the "standard way" of starting Gitaly in test for workhorse, so it has the same environment variables when set up and started. This has an added benefit as now the Gitaly socket is tested before the workhorse tests start.
-
Toon Claes authored
Prior to this change, when Gitaly was spawned in test, it was twice checked whether the UNIX socket is open: - In GitalySetup#start it uses #try_connect! to test the socket. - In GitalySetup#spawn_gitaly it again called #wait to test the socket again. This change removes #wait and the use of it.
-
Toon Claes authored
During test, and test setup, BUNDLE_PATH is set by GitalySetup. It should do The Right Thing(TM), but in case it doesn't you can set GITALY_TEST_BUNDLE_PATH to override the value.
-
Toon Claes authored
GitalySetup was shelling out to scripts/gitaly-test-spawn to spawn Gitaly processes, which was quite complicated to understand. This change simplifies the back-and-forth between the script and the Ruby file. It avoids writing the PID of the Gitaly processes to file, to pass them back to the test environment. With the previous changes included, now scripts/gitaly-test-build & scripts/gitaly-test-spawn are *only* used in CI. When running tests in a local GDK, the Ruby code to build and spawn Gitaly in test is directly called from TestEnv.init.
-
Toon Claes authored
To make it easier to maintain the code that sets up Gitaly, move all the code together in GitalySetup.
-
Toon Claes authored
To have better control on how `make` is ran to build Gitaly, run it from the GitalySetup helper module.
-
Toon Claes authored
Kernel#system by default returns false when the command fails. Before this change the return value was not looked at. With this change we pass `exception: true` to system() so it raises an exception on failure.
-
Toon Claes authored
In the next commit we want to use GitalySetup.build_gitaly for local testing. Prior to this change, HOME is set when calling `make`. But this might break when Golang is installed through `asdf`. This change moves setting HOME to where Gitaly is spawned only. We add a little comment to explain this is done to make sure Git is not affected by user configuration.
-
Toon Claes authored
In 08af0f9f (Speed up gitaly setup in tests, 2021-07-20) the setup of Gitaly was sped up in test by copying it over from GDK whenever possible. This drastically reduced the setup time, but it complicates installations of Ruby gems in Gitaly. This change rolls back that copy-from-GDK installation, but instead incrementally installs Gitaly. So instead of removing tmp/tests/gitaly completely and setting up from scratch, we now fetch the revision specified in GITALY_SERVER_VERSION and trust `make` inside the Gitaly directory to The Right Thing(tm). Combined with the introduction of gitlab-development-kit@d2229da0 (Makefile: Stop nuking gitlab/tmp/tests/gitaly, 2021-12-06) this should avoid Gitaly in test ever again would be built from scratch. In case this would not work in some situations, we look at FORCE_GITALY_INSTALL and if the environment variable is set tmp/tests/gitaly is deleted before installing Gitaly again.
-
Toon Claes authored
In previous commit we started setting BUNDLE_PATH as an environment variable, and this works great. But this value gets overridden in case it's specified in the local config. You can see so by using the `bundle config` command: $ BUNDLE_PATH=vendor/bundle bundle config path Settings for `path` in order of priority. The top value will be used Set for your local app (/home/r/gdk/gitlab/.bundle/config): "vendor/bundle" Set via BUNDLE_PATH: "vendor/bundle" Set for the current user (/home/r/.config/bundle): "vendor/bundle" This isn't persay an issue, but in most cases this is set as a relative path. Because different `bundle` commands might get triggered from different directory levels in the project tree, this might become an issue. To overcome this, the active value of BUNDLE_PATH is read, expanded to an absolute path and passed back to the environment. But because of the prioritization demonstrated above, we need to set BUNDLE_IGNORE_CONFIG so any local, user, or system configuration is ignored.
-
Toon Claes authored
Setting up and spawning Gitaly in tests needs to have some Bundler settings configured. Until now this was done by writing to the local config file in the ruby directory inside the gitaly dir used in test. This method didn't seem to be robust for all our user and use-cases (i.e. CI), because this configuration _could_ be done from different places. To make the situation more predictable, this change injects all Bundler configuration through environment variables instead.
-
Andrejs Cunskis authored
Collect test resources and write to file See merge request gitlab-org/gitlab!77431
-
Tiffany Rea authored
Add rake task for delete test resource task Update Resouce::Base to collect resource after creation Add new ENV var for JSON file path Add new tool to delete test resources Add new tool to collect test resources Update spec helper to write resource collection to file at end of suite
-
Markus Koller authored
Extract agent token usage tracking logic into service See merge request gitlab-org/gitlab!78151
-
Tiger Watson authored
-
Fabio Pitino authored
Fix the order of subsequent jobs when requeuing a job See merge request gitlab-org/gitlab!77528
-
Kushal Pandya authored
Revert "Merge branch 'rajat/work-hierarchy' into 'master'" See merge request gitlab-org/gitlab!78395
-
Brandon Labuschagne authored
Ensure highlight.js matches the GitLab white theme See merge request gitlab-org/gitlab!76725
-
Andrew Fontaine authored
Clean up VSA base template conditions See merge request gitlab-org/gitlab!78189
-
Rémy Coutable authored
Improve Gitaly test setup error message See merge request gitlab-org/gitlab!78311
-
Stan Hu authored
If Gitaly can't be spawned, print a more informative error explaining possible reasons why. This commit will inform the user whether Gitaly or Git binaries are missing.
-
Markus Koller authored
Fix Rails/SaveBang offenses See merge request gitlab-org/gitlab!75976
-
Markus Koller authored
Fix Gitlab/DelegatePredicateMethods offenses See merge request gitlab-org/gitlab!76010
-
Robert May authored
Improve performance of search global service spec See merge request gitlab-org/gitlab!78377
-
Phil Hughes authored
Remove wait_using_real_timer helper See merge request gitlab-org/gitlab!78332
-
Fabio Pitino authored
Destroy trace chunks and data when deleting pipelines See merge request gitlab-org/gitlab!78116
-
Rajat Jain authored
This reverts commit 4f1e3e52, reversing changes made to 78a09154. Changelog: removed
-
Nikola Milojevic authored
Reintroduce adding timestamp to GitLab Standard Context See merge request gitlab-org/gitlab!78067
-
Suzanne Selhorn authored
Add docs for Group (SaaS) User Caps See merge request gitlab-org/gitlab!77567
-
Sheldon Led authored
We have a standard way to write procedures, so attempted to match that standard. Also, added text to the titles so they'll be easier to find via search
-
Jacques Erasmus authored
Blob refactor: Fix sourcegraph integration See merge request gitlab-org/gitlab!78053
-
Marius Bobin authored
Changelog: fixed
-
Enrique Alcántara authored
Refactor group security discover data attributes See merge request gitlab-org/gitlab!77781
-
Ezekiel Kigbo authored
Migrate legacy icon badge usage See merge request gitlab-org/gitlab!78308
-
Rémy Coutable authored
Update bundler to 2.3.5 because 2.1.4 is too old See merge request gitlab-org/gitlab!78298
-
Vitali Tatarintev authored
Enable the `GraphQL/ArgumentName` cop See merge request gitlab-org/gitlab!76013
-
Brandon Labuschagne authored
Expose internal_url setting for Geo secondaries See merge request gitlab-org/gitlab!77179
-
Marcia Ramos authored
Change tense of text to comply with style guidelines See merge request gitlab-org/gitlab!77834
-
VIREN VARIYA authored
-
Piotr Skorupa authored
This reverts commit 8b49d615.
-