Skip to content

Commit 247f9af

Browse files
committed
Install C# MongoDB driver and check connection to Mongodb
## Summary - Added step to install C# MongoDB driver - Checked connection to Mongodb ## Details - Added a new step to the workflow file `test-windows.yaml` to install the C# MongoDB driver using `dotnet add package` - Updated the shell for the new step to use PowerShell (`pwsh`) - Modified an existing step in the workflow file to check the connection to Mongodb using the installed driver
1 parent 4c61a60 commit 247f9af

1 file changed

Lines changed: 5 additions & 1 deletion

File tree

.github/workflows/test-windows.yaml

Lines changed: 5 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -36,9 +36,13 @@ jobs:
3636
}
3737
shell: pwsh
3838

39-
- name: Check connection to Mongodb
39+
- name: Install C# MongoDB driver
4040
run: |
4141
dotnet add package MongoDB.Driver --version 2.21.0
42+
shell: pwsh
43+
44+
- name: Check connection to Mongodb
45+
run: |
4246
$connectionString = "mongodb://$env:WATERLINE_ADAPTER_TESTS_HOST:$env:WATERLINE_ADAPTER_TESTS_PORT/$env:WATERLINE_ADAPTER_TESTS_DATABASE"
4347
$connection = New-Object MongoDB.Driver.MongoClient($connectionString)
4448
$connection.ListDatabaseNames()

0 commit comments

Comments
 (0)