sequence of method calls in a class instantiated from factory

classic Classic list List threaded Threaded
10 messages Options
Reply | Threaded
Open this post in threaded view
|

sequence of method calls in a class instantiated from factory

av9999

Hello:

Here is my factory and myclass

factory{

for(i=0; i<5; i++){
  for(j=0, j<5; j++){
         new myclass()
     }
  }
}
myclass{

   @beforeclass{
   }
  @test0{
   }
   @test1{
   }
   @afterclass{
}
 what is the  expected sequence of method calls?

beforeclass
test1
test2
cleanup
beforeclass
test1
test2
cleanup

But i am seeing
beforeclass
beforeclass (j times)
@test1 (j times)
@test2(j times)
cleanup (j times)

Aruna


--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the Google Groups "testng-users" group.
To post to this group, send email to [hidden email]
To unsubscribe from this group, send email to [hidden email]
For more options, visit this group at http://groups.google.com/group/testng-users?hl=en
-~----------~----~----~----~------~----~------~--~---

Reply | Threaded
Open this post in threaded view
|

Re: sequence of method calls in a class instantiated from factory

Alexandru Popescu ☀

On 4/13/07, av9999 <[hidden email]> wrote:

>
> Hello:
>
> Here is my factory and myclass
>
> factory{
>
> for(i=0; i<5; i++){
>   for(j=0, j<5; j++){
>          new myclass()
>      }
>   }
> }
> myclass{
>
>    @beforeclass{
>    }
>   @test0{
>    }
>    @test1{
>    }
>    @afterclass{
> }
>  what is the  expected sequence of method calls?
>
> beforeclass
> test1
> test2
> cleanup
> beforeclass
> test1
> test2
> cleanup
>
> But i am seeing
> beforeclass
> beforeclass (j times)
> @test1 (j times)
> @test2(j times)
> cleanup (j times)
>

Frankly speaking I don't know how do you see that, because the code
you have pasted is not even compilable :-). Also, you are forgetting
to let us know what version of TestNG you are using.

Now moving along from joking: the contract of @BeforeClass/@AfterClass
is that they will be run before any test method in their
instance/after all test methods in their instance will be invoked.

I agree it would be a bit cleaner to see the ordering you are
presenting, but I would not say that the @BeforeClass/@AfterClass
contract is not respected with the other behavior (I am short on
memory but I thought I have worked on this at some point :-s. Maybe
you can search the archieve or the group for similar threads.)

bests,

./alex
--
.w( the_mindstorm )p.
  TestNG co-founder
EclipseTestNG Creator

> Aruna
>
>
> >
>

--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the Google Groups "testng-users" group.
To post to this group, send email to [hidden email]
To unsubscribe from this group, send email to [hidden email]
For more options, visit this group at http://groups.google.com/group/testng-users?hl=en
-~----------~----~----~----~------~----~------~--~---

Reply | Threaded
Open this post in threaded view
|

Re: sequence of method calls in a class instantiated from factory

av9999

Hi Alex:

I need to send you the code and the logs. I tried pasting here but
looks like it is not sending the message.
Please let me know how ro send the code and the logs.

Basically, the problem in factory is
1. if the instantiation of the class is from one loop, the tests are
executed properly. (similar to testng factory sample)
2. But if there an outer loop which calls the
inner loop ( which instantiates the test class for n times ), all the
out loop iterations are ignored and only the last iteration of the
outer loop is effective and all the inner loops of iterations are
executed only for the  last iteration of the outer loop.
for i=2 and j=3, instead of 6 iterations, only last 3 are executed.
The sequence is also not guaranteed..

Thanks
Aruna


On Apr 13, 2:14 am, "Alexandru Popescu ☀"
<[hidden email]> wrote:

> On 4/13/07,av9999<[hidden email]> wrote:
>
>
>
>
>
> > Hello:
>
> > Here is my factory and myclass
>
> > factory{
>
> > for(i=0; i<5; i++){
> >   for(j=0, j<5; j++){
> >          new myclass()
> >      }
> >   }
> > }
> > myclass{
>
> >    @beforeclass{
> >    }
> >   @test0{
> >    }
> >    @test1{
> >    }
> >    @afterclass{
> > }
> >  what is the  expected sequence of method calls?
>
> > beforeclass
> > test1
> > test2
> > cleanup
> > beforeclass
> > test1
> > test2
> > cleanup
>
> > But i am seeing
> > beforeclass
> > beforeclass (j times)
> > @test1 (j times)
> > @test2(j times)
> > cleanup (j times)
>
> Frankly speaking I don't know how do you see that, because the code
> you have pasted is not even compilable :-). Also, you are forgetting
> to let us know what version of TestNG you are using.
>
> Now moving along from joking: the contract of @BeforeClass/@AfterClass
> is that they will be run before any test method in their
> instance/after all test methods in their instance will be invoked.
>
> I agree it would be a bit cleaner to see the ordering you are
> presenting, but I would not say that the @BeforeClass/@AfterClass
> contract is not respected with the other behavior (I am short on
> memory but I thought I have worked on this at some point :-s. Maybe
> you can search the archieve or the group for similar threads.)
>
> bests,
>
> ./alex
> --
> .w( the_mindstorm )p.
>   TestNG co-founder
> EclipseTestNG Creator
>
> > Aruna


--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the Google Groups "testng-users" group.
To post to this group, send email to [hidden email]
To unsubscribe from this group, send email to [hidden email]
For more options, visit this group at http://groups.google.com/group/testng-users?hl=en
-~----------~----~----~----~------~----~------~--~---

Reply | Threaded
Open this post in threaded view
|

Re: sequence of method calls in a class instantiated from factory

Alexandru Popescu ☀
Aruna if you check the TestNG site you will figure out how to send me
privately what you want to send me ;-).

./alex
--
.w( the_mindstorm )p.
  TestNG co-founder
EclipseTestNG Creator


On 4/15/07, av9999 <[hidden email]> wrote:

>
> Hi Alex:
>
> I need to send you the code and the logs. I tried pasting here but
> looks like it is not sending the message.
> Please let me know how ro send the code and the logs.
>
> Basically, the problem in factory is
> 1. if the instantiation of the class is from one loop, the tests are
> executed properly. (similar to testng factory sample)
> 2. But if there an outer loop which calls the
> inner loop ( which instantiates the test class for n times ), all the
> out loop iterations are ignored and only the last iteration of the
> outer loop is effective and all the inner loops of iterations are
> executed only for the  last iteration of the outer loop.
> for i=2 and j=3, instead of 6 iterations, only last 3 are executed.
> The sequence is also not guaranteed..
>
> Thanks
> Aruna
>
>
> On Apr 13, 2:14 am, "Alexandru Popescu ☀"
> <[hidden email]> wrote:
> > On 4/13/07,av9999<[hidden email]> wrote:
> >
> >
> >
> >
> >
> > > Hello:
> >
> > > Here is my factory and myclass
> >
> > > factory{
> >
> > > for(i=0; i<5; i++){
> > >   for(j=0, j<5; j++){
> > >          new myclass()
> > >      }
> > >   }
> > > }
> > > myclass{
> >
> > >    @beforeclass{
> > >    }
> > >   @test0{
> > >    }
> > >    @test1{
> > >    }
> > >    @afterclass{
> > > }
> > >  what is the  expected sequence of method calls?
> >
> > > beforeclass
> > > test1
> > > test2
> > > cleanup
> > > beforeclass
> > > test1
> > > test2
> > > cleanup
> >
> > > But i am seeing
> > > beforeclass
> > > beforeclass (j times)
> > > @test1 (j times)
> > > @test2(j times)
> > > cleanup (j times)
> >
> > Frankly speaking I don't know how do you see that, because the code
> > you have pasted is not even compilable :-). Also, you are forgetting
> > to let us know what version of TestNG you are using.
> >
> > Now moving along from joking: the contract of @BeforeClass/@AfterClass
> > is that they will be run before any test method in their
> > instance/after all test methods in their instance will be invoked.
> >
> > I agree it would be a bit cleaner to see the ordering you are
> > presenting, but I would not say that the @BeforeClass/@AfterClass
> > contract is not respected with the other behavior (I am short on
> > memory but I thought I have worked on this at some point :-s. Maybe
> > you can search the archieve or the group for similar threads.)
> >
> > bests,
> >
> > ./alex
> > --
> > .w( the_mindstorm )p.
> >   TestNG co-founder
> > EclipseTestNG Creator
> >
> > > Aruna
>
>
> >
>

--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the Google Groups "testng-users" group.
To post to this group, send email to [hidden email]
To unsubscribe from this group, send email to [hidden email]
For more options, visit this group at http://groups.google.com/group/testng-users?hl=en
-~----------~----~----~----~------~----~------~--~---

Reply | Threaded
Open this post in threaded view
|

Re: sequence of method calls in a class instantiated fr

tarun3kumar
Hi Alex
You can use these file. If you execute them the output is as follows:

   [testng] Constructor-i-0
   [testng] Constructor-j-0
   [testng] Constructor-i-0
   [testng] Constructor-j-1
   [testng] Constructor-i-1
   [testng] Constructor-j-0
   [testng] Constructor-i-1
   [testng] Constructor-j-1
   [testng] Constructor-i-2
   [testng] Constructor-j-0
   [testng] Constructor-i-2
   [testng] Constructor-j-1
   [testng] setup-i-2
   [testng] setup-j-0
   [testng] testLoginPositive-i-2
   [testng] testLoginPositive-j-0
   [testng] cleanup-i-2
   [testng] cleanup-j-0
   [testng] setup-i-2
   [testng] setup-j-1
   [testng] testLoginPositive-i-2
   [testng] testLoginPositive-j-1
   [testng] cleanup-i-2
   [testng] cleanup-j-1
   [testng]

As you can see, setup, testLoginPositive and cleanup are called only for the loop i=2. They are not called for i=0 and 1. Why is that so? My understanding was that testng will call all the annotated methods in the class called under factory for all the iterations.
thanks
---------------------------------------------------------------------
Posted via Jive Forums
http://forums.opensymphony.com/thread.jspa?threadID=77035&messageID=142213#142213

--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the Google Groups "testng-users" group.
To post to this group, send email to [hidden email]
To unsubscribe from this group, send email to [hidden email]
For more options, visit this group at http://groups.google.com/group/testng-users?hl=en
-~----------~----~----~----~------~----~------~--~---


test.java (1K) Download Attachment
testFactory.java (562 bytes) Download Attachment
Reply | Threaded
Open this post in threaded view
|

Re: sequence of method calls in a class instantiated fr

Alexandru Popescu ☀

I think you have a flaw in your code:

    @Factory
    public Object[] testLogin() {
        Object[] result = null;
            for (int i=0;i<3;i++) {
                result = new Object[2];
                for (int j=0;j<2;j++) {
                    result[j] = new test(i, j);
                }
            }
        return result;
    }

For each i look you are reseting result (result= new Object[2]]), so
by the time the method returns result is an array of 2 object.
Afterwards the behavior is the expected one.

By the way have you opened a JIRA issue attached to this discussion?

./alex
--
.w( the_mindstorm )p.
  TestNG co-founder
EclipseTestNG Creator


On 4/16/07, magnatron <[hidden email]> wrote:

> Hi Alex
> You can use these file. If you execute them the output is as follows:
>
>    [testng] Constructor-i-0
>    [testng] Constructor-j-0
>    [testng] Constructor-i-0
>    [testng] Constructor-j-1
>    [testng] Constructor-i-1
>    [testng] Constructor-j-0
>    [testng] Constructor-i-1
>    [testng] Constructor-j-1
>    [testng] Constructor-i-2
>    [testng] Constructor-j-0
>    [testng] Constructor-i-2
>    [testng] Constructor-j-1
>    [testng] setup-i-2
>    [testng] setup-j-0
>    [testng] testLoginPositive-i-2
>    [testng] testLoginPositive-j-0
>    [testng] cleanup-i-2
>    [testng] cleanup-j-0
>    [testng] setup-i-2
>    [testng] setup-j-1
>    [testng] testLoginPositive-i-2
>    [testng] testLoginPositive-j-1
>    [testng] cleanup-i-2
>    [testng] cleanup-j-1
>    [testng]
>
> As you can see, setup, testLoginPositive and cleanup are called only for the loop i=2. They are not called for i=0 and 1. Why is that so? My understanding was that testng will call all the annotated methods in the class called under factory for all the iterations.
> thanks
> ---------------------------------------------------------------------
> Posted via Jive Forums
> http://forums.opensymphony.com/thread.jspa?threadID=77035&messageID=142213#142213
>
> >
>
>

--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the Google Groups "testng-users" group.
To post to this group, send email to [hidden email]
To unsubscribe from this group, send email to [hidden email]
For more options, visit this group at http://groups.google.com/group/testng-users?hl=en
-~----------~----~----~----~------~----~------~--~---

Reply | Threaded
Open this post in threaded view
|

Re: sequence of method calls in a class instantiated fr

tarun3kumar

I am confused. So how should the result array be created such that all the annoted methods in my test  class are called i*j times ie 3*2=6 times?
thanks
---------------------------------------------------------------------
Posted via Jive Forums
http://forums.opensymphony.com/thread.jspa?threadID=77035&messageID=142233#142233


--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the Google Groups "testng-users" group.
To post to this group, send email to [hidden email]
To unsubscribe from this group, send email to [hidden email]
For more options, visit this group at http://groups.google.com/group/testng-users?hl=en
-~----------~----~----~----~------~----~------~--~---

Reply | Threaded
Open this post in threaded view
|

Re: sequence of method calls in a class instantiated fr

av9999
In reply to this post by Alexandru Popescu ☀

yes. I have opened the issue#153. But Cedric changed to resolved with
the comments as there is a bug in our code...
What should be the value of array?
if I have it  with the i value, if the j is>i, the result array will
be out of boundary.
Thanks
Aruna

On Apr 16, 11:32 am, "Alexandru Popescu ☀"
<[hidden email]> wrote:

> I think you have a flaw in your code:
>
>     @Factory
>     public Object[] testLogin() {
>         Object[] result = null;
>             for (int i=0;i<3;i++) {
>                 result = new Object[2];
>                 for (int j=0;j<2;j++) {
>                     result[j] = new test(i, j);
>                 }
>             }
>         return result;
>     }
>
> For each i look you are reseting result (result= new Object[2]]), so
> by the time the method returns result is an array of 2 object.
> Afterwards the behavior is the expected one.
>
> By the way have you opened a JIRA issue attached to this discussion?
>
> ./alex
> --
> .w( the_mindstorm )p.
>   TestNG co-founder
> EclipseTestNG Creator
>
> On 4/16/07, magnatron <[hidden email]> wrote:
>
> > Hi Alex
> > You can use these file. If you execute them the output is as follows:
>
> >    [testng] Constructor-i-0
> >    [testng] Constructor-j-0
> >    [testng] Constructor-i-0
> >    [testng] Constructor-j-1
> >    [testng] Constructor-i-1
> >    [testng] Constructor-j-0
> >    [testng] Constructor-i-1
> >    [testng] Constructor-j-1
> >    [testng] Constructor-i-2
> >    [testng] Constructor-j-0
> >    [testng] Constructor-i-2
> >    [testng] Constructor-j-1
> >    [testng] setup-i-2
> >    [testng] setup-j-0
> >    [testng] testLoginPositive-i-2
> >    [testng] testLoginPositive-j-0
> >    [testng] cleanup-i-2
> >    [testng] cleanup-j-0
> >    [testng] setup-i-2
> >    [testng] setup-j-1
> >    [testng] testLoginPositive-i-2
> >    [testng] testLoginPositive-j-1
> >    [testng] cleanup-i-2
> >    [testng] cleanup-j-1
> >    [testng]
>
> > As you can see, setup, testLoginPositive and cleanup are called only for the loop i=2. They are not called for i=0 and 1. Why is that so? My understanding was that testng will call all the annotated methods in the class called under factory for all the iterations.
> > thanks
> > ---------------------------------------------------------------------
> > Posted via Jive Forums
> >http://forums.opensymphony.com/thread.jspa?threadID=77035&messageID=1...


--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the Google Groups "testng-users" group.
To post to this group, send email to [hidden email]
To unsubscribe from this group, send email to [hidden email]
For more options, visit this group at http://groups.google.com/group/testng-users?hl=en
-~----------~----~----~----~------~----~------~--~---

Reply | Threaded
Open this post in threaded view
|

Re: sequence of method calls in a class instantiated fr

Cédric Beust ♔


On 4/16/07, av9999 <[hidden email]> wrote:

yes. I have opened the issue#153. But Cedric changed to resolved with
the comments as there is a bug in our code...
What should be the value of array?
if I have it  with the i value, if the j is>i, the result array will
be out of boundary.

Every time you do "result = new Object[2]", you overwrite the previous values.

Try something like this:

List result = new ArrayList();
             for (int i=0;i<3;i++) {
                 for (int j=0;j<2;j++) {
                     result.add(new test(i, j));
                 }
             }
         return result.toArray();

--
Cedric





Thanks
Aruna

On Apr 16, 11:32 am, "Alexandru Popescu ☀"
<[hidden email]> wrote:

> I think you have a flaw in your code:
>
>     @Factory
>     public Object[] testLogin() {
>         Object[] result = null;
>             for (int i=0;i<3;i++) {
>                 result = new Object[2];
>                 for (int j=0;j<2;j++) {
>                     result[j] = new test(i, j);
>                 }
>             }
>         return result;
>     }
>
> For each i look you are reseting result (result= new Object[2]]), so
> by the time the method returns result is an array of 2 object.
> Afterwards the behavior is the expected one.
>
> By the way have you opened a JIRA issue attached to this discussion?
>
> ./alex
> --
> .w( the_mindstorm )p.
>   TestNG co-founder
> EclipseTestNG Creator
>
> On 4/16/07, magnatron < [hidden email]> wrote:
>
> > Hi Alex
> > You can use these file. If you execute them the output is as follows:
>
> >    [testng] Constructor-i-0
> >    [testng] Constructor-j-0
> >    [testng] Constructor-i-0
> >    [testng] Constructor-j-1
> >    [testng] Constructor-i-1
> >    [testng] Constructor-j-0
> >    [testng] Constructor-i-1
> >    [testng] Constructor-j-1
> >    [testng] Constructor-i-2
> >    [testng] Constructor-j-0
> >    [testng] Constructor-i-2
> >    [testng] Constructor-j-1
> >    [testng] setup-i-2
> >    [testng] setup-j-0
> >    [testng] testLoginPositive-i-2
> >    [testng] testLoginPositive-j-0
> >    [testng] cleanup-i-2
> >    [testng] cleanup-j-0
> >    [testng] setup-i-2
> >    [testng] setup-j-1
> >    [testng] testLoginPositive-i-2
> >    [testng] testLoginPositive-j-1
> >    [testng] cleanup-i-2
> >    [testng] cleanup-j-1
> >    [testng]
>
> > As you can see, setup, testLoginPositive and cleanup are called only for the loop i=2. They are not called for i=0 and 1. Why is that so? My understanding was that testng will call all the annotated methods in the class called under factory for all the iterations.
> > thanks
> > ---------------------------------------------------------------------
> > Posted via Jive Forums
> > http://forums.opensymphony.com/thread.jspa?threadID=77035&messageID=1...







--
Cédric
--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the Google Groups "testng-users" group.
To post to this group, send email to [hidden email]
To unsubscribe from this group, send email to [hidden email]
For more options, visit this group at http://groups.google.com/group/testng-users?hl=en
-~----------~----~----~----~------~----~------~--~---

Reply | Threaded
Open this post in threaded view
|

Re: sequence of method calls in a class instantiated fr

av9999

thanks Cedric. it is working only with the latest beta version of
testng.
is this output look correct to you? is the sequence correct?
Why the constructor is called in a row before it invoke the setup and
test methods? It is storing the objects in the memory?

[testng] this is a new test
   [testng] Constructor-i-0
   [testng] Constructor-j-0
   [testng] Constructor-i-0
   [testng] Constructor-j-1
   [testng] Constructor-i-1
   [testng] Constructor-j-0
   [testng] Constructor-i-1
   [testng] Constructor-j-1
   [testng] Constructor-i-2
   [testng] Constructor-j-0
   [testng] Constructor-i-2
   [testng] Constructor-j-1
   [testng] setup-i-0
   [testng] setup-j-0
   [testng] testLoginPositive-i-0
   [testng] testLoginPositive-j-0
   [testng] cleanup-i-0
   [testng] cleanup-j-0
   [testng] setup-i-0
   [testng] setup-j-1
   [testng] testLoginPositive-i-0
   [testng] testLoginPositive-j-1
   [testng] cleanup-i-0
   [testng] cleanup-j-1
   [testng] setup-i-1
   [testng] setup-j-0
   [testng] testLoginPositive-i-1
   [testng] testLoginPositive-j-0
   [testng] cleanup-i-1
   [testng] cleanup-j-0
   [testng] setup-i-1
   [testng] setup-j-1
   [testng] testLoginPositive-i-1
   [testng] testLoginPositive-j-1
   [testng] cleanup-i-1
   [testng] cleanup-j-1
   [testng] setup-i-2
   [testng] setup-j-0
   [testng] testLoginPositive-i-2
   [testng] testLoginPositive-j-0
   [testng] cleanup-i-2
   [testng] cleanup-j-0
   [testng] setup-i-2
   [testng] setup-j-1
   [testng] testLoginPositive-i-2
   [testng] testLoginPositive-j-1
   [testng] cleanup-i-2
   [testng] cleanup-j-1
   [testng]






On Apr 16, 1:15 pm, "Cédric Beust ♔ " <[hidden email]> wrote:

> On 4/16/07, av9999 <[hidden email]> wrote:
>
>
>
> > yes. I have opened the issue#153. But Cedric changed to resolved with
> > the comments as there is a bug in our code...
> > What should be the value of array?
> > if I have it  with the i value, if the j is>i, the result array will
> > be out of boundary.
>
> Every time you do "result = new Object[2]", you overwrite the previous
> values.
>
> Try something like this:
>
> List result = new ArrayList();
>              for (int i=0;i<3;i++) {
>                  for (int j=0;j<2;j++) {
>                      result.add(new test(i, j));
>                  }
>              }
>          return result.toArray();
>
> --
> Cedric
>
> Thanks
>
>
>
> > Aruna
>
> > On Apr 16, 11:32 am, "Alexandru Popescu ☀"
> > <[hidden email]> wrote:
> > > I think you have a flaw in your code:
>
> > >     @Factory
> > >     public Object[] testLogin() {
> > >         Object[] result = null;
> > >             for (int i=0;i<3;i++) {
> > >                 result = new Object[2];
> > >                 for (int j=0;j<2;j++) {
> > >                     result[j] = new test(i, j);
> > >                 }
> > >             }
> > >         return result;
> > >     }
>
> > > For each i look you are reseting result (result= new Object[2]]), so
> > > by the time the method returns result is an array of 2 object.
> > > Afterwards the behavior is the expected one.
>
> > > By the way have you opened a JIRA issue attached to this discussion?
>
> > > ./alex
> > > --
> > > .w( the_mindstorm )p.
> > >   TestNG co-founder
> > > EclipseTestNG Creator
>
> > > On 4/16/07, magnatron <[hidden email]> wrote:
>
> > > > Hi Alex
> > > > You can use these file. If you execute them the output is as follows:
>
> > > >    [testng] Constructor-i-0
> > > >    [testng] Constructor-j-0
> > > >    [testng] Constructor-i-0
> > > >    [testng] Constructor-j-1
> > > >    [testng] Constructor-i-1
> > > >    [testng] Constructor-j-0
> > > >    [testng] Constructor-i-1
> > > >    [testng] Constructor-j-1
> > > >    [testng] Constructor-i-2
> > > >    [testng] Constructor-j-0
> > > >    [testng] Constructor-i-2
> > > >    [testng] Constructor-j-1
> > > >    [testng] setup-i-2
> > > >    [testng] setup-j-0
> > > >    [testng] testLoginPositive-i-2
> > > >    [testng] testLoginPositive-j-0
> > > >    [testng] cleanup-i-2
> > > >    [testng] cleanup-j-0
> > > >    [testng] setup-i-2
> > > >    [testng] setup-j-1
> > > >    [testng] testLoginPositive-i-2
> > > >    [testng] testLoginPositive-j-1
> > > >    [testng] cleanup-i-2
> > > >    [testng] cleanup-j-1
> > > >    [testng]
>
> > > > As you can see, setup, testLoginPositive and cleanup are called only
> > for the loop i=2. They are not called for i=0 and 1. Why is that so? My
> > understanding was that testng will call all the annotated methods in the
> > class called under factory for all the iterations.
> > > > thanks
> > > > ---------------------------------------------------------------------
> > > > Posted via Jive Forums
> > > >http://forums.opensymphony.com/thread.jspa?threadID=77035&messageID=1.
> > ..
>
> --
> Cédric


--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the Google Groups "testng-users" group.
To post to this group, send email to [hidden email]
To unsubscribe from this group, send email to [hidden email]
For more options, visit this group at http://groups.google.com/group/testng-users?hl=en
-~----------~----~----~----~------~----~------~--~---