fix: Pin OpenZeppelin to v4.9.6 and add mock registrations for Phase 4 tests
Some checks failed
Contract Performance Benchmarks / benchmark-gas-usage (push) Successful in 1m16s
Contract Performance Benchmarks / benchmark-execution-time (push) Successful in 1m0s
Contract Performance Benchmarks / benchmark-throughput (push) Successful in 1m3s
Cross-Chain Functionality Tests / test-cross-chain-sync (push) Successful in 2s
Cross-Chain Functionality Tests / test-cross-chain-transactions (push) Successful in 2s
Cross-Chain Functionality Tests / test-cross-chain-bridge (push) Has been skipped
Cross-Chain Functionality Tests / test-multi-chain-consensus (push) Successful in 2s
Cross-Chain Functionality Tests / aggregate-results (push) Has been skipped
Cross-Node Transaction Testing / transaction-test (push) Successful in 9s
Deploy to Testnet / deploy-testnet (push) Successful in 1m1s
Multi-Node Stress Testing / stress-test (push) Successful in 1s
Node Failover Simulation / failover-test (push) Successful in 2s
Smart Contract Tests / test-solidity (map[name:aitbc-contracts path:contracts]) (push) Failing after 1m0s
Smart Contract Tests / test-solidity (map[name:aitbc-token path:packages/solidity/aitbc-token]) (push) Successful in 10s
Smart Contract Tests / test-foundry (push) Failing after 14s
Smart Contract Tests / lint-solidity (push) Successful in 14s
Smart Contract Tests / deploy-contracts (push) Successful in 1m11s
Contract Performance Benchmarks / compare-benchmarks (push) Successful in 2s
Deploy to Testnet / notify-deployment (push) Successful in 1s
Some checks failed
Contract Performance Benchmarks / benchmark-gas-usage (push) Successful in 1m16s
Contract Performance Benchmarks / benchmark-execution-time (push) Successful in 1m0s
Contract Performance Benchmarks / benchmark-throughput (push) Successful in 1m3s
Cross-Chain Functionality Tests / test-cross-chain-sync (push) Successful in 2s
Cross-Chain Functionality Tests / test-cross-chain-transactions (push) Successful in 2s
Cross-Chain Functionality Tests / test-cross-chain-bridge (push) Has been skipped
Cross-Chain Functionality Tests / test-multi-chain-consensus (push) Successful in 2s
Cross-Chain Functionality Tests / aggregate-results (push) Has been skipped
Cross-Node Transaction Testing / transaction-test (push) Successful in 9s
Deploy to Testnet / deploy-testnet (push) Successful in 1m1s
Multi-Node Stress Testing / stress-test (push) Successful in 1s
Node Failover Simulation / failover-test (push) Successful in 2s
Smart Contract Tests / test-solidity (map[name:aitbc-contracts path:contracts]) (push) Failing after 1m0s
Smart Contract Tests / test-solidity (map[name:aitbc-token path:packages/solidity/aitbc-token]) (push) Successful in 10s
Smart Contract Tests / test-foundry (push) Failing after 14s
Smart Contract Tests / lint-solidity (push) Successful in 14s
Smart Contract Tests / deploy-contracts (push) Successful in 1m11s
Contract Performance Benchmarks / compare-benchmarks (push) Successful in 2s
Deploy to Testnet / notify-deployment (push) Successful in 1s
- Pin OpenZeppelin to v4.9.6 to match contract import structure - Add mock registrations for PerformanceVerifier, AgentBounty, AgentStaking - PerformanceAggregator.initialize() requires these contracts in registry
This commit is contained in:
@@ -134,8 +134,8 @@ jobs:
|
||||
|
||||
echo "=== Running Foundry Tests ==="
|
||||
|
||||
# Install OpenZeppelin dependencies
|
||||
forge install OpenZeppelin/openzeppelin-contracts
|
||||
# Install OpenZeppelin dependencies (v4.x for compatibility with existing imports)
|
||||
forge install OpenZeppelin/openzeppelin-contracts@v4.9.6
|
||||
echo "✅ OpenZeppelin dependencies installed"
|
||||
|
||||
# Build contracts
|
||||
|
||||
@@ -83,6 +83,20 @@ describe("Phase 4 Modular Smart Contracts", function () {
|
||||
);
|
||||
// PerformanceAggregator registers itself during initialize(), so don't register it here
|
||||
|
||||
// Register mock contracts that PerformanceAggregator.initialize() requires
|
||||
await contractRegistry.registerContract(
|
||||
ethers.keccak256(ethers.toUtf8Bytes("PerformanceVerifier")),
|
||||
user1.address
|
||||
);
|
||||
await contractRegistry.registerContract(
|
||||
ethers.keccak256(ethers.toUtf8Bytes("AgentBounty")),
|
||||
user2.address
|
||||
);
|
||||
await contractRegistry.registerContract(
|
||||
ethers.keccak256(ethers.toUtf8Bytes("AgentStaking")),
|
||||
deployer.address
|
||||
);
|
||||
|
||||
// Initialize all contracts (after registration)
|
||||
await treasuryManager.initialize(await contractRegistry.getAddress());
|
||||
await rewardDistributor.initialize(await contractRegistry.getAddress());
|
||||
|
||||
Reference in New Issue
Block a user