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
bbb70f64
Commit
bbb70f64
authored
Nov 30, 2023
by
Mark Tyneway
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
contracts-bedrock: cleanup diff
parent
4c8596ba
Changes
2
Show whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
4 additions
and
6 deletions
+4
-6
Deployer.sol
packages/contracts-bedrock/scripts/Deployer.sol
+1
-3
Initializable.t.sol
packages/contracts-bedrock/test/vendor/Initializable.t.sol
+3
-3
No files found.
packages/contracts-bedrock/scripts/Deployer.sol
View file @
bbb70f64
...
@@ -530,9 +530,7 @@ abstract contract Deployer is Script {
...
@@ -530,9 +530,7 @@ abstract contract Deployer is Script {
if (_isProxy) {
if (_isProxy) {
_contractName = string.concat(_contractName, "Proxy");
_contractName = string.concat(_contractName, "Proxy");
}
}
address addr = getAddress(_contractName);
bytes32 slotVal = vm.load(mustGetAddress(_contractName), bytes32(vm.parseUint(slot.slot)));
bytes32 slotVal = vm.load(addr, bytes32(vm.parseUint(slot.slot)));
initialized_ = uint8((uint256(slotVal) >> (slot.offset * 8)) & 0xFF);
initialized_ = uint8((uint256(slotVal) >> (slot.offset * 8)) & 0xFF);
}
}
...
...
packages/contracts-bedrock/test/vendor/Initializable.t.sol
View file @
bbb70f64
...
@@ -120,7 +120,7 @@ contract Initializer_Test is Bridge_Initializer {
...
@@ -120,7 +120,7 @@ contract Initializer_Test is Bridge_Initializer {
/// 3. The `initialize()` function of each contract cannot be called more than once.
/// 3. The `initialize()` function of each contract cannot be called more than once.
function test_cannotReinitialize_succeeds() public {
function test_cannotReinitialize_succeeds() public {
// Ensure that all L1 `Initializable` contracts are accounted for.
// Ensure that all L1 `Initializable` contracts are accounted for.
assertEq(_getNum
L1
Initializable(), contracts.length);
assertEq(_getNumInitializable(), contracts.length);
// Attempt to re-initialize all contracts within the `contracts` array.
// Attempt to re-initialize all contracts within the `contracts` array.
for (uint256 i; i < contracts.length; i++) {
for (uint256 i; i < contracts.length; i++) {
...
@@ -136,8 +136,8 @@ contract Initializer_Test is Bridge_Initializer {
...
@@ -136,8 +136,8 @@ contract Initializer_Test is Bridge_Initializer {
}
}
}
}
/// @dev Returns the number of contracts that are `Initializable` in `src/L1`.
/// @dev Returns the number of contracts that are `Initializable` in `src/L1`
and `src/L2`
.
function _getNum
L1
Initializable() internal returns (uint256 numContracts_) {
function _getNumInitializable() internal returns (uint256 numContracts_) {
string[] memory command = new string[](3);
string[] memory command = new string[](3);
command[0] = Executables.bash;
command[0] = Executables.bash;
command[1] = "-c";
command[1] = "-c";
...
...
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