@proto-kit/common 0.1.1-develop.1314 → 0.1.1-develop.1315

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -0,0 +1,20 @@
1
+ import { Field } from "o1js";
2
+ export declare function equalProvable(received: Field[], expected: Field[]): {
3
+ message: () => string;
4
+ pass: boolean;
5
+ };
6
+ interface CustomMatchers<R = void> {
7
+ equalProvable(expected: Field[]): R;
8
+ }
9
+ declare global {
10
+ namespace jest {
11
+ interface Expect extends CustomMatchers {
12
+ }
13
+ interface Matchers<R> extends CustomMatchers<R> {
14
+ }
15
+ interface InverseAsymmetricMatchers extends CustomMatchers {
16
+ }
17
+ }
18
+ }
19
+ export {};
20
+ //# sourceMappingURL=equalProvable.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"equalProvable.d.ts","sourceRoot":"","sources":["../../src/test/equalProvable.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,KAAK,EAAE,MAAM,MAAM,CAAC;AAE7B,wBAAgB,aAAa,CAAC,QAAQ,EAAE,KAAK,EAAE,EAAE,QAAQ,EAAE,KAAK,EAAE;;;EAajE;AAMD,UAAU,cAAc,CAAC,CAAC,GAAG,IAAI;IAC/B,aAAa,CAAC,QAAQ,EAAE,KAAK,EAAE,GAAG,CAAC,CAAC;CACrC;AAED,OAAO,CAAC,MAAM,CAAC;IACb,UAAU,IAAI,CAAC;QACb,UAAU,MAAO,SAAQ,cAAc;SAAG;QAC1C,UAAU,QAAQ,CAAC,CAAC,CAAE,SAAQ,cAAc,CAAC,CAAC,CAAC;SAAG;QAClD,UAAU,yBAA0B,SAAQ,cAAc;SAAG;KAC9D;CACF"}
@@ -0,0 +1,13 @@
1
+ export function equalProvable(received, expected) {
2
+ expect(received).toHaveLength(expected.length);
3
+ const receivedBigInts = received.map((f) => f.toBigInt());
4
+ const expectedBigInts = expected.map((f) => f.toBigInt());
5
+ const pass = receivedBigInts.every((v, index) => v === expectedBigInts[index]);
6
+ return {
7
+ message: () => `Expected ${expectedBigInts}, received ${receivedBigInts}`,
8
+ pass,
9
+ };
10
+ }
11
+ expect.extend({
12
+ equalProvable,
13
+ });
package/package.json CHANGED
@@ -3,7 +3,7 @@
3
3
  "license": "MIT",
4
4
  "private": false,
5
5
  "type": "module",
6
- "version": "0.1.1-develop.1314+16839b95",
6
+ "version": "0.1.1-develop.1315+6f08e29d",
7
7
  "scripts": {
8
8
  "build": "tsc -p tsconfig.json",
9
9
  "dev": "tsc -p tsconfig.json --watch",
@@ -30,5 +30,5 @@
30
30
  "@jest/globals": "^29.5.0",
31
31
  "@types/lodash": "^4.14.194"
32
32
  },
33
- "gitHead": "16839b95d5f3f1066ca23693c71c96d7c183ccf3"
33
+ "gitHead": "6f08e29dcb3080d1afdba04f6f875eab5827da0d"
34
34
  }