New rig, build results

I saw a tweet from Scott Hanselman on his new rig and he has a blog post about it. Then I realized I hadn’t posted about my new rig that I built in January. I wanted something fast for development and also for video editing. I went with Linux Mint as I have been running Mint happily on my home computers for a few years now. I chose to go unconventionally with an older server motherboard and some older components that fit. The Motherboard is a Supermicro and holds a paired Intel Xeon E5-26780 server processors, they have 10 cores each. That gives me 40 threads. 16GB of DDR3 memory and a Pro SATA III SSD. I re-used the graphics card from my old rig, I use xBox for gaming anyway. The total was about $1500, bought from Newegg and Ebay.

Let’s take a look at the numbers,

The machine Scott is building ( before over-clocking )
– Warm build just under 10 seconds.
– Cold build takes 33.3 seconds.

My desktop server
– Warm build takes 16.16 seconds.
– Warm build with -no-restore takes 9.35 seconds
– Cold build takes 27.2 seconds

Interestingly my cold build is faster, maybe because of more threads ? Warm is a lot slower on my rig. Nice to see .net use all the available threads during the build. Do your own build see what your rig can do, maybe it’s time for a new one ?

UnitTest MsSql database using Slacker, SlackerRunner

Our open source MsSql UnitTest framework Slacker and SlackerRunner was featured on Microsoft Channel 9. Now it’s easier than ever to UnitTest your database and add it into your CI,CD build pipeline.

Watch Eric Kang from Microsoft explain in detail what you need and how it works.

Nlog configuration

I needed to add Nlog tracing that must be configurable from the config file. Finding a simple sample took a me a while. Therefor I’m putting the needed pieces here.


<?xml version=“1.0” encoding=“utf-8” ?>
    <section name=“nlog” type=“NLog.Config.ConfigSectionHandler, NLog”/>
  <nlog xmlns=“”

    <variable name=“appName” value=“sample” />
    <targets async=“true”>
      <target xsi:type=“File”

      <logger name=“*” writeTo=“default” minlevel=“Info” />

And then in code, you can just do the following.

using NLog;
        Logger logger = LogManager.GetLogger(“mylogger”);
        logger.Log(LogLevel.Debug, “Hellow world”);

.Net Core 1.1 – WebApi Integration testing

Things have changed a bit since the DNX .Net WebApi Integration testing post that I wrote about a year ago. This post will show updated code for .Net Core 1.1, I’m using the TestHost library as before.

I’m using these Nuget packages
xunit 2.3.0-beta1-build3642
Microsoft.AspNet.TestHost 1.1.1

Here is the UnitTest itself

using System;
using System.Diagnostics;
using System.Net.Http;
using Microsoft.AspNetCore.TestHost;
using Microsoft.AspNetCore.Hosting;
using Xunit;
using DevOps.Notes.Core.Util;

namespace DevOps.Notes.Web.Spec
  public class ValuseControllerTest
    public async void PingTheServerRepeat()
      // Setup client & server
      TestServer server = new TestServer(new WebHostBuilder().UseStartup<Startup>());
      HttpClient client = server.CreateClient();
      // Make a request and check response
      var getResponse = await client.GetAsync(“api/values/”);
      var response = await getResponse.Content.ReadAsStringAsync();
      TraceLog.Log(“web api, response=” + response);

      // Hit the webapi, repeatedly
      Stopwatch watch = Stopwatch.StartNew();
      for (int i = 0; i < Util.Repeat; i++)
        getResponse = await client.GetAsync(“/api/values/”+i);
        response = await getResponse.Content.ReadAsStringAsync();
      TraceLog.Log($“WepApi, round trips ={Util.Repeat}, Execution time, millisec={watch.ElapsedMilliseconds}, average roundtrip=” + ((double)watch.ElapsedMilliseconds / Util.Repeat));
      TraceLog.Log(“web api, response=” + response);

      // Done, release resources



Linux tools on Windows

If you are like me, you don’t want to be bothered to remember if you are working on a Windows or a Linux box. Things like ls, curl etc, should just work. So if you are missing the Linux tools on Windows and you don’t want to install the heavy Cygwin, then the is an alternative, Gow is a lightweight set of Linux Tools for Windows.

Gow can be found here

TFS 2015, Xunit transform to Trx

It turns out I was wrong in my last post about transforming nUnit tests to Trx ( Ms Test ) format for display in TFS 2015. It fails short as the nUnit format that xUnit spits out does not have any console or standard out traces. Therefor when you want to view more information about your tests or error traces on failures non are available. I went down the road to use the nUnit format because TFS was supposed to take it and display it in TFS without tranforming to Trx but that does not work. So the solution is to use the xUnit Xml V2 format by passing the -xml switch to xUnit. Then convert the xml to Trx using your Xslt transform. Mine is here on GitHub if you want a copy.