Skip to content

Commit

Permalink
fixed code block style
Browse files Browse the repository at this point in the history
  • Loading branch information
ingridnovak committed May 19, 2024
1 parent 4023eb8 commit 00c5862
Showing 1 changed file with 4 additions and 5 deletions.
9 changes: 4 additions & 5 deletions versioned_docs/version-1/spark/writing-tests.md
Original file line number Diff line number Diff line change
Expand Up @@ -71,11 +71,10 @@ A good practice is to use the pattern `test_Revert[If|When]_Condition` in combin

Now, instead of using `testFail`, you know exactly what reverted and with which error:

```solidity
function test_CannotSubtract43() public {
vm.expectRevert(stdError.arithmeticError);
testNumber -= 43;

```solidity
function test_CannotSubtract43() public {
vm.expectRevert(stdError.arithmeticError);
testNumber -= 43;
}
```
 
Expand Down

0 comments on commit 00c5862

Please sign in to comment.