Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
O
openzeppelin-contracts-upgradeable
Overview
Overview
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
俞永鹏
openzeppelin-contracts-upgradeable
Commits
44566ee8
Commit
44566ee8
authored
Aug 04, 2021
by
github-actions
Browse files
Options
Browse Files
Download
Plain Diff
Merge upstream openzeppelin-contracts into upstream-patched
parents
26e7c4f7
f7829430
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
3 additions
and
7 deletions
+3
-7
ERC2771Context.test.js
test/metatx/ERC2771Context.test.js
+2
-6
ERC721.behavior.js
test/token/ERC721/ERC721.behavior.js
+1
-1
No files found.
test/metatx/ERC2771Context.test.js
View file @
44566ee8
...
...
@@ -76,9 +76,7 @@ contract('ERC2771Context', function (accounts) {
};
const
sign
=
ethSigUtil
.
signTypedMessage
(
this
.
wallet
.
getPrivateKey
(),
{
data
:
{
...
this
.
data
,
message
:
req
}
});
// rejected by lint :/
// expect(await this.forwarder.verify(req, sign)).to.be.true;
expect
(
await
this
.
forwarder
.
verify
(
req
,
sign
)).
to
.
equal
(
true
);
const
{
tx
}
=
await
this
.
forwarder
.
execute
(
req
,
sign
);
await
expectEvent
.
inTransaction
(
tx
,
ERC2771ContextMock
,
'Sender'
,
{
sender
:
this
.
sender
});
...
...
@@ -101,9 +99,7 @@ contract('ERC2771Context', function (accounts) {
};
const
sign
=
ethSigUtil
.
signTypedMessage
(
this
.
wallet
.
getPrivateKey
(),
{
data
:
{
...
this
.
data
,
message
:
req
}
});
// rejected by lint :/
// expect(await this.forwarder.verify(req, sign)).to.be.true;
expect
(
await
this
.
forwarder
.
verify
(
req
,
sign
)).
to
.
equal
(
true
);
const
{
tx
}
=
await
this
.
forwarder
.
execute
(
req
,
sign
);
await
expectEvent
.
inTransaction
(
tx
,
ERC2771ContextMock
,
'Data'
,
{
data
,
integerValue
,
stringValue
});
...
...
test/token/ERC721/ERC721.behavior.js
View file @
44566ee8
...
...
@@ -12,6 +12,7 @@ const Error = [ 'None', 'RevertWithMessage', 'RevertWithoutMessage', 'Panic' ]
const
firstTokenId
=
new
BN
(
'5042'
);
const
secondTokenId
=
new
BN
(
'79217'
);
const
nonExistentTokenId
=
new
BN
(
'13'
);
const
fourthTokenId
=
new
BN
(
4
);
const
baseURI
=
'https://api.example.com/v1/'
;
const
RECEIVER_MAGIC_VALUE
=
'0x150b7a02'
;
...
...
@@ -342,7 +343,6 @@ function shouldBehaveLikeERC721 (errorPrefix, owner, newOwner, approved, another
});
describe
(
'safe mint'
,
function
()
{
const
fourthTokenId
=
new
BN
(
4
);
const
tokenId
=
fourthTokenId
;
const
data
=
'0x42'
;
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment