CanSetWebdriverContext.pm 775 B

1234567891011121314151617181920212223242526
  1. package Selenium::Remote::Driver::CanSetWebdriverContext;
  2. # ABSTRACT: Customize the webdriver context prefix for various drivers
  3. use Moo::Role;
  4. =head1 DESCRIPTION
  5. Some drivers don't use the typical C</wd/hub> context prefix for the
  6. webdriver HTTP communication. For example, the newer versions of the
  7. Firefox driver extension use the context C</hub> instead. This role
  8. just has the one attribute with a default webdriver context prefix,
  9. and is consumed in L<Selenium::Remote::Driver> and
  10. L<Selenium::Remote::RemoteConnection>.
  11. If you're new to webdriver, you probably want to head over to
  12. L<Selenium::Remote::Driver>'s docs; this package is more of an
  13. internal-facing concern.
  14. =cut
  15. has 'wd_context_prefix' => (
  16. is => 'lazy',
  17. default => sub { '/wd/hub' }
  18. );
  19. 1;