File tree Expand file tree Collapse file tree 5 files changed +33
-24
lines changed
utils/questions/lesson-4/2-get-set-up Expand file tree Collapse file tree 5 files changed +33
-24
lines changed Original file line number Diff line number Diff line change 2
2
"question" : " Which of the following can we achieve with automated testing?" ,
3
3
"options" : [
4
4
{
5
- "answer" : " bla bla bla. "
5
+ "answer" : " Prove code actually works "
6
6
},
7
7
{
8
- "answer" : " Create a project. "
8
+ "answer" : " Help write more modular code "
9
9
},
10
10
{
11
- "answer" : " Create a smart contract using a code editor."
11
+ "answer" : " Ensure code doesn't break when changes are made"
12
+ },
13
+ {
14
+ "answer" : " Only a) and c)"
12
15
},
13
16
{
14
17
"answer" : " All of the above" ,
Original file line number Diff line number Diff line change 1
1
{
2
- "question" : " When setting up dependencies, what is relevant to our testing environment? " ,
2
+ "question" : " How does the tokenURI function generate the token metadata? " ,
3
3
"options" : [
4
4
{
5
- "answer" : " bla bla bla. "
5
+ "answer" : " By reading from an external file "
6
6
},
7
7
{
8
- "answer" : " It tells npm to save the dependencies in a development environment." ,
8
+ "answer" : " By using a predefined JSON template"
9
+ },
10
+ {
11
+ "answer" : " By dynamically generating SVG image and JSON data" ,
9
12
"correct" : true
10
13
},
11
14
{
12
- "answer" : " It tells npm to save the dependencies in a production environment "
15
+ "answer" : " By querying an off-chain API "
13
16
}
14
17
]
15
18
}
Original file line number Diff line number Diff line change 1
1
{
2
- "question" : " What is the benefit of using Open Zeppelin contracts in smart contract development ?" ,
2
+ "question" : " What should be added to the scripts section of package.json to run tests using Hardhat ?" ,
3
3
"options" : [
4
4
{
5
- "answer" : " They reduce the amount of code we write "
5
+ "answer" : " \" scripts \" : { \" test \" : \" hardhat test \" } "
6
6
},
7
7
{
8
- "answer" : " They provide rigorously audited and safe contracts "
8
+ "answer" : " \" scripts \" : { \" runTests \" : \" hardhat test \" } "
9
9
},
10
10
{
11
- "answer" : " They allow for easier human collaboration and technical interoperability"
11
+ "answer" : " \" scripts\" : { \" test\" : \" hardhat test --network hardhat\" }" ,
12
+ "correct" : true
12
13
},
13
14
{
14
- "answer" : " All of the above" ,
15
- "correct" : true
15
+ "answer" : " \" scripts\" : { \" runTests\" : \" hardhat test --network hardhat\" }"
16
16
}
17
17
]
18
18
}
Original file line number Diff line number Diff line change 1
1
{
2
- "question" : " We will cover this later, but what do you think the purpose of the .gitignore file created by Hardhat is ?" ,
2
+ "question" : " Why should we verify the Solidity version in the hardhat.config.js file?" ,
3
3
"options" : [
4
4
{
5
- "answer" : " To hide your project's dependencies. "
5
+ "answer" : " To check for any updates to the Solidity version "
6
6
},
7
7
{
8
- "answer" : " To store your project's source code in a private Github repository."
8
+ "answer" : " To ensure compatibility with the contract being tested." ,
9
+ "correct" : true
9
10
},
10
11
{
11
- "answer" : " To ensure that certain files not tracked by Git remain untracked" ,
12
- "correct" : true
12
+ "answer" : " a) and b)"
13
+ },
14
+ {
15
+ "answer" : " neither a) nor b)"
13
16
}
14
17
]
15
18
}
Original file line number Diff line number Diff line change 1
1
{
2
- "question" : " What do you think the 'code .' command in your console is going to do? " ,
2
+ "question" : " Which part of the contract do you think will present us with some extra work to do?" ,
3
3
"options" : [
4
4
{
5
- "answer" : " Create an empty file named ProjectNFT.sol. "
5
+ "answer" : " Testing the mint() function, because if the network is down, we won't see the tokens on a marketplace "
6
6
},
7
7
{
8
- "answer" : " Open your code editor" ,
9
- "correct" : true
8
+ "answer" : " Testing constructor() because it inherits from another contract"
10
9
},
11
10
{
12
- "answer" : " Copy the code of your new contract"
11
+ "answer" : " Testing tokenURI() because the SVG file is in the contract and not in a separate .json file" ,
12
+ "correct" : true
13
13
},
14
14
{
15
- "answer" : " Compile your new contract "
15
+ "answer" : " Testing withdraw() because it involves more than one party for a transaction "
16
16
}
17
17
]
18
18
}
You can’t perform that action at this time.
0 commit comments