https://github.com/testcontainers/tc-guide-getting-started-with-testcontainers-for-dotnet
https://github.com/testcontainers/tc-guide-getting-started-with-testcontainers-for-dotnet
Last synced: 3 months ago
JSON representation
- Host: GitHub
- URL: https://github.com/testcontainers/tc-guide-getting-started-with-testcontainers-for-dotnet
- Owner: testcontainers
- License: mit
- Created: 2023-05-02T05:31:08.000Z (about 2 years ago)
- Default Branch: main
- Last Pushed: 2023-07-26T02:24:33.000Z (almost 2 years ago)
- Last Synced: 2024-05-22T18:20:26.769Z (about 1 year ago)
- Language: C#
- Size: 39.1 KB
- Stars: 3
- Watchers: 9
- Forks: 2
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
- License: LICENSE
Awesome Lists containing this project
README
# Getting started with Testcontainers for .NET
This is sample code for the [Getting started with Testcontainers for .NET](https://testcontainers.com/guides/getting-started-with-testcontainers-for-dotnet) guide.
## 1. Setup Environment
Make sure you have .NET 7 and a [compatible Docker environment](https://www.testcontainers.org/supported_docker_environment/) installed.
For example:
```shell
$ dotnet --list-sdks
7.0.104 [C:\Program Files\dotnet\sdk]
$ docker version
...
Server: Docker Desktop 4.12.0 (85629)
Engine:
Version: 20.10.17
API version: 1.41 (minimum version 1.12)
Go version: go1.17.11
...
```## 2. Setup Project
* Clone the repository
```shell
git clone https://github.com/testcontainers/tc-guide-getting-started-with-testcontainers-for-dotnet.git
cd tc-guide-getting-started-with-testcontainers-for-dotnet/TestcontainersDemo
```* Open the **tc-guide-getting-started-with-testcontainers-for-dotnet/TestcontainersDemo** project in your favorite IDE.
## 3. Run Tests
Run the command to run the tests.
```shell
$ dotnet test
```The tests should pass.