Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
E
edx-platform
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
edx-platform
Commits
e1d3fb73
Commit
e1d3fb73
authored
Jun 04, 2013
by
Will Daly
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Added warning message when no coverage information found.
Added comments to tests.rake
parent
99c185f0
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
17 additions
and
1 deletions
+17
-1
rakefiles/tests.rake
+17
-1
No files found.
rakefiles/tests.rake
View file @
e1d3fb73
...
...
@@ -129,17 +129,33 @@ end
desc
"Build the html, xml, and diff coverage reports"
task
:coverage
=>
:report_dirs
do
found_coverage_info
=
false
TEST_TASK_DIRS
.
each
do
|
dir
|
report_dir
=
report_dir_path
(
dir
)
if
!
File
.
file?
(
"
#{
report_dir
}
/.coverage"
)
next
else
found_coverage_info
=
true
end
# Generate the coverage.py HTML report
sh
(
"coverage html --rcfile=
#{
dir
}
/.coveragerc"
)
# Generate the coverage.py XML report
sh
(
"coverage xml -o
#{
report_dir
}
/coverage.xml --rcfile=
#{
dir
}
/.coveragerc"
)
# Generate the diff coverage HTML report, based on the XML report
sh
(
"diff-cover
#{
report_dir
}
/coverage.xml --html-report
#{
report_dir
}
/diff_cover.html"
)
# Print the diff coverage report to the console
sh
(
"diff-cover
#{
report_dir
}
/coverage.xml"
)
puts
"
\n\n
"
puts
"
\n
"
end
if
not
found_coverage_info
puts
"No coverage info found. Run `rake test` before running `rake coverage`."
end
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