Skip to content

Commit a0448b5

Browse files
authored
Update to OZ Contracts 4.8 (#199)
1 parent f0ee5fc commit a0448b5

18 files changed

+117
-111
lines changed

packages/core/hardhat.config.js

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -43,5 +43,5 @@ task(TASK_COMPILE_SOLIDITY_MERGE_COMPILATION_JOBS, async ({ compilationJobs }, _
4343
* @type import('hardhat/config').HardhatUserConfig
4444
*/
4545
module.exports = {
46-
solidity: '0.8.4',
46+
solidity: '0.8.9',
4747
};

packages/core/package.json

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -19,8 +19,8 @@
1919
"version": "node ../../scripts/bump-changelog.js"
2020
},
2121
"devDependencies": {
22-
"@openzeppelin/contracts": "4.7.3",
23-
"@openzeppelin/contracts-upgradeable": "4.7.3",
22+
"@openzeppelin/contracts": "4.8.0",
23+
"@openzeppelin/contracts-upgradeable": "4.8.0",
2424
"@types/node": "^10.17.51",
2525
"@types/rimraf": "^3.0.0",
2626
"array.prototype.flat": "^1.2.4",

packages/core/src/contract.test.ts.md

Lines changed: 19 additions & 19 deletions
Original file line numberDiff line numberDiff line change
@@ -9,7 +9,7 @@ Generated by [AVA](https://avajs.dev).
99
> Snapshot 1
1010
1111
`// SPDX-License-Identifier: MIT␊
12-
pragma solidity ^0.8.4;␊
12+
pragma solidity ^0.8.9;␊
1313
1414
contract Foo {␊
1515
}␊
@@ -20,7 +20,7 @@ Generated by [AVA](https://avajs.dev).
2020
> Snapshot 1
2121
2222
`// SPDX-License-Identifier: MIT␊
23-
pragma solidity ^0.8.4;␊
23+
pragma solidity ^0.8.9;␊
2424
2525
import "./Bar.sol";␊
2626
@@ -33,7 +33,7 @@ Generated by [AVA](https://avajs.dev).
3333
> Snapshot 1
3434
3535
`// SPDX-License-Identifier: MIT␊
36-
pragma solidity ^0.8.4;␊
36+
pragma solidity ^0.8.9;␊
3737
3838
import "./Bar.sol";␊
3939
import "./Quux.sol";␊
@@ -47,7 +47,7 @@ Generated by [AVA](https://avajs.dev).
4747
> Snapshot 1
4848
4949
`// SPDX-License-Identifier: MIT␊
50-
pragma solidity ^0.8.4;␊
50+
pragma solidity ^0.8.9;␊
5151
5252
import "./Bar.sol";␊
5353
@@ -61,7 +61,7 @@ Generated by [AVA](https://avajs.dev).
6161
> Snapshot 1
6262
6363
`// SPDX-License-Identifier: MIT␊
64-
pragma solidity ^0.8.4;␊
64+
pragma solidity ^0.8.9;␊
6565
6666
import "./Bar.sol";␊
6767
import "./Quux.sol";␊
@@ -76,7 +76,7 @@ Generated by [AVA](https://avajs.dev).
7676
> Snapshot 1
7777
7878
`// SPDX-License-Identifier: MIT␊
79-
pragma solidity ^0.8.4;␊
79+
pragma solidity ^0.8.9;␊
8080
8181
contract Foo {␊
8282
}␊
@@ -87,7 +87,7 @@ Generated by [AVA](https://avajs.dev).
8787
> Snapshot 1
8888
8989
`// SPDX-License-Identifier: MIT␊
90-
pragma solidity ^0.8.4;␊
90+
pragma solidity ^0.8.9;␊
9191
9292
contract Foo {␊
9393
// The following functions are overrides required by Solidity.␊
@@ -106,7 +106,7 @@ Generated by [AVA](https://avajs.dev).
106106
> Snapshot 1
107107
108108
`// SPDX-License-Identifier: MIT␊
109-
pragma solidity ^0.8.4;␊
109+
pragma solidity ^0.8.9;␊
110110
111111
contract Foo {␊
112112
// The following functions are overrides required by Solidity.␊
@@ -129,7 +129,7 @@ Generated by [AVA](https://avajs.dev).
129129
> Snapshot 1
130130
131131
`// SPDX-License-Identifier: MIT␊
132-
pragma solidity ^0.8.4;␊
132+
pragma solidity ^0.8.9;␊
133133
134134
contract Foo {␊
135135
function _otherFunction() internal whenNotPaused {}␊
@@ -141,7 +141,7 @@ Generated by [AVA](https://avajs.dev).
141141
> Snapshot 1
142142
143143
`// SPDX-License-Identifier: MIT␊
144-
pragma solidity ^0.8.4;␊
144+
pragma solidity ^0.8.9;␊
145145
146146
contract Foo {␊
147147
function _otherFunction() internal whenNotPaused override(ERC20, OtherParent) {␊
@@ -155,7 +155,7 @@ Generated by [AVA](https://avajs.dev).
155155
> Snapshot 1
156156
157157
`// SPDX-License-Identifier: MIT␊
158-
pragma solidity ^0.8.4;␊
158+
pragma solidity ^0.8.9;␊
159159
160160
contract Foo {␊
161161
constructor() {␊
@@ -169,7 +169,7 @@ Generated by [AVA](https://avajs.dev).
169169
> Snapshot 1
170170
171171
`// SPDX-License-Identifier: MIT␊
172-
pragma solidity ^0.8.4;␊
172+
pragma solidity ^0.8.9;␊
173173
174174
import "./Bar.sol";␊
175175
@@ -185,7 +185,7 @@ Generated by [AVA](https://avajs.dev).
185185
> Snapshot 1
186186
187187
`// SPDX-License-Identifier: MIT␊
188-
pragma solidity ^0.8.4;␊
188+
pragma solidity ^0.8.9;␊
189189
190190
contract Foo {␊
191191
function _otherFunction() internal {␊
@@ -199,7 +199,7 @@ Generated by [AVA](https://avajs.dev).
199199
> Snapshot 1
200200
201201
`// SPDX-License-Identifier: MIT␊
202-
pragma solidity ^0.8.4;␊
202+
pragma solidity ^0.8.9;␊
203203
204204
contract Foo {␊
205205
function _otherFunction() internal override {␊
@@ -214,7 +214,7 @@ Generated by [AVA](https://avajs.dev).
214214
> Snapshot 1
215215
216216
`// SPDX-License-Identifier: MIT␊
217-
pragma solidity ^0.8.4;␊
217+
pragma solidity ^0.8.9;␊
218218
219219
contract Foo {␊
220220
uint value = 42;␊
@@ -226,7 +226,7 @@ Generated by [AVA](https://avajs.dev).
226226
> Snapshot 1
227227
228228
`// SPDX-License-Identifier: MIT␊
229-
pragma solidity ^0.8.4;␊
229+
pragma solidity ^0.8.9;␊
230230
231231
contract Foo {␊
232232
uint value = 42;␊
@@ -239,7 +239,7 @@ Generated by [AVA](https://avajs.dev).
239239
> Snapshot 1
240240
241241
`// SPDX-License-Identifier: MIT␊
242-
pragma solidity ^0.8.4;␊
242+
pragma solidity ^0.8.9;␊
243243
244244
contract FooBarBaz {␊
245245
}␊
@@ -250,7 +250,7 @@ Generated by [AVA](https://avajs.dev).
250250
> Snapshot 1
251251
252252
`// SPDX-License-Identifier: MIT␊
253-
pragma solidity ^0.8.4;␊
253+
pragma solidity ^0.8.9;␊
254254
255255
import "./Counters.sol";␊
256256
@@ -264,7 +264,7 @@ Generated by [AVA](https://avajs.dev).
264264
> Snapshot 1
265265
266266
`// SPDX-License-Identifier: MIT␊
267-
pragma solidity ^0.8.4;␊
267+
pragma solidity ^0.8.9;␊
268268
269269
/// @custom:security-contact [email protected]
270270
contract Foo {␊
0 Bytes
Binary file not shown.

packages/core/src/custom.test.ts.md

Lines changed: 8 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -9,7 +9,7 @@ Generated by [AVA](https://avajs.dev).
99
> Snapshot 1
1010
1111
`// SPDX-License-Identifier: MIT␊
12-
pragma solidity ^0.8.4;␊
12+
pragma solidity ^0.8.9;␊
1313
1414
contract MyContract {␊
1515
}␊
@@ -20,7 +20,7 @@ Generated by [AVA](https://avajs.dev).
2020
> Snapshot 1
2121
2222
`// SPDX-License-Identifier: MIT␊
23-
pragma solidity ^0.8.4;␊
23+
pragma solidity ^0.8.9;␊
2424
2525
import "@openzeppelin/contracts/security/Pausable.sol";␊
2626
import "@openzeppelin/contracts/access/Ownable.sol";␊
@@ -41,7 +41,7 @@ Generated by [AVA](https://avajs.dev).
4141
> Snapshot 1
4242
4343
`// SPDX-License-Identifier: MIT␊
44-
pragma solidity ^0.8.4;␊
44+
pragma solidity ^0.8.9;␊
4545
4646
import "@openzeppelin/contracts-upgradeable/proxy/utils/Initializable.sol";␊
4747
@@ -58,7 +58,7 @@ Generated by [AVA](https://avajs.dev).
5858
> Snapshot 1
5959
6060
`// SPDX-License-Identifier: MIT␊
61-
pragma solidity ^0.8.4;␊
61+
pragma solidity ^0.8.9;␊
6262
6363
import "@openzeppelin/contracts-upgradeable/proxy/utils/Initializable.sol";␊
6464
import "@openzeppelin/contracts-upgradeable/access/OwnableUpgradeable.sol";␊
@@ -88,7 +88,7 @@ Generated by [AVA](https://avajs.dev).
8888
> Snapshot 1
8989
9090
`// SPDX-License-Identifier: MIT␊
91-
pragma solidity ^0.8.4;␊
91+
pragma solidity ^0.8.9;␊
9292
9393
contract MyContract {␊
9494
}␊
@@ -99,7 +99,7 @@ Generated by [AVA](https://avajs.dev).
9999
> Snapshot 1
100100
101101
`// SPDX-License-Identifier: MIT␊
102-
pragma solidity ^0.8.4;␊
102+
pragma solidity ^0.8.9;␊
103103
104104
import "@openzeppelin/contracts/access/Ownable.sol";␊
105105
@@ -112,7 +112,7 @@ Generated by [AVA](https://avajs.dev).
112112
> Snapshot 1
113113
114114
`// SPDX-License-Identifier: MIT␊
115-
pragma solidity ^0.8.4;␊
115+
pragma solidity ^0.8.9;␊
116116
117117
import "@openzeppelin/contracts/access/AccessControl.sol";␊
118118
@@ -128,7 +128,7 @@ Generated by [AVA](https://avajs.dev).
128128
> Snapshot 1
129129
130130
`// SPDX-License-Identifier: MIT␊
131-
pragma solidity ^0.8.4;␊
131+
pragma solidity ^0.8.9;␊
132132
133133
import "@openzeppelin/contracts-upgradeable/proxy/utils/Initializable.sol";␊
134134
import "@openzeppelin/contracts-upgradeable/access/OwnableUpgradeable.sol";␊
-1 Bytes
Binary file not shown.

packages/core/src/erc1155.test.ts.md

Lines changed: 10 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -9,7 +9,7 @@ Generated by [AVA](https://avajs.dev).
99
> Snapshot 1
1010
1111
`// SPDX-License-Identifier: MIT␊
12-
pragma solidity ^0.8.4;␊
12+
pragma solidity ^0.8.9;␊
1313
1414
import "@openzeppelin/contracts/token/ERC1155/ERC1155.sol";␊
1515
import "@openzeppelin/contracts/access/Ownable.sol";␊
@@ -30,7 +30,7 @@ Generated by [AVA](https://avajs.dev).
3030
> Snapshot 1
3131
3232
`// SPDX-License-Identifier: MIT␊
33-
pragma solidity ^0.8.4;␊
33+
pragma solidity ^0.8.9;␊
3434
3535
import "@openzeppelin/contracts/token/ERC1155/ERC1155.sol";␊
3636
import "@openzeppelin/contracts/access/AccessControl.sol";␊
@@ -67,7 +67,7 @@ Generated by [AVA](https://avajs.dev).
6767
> Snapshot 1
6868
6969
`// SPDX-License-Identifier: MIT␊
70-
pragma solidity ^0.8.4;␊
70+
pragma solidity ^0.8.9;␊
7171
7272
import "@openzeppelin/contracts/token/ERC1155/ERC1155.sol";␊
7373
@@ -83,7 +83,7 @@ Generated by [AVA](https://avajs.dev).
8383
> Snapshot 1
8484
8585
`// SPDX-License-Identifier: MIT␊
86-
pragma solidity ^0.8.4;␊
86+
pragma solidity ^0.8.9;␊
8787
8888
import "@openzeppelin/contracts/token/ERC1155/ERC1155.sol";␊
8989
import "@openzeppelin/contracts/access/Ownable.sol";␊
@@ -105,7 +105,7 @@ Generated by [AVA](https://avajs.dev).
105105
> Snapshot 1
106106
107107
`// SPDX-License-Identifier: MIT␊
108-
pragma solidity ^0.8.4;␊
108+
pragma solidity ^0.8.9;␊
109109
110110
import "@openzeppelin/contracts/token/ERC1155/ERC1155.sol";␊
111111
import "@openzeppelin/contracts/access/Ownable.sol";␊
@@ -143,7 +143,7 @@ Generated by [AVA](https://avajs.dev).
143143
> Snapshot 1
144144
145145
`// SPDX-License-Identifier: MIT␊
146-
pragma solidity ^0.8.4;␊
146+
pragma solidity ^0.8.9;␊
147147
148148
import "@openzeppelin/contracts/token/ERC1155/ERC1155.sol";␊
149149
import "@openzeppelin/contracts/access/Ownable.sol";␊
@@ -178,7 +178,7 @@ Generated by [AVA](https://avajs.dev).
178178
> Snapshot 1
179179
180180
`// SPDX-License-Identifier: MIT␊
181-
pragma solidity ^0.8.4;␊
181+
pragma solidity ^0.8.9;␊
182182
183183
import "@openzeppelin/contracts/token/ERC1155/ERC1155.sol";␊
184184
import "@openzeppelin/contracts/access/AccessControl.sol";␊
@@ -231,7 +231,7 @@ Generated by [AVA](https://avajs.dev).
231231
> Snapshot 1
232232
233233
`// SPDX-License-Identifier: MIT␊
234-
pragma solidity ^0.8.4;␊
234+
pragma solidity ^0.8.9;␊
235235
236236
import "@openzeppelin/contracts/token/ERC1155/ERC1155.sol";␊
237237
import "@openzeppelin/contracts/access/Ownable.sol";␊
@@ -262,7 +262,7 @@ Generated by [AVA](https://avajs.dev).
262262
> Snapshot 1
263263
264264
`// SPDX-License-Identifier: MIT␊
265-
pragma solidity ^0.8.4;␊
265+
pragma solidity ^0.8.9;␊
266266
267267
import "@openzeppelin/contracts-upgradeable/token/ERC1155/ERC1155Upgradeable.sol";␊
268268
import "@openzeppelin/contracts-upgradeable/access/AccessControlUpgradeable.sol";␊
@@ -344,7 +344,7 @@ Generated by [AVA](https://avajs.dev).
344344
> Snapshot 1
345345
346346
`// SPDX-License-Identifier: MIT␊
347-
pragma solidity ^0.8.4;␊
347+
pragma solidity ^0.8.9;␊
348348
349349
import "@openzeppelin/contracts-upgradeable/token/ERC1155/ERC1155Upgradeable.sol";␊
350350
import "@openzeppelin/contracts-upgradeable/access/AccessControlUpgradeable.sol";␊
0 Bytes
Binary file not shown.

0 commit comments

Comments
 (0)