Skip to content

Commit 861b26d

Browse files
authored
Merge pull request #57 from socketlabs/usr/matt.soler/threading-issue
Usr/matt.soler/threading issue
2 parents b4e87cf + a24b968 commit 861b26d

File tree

5 files changed

+36
-8
lines changed

5 files changed

+36
-8
lines changed

README.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -36,7 +36,7 @@ PM> Install-Package SocketLabs.EmailDelivery
3636
Adding a Package Reference to your project:
3737

3838
```
39-
<PackageReference Include="SocketLabs.EmailDelivery" Version="2.0.0" />
39+
<PackageReference Include="SocketLabs.EmailDelivery" Version="2.0.1" />
4040
```
4141

4242
.NET CLI users can also use the following command:

docs/release-notes/2.0.0.md renamed to docs/release-notes/2.0.1.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
## 2.0.0
1+
## 2.0.1
22

33
* Fix issue with ApiKey being unset for bearer type keys
44
* Add explicit support for .NET 8.0 and .NET 9.0

docs/release-notes/latest.md

Lines changed: 10 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,2 +1,10 @@
1-
## 1.4.3
2-
* Added MetadataOrTagsAreTooLarge error messsage
1+
## 2.0.1
2+
3+
* Fix issue with ApiKey being unset for bearer type keys
4+
* Add explicit support for .NET 8.0 and .NET 9.0
5+
* Update dependencies
6+
* Implement nullable pattern
7+
8+
```note
9+
This is a breaking change. Some objects require constructor initialization now.
10+
```

src/SocketLabs/SocketLabs.csproj

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -8,12 +8,12 @@
88
<PackageId>SocketLabs.EmailDelivery</PackageId>
99
<GeneratePackageOnBuild>false</GeneratePackageOnBuild>
1010
<PackageRequireLicenseAcceptance>false</PackageRequireLicenseAcceptance>
11-
<Version>2.0.0</Version>
11+
<Version>2.0.1</Version>
1212
<Copyright>Copyright © 2018-2025 SocketLabs Acquisition LLC</Copyright>
1313
<Authors>Matt Soler, David Schrenker, Mike Boshuyzen, Joe Cooper, Matt Reibach, Ryan Lydzinski, Mike Goodfellow, Saranya Kavuri</Authors>
1414
<Product>SocketLabs .Net Client Library</Product>
15-
<AssemblyVersion>2.0.0</AssemblyVersion>
16-
<FileVersion>2.0.0</FileVersion>
15+
<AssemblyVersion>2.0.1</AssemblyVersion>
16+
<FileVersion>2.0.1</FileVersion>
1717
<Description>Easily send email messages using the SocketLabs Injection API.</Description>
1818
<RepositoryUrl>https://github.com/socketlabs/socketlabs-csharp</RepositoryUrl>
1919
<PackageProjectUrl>https://inject.docs.socketlabs.com/</PackageProjectUrl>

test/SocketLabs.Tests/InjectionApi/SocketLabsClientTests.cs

Lines changed: 21 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,6 @@
1-
using Microsoft.VisualStudio.TestTools.UnitTesting;
1+
using Microsoft.VisualStudio.TestPlatform.CommunicationUtilities;
2+
using Microsoft.VisualStudio.TestTools.UnitTesting;
3+
using Newtonsoft.Json.Linq;
24
using SocketLabs.InjectionApi;
35
using SocketLabs.InjectionApi.Message;
46
using System;
@@ -34,5 +36,23 @@ public async Task SendAsyncTest()
3436
// The client should throw the same exception on subsequent calls.
3537
await Assert.ThrowsExceptionAsync<HttpRequestException>(async () => await client.SendAsync(message, CancellationToken.None));
3638
}
39+
40+
41+
[TestMethod()]
42+
public async Task CanSendMessage()
43+
{
44+
var _client = new SocketLabsClient(42006, "DcYYCkSQoV2exx8ksztt.UsImvR6ckr1_r32wC3KPWmd2D1Sz7PGfRx6fJPrg")
45+
{
46+
NumberOfRetries = 3
47+
};
48+
49+
var message = new BasicMessage();
50+
message.To.Add("matt.soler@socketlabs.com");
51+
message.From.Email = "do-reply@ai.socketlabs.email";
52+
message.Subject = "This is a test";
53+
message.HtmlBody = "<p>Hi!</p>";
54+
55+
var response = await _client.SendAsync(message, CancellationToken.None);
56+
}
3757
}
3858
}

0 commit comments

Comments
 (0)