To grow as a software architect, developer, team member, and leader, in a challenging and caring environment
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?xml version="1.0" encoding="utf-8"?> | |
<CodeSnippets xmlns="http://schemas.microsoft.com/VisualStudio/2005/CodeSnippet"> | |
<CodeSnippet Format="1.0.0"> | |
<Header> | |
<Title>Test Method - Base</Title> | |
<Author>Adam Costenbader</Author> | |
<Description>Use to define the base structure of a test method.</Description> | |
<Shortcut>btest</Shortcut> | |
</Header> | |
<Snippet> |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
CREATE TABLE [dbo].[tokens] | |
( | |
[id] INT IDENTITY(1,1) NOT NULL, | |
[token] NCHAR(6) NOT NULL CONSTRAINT DF_subscribertokens_token DEFAULT CONVERT(nvarchar(6),LEFT(REPLACE(NEWID(),'-',''),6)), | |
[created] DATETIME NOT NULL CONSTRAINT DF_subscribertokens_created DEFAULT getutcdate(), | |
[notes] VARCHAR(MAX) NULL, | |
[deactivated] BIT NOT NULL CONSTRAINT DF_subscribertokens_deactivated DEFAULT 0, | |
CONSTRAINT [PK_tokens] PRIMARY KEY CLUSTERED ([id] ASC), | |
CONSTRAINT UC_tokens_token UNIQUE (token) |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
public class Result<T> | |
{ | |
private readonly T _value; | |
public T Value { get { return _value; } } | |
private List<string> _errors = new List<string>(); | |
public IReadOnlyCollection<string> Errors => _errors; | |
private List<Exception> _exceptions = new List<Exception>(); | |
public IReadOnlyCollection<Exception> Exceptions => _exceptions; |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
myDBContext.Database.Log = message => System.Diagnostics.Debug.WriteLine(message); |
OlderNewer