We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
1 parent 152494f commit bf9e56fCopy full SHA for bf9e56f
1 file changed
t/12-reuse-session.t
@@ -2,6 +2,7 @@ use strict;
2
use warnings;
3
4
use Test::More;
5
+use Test::MockModule;
6
use Test::Selenium::Remote::Driver;
7
use Selenium::Remote::Mock::RemoteConnection;
8
@@ -15,9 +16,15 @@ my $harness = TestHarness->new(
15
16
this_file => $FindBin::Script
17
);
18
-my @browsers = qw/chrome firefox/;
19
+my @browsers = qw/chrome/;
20
21
foreach (@browsers) {
22
+ my @mock_session_ids = qw{2257c1cf-17d9-401a-a13b-fc7a279d7db5 dddddddd-17d9-401a-a13b-fc7a279d7db5 17c83f3a-3f23-4ffc-a50f-06ba5f5202d1};
23
+
24
+ my $mock = Test::MockModule->new('Selenium::Remote::Driver');
25
+ $mock->redefine('new_session', sub { my $s = shift; $s->{session_id} //= shift @mock_session_ids } );
26
27
28
my %selenium_args = (
29
default_finder => 'css',
30
javascript => 1,
0 commit comments