Tuesday, February 5, 2013

What's new in ApprovalTests.Net v.22 ?

ApprovalTests.Net v.22 is here, you can get it on Nuget
Here's what's new:

UTF8 Support

[Contributors: Scott Reed & Maurice De Beijer] 
Text Files will now work with UTF with (many/most) Diff Tools. This basically comes down to making everything UTF8, and including the bom (byte order mark) header in the text files.  


**Backwards compatibility break**
This change means version22 of ApprovalTests will break compatibility with previous versions.
To  adjust for this, when you run your tests, ApprovalTests will check the .approved file and add the UTF8 bom if needed. This might result in you needing to re-check-in your approved file, despite an apparent lack of change.

GitHub

[Contributors: James Counts & Jason Jarrett]
While not strictly a feature of v.22, this version marks the move of the source to GitHub. (https://github.com/approvals/ApprovalTests.Net/) This should make it easier for people to branch and play around with the code. Although my preferred method of collaboration is still a remote pair programming session via skype. If you are interesting in pairing just ping me on twitter @LlewellynFalco 

ORM Support

[Contributors: Scott Reed] 
We have added  the Interface DatabaseAdaptor, which makes it much easier to do IExecutableQuery type approvals. This is based on the ‘Testing the Weather’ pattern. 
This goes along with added support for:

  • NHibernate
  • Entity Framework DbContext (V 4.1+) 

Async

[Contributors: Jake Ginnivan] 
XUnit supports testing of methods using the async and await keywords. Now ApprovalTests supports it as well. Asynchronous parallel programming offers many advantages with both IO and multicore, and it’s great to see this paradigm opening up so nicely in the .net world. 


P4Merge and better path finding

[Contributors: Jason Jarrett]
It’s always been a source of problems detecting where different systems have placed the Diff Reporter programs ApprovalTests uses.  Thanks to the addition of “where.exe” on windows7 and above, if the reporter is in your system path, it will now be found. This comes with the addition of P4Merge in the reporter options. P4Merge will also diff images giving us yet another excellent option. 


CLS complaint

[Contributors: James Counts]
This is not the same as a portable library (that’s also on the list) but it does help with language portability. Meaning if you are using .Net but not using C#, ApprovalTests is looking out for you. 

Contributors

A big thanks to everyone who contributed! I could not have done a ¼ of what I have if it wasn’t for the people who have paired with me (They have also allowed 2 new ports of ApprovalTests in the last iteration as well to Node.js & Perl).
ApprovalTests has always relied on the pairing of contributors, and I was remiss for not being more vocal about it in the past. Thanks again for all your help.


2 comments:

Pankaj said...

What is the latest version of NUNIT approval test is compatible with?
I found that it doesn't identifies TestCase(Severities.Severity4, TestName = ReportConstants.SmartReportName + "Severity4")attribute added NUNIT 2.5 ver onwards

jegViking said...

I am having difficulty getting this to work on Visual Studio 2012. When I run a failing test using a diffreporter, the merge tool does not open to view the differences.

I opened up in Visual Studio 2010 and it did work.

I am using resharper 7 to manage my unit tests.

Thanks!