run prettier on all packages

This commit is contained in:
Greg Weisbrod
2021-11-12 02:41:28 -05:00
parent 3b523d7e37
commit afd6aadaf1
51 changed files with 2086 additions and 2062 deletions

View File

@@ -1,29 +1,29 @@
const { loadFixture } = require("./utils");
const { loadFixture } = require('./utils')
const {
transactionTreeHash,
ledgerHash,
accountStateHash,
} = require("../dist/ledger-hashes");
} = require('../dist/ledger-hashes')
describe("Ledger Hashes", function () {
describe('Ledger Hashes', function () {
function testFactory(ledgerFixture) {
describe(`can calculate hashes for ${ledgerFixture}`, function () {
const ledger = loadFixture(ledgerFixture);
test("computes correct account state hash", function () {
const ledger = loadFixture(ledgerFixture)
test('computes correct account state hash', function () {
expect(accountStateHash(ledger.accountState).toHex()).toBe(
ledger.account_hash
);
});
test("computes correct transaction tree hash", function () {
ledger.account_hash,
)
})
test('computes correct transaction tree hash', function () {
expect(transactionTreeHash(ledger.transactions).toHex()).toBe(
ledger.transaction_hash
);
});
test("computes correct ledger header hash", function () {
expect(ledgerHash(ledger).toHex()).toBe(ledger.hash);
});
});
ledger.transaction_hash,
)
})
test('computes correct ledger header hash', function () {
expect(ledgerHash(ledger).toHex()).toBe(ledger.hash)
})
})
}
testFactory("ledger-full-40000.json");
testFactory("ledger-full-38129.json");
});
testFactory('ledger-full-40000.json')
testFactory('ledger-full-38129.json')
})