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
d7f1b3dd
Commit
d7f1b3dd
authored
Oct 05, 2018
by
Jeremy Watson
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Updated existing spec for new 2 year timeframe
parent
8f6a1f14
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
3 additions
and
3 deletions
+3
-3
spec/workers/prune_old_events_worker_spec.rb
spec/workers/prune_old_events_worker_spec.rb
+3
-3
No files found.
spec/workers/prune_old_events_worker_spec.rb
View file @
d7f1b3dd
...
...
@@ -4,11 +4,11 @@ describe PruneOldEventsWorker do
describe
'#perform'
do
let
(
:user
)
{
create
(
:user
)
}
let!
(
:expired_event
)
{
create
(
:event
,
:closed
,
author:
user
,
created_at:
13
.
months
.
ago
)
}
let!
(
:expired_event
)
{
create
(
:event
,
:closed
,
author:
user
,
created_at:
25
.
months
.
ago
)
}
let!
(
:not_expired_event
)
{
create
(
:event
,
:closed
,
author:
user
,
created_at:
1
.
day
.
ago
)
}
let!
(
:exactly_
12_months_event
)
{
create
(
:event
,
:closed
,
author:
user
,
created_at:
12
.
month
s
.
ago
)
}
let!
(
:exactly_
2_years_event
)
{
create
(
:event
,
:closed
,
author:
user
,
created_at:
2
.
year
s
.
ago
)
}
it
'prunes events older than
12 month
s'
do
it
'prunes events older than
2 year
s'
do
expect
{
subject
.
perform
}.
to
change
{
Event
.
count
}.
by
(
-
1
)
expect
(
Event
.
find_by
(
id:
expired_event
.
id
)).
to
be_nil
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