Skip to content

Commit

Permalink
Rename mock tokens
Browse files Browse the repository at this point in the history
  • Loading branch information
pawurb committed Aug 25, 2023
1 parent 12925e2 commit 93a9db5
Show file tree
Hide file tree
Showing 4 changed files with 12 additions and 12 deletions.
4 changes: 2 additions & 2 deletions contracts/MockTokenA.sol → contracts/MockERC20A.sol
Original file line number Diff line number Diff line change
Expand Up @@ -4,8 +4,8 @@ pragma solidity 0.8.17;

import "@openzeppelin/contracts/token/ERC20/ERC20.sol";

contract MockTokenA is ERC20 {
constructor() ERC20("Mock Token A", "MTA") {
contract MockERC20A is ERC20 {
constructor() ERC20("Mock ERC20 A", "MTA") {
_mint(msg.sender, 1000);
}
}
4 changes: 2 additions & 2 deletions contracts/MockETHTokenB.sol → contracts/MockERC20B.sol
Original file line number Diff line number Diff line change
Expand Up @@ -4,8 +4,8 @@ pragma solidity 0.8.17;

import "@openzeppelin/contracts/token/ERC20/ERC20.sol";

contract MockETHTokenB is ERC20 {
constructor() ERC20("Mock ETH Token B", "ETH") {
contract MockERC20B is ERC20 {
constructor() ERC20("Mock ERC20 B", "MTB") {
_mint(msg.sender, 2000);
}
}
8 changes: 4 additions & 4 deletions test/ERC20LockerPrivTest.ts
Original file line number Diff line number Diff line change
Expand Up @@ -30,13 +30,13 @@ describe("ERC20LockerPriv", () => {

const PriceFeedMock = await ethers.getContractFactory(opts.priceFeedContract);
const ERC20LockerPriv = await ethers.getContractFactory("ERC20LockerPriv");
const MockTokenA = await ethers.getContractFactory("MockTokenA");
const MockETHTokenB = await ethers.getContractFactory("MockETHTokenB");
const MockERC20A = await ethers.getContractFactory("MockERC20A");
const MockERC20B = await ethers.getContractFactory("MockERC20B");

priceFeed = await PriceFeedMock.deploy(opts.currentPrice * 10e7)
locker = await ERC20LockerPriv.deploy()
tokenA = await MockTokenA.connect(notOwner).deploy()
tokenETH = await MockETHTokenB.connect(notOwner).deploy()
tokenA = await MockERC20A.connect(notOwner).deploy()
tokenETH = await MockERC20B.connect(notOwner).deploy()
}

beforeEach(async () => {
Expand Down
8 changes: 4 additions & 4 deletions test/ERC20LockerTest.ts
Original file line number Diff line number Diff line change
Expand Up @@ -30,13 +30,13 @@ describe("ERC20Locker", () => {

const PriceFeedMock = await ethers.getContractFactory(opts.priceFeedContract);
const ERC20Locker = await ethers.getContractFactory("ERC20Locker");
const MockTokenA = await ethers.getContractFactory("MockTokenA");
const MockETHTokenB = await ethers.getContractFactory("MockETHTokenB");
const MockERC20A = await ethers.getContractFactory("MockERC20A");
const MockERC20B = await ethers.getContractFactory("MockERC20B");

priceFeed = await PriceFeedMock.deploy(opts.currentPrice * 10e7)
locker = await ERC20Locker.deploy()
tokenA = await MockTokenA.deploy()
tokenETH = await MockETHTokenB.deploy()
tokenA = await MockERC20A.deploy()
tokenETH = await MockERC20B.deploy()
}

beforeEach(async () => {
Expand Down

0 comments on commit 93a9db5

Please sign in to comment.