change Equal to ShouldBe from Assert.Equal\(([^,]+), ([[]\w\d\(\)\.]+)\); To $2.ShouldBe($1); switch the expect and actual from (^[ \t]*)(\"[:\D \w]+\").ShouldBe\(([\w\.\d\[\]]+)\); to $1$3.ShouldBe($2);