All right, so in this video, we're going to see how we can extend the context options to set the device
resolutions and stuff is very, very simple.
As I told you, this is going to be available for you, even pretty much like how you did with the browser
options.
So here, if I go to the fixtures and if I could dot, you can see that I get all the different options
like browser browse and options, browser type context, context, factory context, options is Chrome
is Linux is Macs.
And so basically you can see that if your test is running on a Mac operating system, then you can specify,
you can set or override how the test should behave for the Mac operating system.
Similarly, if it is a Linux operating system, you can set some flag to see how your test should behave
while it is and Linux operating system.
Similarly, you can override the page.
You can also override the playwright and also get the test info for the reporting's and stuff.
There are so many different cool things which is available on the fixture.
And one thing which I really like.
The fact is this particular Foleo test run or using ability to customize it pretty much like everything
on the test runners.
This is pretty cool.
And now, as that said, this time we are going to be basically extending this context to options where
we are going to override the screen resolution and we'll see how it actually works for doing that.
I'm just going to do pretty much exactly like how we did before.
I'm just going to give this context options.
Just I'm going to create a variable type here and then I'm just going to call this as run and I'm just
going to leave them as it is pretty much like we did before.
So for the run, what I'm going to do is I'm just going to call the vet and I'm just going to do this
for the wait.
I'm just going to use the split syntax to set the context options like everything which is available
on the context options.
Along with that, we also need to set the Devizes.
So here with this syntax, I can set that Devizes as iPhone or BlackBerry, like whatever devices that
you want to set, you can set that Aspell.
So if I just search for iPhone LeBon Permax is that they have to.
Not yet anyways.
So I can set the iPhone 11 Permax over here and you can see that it works fine without any problem.
So you can set many different things, not just this one, but you can keep extending this particular
run options with many different options that we saw before.
So the context option also has got many different browser context options like except download bypass
CSP View Pottz User Agent is mobile and on your locality's offline color scheme proxy's video iPod and
stuff.
So those things you can override over here as well.
And again, it's very, very simple.
As I told you, you have the power of extending it.
Now you can keep doing that without any problem.
So now you can see that our test is already running and had had last month I had full mode.
The headless is off.
And now if I tried to run this test, what going to basically happen is it's going to respond three
different browser, but this time with the iPhone 12 resolution.
But somehow we have this Chrome dev tools available.
And I think that's the reason it's going to not work as expected.
And you can see that this looks terribly bad in the iPhone 12 resolution, though.
But, yeah, this is working fine.
But any problem?
So you can see that two, this has got past what it got failed.
The one is failed because I guess Firefox doesn't really support the the browser.
Yeah, you can see that the E mobile is not supported in the Firefox, so it's not supported yet.
And that's the reason it is fake.
But yeah.
So you got the idea already, like how you can actually set the different options like contest options
and how you can extend the test to run on different settings using the disk fixture.
So that's the guy and this is what is the Foleo and this is what is the test run or of the playwright.
And we can keep extending it as much as possible.
No.
Next video, we'll discuss how we can make this inline code to be available in an external file and
how we can use it.
And it is super simple.
Even you can do it because we have already did that in an earlier video while we were talking about
the Foley example.
But just in case I get the questions from students.
So I just wanted to make things more clearer.
So I really get more questions.
And you are clear as well, maybe even our next video.