Permalink
Browse files

Revert "remove zip_path check due to false errors (bug 856475)"

This reverts commit 9a77526.
  • Loading branch information...
1 parent 7aa5f1f commit 0a06b37f37e74abce40a82c997262a929015a312 @kmaglione kmaglione committed Jun 4, 2013
Showing with 13 additions and 0 deletions.
  1. +13 −0 validator/testcases/jetpack.py
@@ -174,6 +174,19 @@ def inspect_jetpack(err, xpi_package, allow_old_sdk=False):
uri = uri[11:]
zip_path = "resources/%s" % uri.replace("@", "-at-")
+ # Check the zipname element if it exists.
+ if zip_path not in xpi_package:
+ err.warning(
+ err_id=("testcases_jetpack",
+ "inspect_jetpack",
+ "missing_jetpack_module"),
+ warning="Missing Jetpack module",
+ description=["A Jetpack module listed in harness-options.json "
+ "could not be found in the add-on.",
+ "Path: %s" % zip_path],
+ filename="harness-options.json")
+ continue
+
blob_hash = hashlib.sha256(xpi_package.read(zip_path)).hexdigest()
file_hashes[zip_path] = blob_hash

0 comments on commit 0a06b37

Please sign in to comment.