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 "Andrew McIntyre (JIRA)" <ji...@apache.org> on 2007/03/06 22:43:24 UTC

[jira] Updated: (DERBY-2410) Convert grantRevoke.java to JUnit

     [ https://issues.apache.org/jira/browse/DERBY-2410?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]

Andrew McIntyre updated DERBY-2410:
-----------------------------------

    Attachment: derby-2410-pre.diff

Attaching an early draft for converting grantRevoke.java to JUnit. I'd like to get some feedback on the approach, and some extra eyes to make sure I'm not making any mistakes in the logic. This draft does implement all of the testcases from the grant part of grantRevoke.java, although not all of the checks have been implemented yet, as I've encountered some problems.

- assertInsertPrivilege and assertUpdatePrivilege need to be completed. Currently having an issue with getColumns returning an empty ResultSet for tables when the DatabaseMetaData is acquired from the connection opened with openUserConnection

- problems with the triggers in testGrantRollbackAndCommit need to be investigated.

- it might be a good idea to have a version of the assert methods, or at least for select, that takes an array of users, so public privileges can be asserted against all users.

- assertReferences needs an implementation, although it should be noted that the previous version of the test did not have an implementation for references checks.

Questions:

- Is client/server necessary here? I guess verifying the metadata methods work properly is worth running on the client, although perhaps the client/server tests should restrict themselves to the metadata test fixtures.

- adding the revoke testcases and the testcases from grantrevokeDDL and grantrevokeDDL2 will make this a large test. Any opinion on whether or not to split these tests up into several test classes? And what approach: move utility methods into BaseJDBCTestCase? Have a GrantRevokeTestCase that the individual tests extend?

Left to do from grantrevoke.java:

- revoke testcases
- standard error testcases

> Convert grantRevoke.java to JUnit
> ---------------------------------
>
>                 Key: DERBY-2410
>                 URL: https://issues.apache.org/jira/browse/DERBY-2410
>             Project: Derby
>          Issue Type: Improvement
>          Components: Test
>    Affects Versions: 10.3.0.0
>            Reporter: Andrew McIntyre
>         Assigned To: Andrew McIntyre
>             Fix For: 10.3.0.0
>
>         Attachments: derby-2410-pre.diff
>
>
> Convert grantRevoke.java to JUnit. Also add test cases from grantRevokeDDL and grantRevokeDDL2 SQL tests to the new GrantRevokeTest

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