-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
1 parent
c0095da
commit 699931a
Showing
2 changed files
with
17 additions
and
15 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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,11 +1,17 @@ | ||
import StakingRewardsModule, { REWARDS_DURATION } from '../ignition/modules/StakingRewards'; | ||
import StakingRewardsModule, { OWNER, REWARDS_DISTRIBUTION, REWARDS_TOKEN, STAKING_TOKEN } from '../ignition/modules/StakingRewards'; | ||
import hre from 'hardhat'; | ||
import { expect } from 'chai'; | ||
|
||
describe('Deployment', function () { | ||
it('Should set the rewards duration', async function () { | ||
it('Should deploy with constructor params', async function () { | ||
const { stakingRewards } = await hre.ignition.deploy(StakingRewardsModule); | ||
const rewardsDuration: bigint = await stakingRewards.read.rewardsDuration(); | ||
expect(rewardsDuration).to.equal(REWARDS_DURATION); | ||
const owner = await stakingRewards.read.owner(); | ||
const rewardsDistribution = await stakingRewards.read.rewardsDistribution(); | ||
const rewardsToken = await stakingRewards.read.rewardsToken(); | ||
const stakingToken = await stakingRewards.read.stakingToken(); | ||
expect(owner).to.equal(OWNER); | ||
expect(rewardsDistribution).to.equal(REWARDS_DISTRIBUTION); | ||
expect(rewardsToken).to.equal(REWARDS_TOKEN); | ||
expect(stakingToken).to.equal(STAKING_TOKEN); | ||
}); | ||
}); |