You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@geronimo.apache.org by "Prasad Kashyap (JIRA)" <ji...@apache.org> on 2006/11/18 16:45:37 UTC

[jira] Created: (GERONIMO-2579) TestNG testcases in testsuite now broken due to 1.5 build

TestNG testcases in testsuite now broken due to 1.5 build
---------------------------------------------------------

                 Key: GERONIMO-2579
                 URL: http://issues.apache.org/jira/browse/GERONIMO-2579
             Project: Geronimo
          Issue Type: Bug
      Security Level: public (Regular issues)
          Components: buildsystem
    Affects Versions: 2.0
            Reporter: Prasad Kashyap
         Assigned To: Jason Dillon
             Fix For: 2.0
         Attachments: testng-jdk15.patch

The testng testcases broke soon after we moved to building G with jdk1.5.

> cd geronimo/testsuite
> apply testng-jdk15.patch:

Patch changes testng dependency to use jdk15 classifier.
It configures the maven-compiler-plugin to use 1.5 for source and target.
It updates the test methods to use jdk1.5 annotations instead of javadoc style comments.

Problem:
------------
[INFO] [INFO] Compilation failure
[INFO] 
[INFO] C:\Apache\geronimo\trunk\testsuite\console-testsuite\basic\src\test\java\org\apache\geronimo\testsuite\console\LinkCheckTest.java:[30,5] annotations are not supported in -source 1.4
[INFO] (try -source 1.5 to enable annotations)
[INFO]     @Test
[INFO] 
[INFO] C:\Apache\geronimo\trunk\testsuite\console-testsuite\basic\src\test\java\org\apache\geronimo\testsuite\console\SeleniumTestSupport.java:[53,5] annotations are not supported in -source 1.4
[INFO] (try -source 1.5 to enable annotations)
[INFO]     @BeforeSuite


-- 
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators: http://issues.apache.org/jira/secure/Administrators.jspa
-
For more information on JIRA, see: http://www.atlassian.com/software/jira

        

[jira] Commented: (GERONIMO-2579) TestNG testcases in testsuite now broken due to 1.5 build

Posted by "Prasad Kashyap (JIRA)" <ji...@apache.org>.
    [ http://issues.apache.org/jira/browse/GERONIMO-2579?page=comments#action_12451175 ] 
            
Prasad Kashyap commented on GERONIMO-2579:
------------------------------------------

Thanx. With those imports I was able to get the test classes compiled and tests run. But now I am back to the same test failures I had before. 

So firstly, it means that moving to jdk1.5 didn't break the tests.

Second, these are the test failures that I now see uniformly with both testng-jdk14 and testng-jdk15.

Example:
-------------
java.lang.NullPointerException
at org.apache.geronimo.testsuite.console.ConsoleTestSupport.login(ConsoleTestSupport.java:31)
at org.apache.geronimo.testsuite.console.LinkCheckTest.testServerInfoLink(LinkCheckTest.java:34)

Seems like the @BeforeSuite is not getting recognised and executed.

The log.info() in SeleniumTestSupport.java don't show up.

> TestNG testcases in testsuite now broken due to 1.5 build
> ---------------------------------------------------------
>
>                 Key: GERONIMO-2579
>                 URL: http://issues.apache.org/jira/browse/GERONIMO-2579
>             Project: Geronimo
>          Issue Type: Bug
>      Security Level: public(Regular issues) 
>          Components: buildsystem
>    Affects Versions: 2.0
>            Reporter: Prasad Kashyap
>         Assigned To: Jason Dillon
>             Fix For: 2.0
>
>         Attachments: testng-jdk15.patch
>
>
> The testng testcases broke soon after we moved to building G with jdk1.5.
> > cd geronimo/testsuite
> > apply testng-jdk15.patch:
> Patch changes testng dependency to use jdk15 classifier.
> It configures the maven-compiler-plugin to use 1.5 for source and target.
> It updates the test methods to use jdk1.5 annotations instead of javadoc style comments.
> Problem:
> ------------
> [INFO] [INFO] Compilation failure
> [INFO] 
> [INFO] C:\Apache\geronimo\trunk\testsuite\console-testsuite\basic\src\test\java\org\apache\geronimo\testsuite\console\LinkCheckTest.java:[30,5] annotations are not supported in -source 1.4
> [INFO] (try -source 1.5 to enable annotations)
> [INFO]     @Test
> [INFO] 
> [INFO] C:\Apache\geronimo\trunk\testsuite\console-testsuite\basic\src\test\java\org\apache\geronimo\testsuite\console\SeleniumTestSupport.java:[53,5] annotations are not supported in -source 1.4
> [INFO] (try -source 1.5 to enable annotations)
> [INFO]     @BeforeSuite

-- 
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators: http://issues.apache.org/jira/secure/Administrators.jspa
-
For more information on JIRA, see: http://www.atlassian.com/software/jira

        

[jira] Closed: (GERONIMO-2579) TestNG testcases in testsuite broken. JUnit expected. Move to JUnit 4.0 ?

Posted by "Jason Dillon (JIRA)" <ji...@apache.org>.
     [ http://issues.apache.org/jira/browse/GERONIMO-2579?page=all ]

Jason Dillon closed GERONIMO-2579.
----------------------------------

    Resolution: Won't Fix

TestNG with Surefire 2.3-SNAPSHOT appears to work fine with JDK 1.5 annotations.  Appears that you need to use a suite.xml to get the @BeforeSuite and @AfterSuite annotations to get triggered though... that may be a bug in how Surefire has implemented TestNG support though.

> TestNG testcases in testsuite broken. JUnit expected. Move to JUnit 4.0 ?
> -------------------------------------------------------------------------
>
>                 Key: GERONIMO-2579
>                 URL: http://issues.apache.org/jira/browse/GERONIMO-2579
>             Project: Geronimo
>          Issue Type: Bug
>      Security Level: public(Regular issues) 
>          Components: buildsystem
>    Affects Versions: 2.0
>            Reporter: Prasad Kashyap
>         Assigned To: Jason Dillon
>             Fix For: 2.0
>
>         Attachments: testng-jdk15.patch
>
>
> The testng testcases broke soon after we moved to building G with jdk1.5.
> > cd geronimo/testsuite
> > apply testng-jdk15.patch:
> Patch changes testng dependency to use jdk15 classifier.
> It configures the maven-compiler-plugin to use 1.5 for source and target.
> It updates the test methods to use jdk1.5 annotations instead of javadoc style comments.
> Problem:
> ------------
> [INFO] [INFO] Compilation failure
> [INFO] 
> [INFO] C:\Apache\geronimo\trunk\testsuite\console-testsuite\basic\src\test\java\org\apache\geronimo\testsuite\console\LinkCheckTest.java:[30,5] annotations are not supported in -source 1.4
> [INFO] (try -source 1.5 to enable annotations)
> [INFO]     @Test
> [INFO] 
> [INFO] C:\Apache\geronimo\trunk\testsuite\console-testsuite\basic\src\test\java\org\apache\geronimo\testsuite\console\SeleniumTestSupport.java:[53,5] annotations are not supported in -source 1.4
> [INFO] (try -source 1.5 to enable annotations)
> [INFO]     @BeforeSuite

-- 
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators: http://issues.apache.org/jira/secure/Administrators.jspa
-
For more information on JIRA, see: http://www.atlassian.com/software/jira

        

[jira] Commented: (GERONIMO-2579) TestNG testcases in testsuite now broken due to 1.5 build

Posted by "Prasad Kashyap (JIRA)" <ji...@apache.org>.
    [ http://issues.apache.org/jira/browse/GERONIMO-2579?page=comments#action_12451225 ] 
            
Prasad Kashyap commented on GERONIMO-2579:
------------------------------------------

I think is caused by the junit dependency that is inherited from the Geronimo root pom. Surefire disregards testng javadoc/annotation and looks for junit setUp and tearDown.

I added a setUp and tearDown and the tests succeed.

JUnit 4.0 now has @Before and @After for suite level setUp and tearDown. We went with testng since this req'd feature was missing in JUnit. Can we move up to JUnit 4.0 and ditch testng ?

> TestNG testcases in testsuite now broken due to 1.5 build
> ---------------------------------------------------------
>
>                 Key: GERONIMO-2579
>                 URL: http://issues.apache.org/jira/browse/GERONIMO-2579
>             Project: Geronimo
>          Issue Type: Bug
>      Security Level: public(Regular issues) 
>          Components: buildsystem
>    Affects Versions: 2.0
>            Reporter: Prasad Kashyap
>         Assigned To: Jason Dillon
>             Fix For: 2.0
>
>         Attachments: testng-jdk15.patch
>
>
> The testng testcases broke soon after we moved to building G with jdk1.5.
> > cd geronimo/testsuite
> > apply testng-jdk15.patch:
> Patch changes testng dependency to use jdk15 classifier.
> It configures the maven-compiler-plugin to use 1.5 for source and target.
> It updates the test methods to use jdk1.5 annotations instead of javadoc style comments.
> Problem:
> ------------
> [INFO] [INFO] Compilation failure
> [INFO] 
> [INFO] C:\Apache\geronimo\trunk\testsuite\console-testsuite\basic\src\test\java\org\apache\geronimo\testsuite\console\LinkCheckTest.java:[30,5] annotations are not supported in -source 1.4
> [INFO] (try -source 1.5 to enable annotations)
> [INFO]     @Test
> [INFO] 
> [INFO] C:\Apache\geronimo\trunk\testsuite\console-testsuite\basic\src\test\java\org\apache\geronimo\testsuite\console\SeleniumTestSupport.java:[53,5] annotations are not supported in -source 1.4
> [INFO] (try -source 1.5 to enable annotations)
> [INFO]     @BeforeSuite

-- 
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators: http://issues.apache.org/jira/secure/Administrators.jspa
-
For more information on JIRA, see: http://www.atlassian.com/software/jira

        

[jira] Commented: (GERONIMO-2579) TestNG testcases in testsuite now broken due to 1.5 build

Posted by "Jason Dillon (JIRA)" <ji...@apache.org>.
    [ http://issues.apache.org/jira/browse/GERONIMO-2579?page=comments#action_12451111 ] 
            
Jason Dillon commented on GERONIMO-2579:
----------------------------------------

Appears you need to import the annotations, as in:

{code:java}
import org.testng.annotations.Test;
import org.testng.annotations.BeforeSuite;
import org.testng.annotations.AfterSuite;
{code}


> TestNG testcases in testsuite now broken due to 1.5 build
> ---------------------------------------------------------
>
>                 Key: GERONIMO-2579
>                 URL: http://issues.apache.org/jira/browse/GERONIMO-2579
>             Project: Geronimo
>          Issue Type: Bug
>      Security Level: public(Regular issues) 
>          Components: buildsystem
>    Affects Versions: 2.0
>            Reporter: Prasad Kashyap
>         Assigned To: Jason Dillon
>             Fix For: 2.0
>
>         Attachments: testng-jdk15.patch
>
>
> The testng testcases broke soon after we moved to building G with jdk1.5.
> > cd geronimo/testsuite
> > apply testng-jdk15.patch:
> Patch changes testng dependency to use jdk15 classifier.
> It configures the maven-compiler-plugin to use 1.5 for source and target.
> It updates the test methods to use jdk1.5 annotations instead of javadoc style comments.
> Problem:
> ------------
> [INFO] [INFO] Compilation failure
> [INFO] 
> [INFO] C:\Apache\geronimo\trunk\testsuite\console-testsuite\basic\src\test\java\org\apache\geronimo\testsuite\console\LinkCheckTest.java:[30,5] annotations are not supported in -source 1.4
> [INFO] (try -source 1.5 to enable annotations)
> [INFO]     @Test
> [INFO] 
> [INFO] C:\Apache\geronimo\trunk\testsuite\console-testsuite\basic\src\test\java\org\apache\geronimo\testsuite\console\SeleniumTestSupport.java:[53,5] annotations are not supported in -source 1.4
> [INFO] (try -source 1.5 to enable annotations)
> [INFO]     @BeforeSuite

-- 
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators: http://issues.apache.org/jira/secure/Administrators.jspa
-
For more information on JIRA, see: http://www.atlassian.com/software/jira

        

[jira] Updated: (GERONIMO-2579) TestNG testcases in testsuite broken. JUnit expected. Move to JUnit 4.0 ?

Posted by "Prasad Kashyap (JIRA)" <ji...@apache.org>.
     [ http://issues.apache.org/jira/browse/GERONIMO-2579?page=all ]

Prasad Kashyap updated GERONIMO-2579:
-------------------------------------

    Summary: TestNG testcases in testsuite broken. JUnit expected. Move to JUnit 4.0 ?  (was: TestNG testcases in testsuite now broken due to 1.5 build)

> TestNG testcases in testsuite broken. JUnit expected. Move to JUnit 4.0 ?
> -------------------------------------------------------------------------
>
>                 Key: GERONIMO-2579
>                 URL: http://issues.apache.org/jira/browse/GERONIMO-2579
>             Project: Geronimo
>          Issue Type: Bug
>      Security Level: public(Regular issues) 
>          Components: buildsystem
>    Affects Versions: 2.0
>            Reporter: Prasad Kashyap
>         Assigned To: Jason Dillon
>             Fix For: 2.0
>
>         Attachments: testng-jdk15.patch
>
>
> The testng testcases broke soon after we moved to building G with jdk1.5.
> > cd geronimo/testsuite
> > apply testng-jdk15.patch:
> Patch changes testng dependency to use jdk15 classifier.
> It configures the maven-compiler-plugin to use 1.5 for source and target.
> It updates the test methods to use jdk1.5 annotations instead of javadoc style comments.
> Problem:
> ------------
> [INFO] [INFO] Compilation failure
> [INFO] 
> [INFO] C:\Apache\geronimo\trunk\testsuite\console-testsuite\basic\src\test\java\org\apache\geronimo\testsuite\console\LinkCheckTest.java:[30,5] annotations are not supported in -source 1.4
> [INFO] (try -source 1.5 to enable annotations)
> [INFO]     @Test
> [INFO] 
> [INFO] C:\Apache\geronimo\trunk\testsuite\console-testsuite\basic\src\test\java\org\apache\geronimo\testsuite\console\SeleniumTestSupport.java:[53,5] annotations are not supported in -source 1.4
> [INFO] (try -source 1.5 to enable annotations)
> [INFO]     @BeforeSuite

-- 
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators: http://issues.apache.org/jira/secure/Administrators.jspa
-
For more information on JIRA, see: http://www.atlassian.com/software/jira

        

[jira] Updated: (GERONIMO-2579) TestNG testcases in testsuite now broken due to 1.5 build

Posted by "Prasad Kashyap (JIRA)" <ji...@apache.org>.
     [ http://issues.apache.org/jira/browse/GERONIMO-2579?page=all ]

Prasad Kashyap updated GERONIMO-2579:
-------------------------------------

    Attachment: testng-jdk15.patch

> TestNG testcases in testsuite now broken due to 1.5 build
> ---------------------------------------------------------
>
>                 Key: GERONIMO-2579
>                 URL: http://issues.apache.org/jira/browse/GERONIMO-2579
>             Project: Geronimo
>          Issue Type: Bug
>      Security Level: public(Regular issues) 
>          Components: buildsystem
>    Affects Versions: 2.0
>            Reporter: Prasad Kashyap
>         Assigned To: Jason Dillon
>             Fix For: 2.0
>
>         Attachments: testng-jdk15.patch
>
>
> The testng testcases broke soon after we moved to building G with jdk1.5.
> > cd geronimo/testsuite
> > apply testng-jdk15.patch:
> Patch changes testng dependency to use jdk15 classifier.
> It configures the maven-compiler-plugin to use 1.5 for source and target.
> It updates the test methods to use jdk1.5 annotations instead of javadoc style comments.
> Problem:
> ------------
> [INFO] [INFO] Compilation failure
> [INFO] 
> [INFO] C:\Apache\geronimo\trunk\testsuite\console-testsuite\basic\src\test\java\org\apache\geronimo\testsuite\console\LinkCheckTest.java:[30,5] annotations are not supported in -source 1.4
> [INFO] (try -source 1.5 to enable annotations)
> [INFO]     @Test
> [INFO] 
> [INFO] C:\Apache\geronimo\trunk\testsuite\console-testsuite\basic\src\test\java\org\apache\geronimo\testsuite\console\SeleniumTestSupport.java:[53,5] annotations are not supported in -source 1.4
> [INFO] (try -source 1.5 to enable annotations)
> [INFO]     @BeforeSuite

-- 
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators: http://issues.apache.org/jira/secure/Administrators.jspa
-
For more information on JIRA, see: http://www.atlassian.com/software/jira

        

[jira] Commented: (GERONIMO-2579) TestNG testcases in testsuite now broken due to 1.5 build

Posted by "Prasad Kashyap (JIRA)" <ji...@apache.org>.
    [ http://issues.apache.org/jira/browse/GERONIMO-2579?page=comments#action_12451110 ] 
            
Prasad Kashyap commented on GERONIMO-2579:
------------------------------------------

Sorry. Please disregard the above error msgs. Here are the actual errors msgs as seen on the 2.0-SNAPSHOT build

[INFO] [INFO] Compilation failure
[INFO] 
[INFO] C:\Apache\geronimo\trunk\testsuite\console-testsuite\basic\src\test\java\org\apache\geronimo\testsuite\console\LinkCheckTest.java:[30,5] cannot find symbol
[INFO] symbol  : class Test
[INFO] location: class org.apache.geronimo.testsuite.console.LinkCheckTest
[INFO] 
[INFO] C:\Apache\geronimo\trunk\testsuite\console-testsuite\basic\src\test\java\org\apache\geronimo\testsuite\console\SeleniumTestSupport.java:[53,5] cannot find symbol
[INFO] symbol  : class BeforeSuite
[INFO] location: class org.apache.geronimo.testsuite.console.SeleniumTestSupport
[INFO] 
[INFO] C:\Apache\geronimo\trunk\testsuite\console-testsuite\basic\src\test\java\org\apache\geronimo\testsuite\console\SeleniumTestSupport.java:[61,5] cannot find symbol
[INFO] symbol  : class AfterSuite
[INFO] location: class org.apache.geronimo.testsuite.console.SeleniumTestSupport
[INFO] 
[INFO] C:\Apache\geronimo\trunk\testsuite\console-testsuite\basic\src\test\java\org\apache\geronimo\testsuite\console\SimpleLoginTest.java:[30,5] cannot find symbol
[INFO] symbol  : class Test
[INFO] location: class org.apache.geronimo.testsuite.console.SimpleLoginTest
[INFO] 
[INFO] C:\Apache\geronimo\trunk\testsuite\console-testsuite\basic\src\test\java\org\apache\geronimo\testsuite\console\SimpleLoginTest.java:[37,5] cannot find symbol
[INFO] symbol  : class Test
[INFO] location: class org.apache.geronimo.testsuite.console.SimpleLoginTest
[INFO] 
[INFO] C:\Apache\geronimo\trunk\testsuite\console-testsuite\basic\src\test\java\org\apache\geronimo\testsuite\console\SimpleLoginTest.java:[43,5] cannot find symbol
[INFO] symbol  : class Test
[INFO] location: class org.apache.geronimo.testsuite.console.SimpleLoginTest
[INFO] 

> TestNG testcases in testsuite now broken due to 1.5 build
> ---------------------------------------------------------
>
>                 Key: GERONIMO-2579
>                 URL: http://issues.apache.org/jira/browse/GERONIMO-2579
>             Project: Geronimo
>          Issue Type: Bug
>      Security Level: public(Regular issues) 
>          Components: buildsystem
>    Affects Versions: 2.0
>            Reporter: Prasad Kashyap
>         Assigned To: Jason Dillon
>             Fix For: 2.0
>
>         Attachments: testng-jdk15.patch
>
>
> The testng testcases broke soon after we moved to building G with jdk1.5.
> > cd geronimo/testsuite
> > apply testng-jdk15.patch:
> Patch changes testng dependency to use jdk15 classifier.
> It configures the maven-compiler-plugin to use 1.5 for source and target.
> It updates the test methods to use jdk1.5 annotations instead of javadoc style comments.
> Problem:
> ------------
> [INFO] [INFO] Compilation failure
> [INFO] 
> [INFO] C:\Apache\geronimo\trunk\testsuite\console-testsuite\basic\src\test\java\org\apache\geronimo\testsuite\console\LinkCheckTest.java:[30,5] annotations are not supported in -source 1.4
> [INFO] (try -source 1.5 to enable annotations)
> [INFO]     @Test
> [INFO] 
> [INFO] C:\Apache\geronimo\trunk\testsuite\console-testsuite\basic\src\test\java\org\apache\geronimo\testsuite\console\SeleniumTestSupport.java:[53,5] annotations are not supported in -source 1.4
> [INFO] (try -source 1.5 to enable annotations)
> [INFO]     @BeforeSuite

-- 
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators: http://issues.apache.org/jira/secure/Administrators.jspa
-
For more information on JIRA, see: http://www.atlassian.com/software/jira