Skip to content

Commit

Permalink
fix git case sensitive bug
Browse files Browse the repository at this point in the history
  • Loading branch information
phn210 committed Mar 8, 2024
1 parent 042857d commit 58bc0a7
Show file tree
Hide file tree
Showing 2 changed files with 21 additions and 0 deletions.
21 changes: 21 additions & 0 deletions src/IpfsHash.test.ts
Original file line number Diff line number Diff line change
@@ -0,0 +1,21 @@
import { Provable } from 'o1js';
import { IpfsHash } from './IpfsHash.js';

describe('IpfsHash', () => {
it('Should be provable code', async () => {
Provable.runAndCheck(() => {
let ipfsHash = 'QmdfTbBqBPQ7VNxZEYEj14VmRuZBkqFbiwReogJgS1zR1n';
let encodedData = Provable.witness(IpfsHash, () => {
return IpfsHash.fromString(ipfsHash);
});
Provable.log(encodedData);
});
});

it('Should convert correctly', async () => {
let ipfsHash = 'QmdfTbBqBPQ7VNxZEYEj14VmRuZBkqFbiwReogJgS1zR1n';
let encoded = IpfsHash.fromString(ipfsHash);
let decoded = encoded.toString();
expect(decoded).toEqual(ipfsHash);
});
});
File renamed without changes.

0 comments on commit 58bc0a7

Please sign in to comment.