@cofhe/mock-contracts 0.7.1 → 0.8.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/dist/index.js CHANGED
@@ -1,16 +1,157 @@
1
1
  'use strict';
2
2
 
3
+ // src/MockCoFHEAddressBook.ts
4
+ var MockCoFHEAddressBookArtifact = {
5
+ contractName: "MockCoFHEAddressBook",
6
+ isFixed: true,
7
+ fixedAddress: "0xC0F4e00E531a2B086492Ae3DCC1515038307196b",
8
+ abi: [
9
+ {
10
+ type: "function",
11
+ name: "exists",
12
+ inputs: [],
13
+ outputs: [
14
+ {
15
+ name: "",
16
+ type: "bool",
17
+ internalType: "bool"
18
+ }
19
+ ],
20
+ stateMutability: "pure"
21
+ },
22
+ {
23
+ type: "function",
24
+ name: "getTm",
25
+ inputs: [
26
+ {
27
+ name: "id",
28
+ type: "uint256",
29
+ internalType: "uint256"
30
+ }
31
+ ],
32
+ outputs: [
33
+ {
34
+ name: "tm",
35
+ type: "address",
36
+ internalType: "address"
37
+ }
38
+ ],
39
+ stateMutability: "view"
40
+ },
41
+ {
42
+ type: "function",
43
+ name: "setTm",
44
+ inputs: [
45
+ {
46
+ name: "id",
47
+ type: "uint256",
48
+ internalType: "uint256"
49
+ },
50
+ {
51
+ name: "tm",
52
+ type: "address",
53
+ internalType: "address"
54
+ }
55
+ ],
56
+ outputs: [],
57
+ stateMutability: "nonpayable"
58
+ },
59
+ {
60
+ type: "function",
61
+ name: "unsetTm",
62
+ inputs: [
63
+ {
64
+ name: "id",
65
+ type: "uint256",
66
+ internalType: "uint256"
67
+ }
68
+ ],
69
+ outputs: [],
70
+ stateMutability: "nonpayable"
71
+ },
72
+ {
73
+ type: "event",
74
+ name: "TaskManagerSet",
75
+ inputs: [
76
+ {
77
+ name: "id",
78
+ type: "uint256",
79
+ indexed: true,
80
+ internalType: "uint256"
81
+ },
82
+ {
83
+ name: "previous",
84
+ type: "address",
85
+ indexed: true,
86
+ internalType: "address"
87
+ },
88
+ {
89
+ name: "current",
90
+ type: "address",
91
+ indexed: true,
92
+ internalType: "address"
93
+ }
94
+ ],
95
+ anonymous: false
96
+ },
97
+ {
98
+ type: "error",
99
+ name: "InvalidAddress",
100
+ inputs: []
101
+ },
102
+ {
103
+ type: "error",
104
+ name: "TaskManagerNotSet",
105
+ inputs: [
106
+ {
107
+ name: "id",
108
+ type: "uint256",
109
+ internalType: "uint256"
110
+ }
111
+ ]
112
+ }
113
+ ]
114
+ };
115
+
3
116
  // src/MockTaskManager.ts
4
117
  var MockTaskManagerArtifact = {
5
118
  contractName: "MockTaskManager",
6
119
  isFixed: true,
7
- fixedAddress: "0xeA30c4B8b44078Bbf8a6ef5b9f1eC1626C7848D9",
120
+ fixedAddress: "0x0000000000000000000000000000000000005000",
8
121
  abi: [
9
122
  {
10
123
  type: "constructor",
11
124
  inputs: [],
12
125
  stateMutability: "nonpayable"
13
126
  },
127
+ {
128
+ type: "function",
129
+ name: "MOCK_dispatchOperation",
130
+ inputs: [
131
+ {
132
+ name: "ctHash",
133
+ type: "uint256",
134
+ internalType: "uint256"
135
+ },
136
+ {
137
+ name: "funcId",
138
+ type: "uint8",
139
+ internalType: "enum FunctionId"
140
+ },
141
+ {
142
+ name: "inputs",
143
+ type: "uint256[]",
144
+ internalType: "uint256[]"
145
+ },
146
+ {
147
+ name: "arity",
148
+ type: "uint8",
149
+ internalType: "uint8"
150
+ }
151
+ ],
152
+ outputs: [],
153
+ stateMutability: "nonpayable"
154
+ },
14
155
  {
15
156
  type: "function",
16
157
  name: "MOCK_logAllow",
@@ -564,6 +705,19 @@ var MockTaskManagerArtifact = {
564
705
  ],
565
706
  stateMutability: "view"
566
707
  },
708
+ {
709
+ type: "function",
710
+ name: "mockGasExcluded",
711
+ inputs: [],
712
+ outputs: [
713
+ {
714
+ name: "",
715
+ type: "bool",
716
+ internalType: "bool"
717
+ }
718
+ ],
719
+ stateMutability: "view"
720
+ },
567
721
  {
568
722
  type: "function",
569
723
  name: "mockStorage",
@@ -718,6 +872,19 @@ var MockTaskManagerArtifact = {
718
872
  outputs: [],
719
873
  stateMutability: "nonpayable"
720
874
  },
875
+ {
876
+ type: "function",
877
+ name: "setMockGasExcluded",
878
+ inputs: [
879
+ {
880
+ name: "_mockGasExcluded",
881
+ type: "bool",
882
+ internalType: "bool"
883
+ }
884
+ ],
885
+ outputs: [],
886
+ stateMutability: "nonpayable"
887
+ },
721
888
  {
722
889
  type: "function",
723
890
  name: "setSecurityZoneMax",
@@ -963,6 +1130,19 @@ var MockTaskManagerArtifact = {
963
1130
  ],
964
1131
  anonymous: false
965
1132
  },
1133
+ {
1134
+ type: "event",
1135
+ name: "MockGasConsumed",
1136
+ inputs: [
1137
+ {
1138
+ name: "gas",
1139
+ type: "uint256",
1140
+ indexed: false,
1141
+ internalType: "uint256"
1142
+ }
1143
+ ],
1144
+ anonymous: false
1145
+ },
966
1146
  {
967
1147
  type: "event",
968
1148
  name: "ProtocolNotification",
@@ -1272,6 +1452,11 @@ var MockTaskManagerArtifact = {
1272
1452
  }
1273
1453
  ]
1274
1454
  },
1455
+ {
1456
+ type: "error",
1457
+ name: "OnlySelf",
1458
+ inputs: []
1459
+ },
1275
1460
  {
1276
1461
  type: "error",
1277
1462
  name: "RandomFunctionNotSupported",
@@ -1327,19 +1512,6 @@ var MockACLArtifact = {
1327
1512
  inputs: [],
1328
1513
  stateMutability: "nonpayable"
1329
1514
  },
1330
- {
1331
- type: "function",
1332
- name: "TASK_MANAGER_ADDRESS_",
1333
- inputs: [],
1334
- outputs: [
1335
- {
1336
- name: "",
1337
- type: "address",
1338
- internalType: "address"
1339
- }
1340
- ],
1341
- stateMutability: "view"
1342
- },
1343
1515
  {
1344
1516
  type: "function",
1345
1517
  name: "allow",
@@ -1911,6 +2083,19 @@ var MockACLArtifact = {
1911
2083
  outputs: [],
1912
2084
  stateMutability: "nonpayable"
1913
2085
  },
2086
+ {
2087
+ type: "function",
2088
+ name: "setTaskManager",
2089
+ inputs: [
2090
+ {
2091
+ name: "newAddress",
2092
+ type: "address",
2093
+ internalType: "address"
2094
+ }
2095
+ ],
2096
+ outputs: [],
2097
+ stateMutability: "nonpayable"
2098
+ },
1914
2099
  {
1915
2100
  type: "function",
1916
2101
  name: "shareCtHash",
@@ -2029,6 +2214,25 @@ var MockACLArtifact = {
2029
2214
  ],
2030
2215
  anonymous: false
2031
2216
  },
2217
+ {
2218
+ type: "event",
2219
+ name: "TaskManagerUpdated",
2220
+ inputs: [
2221
+ {
2222
+ name: "oldAddress",
2223
+ type: "address",
2224
+ indexed: false,
2225
+ internalType: "address"
2226
+ },
2227
+ {
2228
+ name: "newAddress",
2229
+ type: "address",
2230
+ indexed: false,
2231
+ internalType: "address"
2232
+ }
2233
+ ],
2234
+ anonymous: false
2235
+ },
2032
2236
  {
2033
2237
  type: "error",
2034
2238
  name: "AlreadyDelegated",
@@ -2050,6 +2254,11 @@ var MockACLArtifact = {
2050
2254
  name: "InvalidShortString",
2051
2255
  inputs: []
2052
2256
  },
2257
+ {
2258
+ type: "error",
2259
+ name: "InvalidTaskManagerAddress",
2260
+ inputs: []
2261
+ },
2053
2262
  {
2054
2263
  type: "error",
2055
2264
  name: "NotShared",
@@ -3388,6 +3597,7 @@ var MockThresholdNetworkArtifact = {
3388
3597
  exports.ACPShareRegistryArtifact = ACPShareRegistryArtifact;
3389
3598
  exports.ACPTimestampRevokerArtifact = ACPTimestampRevokerArtifact;
3390
3599
  exports.MockACLArtifact = MockACLArtifact;
3600
+ exports.MockCoFHEAddressBookArtifact = MockCoFHEAddressBookArtifact;
3391
3601
  exports.MockTaskManagerArtifact = MockTaskManagerArtifact;
3392
3602
  exports.MockThresholdNetworkArtifact = MockThresholdNetworkArtifact;
3393
3603
  exports.MockZkVerifierArtifact = MockZkVerifierArtifact;