diff --git a/contracts/interfaces/IBreakerBox.sol b/contracts/interfaces/IBreakerBox.sol index 47fc724f..65322a67 100644 --- a/contracts/interfaces/IBreakerBox.sol +++ b/contracts/interfaces/IBreakerBox.sol @@ -26,14 +26,6 @@ interface IBreakerBox { * * - Enabled: Indicates whether the breaker is enabled for the associated rate feed. */ - - /** - * @dev Used to keep track of the status of a breaker for a specific rate feed. - * - * tradingMode: Represents the trading mode that the breaker is in for the rate feed. - * This is a bitmask, and multiple breakers contribute - * to the final trading mode of the rate feed. - */ struct BreakerStatus { uint8 tradingMode; uint64 lastUpdatedTime; diff --git a/contracts/oracles/BreakerBox.sol b/contracts/oracles/BreakerBox.sol index 5ac39bb5..88ffda2b 100644 --- a/contracts/oracles/BreakerBox.sol +++ b/contracts/oracles/BreakerBox.sol @@ -17,7 +17,7 @@ import { Initializable } from "../common/Initializable.sol"; * to determine whether or not buying or selling should be allowed for a * specified rateFeedIDs. The contract stores references to all breakers * that hold criteria to be checked, rateFeedIDs that - * can make use of the BreakerBox & their current trading. + * can make use of the BreakerBox & their current trading modes. */ contract BreakerBox is IBreakerBox, Ownable { using SafeMath for uint256; diff --git a/contracts/oracles/breakers/MedianDeltaBreaker.sol b/contracts/oracles/breakers/MedianDeltaBreaker.sol index 026ff10a..b0880b17 100644 --- a/contracts/oracles/breakers/MedianDeltaBreaker.sol +++ b/contracts/oracles/breakers/MedianDeltaBreaker.sol @@ -137,7 +137,7 @@ contract MedianDeltaBreaker is IBreaker, WithCooldown, WithThreshold, Ownable { /** * @notice Check if the current median report rate for a rate feed change, relative * to the last median report, is greater than the configured threshold. - * If the change is greater than the threshold the breaker will trip. + * If the change is greater than the threshold the breaker will be triggered. * @param rateFeedID The rate feed to be checked. * @return triggerBreaker A bool indicating whether or not this breaker * should be tripped for the rate feed. diff --git a/contracts/oracles/breakers/ValueDeltaBreaker.sol b/contracts/oracles/breakers/ValueDeltaBreaker.sol index eb325cae..c30feee2 100644 --- a/contracts/oracles/breakers/ValueDeltaBreaker.sol +++ b/contracts/oracles/breakers/ValueDeltaBreaker.sol @@ -123,7 +123,7 @@ contract ValueDeltaBreaker is IBreaker, WithCooldown, WithThreshold, Ownable { /** * @notice Check if the current median report rate change, for a rate feed, relative * to the last median report is greater than a calculated threshold. - * If the change is greater than the threshold the breaker will trip. + * If the change is greater than the threshold the breaker will be triggered. * @param rateFeedID The rate feed to be checked. * @return triggerBreaker A bool indicating whether or not this breaker * should be tripped for the rate feed. diff --git a/test/gas/BrokerGas.t.sol b/test/gas/BrokerGas.t.sol index 148be8f9..4ac00256 100644 --- a/test/gas/BrokerGas.t.sol +++ b/test/gas/BrokerGas.t.sol @@ -9,7 +9,7 @@ import { IERC20 } from "openzeppelin-solidity/contracts/token/ERC20/IERC20.sol"; import { IntegrationTest } from "../utils/IntegrationTest.t.sol"; import { TokenHelpers } from "../utils/TokenHelpers.t.sol"; -// forge test --match-contract BrokerIntegration -vvv +// forge test --match-contract BrokerGasTest -vvv contract BrokerGasTest is IntegrationTest, TokenHelpers { address trader; diff --git a/test/integration/ConstantSumIntegration.t.sol b/test/integration/ConstantSumIntegration.t.sol index b535851c..9177cd95 100644 --- a/test/integration/ConstantSumIntegration.t.sol +++ b/test/integration/ConstantSumIntegration.t.sol @@ -112,7 +112,7 @@ contract ConstantSumIntegrationTest is IntegrationTest, TokenHelpers { assertEq(actualOut, 5000 * 0.995 * 10**6); // 4975(6 decimals) vm.warp(now + exchangeBefore.config.referenceRateResetFrequency); // time travel enable bucket update - setMedianRate(cUSD_bridgedUSDC_referenceRateFeedID, 1e24 * 1.1); // new valid Median that doesnt trip breaker 0.13 + setMedianRate(cUSD_bridgedUSDC_referenceRateFeedID, 1e24 * 1.1); // new valid Median that wont trigger breaker 0.13 // Execute swap cUSD -> USDC (, uint256 actualOut2) = doSwapIn(poolId, amountIn, address(tokenIn), address(tokenOut), false);