Skip to content

Commit 70bdf96

Browse files
committed
feat: add events
1 parent 5cbfd14 commit 70bdf96

File tree

1 file changed

+9
-2
lines changed

1 file changed

+9
-2
lines changed

test/mocks/MockCombination.sol

+9-2
Original file line numberDiff line numberDiff line change
@@ -8,6 +8,10 @@ import { IRegistry, SchemaUID, AttestationRequest } from "src/IRegistry.sol";
88
contract MockCombination is IExternalResolver, IExternalSchemaValidator {
99
bool immutable returnVal;
1010

11+
event AttestationCalled();
12+
event RevokeCalled();
13+
event ModuleCalled();
14+
1115
bool public onAttestCalled;
1216
bool public onRevokeCalled;
1317
bool public onModuleCalled;
@@ -32,23 +36,25 @@ contract MockCombination is IExternalResolver, IExternalSchemaValidator {
3236

3337
function resolveAttestation(AttestationRecord calldata attestation) external payable override returns (bool) {
3438
onAttestCalled = true;
39+
emit AttestationCalled();
3540
return returnVal;
3641
}
3742

3843
function resolveAttestation(AttestationRecord[] calldata attestation) external payable override returns (bool) {
3944
onAttestCalled = true;
45+
emit AttestationCalled();
4046
return returnVal;
4147
}
4248

4349
function resolveRevocation(AttestationRecord calldata attestation) external payable override returns (bool) {
44-
revert();
4550
onRevokeCalled = true;
51+
emit RevokeCalled();
4652
return returnVal;
4753
}
4854

4955
function resolveRevocation(AttestationRecord[] calldata attestation) external payable override returns (bool) {
50-
revert();
5156
onRevokeCalled = true;
57+
emit RevokeCalled();
5258
return returnVal;
5359
}
5460

@@ -64,6 +70,7 @@ contract MockCombination is IExternalResolver, IExternalSchemaValidator {
6470
returns (bool)
6571
{
6672
onModuleCalled = true;
73+
emit ModuleCalled();
6774
return returnVal;
6875
}
6976

0 commit comments

Comments
 (0)