@@ -16,12 +16,11 @@ contract TAPCollectorCollectTest is TAPCollectorTest {
1616 function _getQueryFeeEncodedData (
1717 uint256 _signerPrivateKey ,
1818 address _payer ,
19- address _collector ,
2019 address _indexer ,
2120 address _dataService ,
2221 uint128 _tokens
2322 ) private view returns (bytes memory ) {
24- ITAPCollector.ReceiptAggregateVoucher memory rav = _getRAV (_payer, _collector, _indexer, _dataService, _tokens);
23+ ITAPCollector.ReceiptAggregateVoucher memory rav = _getRAV (_payer, _indexer, _dataService, _tokens);
2524 bytes32 messageHash = tapCollector.encodeRAV (rav);
2625 (uint8 v , bytes32 r , bytes32 s ) = vm.sign (_signerPrivateKey, messageHash);
2726 bytes memory signature = abi.encodePacked (r, s, v);
@@ -31,15 +30,13 @@ contract TAPCollectorCollectTest is TAPCollectorTest {
3130
3231 function _getRAV (
3332 address _payer ,
34- address _collector ,
3533 address _indexer ,
3634 address _dataService ,
3735 uint128 _tokens
3836 ) private pure returns (ITAPCollector.ReceiptAggregateVoucher memory rav ) {
3937 return
4038 ITAPCollector.ReceiptAggregateVoucher ({
4139 payer: _payer,
42- collector: _collector,
4340 dataService: _dataService,
4441 serviceProvider: _indexer,
4542 timestampNs: 0 ,
@@ -62,7 +59,6 @@ contract TAPCollectorCollectTest is TAPCollectorTest {
6259 bytes memory data = _getQueryFeeEncodedData (
6360 signerPrivateKey,
6461 users.gateway,
65- address (tapCollector),
6662 users.indexer,
6763 users.verifier,
6864 uint128 (tokens)
@@ -88,7 +84,6 @@ contract TAPCollectorCollectTest is TAPCollectorTest {
8884 bytes memory data = _getQueryFeeEncodedData (
8985 signerPrivateKey,
9086 users.gateway,
91- address (tapCollector),
9287 users.indexer,
9388 users.verifier,
9489 uint128 (payed + tokensPerStep)
@@ -98,27 +93,6 @@ contract TAPCollectorCollectTest is TAPCollectorTest {
9893 }
9994 }
10095
101- function testTAPCollector_Collect_RevertWhen_OtherCollector () public useGateway useSigner {
102- address otherCollector = makeAddr ("otherCollector " );
103- bytes memory data = _getQueryFeeEncodedData (
104- signerPrivateKey,
105- users.gateway,
106- otherCollector,
107- users.indexer,
108- users.verifier,
109- uint128 (0 )
110- );
111-
112- resetPrank (users.verifier);
113- bytes memory expectedError = abi.encodeWithSelector (
114- ITAPCollector.TAPCollectorInvalidCollector.selector ,
115- address (tapCollector),
116- otherCollector
117- );
118- vm.expectRevert (expectedError);
119- tapCollector.collect (IGraphPayments.PaymentTypes.QueryFee, data);
120- }
121-
12296 function testTAPCollector_Collect_RevertWhen_NoProvision (uint256 tokens ) public useGateway useSigner {
12397 tokens = bound (tokens, 1 , type (uint128 ).max);
12498
@@ -127,7 +101,6 @@ contract TAPCollectorCollectTest is TAPCollectorTest {
127101 bytes memory data = _getQueryFeeEncodedData (
128102 signerPrivateKey,
129103 users.gateway,
130- address (tapCollector),
131104 users.indexer,
132105 users.verifier,
133106 uint128 (tokens)
@@ -157,7 +130,6 @@ contract TAPCollectorCollectTest is TAPCollectorTest {
157130 bytes memory data = _getQueryFeeEncodedData (
158131 signerPrivateKey,
159132 users.gateway,
160- address (tapCollector),
161133 users.indexer,
162134 users.verifier,
163135 uint128 (tokens)
@@ -192,7 +164,6 @@ contract TAPCollectorCollectTest is TAPCollectorTest {
192164 bytes memory data = _getQueryFeeEncodedData (
193165 anotherSignerPrivateKey,
194166 users.gateway,
195- address (tapCollector),
196167 users.indexer,
197168 anotherSigner,
198169 uint128 (tokens)
@@ -217,7 +188,6 @@ contract TAPCollectorCollectTest is TAPCollectorTest {
217188 bytes memory data = _getQueryFeeEncodedData (
218189 signerPrivateKey,
219190 users.gateway,
220- address (tapCollector),
221191 users.indexer,
222192 users.verifier,
223193 uint128 (tokens)
@@ -245,7 +215,6 @@ contract TAPCollectorCollectTest is TAPCollectorTest {
245215 bytes memory data = _getQueryFeeEncodedData (
246216 signerPrivateKey,
247217 anotherPayer,
248- address (tapCollector),
249218 users.indexer,
250219 users.verifier,
251220 uint128 (tokens)
@@ -270,7 +239,6 @@ contract TAPCollectorCollectTest is TAPCollectorTest {
270239 bytes memory data = _getQueryFeeEncodedData (
271240 signerPrivateKey,
272241 users.gateway,
273- address (tapCollector),
274242 users.indexer,
275243 users.verifier,
276244 uint128 (tokens)
@@ -294,7 +262,6 @@ contract TAPCollectorCollectTest is TAPCollectorTest {
294262 bytes memory data = _getQueryFeeEncodedData (
295263 signerPrivateKey,
296264 users.gateway,
297- address (tapCollector),
298265 users.indexer,
299266 users.verifier,
300267 uint128 (tokens)
@@ -319,7 +286,6 @@ contract TAPCollectorCollectTest is TAPCollectorTest {
319286 bytes memory data = _getQueryFeeEncodedData (
320287 signerPrivateKey,
321288 users.gateway,
322- address (tapCollector),
323289 users.indexer,
324290 users.verifier,
325291 uint128 (tokens)
@@ -342,7 +308,6 @@ contract TAPCollectorCollectTest is TAPCollectorTest {
342308 bytes memory data = _getQueryFeeEncodedData (
343309 signerPrivateKey,
344310 users.gateway,
345- address (tapCollector),
346311 users.indexer,
347312 users.verifier,
348313 uint128 (tokens)
@@ -368,7 +333,6 @@ contract TAPCollectorCollectTest is TAPCollectorTest {
368333 bytes memory data = _getQueryFeeEncodedData (
369334 signerPrivateKey,
370335 users.gateway,
371- address (tapCollector),
372336 users.indexer,
373337 users.verifier,
374338 uint128 (tokens)
@@ -390,7 +354,6 @@ contract TAPCollectorCollectTest is TAPCollectorTest {
390354 bytes memory data = _getQueryFeeEncodedData (
391355 signerPrivateKey,
392356 users.gateway,
393- address (tapCollector),
394357 users.indexer,
395358 users.verifier,
396359 uint128 (tokens)
@@ -411,7 +374,6 @@ contract TAPCollectorCollectTest is TAPCollectorTest {
411374 bytes memory data = _getQueryFeeEncodedData (
412375 signerPrivateKey,
413376 users.gateway,
414- address (tapCollector),
415377 users.indexer,
416378 users.verifier,
417379 uint128 (tokens)
0 commit comments