Skip to content

Commit

Permalink
skip test and explain why its skipped. deploy safEth strategy for tests
Browse files Browse the repository at this point in the history
  • Loading branch information
elmutt committed Jul 24, 2023
1 parent 18580c4 commit 123d8ce
Show file tree
Hide file tree
Showing 5 changed files with 30 additions and 5 deletions.
1 change: 1 addition & 0 deletions package.json
Original file line number Diff line number Diff line change
Expand Up @@ -79,6 +79,7 @@
"@openzeppelin/contracts-upgradeable": "^4.8.1",
"@openzeppelin/hardhat-defender": "^1.8.2",
"@openzeppelin/hardhat-upgrades": "^1.17.0",
"axios": "^1.4.0",
"discord.js": "^14.9.0"
}
}
7 changes: 5 additions & 2 deletions test/other_tests/SellVotiumRewards.test.ts
Original file line number Diff line number Diff line change
Expand Up @@ -4,8 +4,11 @@ import axios from "axios";
import ERC20 from "@openzeppelin/contracts/build/contracts/ERC20.json";
import { expect } from "chai";

// TODO move this into votium strategy test
describe("Sell Votium Rewards", async function () {
// TODO
// figure out some way to always use latest block but also use a valid token whale for that block
// this test is skipped because its always breaking because the whales are changing
// also move it into votium strategy test (once its working consistently)
describe.skip("Sell Votium Rewards", async function () {
let votiumStrategy: any;

// mapping of token address to whale address
Expand Down
1 change: 1 addition & 0 deletions test/other_tests/VotiumMock.test.ts
Original file line number Diff line number Diff line change
Expand Up @@ -3,6 +3,7 @@ import { VotiumPosition } from "../typechain-types";
import ERC20 from "@openzeppelin/contracts/build/contracts/ERC20.json";
import { expect } from "chai";
import axios from "axios";

describe("VotiumPosition", async function () {
let votiumMockForked: VotiumPosition; // existing mock from forked mainnet

Expand Down
21 changes: 19 additions & 2 deletions test/strategies/SafEth.test.ts
Original file line number Diff line number Diff line change
@@ -1,5 +1,22 @@
describe("Test SafEth Strategy", async function () {
it("Should test some things (TODO)", async function () {
import { SafEthStrategy } from "../../typechain-types";
import { ethers, upgrades } from "hardhat";
describe("Test SafEth Strategy Specific Functionality", async function () {
let safEthStrategy: SafEthStrategy;
before(async () => {
const safEthStrategyFactory = await ethers.getContractFactory(
"SafEthStrategy"
);
safEthStrategy = (await upgrades.deployProxy(
safEthStrategyFactory
)) as SafEthStrategy;
await safEthStrategy.deployed();
});

it("Should mint() and be able to immediately requestClose() and burn() the position", async function () {
// TODO
});

it("Should be able to call claimRewards() but have no effect because safEth rewards are received upon burning", async function () {
// TODO
});
});
5 changes: 4 additions & 1 deletion test/strategies/VotiumStrategy.test.ts
Original file line number Diff line number Diff line change
@@ -1,4 +1,7 @@
describe("Test Votium Strategy", async function () {
// Votium tests are hard for 2 reasons:
// 1) they require 2 types of oracle updates -- once a week to relock cvx and another every 2 weeks to claim rewards
// 2) We may need to impersonate accounts to update the merkle root and generate/simulate our own reward merkle proofs
describe("Test Votium Strategy Specific Functionality", async function () {
it("Should test some things (TODO)", async function () {
// TODO
});
Expand Down

0 comments on commit 123d8ce

Please sign in to comment.