diff options
author | GitLab Bot <gitlab-bot@gitlab.com> | 2019-10-02 00:06:26 +0000 |
---|---|---|
committer | GitLab Bot <gitlab-bot@gitlab.com> | 2019-10-02 00:06:26 +0000 |
commit | 587794b4b8a6e919e77ee4abe8215fa291e6a91d (patch) | |
tree | 380d6578d1ab5902bb521071128bafd4f70472ef /doc | |
parent | e0bd3a45d9dc6c74cac1a33ea8c03d6d8334249b (diff) | |
download | gitlab-ce-587794b4b8a6e919e77ee4abe8215fa291e6a91d.tar.gz |
Add latest changes from gitlab-org/gitlab@master
Diffstat (limited to 'doc')
-rw-r--r-- | doc/ci/enable_or_disable_ci.md | 20 | ||||
-rw-r--r-- | doc/development/testing_guide/best_practices.md | 28 | ||||
-rw-r--r-- | doc/user/project/merge_requests/merge_when_pipeline_succeeds.md | 16 | ||||
-rw-r--r-- | doc/user/project/settings/img/sharing_and_permissions_settings.png | bin | 46275 -> 0 bytes | |||
-rw-r--r-- | doc/user/project/settings/img/sharing_and_permissions_settings_v12_3.png | bin | 0 -> 479637 bytes | |||
-rw-r--r-- | doc/user/project/settings/index.md | 2 |
6 files changed, 56 insertions, 10 deletions
diff --git a/doc/ci/enable_or_disable_ci.md b/doc/ci/enable_or_disable_ci.md index 56200142055..dcf4d8dde2d 100644 --- a/doc/ci/enable_or_disable_ci.md +++ b/doc/ci/enable_or_disable_ci.md @@ -28,18 +28,28 @@ either: - Site-wide by modifying the settings in `gitlab.yml` and `gitlab.rb` for source and Omnibus installations respectively. +NOTE: **Note:** +This only applies to pipelines run as part of GitLab CI/CD. This will not enable or disable +pipelines that are run from an [external integration](../user/project/integrations/project_services.md#services). + ## Per-project user setting -The setting to enable or disable GitLab CI/CD can be found under your project's -**Settings > General > Permissions**. Choose one of "Disabled", "Only team members" -or "Everyone with access" and hit **Save changes** for the settings to take effect. +The setting to enable or disable GitLab CI/CD Pipelines can be found in your project in +**Settings > General > Visibility, project features, permissions**. If the project +visibility is set to: + +- **Private**, only project members can access pipelines. +- **Internal** or **Public**, pipelines can be made accessible to either + project members only or everyone with access. + +Press **Save changes** for the settings to take effect. -![Sharing & Permissions settings](../user/project/settings/img/sharing_and_permissions_settings.png) +![Sharing & Permissions settings](../user/project/settings/img/sharing_and_permissions_settings_v12_3.png) ## Site-wide admin setting You can disable GitLab CI/CD site-wide, by modifying the settings in `gitlab.yml` -and `gitlab.rb` for source and Omnibus installations respectively. +for source installations, and `gitlab.rb` for Omnibus installations. Two things to note: diff --git a/doc/development/testing_guide/best_practices.md b/doc/development/testing_guide/best_practices.md index 223ebdc6ee4..01db92b09c9 100644 --- a/doc/development/testing_guide/best_practices.md +++ b/doc/development/testing_guide/best_practices.md @@ -202,8 +202,36 @@ so we need to set some guidelines for their use going forward: order is required, otherwise `let` will suffice. Remember that `let` is lazy and won't be evaluated until it is referenced. +### `let_it_be` variables + +In some cases there is no need to recreate the same object for tests +again for each example. For example, a project is needed to test issues +on the same project, one project will do for the entire file. This can +be achieved by using +[`let_it_be`](https://test-prof.evilmartians.io/#/let_it_be) variables +from the [`test-prof` gem](https://rubygems.org/gems/test-prof). + +Note that if you modify an object defined inside a `let_it_be` block, +then you will need to reload the object as needed, or specify the `reload` +option to reload for every example. + +``` +let_it_be(:project, reload: true) { create(:project) } +``` + +You can also specify the `refind` option as well to completely load a +new object. + +``` +let_it_be(:project, refind: true) { create(:project) } +``` + ### `set` variables +NOTE: **Note:** +We are incrementally removing `set` in favour of `let_it_be`. See the +[removal issue](https://gitlab.com/gitlab-org/gitlab/issues/27922). + In some cases there is no need to recreate the same object for tests again for each example. For example, a project is needed to test issues on the same project, one project will do for the entire file. This can be achieved by using diff --git a/doc/user/project/merge_requests/merge_when_pipeline_succeeds.md b/doc/user/project/merge_requests/merge_when_pipeline_succeeds.md index b717cb0ec24..dab2184448a 100644 --- a/doc/user/project/merge_requests/merge_when_pipeline_succeeds.md +++ b/doc/user/project/merge_requests/merge_when_pipeline_succeeds.md @@ -36,11 +36,19 @@ changes to be reviewed. ## Only allow merge requests to be merged if the pipeline succeeds You can prevent merge requests from being merged if their pipeline did not succeed -or if there are threads to be resolved. +or if there are threads to be resolved. This works for both: -Navigate to your project's settings page and expand the **Merge requests** section. -In the **Merge checks** subsection, select the **Pipelines must succeed** check -box and hit **Save** for the changes to take effect. +- GitLab CI/CD pipelines +- Pipelines run from an [external CI integration](../integrations/project_services.md#services) + +As a result, [disabling GitLab CI/CD pipelines](../../../ci/enable_or_disable_ci.md) +will not disable this feature, as it will still be possible to use pipelines from external +CI providers with this feature. To enable it, you must: + +1. Navigate to your project's **Settings > General** page. +1. Expand the **Merge requests** section. +1. In the **Merge checks** subsection, select the **Pipelines must succeed** checkbox. +1. Press **Save** for the changes to take effect. NOTE: **Note:** This setting also prevents merge requests from being merged if there is no pipeline. diff --git a/doc/user/project/settings/img/sharing_and_permissions_settings.png b/doc/user/project/settings/img/sharing_and_permissions_settings.png Binary files differdeleted file mode 100644 index 6cb89c6ea1d..00000000000 --- a/doc/user/project/settings/img/sharing_and_permissions_settings.png +++ /dev/null diff --git a/doc/user/project/settings/img/sharing_and_permissions_settings_v12_3.png b/doc/user/project/settings/img/sharing_and_permissions_settings_v12_3.png Binary files differnew file mode 100644 index 00000000000..cf7fdfe4cce --- /dev/null +++ b/doc/user/project/settings/img/sharing_and_permissions_settings_v12_3.png diff --git a/doc/user/project/settings/index.md b/doc/user/project/settings/index.md index 66a861faf93..131999dbf60 100644 --- a/doc/user/project/settings/index.md +++ b/doc/user/project/settings/index.md @@ -24,7 +24,7 @@ The project description also partially supports [standard markdown](../../markdo Set up your project's access, [visibility](../../../public_access/public_access.md), and enable [Container Registry](../../packages/container_registry/index.md) for your projects: -![projects sharing permissions](img/sharing_and_permissions_settings.png) +![projects sharing permissions](img/sharing_and_permissions_settings_v12_3.png) If Issues are disabled, or you can't access Issues because you're not a project member, then Labels and Milestones links will be missing from the sidebar UI. |