Rietveld Code Review Tool
Help | Bug tracker | Discussion group | Source code

Unified Diff: tests/test_packagerWebExt.py

Issue 29600577: Issue 5997 - Avoid including qunit files in release builds (Closed)
Patch Set: Avoid bundling tests if testScripts option is missing Created Nov. 7, 2017, 4:04 p.m.
Use n/p to move between diff chunks; N/P to move between comments.
Jump to:
View side-by-side diff with in-line comments
Download patch
« packagerChrome.py ('K') | « templates/testIndex.html.tmpl ('k') | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: tests/test_packagerWebExt.py
diff --git a/tests/test_packagerWebExt.py b/tests/test_packagerWebExt.py
index f13ab10ac164a9055d06340d1d9b02c08339b598..e2da0d8ed64b2046eb7d264e7eb93a8aa479e0d6 100644
--- a/tests/test_packagerWebExt.py
+++ b/tests/test_packagerWebExt.py
@@ -231,12 +231,19 @@ def lib_files(tmpdir):
files['ext/a.js'] = 'require("./c.js");\nvar bar;'
files['lib/b.js'] = 'var foo;'
files['ext/c.js'] = 'var this_is_c;'
+ files['qunit/common.js'] = 'var qunit = {};'
+ files['qunit/tests/some_test.js'] = 'var passed = true;'
tmpdir.mkdir('lib').join('b.js').write(files['lib/b.js'])
ext_dir = tmpdir.mkdir('ext')
ext_dir.join('a.js').write(files['ext/a.js'])
ext_dir.join('c.js').write(files['ext/c.js'])
-
+ qunit_dir = tmpdir.mkdir('qunit')
+ qunit_dir.join('common.js').write(files['qunit/common.js'])
+ qunit_tests_dir = qunit_dir.mkdir('tests')
+ qunit_tests_dir.join('some_test.js').write(
+ files['qunit/tests/some_test.js']
+ )
tlucas 2017/11/08 12:08:51 You are adding these scripts but do not use it in
kzar 2017/11/09 15:33:16 Well they are used since the bundle is created, bu
return files
« packagerChrome.py ('K') | « templates/testIndex.html.tmpl ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld