(actual: any, expected: any)
| 130 | } |
| 131 | |
| 132 | function assertBlock(actual: any, expected: any): void { |
| 133 | // Check transactions |
| 134 | for (let i = 0; i < expected.transactions.length; i++) { |
| 135 | const expectedTx = expected.transactions[i]; |
| 136 | if (typeof(expectedTx) === "string") { |
| 137 | assert.equal(actual.transactions[i], expectedTx, `block.transactions[${ i }]`); |
| 138 | } else { |
| 139 | throw new Error("@TODO"); |
| 140 | } |
| 141 | } |
| 142 | |
| 143 | // Remove the transactions and test keys |
| 144 | expected = Object.assign({ }, expected, { transactions: undefined, test: undefined }); |
| 145 | |
| 146 | // Check remaining keys |
| 147 | assertObj("block", actual, expected); |
| 148 | } |
| 149 | |
| 150 | function assertTransaction(actual: any, expected: any): void { |
| 151 | // @TODO: Accesslist |
no test coverage detected