I think the GetSuite method needs to be static... If that's not it, please include the full exception details. I expect there's a chunk missing from what you quoted below.
Jeff. -----Original Message----- From: [email protected] [mailto:[EMAIL PROTECTED] On Behalf Of Gabe Sent: Tuesday, March 04, 2008 1:35 PM To: MbUnit.User Subject: MbUnit Can't get assembly to load after having switched to [TestSuiteFixture] Sorry for the funky subject line -- let me be more clear: I have a bunch of data-driven tests. The tests are all defined in a database table, and executed by my driver, which makes use of mbunit. The way I *was* running them was just to have a single [Test] method, which looped through the table and, ultimately, only gave me a single pass/fail. Details were spit out through Console.Writeline. It worked, but definitely not the way I wanted it to. So I looked around and found this snippet http://blog.dotnetwiki.org/TestSuiteSupportInMbUnit.aspx on TestSuites in mbunit. I've restructured things significantly to follow what was shown there. Effectively, I've now got: namespace <namespacename> { [TestSuiteFixture] public class <classname> { public delegate void TestDelegate(Object context); [TestFixtureSetUp] public void <methodname> { does setup stuff } [MbUnit.Framework.TestSuite] public MbUnit.Framework.TestSuite GetSuite() { MbUnit.Framework.TestSuite suite = new MbUnit.Framework.TestSuite("suite name here"); foreach loop through my data table { suite.Add("name "+ <TestCaseIDInDatabase>.ToString(), new TestDelegate(DoTest), <TestCaseIDInDatabase>); } return suite; } public void DoTest(Object testContext) { Assert here for test failure or success. } } } I've also got a [TestFixtureTearDown] method. What's happening is that when I try to add this assembly in mbunit gui, it's generating an error right away, stating that: Message: A parent fixture failed Type: MbUnit.Core.Exceptions.FixtureFailedLoadingException Source: MbUnit.Framework TargetSite: System.Object Execute(System.Object, System.Collections.IList) HelpLink: null Stack: at MbUnit.Core.Invokers.FailedLoadingRunInvoker.Execute(Object o, IList args) at MbUnit.Core.RunPipeStarter.Run(Object fixture) I've spent a LOT of time googling around on this and going back over it, but can't for the life of me figure out what I've done wrong. --~--~---------~--~----~------------~-------~--~----~ You received this message because you are subscribed to the Google Groups "MbUnit.User" group. To post to this group, send email to [email protected] To unsubscribe from this group, send email to [EMAIL PROTECTED] For more options, visit this group at http://groups.google.com/group/MbUnitUser?hl=en -~----------~----~----~----~------~----~------~--~---
