Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
G
gitlab-shell
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
0
Merge Requests
0
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-shell
Commits
37148a6c
Commit
37148a6c
authored
Nov 25, 2016
by
Elan Ruusamäe
Committed by
Sean McGivern
Dec 01, 2016
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
test gl_id_test_hook as global and as repo hook separately
parent
24d6df6c
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
24 additions
and
1 deletion
+24
-1
spec/gitlab_custom_hook_spec.rb
spec/gitlab_custom_hook_spec.rb
+24
-1
No files found.
spec/gitlab_custom_hook_spec.rb
View file @
37148a6c
...
...
@@ -81,9 +81,32 @@ describe GitlabCustomHook do
cleanup_hook_setup
end
context
'with gl_id_test_hook'
do
context
'with gl_id_test_hook
as repo hook
'
do
before
do
create_repo_hooks
(
hook_gl_id
)
end
context
'pre_receive hook'
do
it
'passes GL_ID variable to hook'
do
expect
(
gitlab_custom_hook
.
pre_receive
(
changes
)).
to
eq
(
true
)
end
end
context
'post_receive hook'
do
it
'passes GL_ID variable to hook'
do
expect
(
gitlab_custom_hook
.
post_receive
(
changes
)).
to
eq
(
true
)
end
end
context
'update hook'
do
it
'passes GL_ID variable to hook'
do
expect
(
gitlab_custom_hook
.
update
(
ref_name
,
old_value
,
new_value
)).
to
eq
(
true
)
end
end
end
context
'with gl_id_test_hook as global hook'
do
before
do
create_global_hooks_d
(
hook_gl_id
)
end
...
...
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