A RetroSearch Logo

Home - News ( United States | United Kingdom | Italy | Germany ) - Football scores

Search Query:

Showing content from https://github.com/MeadowSuite/Meadow/wiki/Using-the-VSCode-Solidity-Debugger below:

Using the VSCode Solidity Debugger · MeadowSuite/Meadow Wiki · GitHub

Debugging using only Solidity Option 1) Debug a single .sol file containing a single contract Option 2) Debug Solidity codebases with multiple contracts Debugging using Unit Tests Setup a unit test project

First, follow the quick guide to setting up a Solidity test project using Meadow.

Install the C# Extension for VSCode

https://marketplace.visualstudio.com/items?itemName=ms-vscode.csharp

  1. Open your project in VSCode and select the debug panel (located on the left vertical menu bar).
  2. At the top left debug dropdown (next to the green play button), select "Add Configuration..."
  3. Inside the .vscode/launch.json file, add the following configuration:
{
    "version": "0.2.0",
    "configurations": [
        {
            "type": "solidityMeadow",
            "request": "launch",
            "name": "Debug Solidity (via unit test run)"
        }
    ]
}

Open a .sol source file from your contracts directory and set breakpoints in a function that gets executed by your C# unit tests.

Select the debug panel again, ensure the correct configuration is selected, and click the green play button.

The unit tests will be executed and your breakpoint will be hit.


RetroSearch is an open source project built by @garambo | Open a GitHub Issue

Search and Browse the WWW like it's 1997 | Search results from DuckDuckGo

HTML: 3.2 | Encoding: UTF-8 | Version: 0.7.4