Careers   |   Events   |   Contact   |   402.238.1399   |   contactus@deliveron.com

Deliveron
Connect with us on FacebookConnect with us on LinkedInFollow Us on Twitter

Category List


Tag List

alm (9)
msi (2)
ninject (2)
Node.js (1)
Office 365 (1)
business intelligence (2)
lync (2)
video (2)
mstestv2 (1)
agile (12)
selinium (1)
MSBuild (1)
Java (1)
serverless (3)
sharepoint 2013 (6)
AAD (2)
site collections (2)
user profiles (4)
connect() (1)
team web access (2)
power tools (2)
azure mobile services (2)
Visual Studio 2017 (4)
API Tests (1)
dependency-injection (2)
selenium (4)
Visual Studio Online (6)
swagger (1)
webpack (1)
IntelliSense (1)
visual studio 2010 (18)
sharepoint (5)
webs (2)
team foundation server 11 beta (2)
data warehousing (2)
wiki (1)
burndown (2)
asp.net-mvc-routing (2)
test cases (2)
association (1)
test controller (2)
TestArchitect (5)
Business (2)
tfs odata (2)
onenote (4)
web performance tests (2)
opensource (1)
REST (1)
sql server 2008 (2)
team foundation server (6)
release management (7)
coded ui tests (6)
react (1)
angular (1)
my work (2)
nebraska code camp (2)
2013 (2)
outlook (2)
test automation (1)
razor (4)
test agent (2)
Analytics (2)
AzureAD Admins (1)
tips (2)
action-filters (2)
Decisions (2)
tfs 2017 (1)
Cosmos DB (1)
web (1)
zap (1)
DevOps (14)
artifacts (1)
team foundation 2012 (2)
Meetings (1)
microsoft case study (2)
nintex (4)
webparts (2)
cascading-dropdown (2)
storyboarding (2)
Mike Douglas (4)
Quality (2)
Collaboration (2)
web application firewall (1)
faq (2)
Web API (1)
tfs (11)
team deploy (2)
Nuget (1)
workflow (2)
Powershell (1)
dbpro (2)
pdf (2)
Automated Testing (10)
fields (2)
CI (3)
application insights (2)
owasp (3)
AzureAD (1)
automatedui (1)
requirements (2)
event-handling (2)
table-valued-parameters (4)
tags (2)
jquery (4)
vsdbcmd (2)
pipeline (1)
mvvm (2)
team build (2)
Document (1)
licensing (2)
performancepoint services (2)
deliveron agile delivery process (2)
subsites (2)
ssas (2)
wit (2)
web deploy (1)
gulp (2)
alm rangers (1)
entity-framework (6)
webcast (4)
fluentvalidation (2)
silverlight (2)
insiders (1)
tfs 2012 (4)
nunit (1)
top 5 (1)
tls 1.2 (1)
OAuth2 (1)
ARM Template (1)
business insight (2)
Functions (2)
bundling (2)
lab environments (1)
Keith Holt (1)
MVP (2)
visual studio team services (1)
installation (2)
HOLs (1)
certificates (2)
sharepoint 2010 (10)
gherkin (2)
angular 2 (3)
team foundation server 2012 (4)
planning poker (4)
adfs (3)
sql server (2)
example (2)
visual studio 11 beta (2)
sp1 (2)
kanban (1)
testing (5)
azure resource manager (1)
tokenization (1)
Azure Functions (1)
necc (2)
ssrs (4)
PBI (1)
TFS 2015 (6)
deployment (2)
load testing (2)
javascript (3)
single page applicaiton (1)
feedback (2)
dns (2)
netstandard (2)
performance (3)
powershell 2.0 (8)
lunch and learn (2)
exchange (2)
database projects (4)
whitelist (1)
sharepoint 2007 (2)
Azure (14)
preview (1)
service-fabric (1)
reporting (2)
DevSecOps (2)
Build (6)
json (2)
scrum (8)
Infrastructure (1)
github (1)
xaml (2)
asp.net-mvc-4 (2)
Multi-Factor Authentication (1)
alerts (2)
work item (2)
visual studio (8)
MFA (1)
whitesource (1)
pipelines (1)
microsoft alm rangers (2)
Template (1)
code-first (4)
lab management 2010 (2)
rest assured (1)
continuous integration (2)
xunit (1)
windows azure (2)
M Query (1)
asp.net-mvc-3 (4)
continuous inegration (2)
asp.net-mvc (6)
database publishing wizard (2)
vsts (22)
sql saturday (2)
Big Data (2)
tfs 2013 (2)
spc14 (4)
c# (13)
Power BI (3)
tfs 2010 (2)
Data Analytics (1)
bi (2)
security (1)
home projects (1)
deliveron alm delivery guidance (2)
load tests (2)
visual studio 2012 (10)
windows 8 store app (2)
bdd (2)
visual studio code (1)
ssl (1)
microsoft test manager (2)

Archive

Test Case Association to xUnit, NUnit, and MSTestV2 Tests is available in Visual Studio 2017 15.7.1

May 18, 2018

11/20/2018 Update - The Associate to Test Case option is working again in 15.9.2!  I didn't get a chance to try 15.9.1 to know if it worked with that version or not. I'll keep this updated if the behavior changes.  

9/04/2018 Update - The Associate to Test Cases option has been disabled again in 15.8.0, 15.8.1, and 15.8.2.  Other workarounds are to reference the MSTestV1 (Microsoft.VisualStudio.QualityTools.UnitTestFramework) and remove MSTestV2 references when doing the associate or use the API for doing the association.

The "truth center" of detailed requirements for projects should be represented as tests or sometime also refereed as executable requirements.  Traditionally we have accomplished this using the following "Test Case First" process.

User Story (Desirement) > Acceptance Criteria (Informal detailed requirements) > Test Cases (Work Item with Given, When, Then)

We then create the UI or API automated functional test and associate the automated test with the Test Case Work Item.  This gave us a great amount management and reporting capabilities for test cases and provided a consistent way to work with manual and automated tests.  However, one downside to this approach is that this has only worked with MSTestV1.  Other test frameworks have become more popular such as xUnit and NUnit and even Microsoft introduced MsTestV2.  The problem is that none of these other frameworks would work.  The Associate Test Case Option has been disabled.  Note: Even though these are unit test testing frameworks, these frameworks are often used for writing and running functional UI and APIs through code and linking to other testing tools like TestArchitect and SoapUi.

The DevOps movement has been pushing activities like testing upstream to the developers with the focus to automate all tests.  One could argue that having a Test Case work item and an automated test with the details of the requirements is redundant.  Which is the truth?  As teams want to move faster, they skip the test case and use the automated test and test results as the test case itself.   VSTS allows for the test results to be associated to requirements to still provide tracability and to be able to show test quality at the requirement level. 

With Visual Studio not supporting the ability to associate test cases to xUnit, NUnit, or MSTest V2 tests, this has forced teams to abandon the test case first approach and to use the requirements.  I have been following this thread on Visual Studio Developer Community website where it was mentioned that this functionality is available with Visual Studio 15.7.1.  I'm excited to report that you can now associate Test Cases to all three of these frameworks and possibly other others.  I created a Unit Testing Solution with 3 projects representing each of these tools.  I was able to associate all of the tests and run them through VSTS using the Test Plan option.

Now you can choose the approach that best fits your process and not base it on a tool limitation.

unittest-comparison-project.jpg

 

In VSTS, the Visual Studio Test task has the option to run tests by Test Plan / Test Suite / Test Configuration.

 visualstudio-test-task.jpg

 

vsts-test-results-test-suite.jpg

 

test-case-results-chart.jpg

As always, reach out to me at twitter at https://twitter.com/mikedouglasdev for any questions or comments.

 



Category: Test Automation

Mike Douglas

user_avatar

He is a solution consultant focused on helping organization build high quality application effectively utilizing DevOps practices. He is a Microsoft DevOps / ALM Ranger and you can reach him on Twitter at @mikedouglasdev


We believe in helping our customers create software solutions in a better way.
We do this by having a project delivery process and technology expertise that ensures we are solving the right problem in the right way and driving the most business value.