fune/tools/code-coverage/tests/test_basic.js
Marco Castelluccio d6b5f01351 Bug 1380659 - Add basic xpcshell test for the code coverage component. r=erahm
--HG--
extra : rebase_source : 245fa834b7b2a8d4c3f61871e93f5bdfd3d0cf72
2017-07-14 10:59:12 +02:00

17 lines
547 B
JavaScript

/* This Source Code Form is subject to the terms of the Mozilla Public
* License, v. 2.0. If a copy of the MPL was not distributed with this
* file, You can obtain one at http://mozilla.org/MPL/2.0/. */
function run_test() {
Assert.ok("@mozilla.org/tools/code-coverage;1" in Cc);
let codeCoverageCc = Cc["@mozilla.org/tools/code-coverage;1"];
Assert.ok(!!codeCoverageCc);
let codeCoverage = codeCoverageCc.getService(Ci.nsICodeCoverage);
Assert.ok(!!codeCoverage);
codeCoverage.dumpCounters();
codeCoverage.resetCounters();
}