[arquillian-issues] [JBoss JIRA] (ARQ-1352) Script can not insert unix path separator '/' into the DB

Bartosz Majsak (JIRA) jira-events at lists.jboss.org
Wed Mar 13 14:04:42 EDT 2013


    [ https://issues.jboss.org/browse/ARQ-1352?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=12760973#comment-12760973 ] 

Bartosz Majsak commented on ARQ-1352:
-------------------------------------

Thank you very much for spotting this problem and providing the fix! Shame on me :)

Would it be possible for you to fork the repository on github and send fix (maybe with the unit test?) through the pull request? Then you will be automatically recognized as a contributor on the Arquillian web site and will gain eternal fame :) If you are not that familiar with the workflow, please have a look at this [guide|http://community.jboss.org/wiki/ShrinkWrapDevelopmentAndContribution] or simply just ask. I'll be more than happy to help.
                
> Script can not insert unix path separator '/' into the DB
> ---------------------------------------------------------
>
>                 Key: ARQ-1352
>                 URL: https://issues.jboss.org/browse/ARQ-1352
>             Project: Arquillian
>          Issue Type: Bug
>      Security Level: Public(Everyone can see) 
>          Components: Extension - Persistence
>    Affects Versions: persistence_1.0.0.Alpha6
>            Reporter: Sandor Bodo-Merle
>            Assignee: Bartosz Majsak
>             Fix For: persistence_1.0.0.next
>
>         Attachments: 0001-ScriptExecutor-fix-commit-parsing.patch
>
>
> I have a test class which try to insert a unix path value in the DB on schema creation:
> @CreateSchema({"setup.sql"})                
> public class UserTest {
> ...
> }
> Th the ScriptExecutor introduced in 1.0.0.Alpha6 will iron out the '/' character from the path on insert - like in the following small example:
> public class main {
>      public static void main(String[] args) {
>          final String ANSI_SQL_COMMENTS_PATTERN = "--.*|//.*|(?s)/\\\\*.*?\\\\*/|(?s)\\{.*?\\}";
>          String script = "INSERT INTO config (name, value) VALUES ('path', '/home/sbodo/test.txt');";
>          System.out.println(script.replaceAll(ANSI_SQL_COMMENTS_PATTERN, ""));
>      }
>  }
> Output is:
> INSERT INTO config (name, value) VALUES ('path', 'sbodo/test.txt');
> instead of:
> INSERT INTO config (name, value) VALUES ('path', '/home/sbodo/test.txt');
> Tested with Jboss 7.1.1 and Postgres 9.1.
> The test worked fine in 1.0.0.Alpha5.

--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators
For more information on JIRA, see: http://www.atlassian.com/software/jira


More information about the arquillian-issues mailing list