Use hardhat-exposed to reduce the need for mocks (#3666)
Co-authored-by: Francisco <fg@frang.io>
This commit is contained in:
@ -1,12 +1,14 @@
|
||||
const {
|
||||
DEFAULT_ADMIN_ROLE,
|
||||
shouldBehaveLikeAccessControl,
|
||||
} = require('./AccessControl.behavior.js');
|
||||
|
||||
const AccessControlMock = artifacts.require('AccessControlMock');
|
||||
const AccessControl = artifacts.require('$AccessControl');
|
||||
|
||||
contract('AccessControl', function (accounts) {
|
||||
beforeEach(async function () {
|
||||
this.accessControl = await AccessControlMock.new({ from: accounts[0] });
|
||||
this.accessControl = await AccessControl.new({ from: accounts[0] });
|
||||
await this.accessControl.$_grantRole(DEFAULT_ADMIN_ROLE, accounts[0]);
|
||||
});
|
||||
|
||||
shouldBehaveLikeAccessControl('AccessControl', ...accounts);
|
||||
|
||||
Reference in New Issue
Block a user