@cofhe/mock-contracts 0.2.0 → 0.3.0
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.
- package/CHANGELOG.md +26 -0
- package/README.md +63 -9
- package/contracts/MockACL.sol +4 -0
- package/contracts/MockTaskManager.sol +86 -1
- package/contracts/{MockQueryDecrypter.sol → MockThresholdNetwork.sol} +67 -1
- package/contracts/TestBed.sol +34 -2
- package/contracts/foundry/CoFheTest.sol +47 -27
- package/dist/index.d.mts +14 -11
- package/dist/index.d.ts +14 -11
- package/dist/index.js +397 -26
- package/dist/index.js.map +1 -1
- package/dist/index.mjs +397 -26
- package/dist/index.mjs.map +1 -1
- package/package.json +5 -5
- package/src/MockACL.ts +65 -6
- package/src/MockTaskManager.ts +187 -5
- package/src/MockThresholdNetwork.ts +457 -0
- package/src/MockZkVerifier.ts +5 -6
- package/src/TestBed.ts +35 -13
- package/src/index.ts +1 -1
- package/src/types.ts +12 -5
- package/test/TestBed.t.sol +18 -7
- package/src/MockQueryDecrypter.ts +0 -353
package/dist/index.d.mts
CHANGED
|
@@ -1,13 +1,18 @@
|
|
|
1
|
-
type
|
|
1
|
+
type MockArtifact = {
|
|
2
2
|
contractName: string;
|
|
3
|
-
fixedAddress: string;
|
|
4
3
|
abi: any;
|
|
4
|
+
} & ({
|
|
5
|
+
isFixed: true;
|
|
6
|
+
fixedAddress: string;
|
|
5
7
|
deployedBytecode: string;
|
|
8
|
+
} | {
|
|
9
|
+
isFixed: false;
|
|
6
10
|
bytecode: string;
|
|
7
|
-
};
|
|
11
|
+
});
|
|
8
12
|
|
|
9
13
|
declare const MockTaskManagerArtifact: {
|
|
10
14
|
contractName: string;
|
|
15
|
+
isFixed: true;
|
|
11
16
|
fixedAddress: string;
|
|
12
17
|
abi: ({
|
|
13
18
|
type: string;
|
|
@@ -66,12 +71,11 @@ declare const MockTaskManagerArtifact: {
|
|
|
66
71
|
anonymous?: undefined;
|
|
67
72
|
})[];
|
|
68
73
|
deployedBytecode: string;
|
|
69
|
-
bytecode: string;
|
|
70
74
|
};
|
|
71
75
|
|
|
72
76
|
declare const MockACLArtifact: {
|
|
73
77
|
contractName: string;
|
|
74
|
-
|
|
78
|
+
isFixed: false;
|
|
75
79
|
abi: ({
|
|
76
80
|
type: string;
|
|
77
81
|
inputs: never[];
|
|
@@ -128,12 +132,12 @@ declare const MockACLArtifact: {
|
|
|
128
132
|
outputs?: undefined;
|
|
129
133
|
anonymous?: undefined;
|
|
130
134
|
})[];
|
|
131
|
-
deployedBytecode: string;
|
|
132
135
|
bytecode: string;
|
|
133
136
|
};
|
|
134
137
|
|
|
135
138
|
declare const MockZkVerifierArtifact: {
|
|
136
139
|
contractName: string;
|
|
140
|
+
isFixed: true;
|
|
137
141
|
fixedAddress: string;
|
|
138
142
|
abi: ({
|
|
139
143
|
type: string;
|
|
@@ -176,11 +180,11 @@ declare const MockZkVerifierArtifact: {
|
|
|
176
180
|
stateMutability?: undefined;
|
|
177
181
|
})[];
|
|
178
182
|
deployedBytecode: string;
|
|
179
|
-
bytecode: string;
|
|
180
183
|
};
|
|
181
184
|
|
|
182
|
-
declare const
|
|
185
|
+
declare const MockThresholdNetworkArtifact: {
|
|
183
186
|
contractName: string;
|
|
187
|
+
isFixed: true;
|
|
184
188
|
fixedAddress: string;
|
|
185
189
|
abi: ({
|
|
186
190
|
type: string;
|
|
@@ -214,11 +218,11 @@ declare const MockQueryDecrypterArtifact: {
|
|
|
214
218
|
stateMutability?: undefined;
|
|
215
219
|
})[];
|
|
216
220
|
deployedBytecode: string;
|
|
217
|
-
bytecode: string;
|
|
218
221
|
};
|
|
219
222
|
|
|
220
223
|
declare const TestBedArtifact: {
|
|
221
224
|
contractName: string;
|
|
225
|
+
isFixed: true;
|
|
222
226
|
fixedAddress: string;
|
|
223
227
|
abi: ({
|
|
224
228
|
type: string;
|
|
@@ -261,7 +265,6 @@ declare const TestBedArtifact: {
|
|
|
261
265
|
stateMutability?: undefined;
|
|
262
266
|
})[];
|
|
263
267
|
deployedBytecode: string;
|
|
264
|
-
bytecode: string;
|
|
265
268
|
};
|
|
266
269
|
|
|
267
|
-
export { MockACLArtifact,
|
|
270
|
+
export { MockACLArtifact, type MockArtifact, MockTaskManagerArtifact, MockThresholdNetworkArtifact, MockZkVerifierArtifact, TestBedArtifact };
|
package/dist/index.d.ts
CHANGED
|
@@ -1,13 +1,18 @@
|
|
|
1
|
-
type
|
|
1
|
+
type MockArtifact = {
|
|
2
2
|
contractName: string;
|
|
3
|
-
fixedAddress: string;
|
|
4
3
|
abi: any;
|
|
4
|
+
} & ({
|
|
5
|
+
isFixed: true;
|
|
6
|
+
fixedAddress: string;
|
|
5
7
|
deployedBytecode: string;
|
|
8
|
+
} | {
|
|
9
|
+
isFixed: false;
|
|
6
10
|
bytecode: string;
|
|
7
|
-
};
|
|
11
|
+
});
|
|
8
12
|
|
|
9
13
|
declare const MockTaskManagerArtifact: {
|
|
10
14
|
contractName: string;
|
|
15
|
+
isFixed: true;
|
|
11
16
|
fixedAddress: string;
|
|
12
17
|
abi: ({
|
|
13
18
|
type: string;
|
|
@@ -66,12 +71,11 @@ declare const MockTaskManagerArtifact: {
|
|
|
66
71
|
anonymous?: undefined;
|
|
67
72
|
})[];
|
|
68
73
|
deployedBytecode: string;
|
|
69
|
-
bytecode: string;
|
|
70
74
|
};
|
|
71
75
|
|
|
72
76
|
declare const MockACLArtifact: {
|
|
73
77
|
contractName: string;
|
|
74
|
-
|
|
78
|
+
isFixed: false;
|
|
75
79
|
abi: ({
|
|
76
80
|
type: string;
|
|
77
81
|
inputs: never[];
|
|
@@ -128,12 +132,12 @@ declare const MockACLArtifact: {
|
|
|
128
132
|
outputs?: undefined;
|
|
129
133
|
anonymous?: undefined;
|
|
130
134
|
})[];
|
|
131
|
-
deployedBytecode: string;
|
|
132
135
|
bytecode: string;
|
|
133
136
|
};
|
|
134
137
|
|
|
135
138
|
declare const MockZkVerifierArtifact: {
|
|
136
139
|
contractName: string;
|
|
140
|
+
isFixed: true;
|
|
137
141
|
fixedAddress: string;
|
|
138
142
|
abi: ({
|
|
139
143
|
type: string;
|
|
@@ -176,11 +180,11 @@ declare const MockZkVerifierArtifact: {
|
|
|
176
180
|
stateMutability?: undefined;
|
|
177
181
|
})[];
|
|
178
182
|
deployedBytecode: string;
|
|
179
|
-
bytecode: string;
|
|
180
183
|
};
|
|
181
184
|
|
|
182
|
-
declare const
|
|
185
|
+
declare const MockThresholdNetworkArtifact: {
|
|
183
186
|
contractName: string;
|
|
187
|
+
isFixed: true;
|
|
184
188
|
fixedAddress: string;
|
|
185
189
|
abi: ({
|
|
186
190
|
type: string;
|
|
@@ -214,11 +218,11 @@ declare const MockQueryDecrypterArtifact: {
|
|
|
214
218
|
stateMutability?: undefined;
|
|
215
219
|
})[];
|
|
216
220
|
deployedBytecode: string;
|
|
217
|
-
bytecode: string;
|
|
218
221
|
};
|
|
219
222
|
|
|
220
223
|
declare const TestBedArtifact: {
|
|
221
224
|
contractName: string;
|
|
225
|
+
isFixed: true;
|
|
222
226
|
fixedAddress: string;
|
|
223
227
|
abi: ({
|
|
224
228
|
type: string;
|
|
@@ -261,7 +265,6 @@ declare const TestBedArtifact: {
|
|
|
261
265
|
stateMutability?: undefined;
|
|
262
266
|
})[];
|
|
263
267
|
deployedBytecode: string;
|
|
264
|
-
bytecode: string;
|
|
265
268
|
};
|
|
266
269
|
|
|
267
|
-
export { MockACLArtifact,
|
|
270
|
+
export { MockACLArtifact, type MockArtifact, MockTaskManagerArtifact, MockThresholdNetworkArtifact, MockZkVerifierArtifact, TestBedArtifact };
|