Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
G
gitlab-ce
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Issues
0
Issues
0
List
Boards
Labels
Milestones
Merge Requests
1
Merge Requests
1
Analytics
Analytics
Repository
Value Stream
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Commits
Issue Boards
Open sidebar
nexedi
gitlab-ce
Commits
fd994b66
Commit
fd994b66
authored
Jan 23, 2019
by
Heinrich Lee Yu
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Add factory docs to developing EE features
parent
2d53333c
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
23 additions
and
0 deletions
+23
-0
doc/development/ee_features.md
doc/development/ee_features.md
+23
-0
No files found.
doc/development/ee_features.md
View file @
fd994b66
...
...
@@ -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.
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment