PowerShell Scripts Need Tests Too!

Most of you probably know that I’m a big fan of automated testing and especially testing during the development process. It significantly improves the design of the code by encouraging loose coupling and high cohesion. It also provides great documentation and increases the confidence of anyone who needs to change the code in the future … Continue reading PowerShell Scripts Need Tests Too!

Debugging Powershell Modules in VS Code

TLDR; Use a .ps1 script or Pester test to force the load of the local module file and execute the function. Visual Studio Code Powershell Debugging Microsoft has a created a great Powershell extension for VS Code that makes it easy to work with Powershell files. Once the plugin is installed you get intellisense, syntax … Continue reading Debugging Powershell Modules in VS Code

Using TeamCity Detached Builds to Invoke AWS Services

TLDR; Use TeamCity detached builds and callbacks to provide a more seamless integration between TeamCity and AWS Services. Asynchronous External Service One of the challenges with invoking a process in AWS from TeamCity is that the call to AWS is usually asynchronous. An example of when you might want to do this is to make … Continue reading Using TeamCity Detached Builds to Invoke AWS Services

The 100% Utilization Fallacy

Recently I've been thinking a lot about developer and team productivity. I've realized that one of the factors that has a significant impact on a team's efficiency and productivity is the amount of work in progress (WIP) they have at any given time. Too much WIP is a really bad thing for team workflow. In … Continue reading The 100% Utilization Fallacy

AWS CloudFormation Linting in Team City and GitHub

TLDR; Use cfn-lint in your build pipeline to ensure the quality of AWS CloudFormation templates as part of your code build and deployment process. It's important to ensure the quality of all the code artifacts your team is creating. Even if it's configuration as code. We have been using CloudFormation templates for provisioning our AWS … Continue reading AWS CloudFormation Linting in Team City and GitHub

cypress-ntlm-auth 401 Unauthorized Response

TLDR; Be sure to only run cy.ntlmReset() after all requests in a test are completed. Recently we started to experience intermittent 401 unauthorized errors when our Cypress tests were executing on our build server. These errors were intermittent because they were timing dependent. We've been using a library with Cypress that allows it to authenticate … Continue reading cypress-ntlm-auth 401 Unauthorized Response

Cypress.io baseUrl

TLDR; To help make your tests more reliable and prevent unexpected issues, organize Cypress tests around a single FQDN and don't switch between different target URLs during a test execution. Cypress Journey Recently I've been spending some time improving an existing test suite and writing tests in Cypress.io. Cypress is an excellent framework for developing … Continue reading Cypress.io baseUrl

IIS ASP.NET Core Hosting Bundle 500.19 Error

TLDR; Re-install the latest hosting bundle; Recently I was upgrading the IIS ASP.NET Core Hosting Bundle to ensure the server had the latest patch release (3.1.8). Just to keep the server installations clean, I wanted to also remove all the previous versions of the core hosting bundle so that I only had the single required … Continue reading IIS ASP.NET Core Hosting Bundle 500.19 Error

Troubleshooting CORS Issues in ASP.NET Core Web API

Correctly configuring cross-origin resource sharing can be challenging. This post covers common CORS issues encountered while setting up a local development environment with ASP.NET Core Web API. Disclaimer:  I am not an expert in configuring cross origin resource sharing (CORS).  This post is intended to be for learning purposes only and is not a guide … Continue reading Troubleshooting CORS Issues in ASP.NET Core Web API

Linux Style Line Feeds in Docker Desktop on Windows

Recently I was creating a new image using a dockerfile and encountered a very strange error during the build: ./my-script.sh: 1: ./my-script.sh: Syntax error: word unexpected The cause of this wasn't obvious and it took me a little bit to understand what was happening. It turned out to be a line ending compatibility issue between … Continue reading Linux Style Line Feeds in Docker Desktop on Windows