Unit testing: executing order

Questions and answers regarding the use of eclipse environment as seen in Servoy Developer

Unit testing: executing order

Postby mboegem » Wed Sep 08, 2010 12:39 pm

Hi all,

does anyone know where the executing order of unit-testing depends on?

I tried to find out, but it doesn't seem to be any of the following: methodname, method UUID, method comment, method order in the js-file...

I'd like to have an order to be able to build time consuming objects and store them as js-variable in order to have them reusable...

Thnkx for any input.
Marc Boegem
Solutiative / JBS Group, Partner
Servoy Specialist
• Servoy Certified Developer
• Servoy Valued Professional
• Freelance Developer

Image
User avatar
mboegem
 
Posts: 1749
Joined: Sun Oct 14, 2007 1:34 pm
Location: Amsterdam

Re: Unit testing: executing order

Postby pbakker » Thu Sep 09, 2010 9:56 am

Not quite following what you mean.

UnitTests are to operate standalone, so their order shouldn't matter. There is however a way to to some initialization (and cleanup) withing the scope where the tests run, by creating a setUp() and a tearDown() method.

Paul
pbakker
 
Posts: 2822
Joined: Wed Oct 01, 2003 8:12 pm
Location: Amsterdam, the Netherlands

Re: Unit testing: executing order

Postby mboegem » Thu Sep 09, 2010 10:32 am

Hi Paul,

They will operate stand-alone, but there are bits of code which have to be executed over and over again.
For this purpose I'd like to have an Init method.

I forgot about the setUp and tearDown methods, they'll do the job for what I am trying to achieve.

Thnkx a lot!
Marc Boegem
Solutiative / JBS Group, Partner
Servoy Specialist
• Servoy Certified Developer
• Servoy Valued Professional
• Freelance Developer

Image
User avatar
mboegem
 
Posts: 1749
Joined: Sun Oct 14, 2007 1:34 pm
Location: Amsterdam


Return to Eclipse Environment

Who is online

Users browsing this forum: No registered users and 11 guests

cron