From c0264f24b281d4e78aa254d30103e6b7d01ec464 Mon Sep 17 00:00:00 2001 From: andreivladbrg Date: Wed, 27 Apr 2022 23:39:15 +0300 Subject: [PATCH] refactor: change contract name test: add cliff duration constant in create with duration test: change what to expect to be reverted --- test/unit/sablier-v2-cliff/SablierV2Cliff.t.sol | 2 +- .../create-with-duration/createWithDuration.t.sol | 4 ++-- test/unit/sablier-v2-cliff/create/create.t.sol | 4 ++-- 3 files changed, 5 insertions(+), 5 deletions(-) diff --git a/test/unit/sablier-v2-cliff/SablierV2Cliff.t.sol b/test/unit/sablier-v2-cliff/SablierV2Cliff.t.sol index 303339a84..bbf5cc109 100644 --- a/test/unit/sablier-v2-cliff/SablierV2Cliff.t.sol +++ b/test/unit/sablier-v2-cliff/SablierV2Cliff.t.sol @@ -4,7 +4,7 @@ pragma solidity >=0.8.4; import { SablierV2Cliff } from "@sablier/v2-core/SablierV2Cliff.sol"; import { SablierV2CliffUnitTest } from "../SablierV2CliffUnitTest.t.sol"; -contract SablierV2LinearTest is SablierV2CliffUnitTest { +contract SablierV2CliffTest is SablierV2CliffUnitTest { function testConstructor() external { assertEq(sablierV2Cliff.nextStreamId(), 1); } diff --git a/test/unit/sablier-v2-cliff/create-with-duration/createWithDuration.t.sol b/test/unit/sablier-v2-cliff/create-with-duration/createWithDuration.t.sol index 1441cda0b..e3788efb7 100644 --- a/test/unit/sablier-v2-cliff/create-with-duration/createWithDuration.t.sol +++ b/test/unit/sablier-v2-cliff/create-with-duration/createWithDuration.t.sol @@ -18,7 +18,7 @@ contract SablierV2Cliff__CreateWithDuration__UnitTest is SablierV2CliffUnitTest cliffStream.depositAmount, cliffStream.token, duration, - cliffStream.cliffTime, + DEFAULT_CLIFF_DURATION, cliffStream.cancelable ); } @@ -32,7 +32,7 @@ contract SablierV2Cliff__CreateWithDuration__UnitTest is SablierV2CliffUnitTest cliffStream.depositAmount, cliffStream.token, DEFAULT_DURATION, - cliffStream.cliffTime, + DEFAULT_CLIFF_DURATION, cliffStream.cancelable ); ISablierV2Cliff.CliffStream memory createdCliffStream = sablierV2Cliff.getCliffStream(streamId); diff --git a/test/unit/sablier-v2-cliff/create/create.t.sol b/test/unit/sablier-v2-cliff/create/create.t.sol index 78924587a..b5c240d8a 100644 --- a/test/unit/sablier-v2-cliff/create/create.t.sol +++ b/test/unit/sablier-v2-cliff/create/create.t.sol @@ -95,8 +95,8 @@ contract SablierV2Cliff__Create__UnitTest is SablierV2CliffUnitTest { vm.expectRevert( abi.encodeWithSelector( ISablierV2Cliff.SablierV2Cliff__CliffTimeGreaterThanStopTime.selector, - stopTime, - cliffTime + cliffTime, + stopTime ) ); sablierV2Cliff.create(