generated from rhinestonewtf/module-template
-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
1 parent
1be45b4
commit b6394a0
Showing
5 changed files
with
102 additions
and
8 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,52 @@ | ||
// SPDX-License-Identifier: MIT | ||
pragma solidity ^0.8.23; | ||
|
||
import { Test } from "forge-std/Test.sol"; | ||
import { | ||
RhinestoneModuleKit, | ||
ModuleKitHelpers, | ||
ModuleKitUserOp, | ||
AccountInstance, | ||
UserOpData | ||
} from "modulekit/ModuleKit.sol"; | ||
import { MODULE_TYPE_VALIDATOR } from "modulekit/external/ERC7579.sol"; | ||
|
||
import { Semaphore } from "@semaphore-protocol/Semaphore.sol"; | ||
import { SemaphoreVerifier } from "@semaphore-protocol/base/SemaphoreVerifier.sol"; | ||
import { ISemaphoreVerifier } from "@semaphore-protocol/interfaces/ISemaphoreVerifier.sol"; | ||
|
||
import { SemaphoreMemberValidator } from "src/SemaphoreMemberValidator.sol"; | ||
|
||
contract SemaphoreMemberValidatorTest is RhinestoneModuleKit, Test { | ||
using ModuleKitHelpers for *; | ||
using ModuleKitUserOp for *; | ||
|
||
AccountInstance internal smartAcct; | ||
|
||
Semaphore internal semaphore; | ||
SemaphoreVerifier internal semaphoreVerifier; | ||
SemaphoreMemberValidator internal validator; | ||
|
||
Account user1; | ||
Account user2; | ||
Account admin; | ||
|
||
function setUp() public { | ||
init(); | ||
|
||
// Deploy Semaphore | ||
semaphoreVerifier = new SemaphoreVerifier(); | ||
ISemaphoreVerifier isv = ISemaphoreVerifier(address(semaphoreVerifier)); | ||
semaphore = new Semaphore(isv); | ||
|
||
// Create the validator | ||
validator = new SemaphoreMemberValidator(address(semaphore)); | ||
vm.label(address(validator), "SemaphoreMemberValidator"); | ||
|
||
// Create some users | ||
} | ||
|
||
function test() public { | ||
|
||
} | ||
} |