Skip to content

Commit

Permalink
update default trading fee
Browse files Browse the repository at this point in the history
  • Loading branch information
ivanzhelyazkov committed Jun 12, 2024
1 parent a5f4bbe commit ab5af7d
Show file tree
Hide file tree
Showing 3 changed files with 5 additions and 5 deletions.
2 changes: 1 addition & 1 deletion contracts/carbon/Strategies.sol
Original file line number Diff line number Diff line change
Expand Up @@ -161,7 +161,7 @@ abstract contract Strategies is Initializable {

uint256 private constant ORDERS_INVERTED_FLAG = 1 << 255;

uint32 private constant DEFAULT_TRADING_FEE_PPM = 2000; // 0.2%
uint32 private constant DEFAULT_TRADING_FEE_PPM = 4000; // 0.4%

// total number of strategies
uint128 private _strategyCounter;
Expand Down
4 changes: 2 additions & 2 deletions test/forge/CarbonController.t.sol
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,7 @@ contract CarbonControllerTest is TestFixture {
using Address for address payable;

uint16 private constant CONTROLLER_TYPE = 1;
uint32 private constant TRADING_FEE_PPM = 2000;
uint32 private constant TRADING_FEE_PPM = 4000;

/// @dev function to set up state before tests
function setUp() public virtual {
Expand All @@ -32,7 +32,7 @@ contract CarbonControllerTest is TestFixture {
* @dev construction tests
*/

function testShouldBeInitializedProperly() public {
function testShouldBeInitializedProperly() public view {
uint256 version = carbonController.version();
assertEq(version, 2);

Expand Down
4 changes: 2 additions & 2 deletions test/forge/Strategies.t.sol
Original file line number Diff line number Diff line change
Expand Up @@ -31,7 +31,7 @@ contract StrategiesTest is TestFixture {
uint8 private constant STRATEGY_UPDATE_REASON_EDIT = 0;
uint8 private constant STRATEGY_UPDATE_REASON_TRADE = 1;

uint32 private constant DEFAULT_TRADING_FEE_PPM = 2000;
uint32 private constant DEFAULT_TRADING_FEE_PPM = 4000;
uint32 private constant NEW_TRADING_FEE_PPM = 300_000;

uint256 private constant FETCH_AMOUNT = 5;
Expand Down Expand Up @@ -1266,7 +1266,7 @@ contract StrategiesTest is TestFixture {
carbonController.pairTradingFeePPM(token0, token1);
}

function testSetsTheDefaultOnInitialization() public {
function testSetsTheDefaultOnInitialization() public view {
uint32 tradingFee = carbonController.tradingFeePPM();
assertEq(tradingFee, DEFAULT_TRADING_FEE_PPM);
}
Expand Down

0 comments on commit ab5af7d

Please sign in to comment.