mirror of
https://github.com/ckaczor/sqltoolsservice.git
synced 2026-01-13 17:23:02 -05:00
2.0 KiB
2.0 KiB
Build the SQL Tools Service
SQL Tools Service depends on .Net Core SDK. Please install .Net Core SDK before building. Please see https://dotnet.github.io for additional information on .Net Core.
- Clone the SQL Tools Service repo from https://github.com/Microsoft/sqltoolsservice.
- Run
dotnet restorefrom the cloned repo's root directory. - Run
dotnet build src/Microsoft.SqlTools.ServiceLayerfrom the cloned repo's root directory.
Tip
there is a
build.cmdorbuild.shfile in the repo's root directory that can be used to build and package the service.
Building the Documentation
The documentation is generated using docfx. Please install docfx from https://dotnet.github.io/docfx/.
- Clone the SQL Tools Service docs repo from https://github.com/Microsoft/sqltoolssdk.
- Run
docfx docfx.json --servefrom the docs directory. - Copy the contents of the docs/_site directory to the root directory of the sqltoolssdk repo.
Run Tests
The SQL Tools Service has several different types of tests such as unit tests, "connected" tests, integration tests, perf tests and stress tests.
Running Unit Tests
- Run
dotnet restorefrom the cloned repo's root directory. - Run
dotnet test test/Microsoft.SqlToosl.ServiceLayer.Testfrom the cloned repo's root directory.
The test output should be similar to the below. There may also be additional debugging output based on test details and execution environment.
xUnit.net .NET CLI test runner (64-bit win10-x64)
Discovering: Microsoft.SqlTools.ServiceLayer.Test
Discovered: Microsoft.SqlTools.ServiceLayer.Test
Starting: Microsoft.SqlTools.ServiceLayer.Test
=== TEST EXECUTION SUMMARY ===
Microsoft.SqlTools.ServiceLayer.Test Total: 434, Errors: 0, Failed: 0, Skipped: 0, Time: 21.139s
SUMMARY: Total: 1 targets, Passed: 1, Failed: 0.