apache / cordova-js

Compare af904b7 ... +0 ... d83f8d8

No flags found

Use flags to group coverage reports by test type, project and/or folders.
Then setup custom commit statuses and notifications for each flag.

e.g., #unittest #integration

#production #enterprise

#frontend #backend

Learn more about Codecov Flags here.

Showing 1 of 2 files from the diff.
Other files ignored by Codecov

@@ -23,7 +23,7 @@
Loading
23 23
24 24
base64.fromArrayBuffer = function (arrayBuffer) {
25 25
    var array = new Uint8Array(arrayBuffer);
26 -
    return uint8ToBase64(array);
26 +
    return btoa(bytesToBinaryString(array));
27 27
};
28 28
29 29
base64.toArrayBuffer = function (str) {
@@ -36,46 +36,12 @@
Loading
36 36
    return arrayBuffer;
37 37
};
38 38
39 -
// ------------------------------------------------------------------------------
40 -
41 -
/* This code is based on the performance tests at http://jsperf.com/b64tests
42 -
 * This 12-bit-at-a-time algorithm was the best performing version on all
43 -
 * platforms tested.
44 -
 */
45 -
46 -
var b64_6bit = 'ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/';
47 -
var b64_12bit;
48 -
49 -
var b64_12bitTable = function () {
50 -
    b64_12bit = [];
51 -
    for (var i = 0; i < 64; i++) {
52 -
        for (var j = 0; j < 64; j++) {
53 -
            b64_12bit[i * 64 + j] = b64_6bit[i] + b64_6bit[j];
54 -
        }
55 -
    }
56 -
    b64_12bitTable = function () { return b64_12bit; };
57 -
    return b64_12bit;
58 -
};
59 -
60 -
function uint8ToBase64 (rawData) {
61 -
    var numBytes = rawData.byteLength;
62 -
    var output = '';
63 -
    var segment;
64 -
    var table = b64_12bitTable();
65 -
    for (var i = 0; i < numBytes - 2; i += 3) {
66 -
        segment = (rawData[i] << 16) + (rawData[i + 1] << 8) + rawData[i + 2];
67 -
        output += table[segment >> 12];
68 -
        output += table[segment & 0xfff];
69 -
    }
70 -
    if (numBytes - i === 2) {
71 -
        segment = (rawData[i] << 16) + (rawData[i + 1] << 8);
72 -
        output += table[segment >> 12];
73 -
        output += b64_6bit[(segment & 0xfff) >> 6];
74 -
        output += '=';
75 -
    } else if (numBytes - i === 1) {
76 -
        segment = (rawData[i] << 16);
77 -
        output += table[segment >> 12];
78 -
        output += '==';
39 +
function bytesToBinaryString (bytes) {
40 +
    var CHUNK_SIZE = 1 << 15;
41 +
    var string = '';
42 +
    for (var i = 0; i < bytes.length; i += CHUNK_SIZE) {
43 +
        var chunk = bytes.subarray(i, i + CHUNK_SIZE);
44 +
        string += String.fromCharCode.apply(null, chunk);
79 45
    }
80 -
    return output;
46 +
    return string;
81 47
}

Everything is accounted for!

No changes detected that need to be reviewed.
What changes does Codecov check for?
Lines, not adjusted in diff, that have changed coverage data.
Files that introduced coverage data that had none before.
Files that have missing coverage data that once were tracked.
Files Coverage
src -0.58% 83.59%
test/test-platform-modules 100.00%
Project Totals (14 files) 83.65%
Loading