[arquillian-issues] [JBoss JIRA] (ARQGRA-337) Disallow initialization of page abstractions which has non-private members

Lukáš Fryč (JIRA) issues at jboss.org
Tue Jan 19 04:10:02 EST 2016


     [ https://issues.jboss.org/browse/ARQGRA-337?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]

Lukáš Fryč updated ARQGRA-337:
------------------------------
    Fix Version/s: 2.2-Tracking
                       (was: 2.1-Tracking)


> Disallow initialization of page abstractions which has non-private members
> --------------------------------------------------------------------------
>
>                 Key: ARQGRA-337
>                 URL: https://issues.jboss.org/browse/ARQGRA-337
>             Project: Arquillian Graphene
>          Issue Type: Enhancement
>            Reporter: Lukáš Fryč
>             Fix For: 2.2-Tracking
>
>
> It is not allowed to access Graphene-injected page abstractions directly through field references because then the object's calls can't be intercepted:
> {code:java}
> // not allowed
> class Page {
>    @FindBy(...)
>    Tree tree;
> }
> {code}
> The accessors should be used instead:
> {code:java}
> // allowed
> class Page {
>    @FindBy(...)
>    private Tree tree;
>    public Tree tree() {
>       return tree;
>    }
> }
> {code}
> We need to disallow that - either provide a warning or fail.



--
This message was sent by Atlassian JIRA
(v6.4.11#64026)



More information about the arquillian-issues mailing list