Prechádzať zdrojové kódy

print base64 encoded body if CRC does not match

jomo 9 rokov pred
rodič
commit
b0f50cbed0
1 zmenil súbory, kde vykonal 1 pridanie a 1 odobranie
  1. 1 1
      test/test.js

+ 1 - 1
test/test.js

@@ -799,7 +799,7 @@ describe("Crafatar", function() {
             try {
               assert.ok(matches);
             } catch(e) {
-              throw new Error(crc(body) + " != " + location.crc32);
+              throw new Error(crc(body) + " != " + location.crc32 + " | " + body.toString("base64"));
             }
             assert.strictEqual(res.headers.location, location.redirect);
             if (location.etag === undefined) {