aboutsummaryrefslogtreecommitdiffstats
path: root/Software/Visual_Studio/Tango.UnitTesting/SendGrid
diff options
context:
space:
mode:
Diffstat (limited to 'Software/Visual_Studio/Tango.UnitTesting/SendGrid')
-rw-r--r--Software/Visual_Studio/Tango.UnitTesting/SendGrid/SendGrid_TST.cs29
1 files changed, 4 insertions, 25 deletions
diff --git a/Software/Visual_Studio/Tango.UnitTesting/SendGrid/SendGrid_TST.cs b/Software/Visual_Studio/Tango.UnitTesting/SendGrid/SendGrid_TST.cs
index 9465676ef..ca0ba1143 100644
--- a/Software/Visual_Studio/Tango.UnitTesting/SendGrid/SendGrid_TST.cs
+++ b/Software/Visual_Studio/Tango.UnitTesting/SendGrid/SendGrid_TST.cs
@@ -50,26 +50,12 @@ namespace Tango.UnitTesting.SendGrid
msg.Subject = "SnapMatch Color Result";
msg.SetTemplateId("d-619b8adc604d4f6fa486d7bbc9e3c2cc");
- Bitmap rect = new Bitmap(80, 80);
- using (Graphics g = Graphics.FromImage(rect))
+ var dynamicTemplateData = new
{
- g.Clear(Color.FromArgb(255, 0, 0));
- }
-
- String image64 = String.Empty;
-
- using (MemoryStream ms = new MemoryStream())
- {
- rect.Save(ms, ImageFormat.Jpeg);
- ms.Position = 0;
- image64 = Convert.ToBase64String(ms.ToArray());
- }
-
- var dynamicTemplateData = new ExampleTemplateData
- {
- Name = "Roy",
Message = "This is my personal note...",
- ImageSource = image64,
+ R = 0,
+ G = 255,
+ B = 0,
};
msg.SetTemplateData(dynamicTemplateData);
@@ -86,12 +72,5 @@ namespace Tango.UnitTesting.SendGrid
Assert.IsTrue(result.StatusCode == HttpStatusCode.Accepted);
}
-
- public class ExampleTemplateData
- {
- public String Name { get; set; }
- public String ImageSource { get; set; }
- public String Message { get; set; }
- }
}
}