isohash/test/test.both.ts

13 lines
444 B
TypeScript
Raw Normal View History

2024-05-28 10:40:32 +00:00
import { expect, tap } from '@push.rocks/tapbundle';
2022-03-24 12:12:59 +00:00
import * as isohash from '../ts/index.js';
2020-09-29 16:21:56 +00:00
tap.test('first test', async () => {
const compareHash = 'f94b840e404ef088fd378ad3811e36357ab6ee39020bfbe48c8bf11b65d100dc';
const originString = 'eruzw873zrhchkjhdfuezrw';
const hashResult = await isohash.sha256FromString(originString);
2022-03-24 12:12:59 +00:00
expect(hashResult).toEqual(compareHash);
2020-09-29 16:21:56 +00:00
console.log(hashResult);
});
2024-05-28 10:40:32 +00:00
export default tap.start();