-
Notifications
You must be signed in to change notification settings - Fork 80
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Oracle updates, use million USD for low precision tokens (#1079)
- Loading branch information
Showing
17 changed files
with
964 additions
and
93 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
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
28 changes: 28 additions & 0 deletions
28
protocol/contracts/mocks/mockFacets/MockSeasonGettersFacet.sol
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,28 @@ | ||
/* | ||
SPDX-License-Identifier: MIT | ||
*/ | ||
|
||
pragma solidity ^0.8.20; | ||
|
||
import {SeasonGettersFacet} from "../../beanstalk/sun/SeasonFacet/SeasonGettersFacet.sol"; | ||
import {LibDeltaB} from "../../libraries/Oracle/LibDeltaB.sol"; | ||
import {LibAppStorage, AppStorage} from "../../libraries/LibAppStorage.sol"; | ||
import "forge-std/console.sol"; | ||
|
||
/** | ||
* @author pizzaman1337 | ||
* @title Mock Season Getters Facet | ||
**/ | ||
contract MockSeasonGettersFacet is SeasonGettersFacet { | ||
// this mock removes the isWell check, so that a well's deltaB can be checked without requiring whitelisting | ||
function poolCurrentDeltaBMock(address pool) public view returns (int256 deltaB) { | ||
console.log("poolCurrentDeltaB"); | ||
(deltaB) = LibDeltaB.currentDeltaB(pool); | ||
return deltaB; | ||
} | ||
|
||
function mockInitState() public { | ||
AppStorage storage s = LibAppStorage.diamondStorage(); | ||
s.sys.tokens.bean = 0xBEA0000029AD1c77D3d5D23Ba2D8893dB9d1Efab; | ||
} | ||
} |
Oops, something went wrong.