Merge pull request #7972 from Snuffleupagus/eslint_no-unused-vars

Enable the `no-unused-vars` ESLint rule
This commit is contained in:
Tim van der Meij 2017-02-01 23:50:23 +01:00 committed by GitHub
commit 6f0cf8c4cb
23 changed files with 37 additions and 85 deletions

View file

@ -685,3 +685,5 @@ var Driver = (function DriverClosure() {
return Driver;
})();
exports.Driver = Driver;

View file

@ -88,3 +88,7 @@ function verifyTtxOutput(output) {
throw m[1];
}
}
exports.decodeFontData = decodeFontData;
exports.ttx = ttx;
exports.verifyTtxOutput = verifyTtxOutput;

View file

@ -189,7 +189,7 @@ describe('CFFParser', function() {
it('parses a CharString endchar with 4 args w/seac enabled', function() {
var parser = new CFFParser(fontData, {},
/* seacAnalysisEnabled = */ true);
var cff = parser.parse();
parser.parse(); // cff
var bytes = new Uint8Array([0, 1, // count
1, // offsetSize
@ -211,7 +211,7 @@ describe('CFFParser', function() {
it('parses a CharString endchar with 4 args w/seac disabled', function() {
var parser = new CFFParser(fontData, {},
/* seacAnalysisEnabled = */ false);
var cff = parser.parse();
parser.parse(); // cff
var bytes = new Uint8Array([0, 1, // count
1, // offsetSize

View file

@ -40,8 +40,6 @@
'use strict';
var pdfjsLibs;
function initializePDFJS(callback) {
require.config({paths: {'pdfjs': '../../src', 'pdfjs-web': '../../web',
'pdfjs-test': '..'}});

View file

@ -63,7 +63,7 @@ describe('network', function() {
});
};
var readPromise = read();
var readPromise = Promise.all([read(), promise]);
readPromise.then(function (page) {
expect(len).toEqual(pdf1Length);
@ -117,12 +117,13 @@ describe('network', function() {
});
};
var readPromise = read();
var readPromise = Promise.all([read(), promise]);
readPromise.then(function () {
expect(len).toEqual(pdf2Length);
expect(count).toBeGreaterThan(1);
expect(isStreamingSupported).toEqual(true);
expect(isRangeSupported).toEqual(true);
done();
}).catch(function (reason) {
done.fail(reason);
@ -179,6 +180,7 @@ describe('network', function() {
readPromises.then(function () {
expect(result1.value).toEqual(rangeSize);
expect(result2.value).toEqual(tailSize);
expect(isStreamingSupported).toEqual(false);
expect(isRangeSupported).toEqual(true);
expect(fullReaderCancelled).toEqual(true);
done();

View file

@ -74,3 +74,5 @@ var TestReporter = function(browser, appPath) {
setTimeout(sendQuitRequest, 500);
};
};
exports.TestReporter = TestReporter;