Re: Invalid SetUp method signature
"Charlie Poole" <[email protected]> Wed, 6 Aug 2008 13:22:11 -0700
| Newsgroups | gmane.comp.windows.dotnet.nunit.devel |
|---|---|
| Message-ID | <001201c8f802$1f7fc770$6401a8c0@ferrari> |
I can't see why this would be at first glance, so please file a bug. It would be useful to know if this only happens when there is a single TestCase as opposed to more. Charlie > -----Original Message----- > From: [email protected] > [mailto:[email protected]] On > Behalf Of Kelly Anderson > Sent: Wednesday, August 06, 2008 11:14 AM > To: [email protected] > Subject: [nunit-developer] Invalid SetUp method signature > > Hi folks, I'm using the 2.5 alpha, and got this message > running my test case. > > Reason: Invalid SetUp method signature > > Here's my code: > > using NUnit.Framework; > using NUnit.Framework.SyntaxHelpers; > using Sonic.IC5; > > namespace IC5Test > { > [TestFixture] > public class ProfileConfigTests > { > private IDataMap _map; > > [SetUp] > public void setup() > { > FileState fileState = FileState.GetFileState(); > MockDirectory.SetTestRoot("TestRoot4"); > IBytes bytes = new RandomAccessMemory( Constants.EEPROM_SIZE ); > _map = E2MapBuilder.CreateMap( fileState.MapVersion, > bytes, Side.Right ); > } > > [TestCase(1)] // Theory, what goes in comes out. > public void > ProfileConfigSavesAndRetrievesDefaultDaiIndex(int value) > { > ProfileConfig config = new ProfileConfig(_map); > config.DefaultDaiIndex = value; > Assert.That(config.DefaultDaiIndex, Is.EqualTo(value)); > Assert.That( _map.GetInt( > MapConstants.REC_PROFILE_CONFIG, "DefaultDaiIndex" ), > Is.EqualTo( value ) ); > } > } > } > > Now everything worked fine when this was just a Test, so it > has something to do with converting Test to TestCase(1)... > any thoughts? > Why would adding a parameter change the structural > requirements of my SetUp function? > > -Kelly > > -------------------------------------------------------------- > ----------- > This SF.Net email is sponsored by the Moblin Your Move > Developer's challenge Build the coolest Linux based > applications with Moblin SDK & win great prizes Grand prize > is a trip for two to an Open Source event anywhere in the > world http://moblin-contest.org/redirect.php?banner_id=100&url=/ > _______________________________________________ > nunit-developer mailing list > [email protected] > https://lists.sourceforge.net/lists/listinfo/nunit-developer > ------------------------------------------------------------------------- This SF.Net email is sponsored by the Moblin Your Move Developer's challenge Build the coolest Linux based applications with Moblin SDK & win great prizes Grand prize is a trip for two to an Open Source event anywhere in the world http://moblin-contest.org/redirect.php?banner_id=100&url=/