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
07eff5ff
Commit
07eff5ff
authored
Jul 16, 2012
by
Rocky Duan
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
fixed Rakefile
parent
5f4bd140
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
6 additions
and
6 deletions
+6
-6
Rakefile
+6
-6
No files found.
Rakefile
View file @
07eff5ff
...
@@ -20,7 +20,7 @@ task :environment do
...
@@ -20,7 +20,7 @@ task :environment do
end
end
namespace
:test
do
namespace
:test
do
task
:
check_
nested_comments
=>
:environment
do
task
:nested_comments
=>
:environment
do
puts
"checking"
puts
"checking"
50
.
times
do
50
.
times
do
Comment
.
delete_all
Comment
.
delete_all
...
@@ -31,19 +31,19 @@ namespace :test do
...
@@ -31,19 +31,19 @@ namespace :test do
commentable
=
Commentable
.
create!
(
commentable_type:
"questions"
,
commentable_id:
"1"
)
commentable
=
Commentable
.
create!
(
commentable_type:
"questions"
,
commentable_id:
"1"
)
user
=
User
.
create!
(
id:
"1"
)
user
=
User
.
create!
(
external_
id:
"1"
)
comment_thread
=
commentable
.
comment_threads
.
create!
(
title:
"I can't solve this problem"
,
body:
"can anyone help me?"
,
course_id:
"1"
)
comment_thread
=
commentable
.
comment_threads
.
new
(
title:
"I can't solve this problem"
,
body:
"can anyone help me?"
,
course_id:
"1"
)
comment_thread
.
author
=
user
comment_thread
.
author
=
user
comment_thread
.
save!
comment_thread
.
save!
comment
=
comment_thread
.
comments
.
create!
(
body:
"this problem is so easy"
,
course_id:
"1"
)
comment
=
comment_thread
.
comments
.
new
(
body:
"this problem is so easy"
,
course_id:
"1"
)
comment
.
author
=
user
comment
.
author
=
user
comment
.
save!
comment
.
save!
comment1
=
comment
.
children
.
create!
(
body:
"not for me!"
,
course_id:
"1"
)
comment1
=
comment
.
children
.
new
(
body:
"not for me!"
,
course_id:
"1"
)
comment1
.
author
=
user
comment1
.
author
=
user
comment1
.
save!
comment1
.
save!
comment2
=
comment1
.
children
.
create!
(
body:
"not for me neither!"
,
course_id:
"1"
)
comment2
=
comment1
.
children
.
new
(
body:
"not for me neither!"
,
course_id:
"1"
)
comment2
.
author
=
user
comment2
.
author
=
user
comment2
.
save!
comment2
.
save!
...
...
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