Skip to content

Commit

Permalink
Switch openzeppelin package we target to newly introduced one
Browse files Browse the repository at this point in the history
Small fixes to test contracts
  • Loading branch information
elenadimitrova committed Jun 3, 2020
1 parent 5c4cf40 commit 9994690
Show file tree
Hide file tree
Showing 10 changed files with 18 additions and 18 deletions.
2 changes: 1 addition & 1 deletion contracts-test/KyberNetworkTest.sol
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
pragma solidity ^0.6.8;
import "../lib/other/ERC20.sol";
import "../lib/other/KyberNetwork.sol";
import "openzeppelin-solidity/contracts/math/SafeMath.sol";
import "@openzeppelin/contracts/math/SafeMath.sol";

// SPDX-License-Identifier: GPL-3.0-only
contract KyberNetworkTest is KyberNetwork {
Expand Down
2 changes: 1 addition & 1 deletion contracts-test/LegacyBaseWallet.sol
Original file line number Diff line number Diff line change
Expand Up @@ -24,7 +24,7 @@ pragma solidity ^0.6.8;

/**
* @dev Utility method to recover any ERC20 token that was sent to the
* module by mistake.
* contract by mistake.
* @param _token The token to recover.
*/
function recoverToken(address _token) external;
Expand Down
2 changes: 1 addition & 1 deletion contracts-test/TestContract.sol
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
// SPDX-License-Identifier: GPL-3.0-only
pragma solidity ^0.6.8;
import "./TokenConsumer.sol";
import "openzeppelin-solidity/contracts/token/ERC20/ERC20.sol";
import "@openzeppelin/contracts/token/ERC20/ERC20.sol";

/**
* @title TestContract
Expand Down
10 changes: 5 additions & 5 deletions contracts-test/TestERC20.sol
Original file line number Diff line number Diff line change
@@ -1,24 +1,24 @@
// SPDX-License-Identifier: GPL-3.0-only
pragma solidity ^0.6.8;

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

/**
* ERC20 test contract.
*/
contract TestERC20 is ERC20("ArgentToken", "AGT") {
constructor (address[] memory _initialAccounts, uint _supply, uint8 _decimals) public {
super._setupDecimals(_decimals);
_setupDecimals(_decimals);
for (uint i = 0; i < _initialAccounts.length; i++) {
super._mint(_initialAccounts[i], _supply * 10**uint(_decimals));
_mint(_initialAccounts[i], _supply * 10**uint(_decimals));
}
}

function mint(address account, uint256 amount) public {
super._mint(account, amount);
_mint(account, amount);
}

function burn(address account, uint256 amount) public {
super._burn(account, amount);
_burn(account, amount);
}
}
2 changes: 1 addition & 1 deletion contracts-test/TestERC721.sol
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
// SPDX-License-Identifier: GPL-3.0-only
pragma solidity ^0.6.8;

import "openzeppelin-solidity/contracts/token/ERC721/ERC721.sol";
import "@openzeppelin/contracts/token/ERC721/ERC721.sol";

contract TestERC721 is ERC721 {
constructor() ERC721("Argent Kitties", "AGKT") public {
Expand Down
2 changes: 1 addition & 1 deletion contracts-test/TokenConsumer.sol
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
// SPDX-License-Identifier: GPL-3.0-only
pragma solidity ^0.6.8;

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

contract TokenConsumer {

Expand Down
2 changes: 1 addition & 1 deletion contracts/modules/common/BaseModule.sol
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,7 @@
// SPDX-License-Identifier: GPL-3.0-only
pragma solidity ^0.6.8;

import "openzeppelin-solidity/contracts/math/SafeMath.sol";
import "@openzeppelin/contracts/math/SafeMath.sol";
import "../../wallet/BaseWallet.sol";
import "../../infrastructure/IModuleRegistry.sol";
import "../storage/GuardianStorage.sol";
Expand Down
2 changes: 1 addition & 1 deletion contracts/modules/common/TokenPriceProvider.sol
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,7 @@

// SPDX-License-Identifier: GPL-3.0-only
pragma solidity ^0.6.8;
import "openzeppelin-solidity/contracts/math/SafeMath.sol";
import "@openzeppelin/contracts/math/SafeMath.sol";
import "../../../lib/other/ERC20.sol";
import "../../infrastructure/base/Managed.sol";

Expand Down
10 changes: 5 additions & 5 deletions package-lock.json

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

2 changes: 1 addition & 1 deletion package.json
Original file line number Diff line number Diff line change
Expand Up @@ -45,6 +45,7 @@
},
"homepage": "https://github.com/argentlabs/argent-contracts#readme",
"dependencies": {
"@openzeppelin/contracts": "3.0.1",
"ajv": "^6.10.0",
"aws-sdk": "^2.521.0",
"bip39": "^3.0.2",
Expand All @@ -61,7 +62,6 @@
"inquirer": "^7.0.0",
"istanbul": "^0.4.5",
"node-fetch": "^2.3.0",
"openzeppelin-solidity": "3.0.1",
"ps-node": "^0.1.6",
"semver": "^7.1.3",
"solc": "0.6.8",
Expand Down

0 comments on commit 9994690

Please sign in to comment.