Skip to content

Microsoft.VisualStudio.QualityTools.UnitTestFramework not found at runtime#68

Merged
danielli90 merged 1 commit intomicrosoft:masterfrom
danielli90:zip
Nov 19, 2015
Merged

Microsoft.VisualStudio.QualityTools.UnitTestFramework not found at runtime#68
danielli90 merged 1 commit intomicrosoft:masterfrom
danielli90:zip

Conversation

@danielli90
Copy link
Member

Microsoft.VisualStudio.QualityTools.UnitTestFramework is not part of .Net Framework (just part of VS IDE); by enabling "Copy Local" to true in the reference, the DLL will be included as part of final build, which avoids the exception of missing UnitTestFramework.dll when running on servers without VS IDE installed.

Running "sparkclr.samples.torun PiSample" in the cluster without VS IDE installed repro's this issue.

@jthelin
Copy link
Contributor

jthelin commented Nov 19, 2015

The other way to deal with this type of problem is to switch to using a different "Assertions" package from NuGet rather than Microsoft.VisualStudio.QualityTools.UnitTestFramework.

FluentAssertions is one I have used, but there are other examples like NFluent etc. too.
http://www.fluentassertions.com/
http://n-fluent.net/

I personally like the "fluent" style of writing assertion because it is so much easier to read and get right.

With the old-school Assert.Blah(..) methods I often have to keep checking which way round the paramaters go, and it is different for AreEquals and IsInstanceOfType for example. :(

@danielli90
Copy link
Member Author

Thanks @jthelin. Created #75 to track this suggestion.

….Net Framework (just part of VS IDE); by enabling "Copy Local" to true in the reference, the DLL will be included as part of final build, which avoids the exception of missing UnitTestFramework.dll when running on servers without VS IDE installed.
danielli90 added a commit that referenced this pull request Nov 19, 2015
Microsoft.VisualStudio.QualityTools.UnitTestFramework not found at runtime
@danielli90 danielli90 merged commit 756e48d into microsoft:master Nov 19, 2015
@danielli90 danielli90 deleted the zip branch November 19, 2015 22:09
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants