You are viewing a plain text version of this content. The canonical link for it is here.
Posted to derby-dev@db.apache.org by "Ugo Matrangolo (JIRA)" <ji...@apache.org> on 2007/05/30 00:26:15 UTC

[jira] Created: (DERBY-2727) convert lang/AggregateClassLoading to JUnit.

convert lang/AggregateClassLoading to JUnit.
--------------------------------------------

                 Key: DERBY-2727
                 URL: https://issues.apache.org/jira/browse/DERBY-2727
             Project: Derby
          Issue Type: Test
          Components: Test
            Reporter: Ugo Matrangolo
            Priority: Minor




-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.


[jira] Updated: (DERBY-2727) convert lang/AggregateClassLoading to JUnit.

Posted by "Ugo Matrangolo (JIRA)" <ji...@apache.org>.
     [ https://issues.apache.org/jira/browse/DERBY-2727?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]

Ugo Matrangolo updated DERBY-2727:
----------------------------------

    Derby Info: [Patch Available]

> convert lang/AggregateClassLoading to JUnit.
> --------------------------------------------
>
>                 Key: DERBY-2727
>                 URL: https://issues.apache.org/jira/browse/DERBY-2727
>             Project: Derby
>          Issue Type: Test
>          Components: Test
>            Reporter: Ugo Matrangolo
>            Assignee: Ugo Matrangolo
>            Priority: Minor
>         Attachments: DERBY-2727_diff_120607.txt, DERBY-2727_diff_240607.txt, DERBY-2727_stat_120607.txt, DERBY-2727_stat_240607.txt
>
>


-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.


[jira] Closed: (DERBY-2727) convert lang/AggregateClassLoading to JUnit.

Posted by "Ugo Matrangolo (JIRA)" <ji...@apache.org>.
     [ https://issues.apache.org/jira/browse/DERBY-2727?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]

Ugo Matrangolo closed DERBY-2727.
---------------------------------


> convert lang/AggregateClassLoading to JUnit.
> --------------------------------------------
>
>                 Key: DERBY-2727
>                 URL: https://issues.apache.org/jira/browse/DERBY-2727
>             Project: Derby
>          Issue Type: Test
>          Components: Test
>            Reporter: Ugo Matrangolo
>            Assignee: Ugo Matrangolo
>            Priority: Minor
>             Fix For: 10.4.0.0
>
>         Attachments: DERBY-2727_diff_120607.txt, DERBY-2727_diff_240607.txt, DERBY-2727_stat_120607.txt, DERBY-2727_stat_240607.txt
>
>


-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.


[jira] Commented: (DERBY-2727) convert lang/AggregateClassLoading to JUnit.

Posted by "Kathey Marsden (JIRA)" <ji...@apache.org>.
    [ https://issues.apache.org/jira/browse/DERBY-2727?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel#action_12504024 ] 

Kathey Marsden commented on DERBY-2727:
---------------------------------------

I see that for the original test there is a AggregateClassLoading_app.properties
which has:


# this test creates a class loader, adding that permission to
# derbyTesting.jar would mean that permission was granted all
# the way up the stack to the derby engine. Thus increasing
# the chance that incorrectly a privileged block could be dropped
# but the tests continue to pass.
noSecurityManager=true

The equivalant junit decorator is org.apache.derbyTesting.junit.SecurityManagerSetup.noSecurityManager(Test test);
http://db.apache.org/derby/javadoc/testing/org/apache/derbyTesting/junit/SecurityManagerSetup.html#noSecurityManager(junit.framework.Test)



> convert lang/AggregateClassLoading to JUnit.
> --------------------------------------------
>
>                 Key: DERBY-2727
>                 URL: https://issues.apache.org/jira/browse/DERBY-2727
>             Project: Derby
>          Issue Type: Test
>          Components: Test
>            Reporter: Ugo Matrangolo
>            Assignee: Ugo Matrangolo
>            Priority: Minor
>         Attachments: DERBY-2727_diff_120607.txt, DERBY-2727_stat_120607.txt
>
>


-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.


[jira] Commented: (DERBY-2727) convert lang/AggregateClassLoading to JUnit.

Posted by "Ugo Matrangolo (JIRA)" <ji...@apache.org>.
    [ https://issues.apache.org/jira/browse/DERBY-2727?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel#action_12504002 ] 

Ugo Matrangolo commented on DERBY-2727:
---------------------------------------

Followinf from the previous comment: the code that fails is :

/*
 * Find the location of the code for the Derby connection. The
 * rest of the engine will be at the same location!
 */			
derbyURL = s.getConnection().getClass().getProtectionDomain().getCodeSource().getLocation();

borrowed from the old test. I suspect that the context is not the same of the old harness test.

-- Ugo.


> convert lang/AggregateClassLoading to JUnit.
> --------------------------------------------
>
>                 Key: DERBY-2727
>                 URL: https://issues.apache.org/jira/browse/DERBY-2727
>             Project: Derby
>          Issue Type: Test
>          Components: Test
>            Reporter: Ugo Matrangolo
>            Assignee: Ugo Matrangolo
>            Priority: Minor
>         Attachments: DERBY-2727_diff_120607.txt, DERBY-2727_stat_120607.txt
>
>


-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.


[jira] Updated: (DERBY-2727) convert lang/AggregateClassLoading to JUnit.

Posted by "Ugo Matrangolo (JIRA)" <ji...@apache.org>.
     [ https://issues.apache.org/jira/browse/DERBY-2727?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]

Ugo Matrangolo updated DERBY-2727:
----------------------------------

    Attachment: DERBY-2727_stat_240607.txt
                DERBY-2727_diff_240607.txt

> convert lang/AggregateClassLoading to JUnit.
> --------------------------------------------
>
>                 Key: DERBY-2727
>                 URL: https://issues.apache.org/jira/browse/DERBY-2727
>             Project: Derby
>          Issue Type: Test
>          Components: Test
>            Reporter: Ugo Matrangolo
>            Assignee: Ugo Matrangolo
>            Priority: Minor
>         Attachments: DERBY-2727_diff_120607.txt, DERBY-2727_diff_240607.txt, DERBY-2727_stat_120607.txt, DERBY-2727_stat_240607.txt
>
>


-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.


[jira] Resolved: (DERBY-2727) convert lang/AggregateClassLoading to JUnit.

Posted by "Myrna van Lunteren (JIRA)" <ji...@apache.org>.
     [ https://issues.apache.org/jira/browse/DERBY-2727?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]

Myrna van Lunteren resolved DERBY-2727.
---------------------------------------

       Resolution: Fixed
    Fix Version/s: 10.4.0.0

It appears to me that this is fixed, now. Leaving to reporter to close.

> convert lang/AggregateClassLoading to JUnit.
> --------------------------------------------
>
>                 Key: DERBY-2727
>                 URL: https://issues.apache.org/jira/browse/DERBY-2727
>             Project: Derby
>          Issue Type: Test
>          Components: Test
>            Reporter: Ugo Matrangolo
>            Assignee: Ugo Matrangolo
>            Priority: Minor
>             Fix For: 10.4.0.0
>
>         Attachments: DERBY-2727_diff_120607.txt, DERBY-2727_diff_240607.txt, DERBY-2727_stat_120607.txt, DERBY-2727_stat_240607.txt
>
>


-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.


[jira] Commented: (DERBY-2727) convert lang/AggregateClassLoading to JUnit.

Posted by "Kathey Marsden (JIRA)" <ji...@apache.org>.
    [ https://issues.apache.org/jira/browse/DERBY-2727?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel#action_12507923 ] 

Kathey Marsden commented on DERBY-2727:
---------------------------------------

I committed this patch with the following changes.
- Removed old test files
- Removed Database/System property setup for usedefaults.  usedefaults has no meaning outside the old test harness.

Thanks  Ugo!


> convert lang/AggregateClassLoading to JUnit.
> --------------------------------------------
>
>                 Key: DERBY-2727
>                 URL: https://issues.apache.org/jira/browse/DERBY-2727
>             Project: Derby
>          Issue Type: Test
>          Components: Test
>            Reporter: Ugo Matrangolo
>            Assignee: Ugo Matrangolo
>            Priority: Minor
>         Attachments: DERBY-2727_diff_120607.txt, DERBY-2727_diff_240607.txt, DERBY-2727_stat_120607.txt, DERBY-2727_stat_240607.txt
>
>


-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.


[jira] Commented: (DERBY-2727) convert lang/AggregateClassLoading to JUnit.

Posted by "Daniel John Debrunner (JIRA)" <ji...@apache.org>.
    [ https://issues.apache.org/jira/browse/DERBY-2727?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel#action_12508348 ] 

Daniel John Debrunner commented on DERBY-2727:
----------------------------------------------

I have a fix for this but cannot apply it because the patch was already reverted

> convert lang/AggregateClassLoading to JUnit.
> --------------------------------------------
>
>                 Key: DERBY-2727
>                 URL: https://issues.apache.org/jira/browse/DERBY-2727
>             Project: Derby
>          Issue Type: Test
>          Components: Test
>            Reporter: Ugo Matrangolo
>            Assignee: Ugo Matrangolo
>            Priority: Minor
>         Attachments: DERBY-2727_diff_120607.txt, DERBY-2727_diff_240607.txt, DERBY-2727_stat_120607.txt, DERBY-2727_stat_240607.txt
>
>


-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.


[jira] Commented: (DERBY-2727) convert lang/AggregateClassLoading to JUnit.

Posted by "Ugo Matrangolo (JIRA)" <ji...@apache.org>.
    [ https://issues.apache.org/jira/browse/DERBY-2727?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel#action_12504161 ] 

Ugo Matrangolo commented on DERBY-2727:
---------------------------------------

Thank you Kathey. I will modify the code asap.

Bye,
-- Ugo


> convert lang/AggregateClassLoading to JUnit.
> --------------------------------------------
>
>                 Key: DERBY-2727
>                 URL: https://issues.apache.org/jira/browse/DERBY-2727
>             Project: Derby
>          Issue Type: Test
>          Components: Test
>            Reporter: Ugo Matrangolo
>            Assignee: Ugo Matrangolo
>            Priority: Minor
>         Attachments: DERBY-2727_diff_120607.txt, DERBY-2727_stat_120607.txt
>
>


-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.


[jira] Updated: (DERBY-2727) convert lang/AggregateClassLoading to JUnit.

Posted by "Kathey Marsden (JIRA)" <ji...@apache.org>.
     [ https://issues.apache.org/jira/browse/DERBY-2727?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]

Kathey Marsden updated DERBY-2727:
----------------------------------

    Derby Info:   (was: [Patch Available])

> convert lang/AggregateClassLoading to JUnit.
> --------------------------------------------
>
>                 Key: DERBY-2727
>                 URL: https://issues.apache.org/jira/browse/DERBY-2727
>             Project: Derby
>          Issue Type: Test
>          Components: Test
>            Reporter: Ugo Matrangolo
>            Assignee: Ugo Matrangolo
>            Priority: Minor
>         Attachments: DERBY-2727_diff_120607.txt, DERBY-2727_diff_240607.txt, DERBY-2727_stat_120607.txt, DERBY-2727_stat_240607.txt
>
>


-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.


[jira] Updated: (DERBY-2727) convert lang/AggregateClassLoading to JUnit.

Posted by "Ugo Matrangolo (JIRA)" <ji...@apache.org>.
     [ https://issues.apache.org/jira/browse/DERBY-2727?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]

Ugo Matrangolo updated DERBY-2727:
----------------------------------

    Attachment: DERBY-2727_stat_120607.txt
                DERBY-2727_diff_120607.txt

Initial attempt to convert this test.

At first sight it seems trivial to convert but, obviously, he doesn't work! :)

Running the test I get a security exception:

java.security.AccessControlException: access denied (java.lang.RuntimePermission getProtectionDomain)
	at java.security.AccessControlContext.checkPermission(AccessControlContext.java:269)
	at java.security.AccessController.checkPermission(AccessController.java:401)
	at java.lang.SecurityManager.checkPermission(SecurityManager.java:524)
	at java.lang.Class.getProtectionDomain(Class.java:1392)
	at org.apache.derbyTesting.functionTests.tests.lang.AggregateClassLoadingTest$1.decorateSQL(AggregateClassLoadingTest.java:106)
	at org.apache.derbyTesting.junit.CleanDatabaseTestSetup.setUp(CleanDatabaseTestSetup.java:70)
	at junit.extensions.TestSetup$1.protect(TestSetup.java:20)
	at junit.framework.TestResult.runProtected(TestResult.java:124)
	at junit.extensions.TestSetup.run(TestSetup.java:25)
	at org.apache.derbyTesting.junit.BaseTestSetup.run(BaseTestSetup.java:57)
	at junit.extensions.TestDecorator.basicRun(TestDecorator.java:24)
	at junit.extensions.TestSetup$1.protect(TestSetup.java:21)
	at junit.framework.TestResult.runProtected(TestResult.java:124)
	at junit.extensions.TestSetup.run(TestSetup.java:25)
	at junit.extensions.TestDecorator.basicRun(TestDecorator.java:24)
	at junit.extensions.TestSetup$1.protect(TestSetup.java:21)
	at junit.framework.TestResult.runProtected(TestResult.java:124)
	at junit.extensions.TestSetup.run(TestSetup.java:25)
	at org.apache.derbyTesting.junit.BaseTestSetup.run(BaseTestSetup.java:57)
	at org.eclipse.jdt.internal.junit.runner.junit3.JUnit3TestReference.run(JUnit3TestReference.java:128)
	at org.eclipse.jdt.internal.junit.runner.TestExecution.run(TestExecution.java:38)
	at org.eclipse.jdt.internal.junit.runner.RemoteTestRunner.runTests(RemoteTestRunner.java:460)
	at org.eclipse.jdt.internal.junit.runner.RemoteTestRunner.runTests(RemoteTestRunner.java:673)
	at org.eclipse.jdt.internal.junit.runner.RemoteTestRunner.run(RemoteTestRunner.java:386)
	at org.eclipse.jdt.internal.junit.runner.RemoteTestRunner.main(RemoteTestRunner.java:196)

Can someone point me toward the solution of this ??

Thank you in advance,
-- Ugo.

> convert lang/AggregateClassLoading to JUnit.
> --------------------------------------------
>
>                 Key: DERBY-2727
>                 URL: https://issues.apache.org/jira/browse/DERBY-2727
>             Project: Derby
>          Issue Type: Test
>          Components: Test
>            Reporter: Ugo Matrangolo
>            Assignee: Ugo Matrangolo
>            Priority: Minor
>         Attachments: DERBY-2727_diff_120607.txt, DERBY-2727_stat_120607.txt
>
>


-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.


[jira] Assigned: (DERBY-2727) convert lang/AggregateClassLoading to JUnit.

Posted by "Ugo Matrangolo (JIRA)" <ji...@apache.org>.
     [ https://issues.apache.org/jira/browse/DERBY-2727?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]

Ugo Matrangolo reassigned DERBY-2727:
-------------------------------------

    Assignee: Ugo Matrangolo

> convert lang/AggregateClassLoading to JUnit.
> --------------------------------------------
>
>                 Key: DERBY-2727
>                 URL: https://issues.apache.org/jira/browse/DERBY-2727
>             Project: Derby
>          Issue Type: Test
>          Components: Test
>            Reporter: Ugo Matrangolo
>            Assignee: Ugo Matrangolo
>            Priority: Minor
>


-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.


[jira] Commented: (DERBY-2727) convert lang/AggregateClassLoading to JUnit.

Posted by "Daniel John Debrunner (JIRA)" <ji...@apache.org>.
    [ https://issues.apache.org/jira/browse/DERBY-2727?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel#action_12508955 ] 

Daniel John Debrunner commented on DERBY-2727:
----------------------------------------------

Renabled converted test with fixes for IBM 1.5. Committed revision 551732

> convert lang/AggregateClassLoading to JUnit.
> --------------------------------------------
>
>                 Key: DERBY-2727
>                 URL: https://issues.apache.org/jira/browse/DERBY-2727
>             Project: Derby
>          Issue Type: Test
>          Components: Test
>            Reporter: Ugo Matrangolo
>            Assignee: Ugo Matrangolo
>            Priority: Minor
>         Attachments: DERBY-2727_diff_120607.txt, DERBY-2727_diff_240607.txt, DERBY-2727_stat_120607.txt, DERBY-2727_stat_240607.txt
>
>


-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.


[jira] Commented: (DERBY-2727) convert lang/AggregateClassLoading to JUnit.

Posted by "Ugo Matrangolo (JIRA)" <ji...@apache.org>.
    [ https://issues.apache.org/jira/browse/DERBY-2727?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel#action_12507710 ] 

Ugo Matrangolo commented on DERBY-2727:
---------------------------------------

Code modified accordingly to the Kathey's comments.

Please review,
-- Ugo.

> convert lang/AggregateClassLoading to JUnit.
> --------------------------------------------
>
>                 Key: DERBY-2727
>                 URL: https://issues.apache.org/jira/browse/DERBY-2727
>             Project: Derby
>          Issue Type: Test
>          Components: Test
>            Reporter: Ugo Matrangolo
>            Assignee: Ugo Matrangolo
>            Priority: Minor
>         Attachments: DERBY-2727_diff_120607.txt, DERBY-2727_diff_240607.txt, DERBY-2727_stat_120607.txt, DERBY-2727_stat_240607.txt
>
>


-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.