Edgewall Software
Modify

Opened 13 years ago

Last modified 13 years ago

#697 assigned enhancement

Add .NET unit testing recipe command support

Reported by: Sergey Gerasimov <sergun@…> Owned by: hodgestar
Priority: major Milestone:
Component: Recipe commands Version:
Keywords: Cc: mpotter@…
Operating System:

Description

It would be nice to add support of .NET unit testing to Bitten.

Bitten & TRAC are nice tools.. and case of support of .NET unit testing they could be real competitor to MS Team Foundation Server.

Attachments (0)

Change History (8)

comment:1 follow-up: Changed 13 years ago by hodgestar

  • Owner set to hodgestar

Can the .NET unit tests output Nunit format? There is already a recipe command for uploading Nunit files (see mono-nunit).

comment:2 Changed 13 years ago by mpotter@…

  • Cc mpotter@… added

comment:3 in reply to: ↑ 1 ; follow-up: Changed 13 years ago by anonymous

Replying to hodgestar:

Can the .NET unit tests output Nunit format? There is already a recipe command for uploading Nunit files (see mono-nunit).

This is Microsoft we are taking about.

Using MSTest at the command line, one can generate a results file (by convension with a .trx extension) which appears to be an XML file.

mstest /testcontainer:UnitTest.dll /resultsfile:out.trx

It should be possible to write an XSLT to transform this results file into a Bitten usable format. Hmm, looks like someone already has (Ms Test Xslt).

Of course the better solution would be for bitten to support these files directly.

comment:4 Changed 13 years ago by hodgestar

  • Status changed from new to assigned

I'll have a look at what from that wiki page can be integrated into Bitten -- I'll probably need patches to be tested by someone with MS Windows / Visual Studio.

comment:5 Changed 13 years ago by osimons

I'd like to see this added too. Never really been comfortable with the 'mono' namespace and what it does for perception and how it somewhat restricts what tools we may support. In my world .NET developers are using Microsoft tools.

I suggest we introduce any new commands under the dotnet:<cmd> namespace, move NUnit there too as dotnet:nunit while keeping the old mono namespace working for 0.6 to be removed in 0.7.

A dotnet:mstest command would be a natural addition.

comment:6 in reply to: ↑ 3 Changed 13 years ago by mpotter@…

Replying to anonymous:

It should be possible to write an XSLT to transform this results file into a Bitten usable format. Hmm, looks like someone already has (Ms Test Xslt).

The script on Ms Test Xslt treats outcome's of "Passed" as success and all other outcome's as failure. So far I have seen outcome values of: "Passed", "Failed" and "Inconclusive". Should "Inconclusive" be treated differently?

comment:7 follow-up: Changed 13 years ago by osimons

The Bitten test summarizers (table + graph) really only support success, failure and ignored. Adding 'maybe' really sounds strange to me...

I'm fine with making 'inconclusive' the same as failure.

comment:8 in reply to: ↑ 7 Changed 13 years ago by mpotter@…

Replying to osimons:
Was just mentioning it for completeness and thought. The more I think about it, the more treating "Inconclusive" as "failure" is reasonable. The only other possibility would be to treat it as "ignored".

Additional information: The "Inconclusive" results are generated by the UnitTesting.Assert.Inconclusive() methods. Though a programmer could put these in manually, they are most commonly from the code generated by the Unit Test wizard. Thus these are tests that the wizard generated, but the programmer has not gone into and filled in the details. Example wizard generated test in C#:

/// <summary>
///A test for Foo Constructor
///</summary>
[TestMethod()]
public void FooConstructorTest()
{
    IEvents events = null; // TODO: Initialize to an appropriate value
    IBar bar = null; // TODO: Initialize to an appropriate value
    Foo target = new Foo(events, bar);
    Assert.Inconclusive("TODO: Implement code to verify target");
}

Add Comment

Modify Ticket

Change Properties
Set your email in Preferences
Action
as assigned The owner will remain hodgestar.
Author


E-mail address and user name can be saved in the Preferences.

 
Note: See TracTickets for help on using tickets.