Move coverage report html into the reports directory
This commit is contained in:
@@ -20,7 +20,7 @@ INSTALLED_APPS = [
|
||||
|
||||
# Nose Test Runner
|
||||
INSTALLED_APPS += ['django_nose']
|
||||
NOSE_ARGS = ['--cover-erase', '--with-xunit', '--with-xcoverage', '--cover-html', '--cover-inclusive']
|
||||
NOSE_ARGS = ['--cover-erase', '--with-xunit', '--with-xcoverage', '--cover-html', '--cover-inclusive', '--cover-html-dir', os.environ['NOSE_COVER_HTML_DIR']]
|
||||
for app in os.listdir(PROJECT_ROOT / 'djangoapps'):
|
||||
NOSE_ARGS += ['--cover-package', app]
|
||||
TEST_RUNNER = 'django_nose.NoseTestSuiteRunner'
|
||||
|
||||
3
rakefile
3
rakefile
@@ -66,6 +66,7 @@ end
|
||||
desc "Run all django tests on our djangoapps for the #{system}"
|
||||
task task_name => report_dir do
|
||||
ENV['NOSE_XUNIT_FILE'] = File.join(report_dir, "nosetests.xml")
|
||||
ENV['NOSE_COVER_HTML_DIR'] = File.join(report_dir, "cover")
|
||||
sh(django_admin(:lms, :test, 'test', *Dir['lms/djangoapps'].each))
|
||||
end
|
||||
task :test => task_name
|
||||
@@ -80,7 +81,7 @@ Dir["common/lib/*"].each do |lib|
|
||||
desc "Run tests for common lib #{lib}"
|
||||
task task_name => report_dir do
|
||||
ENV['NOSE_XUNIT_FILE'] = File.join(report_dir, "nosetests.xml")
|
||||
sh("nosetests #{lib} --cover-erase --with-xunit --with-xcoverage --cover-html --cover-inclusive --cover-package #{File.basename(lib)}")
|
||||
sh("nosetests #{lib} --cover-erase --with-xunit --with-xcoverage --cover-html --cover-inclusive --cover-package #{File.basename(lib)} --cover-html-dir #{File.join(report_dir, "cover")}")
|
||||
end
|
||||
task :test => task_name
|
||||
end
|
||||
|
||||
Reference in New Issue
Block a user