modules/libjar/test/unit/test_bug458158.js

changeset 0
6474c204b198
     1.1 --- /dev/null	Thu Jan 01 00:00:00 1970 +0000
     1.2 +++ b/modules/libjar/test/unit/test_bug458158.js	Wed Dec 31 06:09:35 2014 +0100
     1.3 @@ -0,0 +1,11 @@
     1.4 +function run_test() {
     1.5 +  var zReader = Components.classes["@mozilla.org/libjar/zip-reader;1"]
     1.6 +                        .createInstance(Components.interfaces.nsIZipReader);
     1.7 +  try {
     1.8 +    zReader.open(null);
     1.9 +    do_throw("Shouldn't get here!");
    1.10 +  } catch (e if (e instanceof Components.interfaces.nsIException &&
    1.11 +                 e.result == Components.results.NS_ERROR_NULL_POINTER)) {
    1.12 +    // do nothing, this test passes
    1.13 +  }
    1.14 +}

mercurial