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

Unified Diff: tests/test_packagerWebExt.py

Issue 29825555: Issue 6291 - add ManifoldJS packaging for Edge (Closed) Base URL: https://hg.adblockplus.org/buildtools/file/9a56d76cd951
Patch Set: Created July 11, 2018, 12:05 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
« packagerEdge.py ('K') | « tests/test_packagerEdge.py ('k') | tox.ini » ('j') | 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 f2fd855fd16a57abb39883f289e5cce14885bfd0..cc58f52ac9e7fc3df899d0a87668916851a7b418 100644
--- a/tests/test_packagerWebExt.py
+++ b/tests/test_packagerWebExt.py
@@ -345,13 +345,13 @@ def assert_devenv_scripts(package, prefix, devenv):
assert set(manifest['background']['scripts']) == set(scripts)
-def assert_base_files(package, platform, prefix):
+def assert_base_files(package, platform, prefix, devenv):
filenames = set(package.namelist())
if platform == 'edge':
- assert 'AppxManifest.xml' in filenames
- assert 'AppxBlockMap.xml' in filenames
- assert '[Content_Types].xml' in filenames
+ assert ('AppxManifest.xml' in filenames) is not devenv
+ assert ('AppxBlockMap.xml' in filenames) is not devenv
+ assert ('[Content_Types].xml' in filenames) is not devenv
assert package.read('Assets/logo_44.png') == '44'
assert package.read('Extension/icons/abp-44.png') == '44'
@@ -429,10 +429,12 @@ def test_build_webext(platform, command, keyfile, tmpdir, srcdir, capsys):
manifests = {
'gecko': [('', 'manifest', 'json')],
'chrome': [('', 'manifest', 'json')],
- 'edge': [('', 'AppxManifest', 'xml'),
- ('Extension', 'manifest', 'json')],
+ 'edge': [('Extension', 'manifest', 'json')],
}
+ if not devenv:
+ manifests['edge'].append(('', 'AppxManifest', 'xml'))
+
filenames = {
'gecko': 'adblockplusfirefox-1.2.3{}.xpi',
'chrome': 'adblockpluschrome-1.2.3{{}}.{}'.format(
@@ -474,7 +476,7 @@ def test_build_webext(platform, command, keyfile, tmpdir, srcdir, capsys):
assert_chrome_signature(out_file_path, keyfile)
with content_class(out_file_path) as package:
- assert_base_files(package, platform, prefix)
+ assert_base_files(package, platform, prefix, devenv)
assert_all_locales_present(package, prefix)
assert_webpack_bundle(package, prefix, not release and not devenv,
platform == 'gecko')
« packagerEdge.py ('K') | « tests/test_packagerEdge.py ('k') | tox.ini » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld