Uploaded image for project: 'Arquillian'
  1. Arquillian
  2. ARQ-1761

Investigate Screenshooter per container for Droidium

    Details

    • Type: Feature Request
    • Status: Open (View Workflow)
    • Priority: Major
    • Resolution: Unresolved
    • Affects Version/s: droidium_1.0.0.Alpha5
    • Fix Version/s: None
    • Component/s: Extension - Droidium
    • Labels:
      None

      Description

      Screenshooter is injected into test case like this

      @ArquillianResource private Screenshooter screenshooter;
      

      It behaves ok when you have just one Android container available.

      The problem is, how to make difference between these screenshooters when you have multiple Androids in your test.

      Injection of Screenshooter has to know which device will be that screenshooter backed by.

      The best solution to me seems to be like this:

      @ArquillianResource
      @TargetsContainer("android_1")
      private Screenshooter screenshooter_1;
      
      @ArquillianResource
      @TargetsContainer("android_2")
      private Screenshooter screenshooter_2;
      

      Enrichment of test class is done in this context in ResourceProvider where we have access to annotations put on injection point.

      There is already ApplicationScoped register of AndroidDevices which are bound to some container and deployments.

      In general, you do not need any deployment method but you have always some Android container so matching ArquillianResource with @TargetsContainer seems to be very natural.

        Gliffy Diagrams

          Attachments

            Activity

              People

              • Assignee:
                Unassigned
                Reporter:
                smikloso Stefan Miklosovic
              • Votes:
                0 Vote for this issue
                Watchers:
                1 Start watching this issue

                Dates

                • Created:
                  Updated: