Wrecked Games

Please login or register.

Login with username, password and session length
Advanced search  

News:

We're just that awesome.

Author Topic: NUnit added to svn  (Read 2477 times)

pjcast

  • Administrator
  • Veteran
  • *****
  • Karma: +0/-0
  • Posts: 2653
    • View Profile
    • http://www.wreckedgames.com
NUnit added to svn
« on: August 10, 2006, 03:53:42 PM »

Well, I added the NUnit binaries (and Gui and console app) to svn. Mostly, this is for the framework assembly, but since the whole thing was only 1.5MBs and I have plenty of bandwidth, I thought why not :)

Anyway, I create the first (of I hope many) NUnit test. Since many of the methods of Ogre Studio Core are internal or private, the external test dll's (built when in NUnit mode) can only test public methods. Which is fine, and actually preferred.
Logged

pjcast

  • Administrator
  • Veteran
  • *****
  • Karma: +0/-0
  • Posts: 2653
    • View Profile
    • http://www.wreckedgames.com
NUnit added to svn
« Reply #1 on: August 10, 2006, 06:01:56 PM »

Well, I've made the simple tests for MainForm & ProrpertyManager classes. I create an init method that will also reduce test completion time (so Ogre Studio is only init'd once.. Of course, some tests might not need all of Ogre Studio started. But, most of the managers are deeply tied to it, so it is fairly important).

Only thing, an exception get's thrown: DragDrop registration did not succeed. I havn't found a workaround yet, but I think it has to do with a threading model.. Doesn't seem to affect the test outcomes.. When we need to do unit tests on results from drag/drop ops though, it will be imporatant to fix this ;)
Logged

cristiroma

  • Newbie
  • *
  • Karma: +0/-0
  • Posts: 1
    • View Profile
Re: DragDrop registration did not succeed
« Reply #2 on: February 22, 2007, 09:29:08 AM »

I know it's pretty late, but found topic on goole :D and hope next one coming here will find the answer :P

Here is the problem:

method Main must have defined [STAThread] attribute, like this:

Code: [Select]

[STAThread]
public static int Main(string[] args)
{
  return NUnit.Gui.AppEntry.Main(args);
}
Logged