Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
N
nebula
Project
Project
Details
Activity
Releases
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Boards
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
exchain
nebula
Commits
31c09175
Commit
31c09175
authored
May 03, 2023
by
tre
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
lint
parent
c2f5745a
Changes
3
Show whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
7 additions
and
8 deletions
+7
-8
Faucet.t.sol
.../contracts-periphery/contracts/foundry-tests/Faucet.t.sol
+0
-1
FaucetHelper.sol
...acts-periphery/contracts/testing/helpers/FaucetHelper.sol
+5
-5
Faucet.sol
...contracts-periphery/contracts/universal/faucet/Faucet.sol
+2
-2
No files found.
packages/contracts-periphery/contracts/foundry-tests/Faucet.t.sol
View file @
31c09175
//SPDX-License-Identifier: MIT
//SPDX-License-Identifier: MIT
pragma solidity 0.8.15;
pragma solidity 0.8.15;
/* Testing utilities */
import { Test } from "forge-std/Test.sol";
import { Test } from "forge-std/Test.sol";
import { AdminFAM, Faucet } from "../universal/faucet/Faucet.sol";
import { AdminFAM, Faucet } from "../universal/faucet/Faucet.sol";
import { FaucetHelper } from "../testing/helpers/FaucetHelper.sol";
import { FaucetHelper } from "../testing/helpers/FaucetHelper.sol";
...
...
packages/contracts-periphery/contracts/testing/helpers/FaucetHelper.sol
View file @
31c09175
...
@@ -9,7 +9,7 @@ import { ECDSA } from "@openzeppelin/contracts/utils/cryptography/ECDSA.sol";
...
@@ -9,7 +9,7 @@ import { ECDSA } from "@openzeppelin/contracts/utils/cryptography/ECDSA.sol";
*/
*/
contract FaucetHelper {
contract FaucetHelper {
/**
/**
* @notice EIP712 typehash for the
ClaimableInvite
type.
* @notice EIP712 typehash for the
Proof
type.
*/
*/
bytes32 public constant PROOF_TYPEHASH =
bytes32 public constant PROOF_TYPEHASH =
keccak256("Proof(address recipient,bytes32 nonce,bytes id)");
keccak256("Proof(address recipient,bytes32 nonce,bytes id)");
...
@@ -23,7 +23,7 @@ contract FaucetHelper {
...
@@ -23,7 +23,7 @@ contract FaucetHelper {
);
);
/**
/**
* @notice Keeps track of current nonce to generate new nonces for each
invite
.
* @notice Keeps track of current nonce to generate new nonces for each
drip
.
*/
*/
uint256 public currentNonce;
uint256 public currentNonce;
...
@@ -38,9 +38,9 @@ contract FaucetHelper {
...
@@ -38,9 +38,9 @@ contract FaucetHelper {
}
}
/**
/**
* @notice Returns the hash of the struct
ClaimableInvite
.
* @notice Returns the hash of the struct
Proof
.
*
*
* @param _proof
ClaimableInvite
struct to hash.
* @param _proof
Proof
struct to hash.
*
*
* @return EIP-712 typed struct hash.
* @return EIP-712 typed struct hash.
*/
*/
...
@@ -64,7 +64,7 @@ contract FaucetHelper {
...
@@ -64,7 +64,7 @@ contract FaucetHelper {
* @notice Computes the EIP712 digest with the given domain parameters.
* @notice Computes the EIP712 digest with the given domain parameters.
* Used for testing that different domain parameters fail.
* Used for testing that different domain parameters fail.
*
*
* @param _proof
ClaimableInvite
struct to hash.
* @param _proof
Proof
struct to hash.
* @param _name Contract name to use in the EIP712 domain.
* @param _name Contract name to use in the EIP712 domain.
* @param _version Contract version to use in the EIP712 domain.
* @param _version Contract version to use in the EIP712 domain.
* @param _chainid Chain ID to use in the EIP712 domain.
* @param _chainid Chain ID to use in the EIP712 domain.
...
...
packages/contracts-periphery/contracts/universal/faucet/Faucet.sol
View file @
31c09175
...
@@ -60,7 +60,7 @@ contract AdminFAM is FaucetAuthModule, Semver, EIP712Upgradeable {
...
@@ -60,7 +60,7 @@ contract AdminFAM is FaucetAuthModule, Semver, EIP712Upgradeable {
address public immutable ADMIN;
address public immutable ADMIN;
/**
/**
* @notice EIP712 typehash for the
ClaimableInvite
type.
* @notice EIP712 typehash for the
Proof
type.
*/
*/
bytes32 public constant PROOF_TYPEHASH =
bytes32 public constant PROOF_TYPEHASH =
keccak256("Proof(address recipient,bytes32 nonce,bytes id)");
keccak256("Proof(address recipient,bytes32 nonce,bytes id)");
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment