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
8fb5da12
Commit
8fb5da12
authored
Jul 26, 2017
by
Douglas Barbosa Alexandre
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Remove unncessary stub for Gitlab::Geo.current_node method
parent
a395d194
Changes
2
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
2 additions
and
5 deletions
+2
-5
spec/lib/gitlab/geo/log_cursor/daemon_spec.rb
spec/lib/gitlab/geo/log_cursor/daemon_spec.rb
+2
-4
spec/workers/geo/repository_sync_worker_spec.rb
spec/workers/geo/repository_sync_worker_spec.rb
+0
-1
No files found.
spec/lib/gitlab/geo/log_cursor/daemon_spec.rb
View file @
8fb5da12
...
...
@@ -22,13 +22,12 @@ describe Gitlab::Geo::LogCursor::Daemon do
end
context
'when replaying a repository updated event'
do
let!
(
:geo_node
)
{
create
(
:geo_node
)
}
let!
(
:geo_node
)
{
create
(
:geo_node
,
:current
)
}
let
(
:event_log
)
{
create
(
:geo_event_log
,
:updated_event
)
}
let!
(
:event_log_state
)
{
create
(
:geo_event_log_state
,
event_id:
event_log
.
id
-
1
)
}
let
(
:repository_updated_event
)
{
event_log
.
repository_updated_event
}
before
do
allow
(
Gitlab
::
Geo
).
to
receive
(
:current_node
).
and_return
(
geo_node
)
allow
(
subject
).
to
receive
(
:exit?
).
and_return
(
false
,
true
)
end
...
...
@@ -83,7 +82,7 @@ describe Gitlab::Geo::LogCursor::Daemon do
end
context
'when node have group restrictions'
do
let
(
:geo_node
)
{
create
(
:geo_node
)
}
let
(
:geo_node
)
{
create
(
:geo_node
,
:current
)
}
let
(
:group
)
{
create
(
:group
)
}
let
(
:project
)
{
create
(
:empty_project
,
group:
group
)
}
let
(
:repository_updated_event
)
{
create
(
:geo_repository_updated_event
,
project:
project
)
}
...
...
@@ -91,7 +90,6 @@ describe Gitlab::Geo::LogCursor::Daemon do
let!
(
:event_log_state
)
{
create
(
:geo_event_log_state
,
event_id:
event_log
.
id
-
1
)
}
before
do
allow
(
Gitlab
::
Geo
).
to
receive
(
:current_node
).
and_return
(
geo_node
)
allow
(
subject
).
to
receive
(
:exit?
).
and_return
(
false
,
true
)
end
...
...
spec/workers/geo/repository_sync_worker_spec.rb
View file @
8fb5da12
...
...
@@ -66,7 +66,6 @@ describe Geo::RepositorySyncWorker do
context
'when node have group restrictions'
do
before
do
allow
(
Gitlab
::
Geo
).
to
receive
(
:current_node
).
and_return
(
secondary
)
secondary
.
update_attribute
(
:groups
,
[
group
])
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