Changes suggested in the PR discussions

This commit is contained in:
Hadrien Croubois
2023-07-13 11:00:11 +02:00
parent 4c25b48803
commit 20048ca3b9
15 changed files with 75 additions and 98 deletions

View File

@ -524,14 +524,6 @@ function shouldBehaveLikeERC721(owner, newOwner, approved, anotherApproved, oper
});
});
context('when the address that receives the approval is the owner', function () {
it('reverts', async function () {
await expectRevertCustomError(this.token.approve(owner, tokenId, { from: owner }), 'ERC721InvalidOperator', [
owner,
]);
});
});
context('when the sender does not own the given token ID', function () {
it('reverts', async function () {
await expectRevertCustomError(
@ -644,16 +636,6 @@ function shouldBehaveLikeERC721(owner, newOwner, approved, anotherApproved, oper
});
});
});
context('when the operator is the owner', function () {
it('reverts', async function () {
await expectRevertCustomError(
this.token.setApprovalForAll(owner, true, { from: owner }),
'ERC721InvalidOperator',
[owner],
);
});
});
});
describe('getApproved', async function () {