Welcome to mirror list, hosted at ThFree Co, Russian Federation.

gitlab.com/gitlab-org/gitlab-foss.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorMarcel Amirault <ravlen@gmail.com>2019-02-12 15:39:48 +0300
committerAchilleas Pipinellis <axil@gitlab.com>2019-02-12 15:39:48 +0300
commit9d6a8003e07ad621206387c641343e020aeac188 (patch)
tree48ede72825b998a6848531c35747b9744a64932d /doc/development
parent8d7ed982ef361120fef3b431249684333a5462c3 (diff)
Docs: Realign more CE docs that diverged from EE unnecessarily (second MR)
Diffstat (limited to 'doc/development')
-rw-r--r--doc/development/ee_features.md23
-rw-r--r--doc/development/testing_guide/ci.md2
2 files changed, 24 insertions, 1 deletions
diff --git a/doc/development/ee_features.md b/doc/development/ee_features.md
index e0985922443..3e85c0e1995 100644
--- a/doc/development/ee_features.md
+++ b/doc/development/ee_features.md
@@ -831,6 +831,29 @@ should remain working as-is when EE is running without a license.
Instead place EE specs in the `ee/spec` folder.
+### Code in `spec/factories`
+
+Use `FactoryBot.modify` to extend factories already defined in CE.
+
+Note that you cannot define new factories (even nested ones) inside the `FactoryBot.modify` block. You can do so in a
+separate `FactoryBot.define` block as shown in the example below:
+
+```ruby
+# ee/spec/factories/notes.rb
+FactoryBot.modify do
+ factory :note do
+ trait :on_epic do
+ noteable { create(:epic) }
+ project nil
+ end
+ end
+end
+
+FactoryBot.define do
+ factory :note_on_epic, parent: :note, traits: [:on_epic]
+end
+```
+
## JavaScript code in `assets/javascripts/`
To separate EE-specific JS-files we should also move the files into an `ee` folder.
diff --git a/doc/development/testing_guide/ci.md b/doc/development/testing_guide/ci.md
index d685cacf9ea..5aa668290b4 100644
--- a/doc/development/testing_guide/ci.md
+++ b/doc/development/testing_guide/ci.md
@@ -24,7 +24,7 @@ Our current CI parallelization setup is as follows:
uploaded to S3.
After that, the next pipeline will use the up-to-date
-`knapsack/${CI_PROJECT_NAME}/rspec_report-master.json` file.
+`knapsack/${CI_PROJECT_NAME}/rspec_report-master.json` file.
### Monitoring