Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
C
cs_comments_service
Overview
Overview
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
edx
cs_comments_service
Commits
c2265050
Commit
c2265050
authored
Aug 07, 2013
by
Kevin Chugh
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
add sleep to prevent tests artificially failing
parent
1f59831e
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
7 additions
and
0 deletions
+7
-0
spec/api/notifications_spec.rb
+7
-0
No files found.
spec/api/notifications_spec.rb
View file @
c2265050
...
...
@@ -48,6 +48,8 @@ describe "app" do
start_time
=
Date
.
today
-
400
.
days
end_time
=
Time
.
now
sleep
1
post
"/api/v1/notifications"
,
from:
CGI
::
escape
(
start_time
.
to_s
),
to:
CGI
::
escape
(
end_time
.
to_s
),
user_ids:
user
.
id
last_response
.
should
be_ok
payload
=
JSON
.
parse
last_response
.
body
...
...
@@ -70,6 +72,9 @@ describe "app" do
start_time
=
Date
.
today
-
400
.
days
end_time
=
Time
.
now
user
=
User
.
find
Subscription
.
first
.
subscriber_id
sleep
1
post
"/api/v1/notifications"
,
from:
CGI
::
escape
(
start_time
.
to_s
),
to:
CGI
::
escape
(
end_time
.
to_s
),
user_ids:
user
.
id
last_response
.
should
be_ok
payload
=
JSON
.
parse
last_response
.
body
...
...
@@ -84,6 +89,8 @@ describe "app" do
thread
=
CommentThread
.
find
thread_ids
.
first
thread
.
historical_abuse_flaggers
<<
[
"1"
]
sleep
1
post
"/api/v1/notifications"
,
from:
CGI
::
escape
(
start_time
.
to_s
),
to:
CGI
::
escape
(
end_time
.
to_s
),
user_ids:
user
.
id
last_response
.
should
be_ok
payload
=
JSON
.
parse
last_response
.
body
...
...
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