Skip to content

Commit

Permalink
test: fix some tests with non-standard values
Browse files Browse the repository at this point in the history
  • Loading branch information
b00ste committed Aug 15, 2023
1 parent 75d4edd commit 052f4ed
Show file tree
Hide file tree
Showing 5 changed files with 6 additions and 6 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -552,7 +552,7 @@ export const shouldBehaveLikePermissionChangeOrAddExtensions = (
],
dataValues: [
extensionB,
ethers.utils.hexZeroPad(ethers.utils.hexlify(8), 32),
ethers.utils.hexZeroPad(ethers.utils.hexlify(8), 16),
'0xaabb',
],
};
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -590,7 +590,7 @@ export const shouldBehaveLikePermissionChangeOrAddController = (

const newLength = ethers.BigNumber.from(currentLength).sub(1).toNumber();

const value = ethers.utils.hexZeroPad(ethers.utils.hexlify(newLength), 32);
const value = ethers.utils.hexZeroPad(ethers.utils.hexlify(newLength), 16);

await context.universalProfile.connect(canOnlyEditPermissions).setData(key, value);

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -684,7 +684,7 @@ export const shouldBehaveLikePermissionChangeOrAddExtensions = (
],
dataValues: [
extensionB,
ethers.utils.hexZeroPad(ethers.utils.hexlify(8), 32),
ethers.utils.hexZeroPad(ethers.utils.hexlify(8), 16),
'0xaabb',
],
};
Expand Down
4 changes: 2 additions & 2 deletions tests/LSP6KeyManager/LSP6ControlledToken.test.ts
Original file line number Diff line number Diff line change
Expand Up @@ -431,7 +431,7 @@ describe('When deploying LSP7 with LSP6 as owner', () => {
const key =
ERC725YDataKeys.LSP6['AddressPermissions:Permissions'] +
addressCanSetData.address.substring(2);
const value = ARRAY_LENGTH.ZERO;
const value = '0x';
const payload = context.token.interface.encodeFunctionData('setData', [key, value]);

await expect(context.keyManager.connect(addressCanAddController).execute(payload))
Expand All @@ -443,7 +443,7 @@ describe('When deploying LSP7 with LSP6 as owner', () => {
const key =
ERC725YDataKeys.LSP6['AddressPermissions:Permissions'] +
addressCanSetData.address.substring(2);
const value = ARRAY_LENGTH.ZERO;
const value = '0x';
const payload = context.token.interface.encodeFunctionData('setData', [key, value]);

await context.keyManager.connect(context.owner).execute(payload);
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -698,7 +698,7 @@ export const shouldBehaveLikePermissionChangeOrAddController = (

const newLength = ethers.BigNumber.from(currentLength).sub(1).toNumber();

const value = ethers.utils.hexZeroPad(ethers.utils.hexlify(newLength), 32);
const value = ethers.utils.hexZeroPad(ethers.utils.hexlify(newLength), 16);

const payload = context.universalProfile.interface.encodeFunctionData('setData', [
key,
Expand Down

0 comments on commit 052f4ed

Please sign in to comment.