Notes compiled over the years, because we forget.
> git config --global color.ui auto| [config] | |
| project = src/ui/ui.csproj | |
| SCM_BUILD_ARGS=-p:Configuration=uat;PublishProfile=uatWeb |
| ALTER DATABASE [dbName] SET SINGLE_USER WITH ROLLBACK IMMEDIATE | |
| GO | |
| DROP DATABASE [dbName] | |
| GO | |
| DROP LOGIN <loginName> | |
| GO | |
| /** |
| <add name="MyContext" connectionString="Data Source=|DataDirectory|myDatabase.sdf" providerName="System.Data.SqlServerCe.4.0"/> |
| # Create a certificate authority | |
| openssl genrsa -des3 -out ca.key 1024 | |
| openssl req -new -key ca.key -out ca.csr | |
| openssl x509 -req -days 365 -in ca.csr -out ca.crt -signkey ca.key | |
| # Create a server certificate | |
| openssl genrsa -des3 -out server.key 1024 | |
| openssl req -new -key server.key -out server.csr |
| private readonly ILog log = LogManager.GetLogger(typeof (MyType)); | |
| <section name="log4net" type="log4net.Config.Log4NetConfigurationSectionHandler, log4net" /> | |
| <log4net> | |
| <root> | |
| <priority value="INFO"/> | |
| <appender-ref ref="RollingFileAppender" /> | |
| <appender-ref ref="EventLogAppender" /> |
| [Test] | |
| [Description("Seeks out all implementations of IMappingConfiguration and tests the configuration for missing member mappings")] | |
| public void ValidateAllMappingConfigurations() | |
| { | |
| var webAssembly = typeof (HomeController).Assembly; | |
| var allMappingConfigurations = from typ in webAssembly.GetTypes() | |
| let interfaces = typ.GetInterfaces() | |
| where interfaces.Contains(typeof (IMappingConfiguration)) | |
| select typ; |
| [TestFixture] | |
| public class CustomHandleErrorAttributeTests | |
| { | |
| private CustomHandleErrorAttribute sut; | |
| private ExceptionContext exceptionContext; | |
| private readonly Mock<HttpRequestBase> mockRequest= new Mock<HttpRequestBase>(); | |
| private readonly Mock<HttpContextBase> mockContext = new Mock<HttpContextBase>(); | |
| private readonly Mock<HttpResponseBase> mockResponse = new Mock<HttpResponseBase>(); | |
| [SetUp] |
| $('#my-modal').modal({ | |
| backdrop: true, | |
| keyboard: true | |
| }).css({ | |
| width: 'auto', | |
| 'margin-left': function () { | |
| return -($(this).width() / 2); | |
| } | |
| }); |