Re: Error running Maven Tests with powermock and junit

2011-07-15 Thread Greg Akins
On Fri, Jul 15, 2011 at 9:35 AM, Chiara chiara_sime...@hotmail.it wrote:
 Hi,
 I am not being able to run Powermock through maven.
 I've an ejb 2.0 project and i've put under test folder my test's classes.

Everything looked ok to me.  But to make sure.. Did you put the tests
in project root/src/test/java ?

-- 
Greg Akins
http://twitter.com/akinsgre

-
To unsubscribe, e-mail: users-unsubscr...@maven.apache.org
For additional commands, e-mail: users-h...@maven.apache.org



RE: Error running Maven Tests with powermock and junit

2011-07-15 Thread Chiara

Hi, yes i've put all test under this folder.
I don't know what to do seriously.. 'cause if i try to run test using run as 
junit tests it works..

Date: Fri, 15 Jul 2011 06:42:28 -0700
From: ml-node+4590720-191037357-230...@n5.nabble.com
To: chiara_sime...@hotmail.it
Subject: Re: Error running Maven Tests with powermock and junit



On Fri, Jul 15, 2011 at 9:35 AM, Chiara [hidden email] wrote:

 Hi,

 I am not being able to run Powermock through maven.

 I've an ejb 2.0 project and i've put under test folder my test's classes.


Everything looked ok to me.  But to make sure.. Did you put the tests

in project root/src/test/java ?


-- 

Greg Akins

http://twitter.com/akinsgre

-

To unsubscribe, e-mail: [hidden email]

For additional commands, e-mail: [hidden email]










If you reply to this email, your message will be added to the 
discussion below:

http://maven.40175.n5.nabble.com/Error-running-Maven-Tests-with-powermock-and-junit-tp4590673p4590720.html



To unsubscribe from Error running Maven Tests with powermock 
and junit, click here.
  

--
View this message in context: 
http://maven.40175.n5.nabble.com/Error-running-Maven-Tests-with-powermock-and-junit-tp4590673p4590726.html
Sent from the Maven - Users mailing list archive at Nabble.com.

Re: Error running Maven Tests with powermock and junit

2011-07-15 Thread Greg Akins
On Fri, Jul 15, 2011 at 9:44 AM, Chiara chiara_sime...@hotmail.it wrote:

 Hi, yes i've put all test under this folder.
 I don't know what to do seriously.. 'cause if i try to run test using run as 
 junit tests it works..

So the only change you make.. after the JUnit tests run, is to add the
@RunWith(PowerMockRunner.class) attribute?

And then the tests are not recognized?

-- 
Greg Akins
http://twitter.com/akinsgre

-
To unsubscribe, e-mail: users-unsubscr...@maven.apache.org
For additional commands, e-mail: users-h...@maven.apache.org



Re: Error running Maven Tests with powermock and junit

2011-07-15 Thread Guillaume Polet

Does your class containing the tests matches the default include patterns?
 
http://maven.apache.org/plugins/maven-surefire-plugin/test-mojo.html#includes


includes
include**/Test*.java/include
include**/*Test.java/include
include**/*TestCase.java/include
/includes

Guillaume

Le 15/07/2011 15:51, Greg Akins a écrit :

On Fri, Jul 15, 2011 at 9:44 AM, Chiarachiara_sime...@hotmail.it  wrote:

Hi, yes i've put all test under this folder.
I don't know what to do seriously.. 'cause if i try to run test using run as 
junit tests it works..

So the only change you make.. after the JUnit tests run, is to add the
@RunWith(PowerMockRunner.class) attribute?

And then the tests are not recognized?




-
To unsubscribe, e-mail: users-unsubscr...@maven.apache.org
For additional commands, e-mail: users-h...@maven.apache.org



RE: Error running Maven Tests with powermock and junit

2011-07-15 Thread Chiara

Yes 'cause my test class is AdapterTest.java

I have to add some specific plugin ??

Plugin i've added to project are :

plugin
groupIdorg.codehaus.mojo/groupId
artifactIdwas6-maven-plugin/artifactId
version1.1.2/version
executions
execution
goals
goalejbdeploy/goal
/goals
/execution
/executions
configuration
wasHome${was61.home}/wasHome
/configuration
/plugin
plugin
groupIdorg.apache.maven.plugins/groupId
artifactIdmaven-ejb-plugin/artifactId
version2.3/version
configuration
ejbVersion2.1/ejbVersion
generateClienttrue/generateClient
archive
manifest
addClasspathtrue/addClasspath
/manifest
indexfalse/index
addMavenDescriptorfalse/addMavenDescriptor
/archive
/configuration
/plugin 

thk a lot

Date: Fri, 15 Jul 2011 07:05:39 -0700
From: ml-node+4590805-1772571158-230...@n5.nabble.com
To: chiara_sime...@hotmail.it
Subject: Re: Error running Maven Tests with powermock and junit



Does your class containing the tests matches the default include 
patterns?

  

http://maven.apache.org/plugins/maven-surefire-plugin/test-mojo.html#includes

includes

include**/Test*.java/include

include**/*Test.java/include

include**/*TestCase.java/include

/includes


Guillaume


Le 15/07/2011 15:51, Greg Akins a écrit :

 On Fri, Jul 15, 2011 at 9:44 AM, Chiara[hidden email]  wrote:

 Hi, yes i've put all test under this folder.

 I don't know what to do seriously.. 'cause if i try to run test using run as 
 junit tests it works..

 So the only change you make.. after the JUnit tests run, is to add the

 @RunWith(PowerMockRunner.class) attribute?



 And then the tests are not recognized?





-

To unsubscribe, e-mail: [hidden email]

For additional commands, e-mail: [hidden email]










If you reply to this email, your message will be added to the 
discussion below:

http://maven.40175.n5.nabble.com/Error-running-Maven-Tests-with-powermock-and-junit-tp4590673p4590805.html



To unsubscribe from Error running Maven Tests with powermock 
and junit, click here.
  

--
View this message in context: 
http://maven.40175.n5.nabble.com/Error-running-Maven-Tests-with-powermock-and-junit-tp4590673p4590845.html
Sent from the Maven - Users mailing list archive at Nabble.com.

Re: Error running Maven Tests with powermock and junit

2011-07-15 Thread Wayne Fay
 Yes 'cause my test class is AdapterTest.java

 I have to add some specific plugin ??

Perhaps try mvn -X ... and see if you notice anything interesting in
the debug output? Otherwise maybe post the output of that command to
www.pastebin.com and send a link here (please do NOT send the full log
via email) and someone can take a look at it.

Also, if you can package up a sample project that demonstrates this
behavior consistently, that may be helpful for diagnosing the problem
and providing a fix.

Wayne

-
To unsubscribe, e-mail: users-unsubscr...@maven.apache.org
For additional commands, e-mail: users-h...@maven.apache.org