WebAIM - Web Accessibility In Mind

E-mail List Archives

Thread: Automated testing tools and viewport size

for

Number of posts in this thread: 6 (In chronological order)

From: Steve Green
Date: Wed, May 06 2020 11:43AM
Subject: Automated testing tools and viewport size
No previous message | Next message →

I never really thought about this before, but automated testing tools that use a headless browser still need to apply viewport dimensions, and this will determine which media queries are and are not applied. This raises the question of what dimensions they are using.

These thoughts were prompted by an issue that SortSite reported, but the Axe browser extension did not. It turns out that the issue occurs at viewport widths below 1300 pixels and that Axe did not find it because I just happened to run the test with a larger window than that. By contrast, SortSite's headless browser always works at 1024x768 pixels, so it found the issue.

In this case I got lucky, but I want a more robust solution. Does anyone know of a tool that can test a whole website (like SortSite does) rather than one page at a time, but it tests at multiple viewport sizes. At the very least the sizes should be selectable and ideally the tool should work out what sizes it needs to test at to cover all the breakpoints?

I suspect that such a tool will be expensive if it exists at all, but significant issues could be missed if a tool doesn't do that.

Regards,
Steve Green
Managing Director
Test Partners Ltd
020 3002 4176 (direct)
0800 612 2780 (switchboard)
07957 246 276 (mobile)
020 7692 5517 (fax)
Skype: testpartners
= EMAIL ADDRESS REMOVED =
www.testpartners.co.uk
 
Connect to me on LinkedIn - http://uk.linkedin.com/in/stevegreen2

From: Peter Krautzberger
Date: Wed, May 06 2020 12:36PM
Subject: Re: Automated testing tools and viewport size
← Previous message | Next message →

Hi Steve,

A random (untested) idea would be to use axe-puppeteer [1]. Tell puppeteer
to set some viewport dimensions, test with axe-puppeteer, change viewport,
test again; rinse and repeat.

Peter.

[1] https://github.com/dequelabs/axe-puppeteer

Am Mi., 6. Mai 2020 um 19:43 Uhr schrieb Steve Green <
= EMAIL ADDRESS REMOVED = >:

> I never really thought about this before, but automated testing tools that
> use a headless browser still need to apply viewport dimensions, and this
> will determine which media queries are and are not applied. This raises the
> question of what dimensions they are using.
>
> These thoughts were prompted by an issue that SortSite reported, but the
> Axe browser extension did not. It turns out that the issue occurs at
> viewport widths below 1300 pixels and that Axe did not find it because I
> just happened to run the test with a larger window than that. By contrast,
> SortSite's headless browser always works at 1024x768 pixels, so it found
> the issue.
>
> In this case I got lucky, but I want a more robust solution. Does anyone
> know of a tool that can test a whole website (like SortSite does) rather
> than one page at a time, but it tests at multiple viewport sizes. At the
> very least the sizes should be selectable and ideally the tool should work
> out what sizes it needs to test at to cover all the breakpoints?
>
> I suspect that such a tool will be expensive if it exists at all, but
> significant issues could be missed if a tool doesn't do that.
>
> Regards,
> Steve Green
> Managing Director
> Test Partners Ltd
> 020 3002 4176 (direct)
> 0800 612 2780 (switchboard)
> 07957 246 276 (mobile)
> 020 7692 5517 (fax)
> Skype: testpartners
> = EMAIL ADDRESS REMOVED =
> www.testpartners.co.uk
>
> Connect to me on LinkedIn - http://uk.linkedin.com/in/stevegreen2
>
> > > > >

From: Steve Green
Date: Wed, May 06 2020 12:47PM
Subject: Re: Automated testing tools and viewport size
← Previous message | Next message →

I can see that could work for that type of tool, but I want a tool that will spider a website and present the results in a GUI like SortSite does.

Steve


From: Patrick H. Lauke
Date: Wed, May 06 2020 1:00PM
Subject: Re: Automated testing tools and viewport size
← Previous message | Next message →

On 06/05/2020 18:43, Steve Green wrote:
> I never really thought about this before, but automated testing tools that use a headless browser still need to apply viewport dimensions, and this will determine which media queries are and are not applied. This raises the question of what dimensions they are using.

Yes, ideally, the tool should really run at every major breakpoint
defined in CSS, and possibly some further random samplings/common device
widths/heights. And orientations/aspect ratios.

I pointed this out a few years ago as well for tools like the Trace
Center Photosensitive Epilepsy Analysis Tool (PEAT) (which, last time I
checked, assumed/required a browser at 1024x768 in order to do its
calculations of screen area). Those tools will, essentially, only
capture one single potential state, and if they can't be modified to
work at different viewport sizes, their results will be potentially
meaningless.

P
--
Patrick H. Lauke

https://www.splintered.co.uk/ | https://github.com/patrickhlauke
https://flickr.com/photos/redux/ | https://www.deviantart.com/redux
twitter: @patrick_h_lauke | skype: patrick_h_lauke

From: Jared Smith
Date: Wed, May 06 2020 2:32PM
Subject: Re: Automated testing tools and viewport size
← Previous message | Next message →

Steve -

With the WAVE API you can specify the viewport width for each request.
The default is 1200 pixels. You can also define the user agent string
(and a bunch of other stuff), in case that makes a difference. The
pope.tech service (which uses WAVE) also allows you to specify
viewport sizes, and provides the spidering, full-site scanning, and
reporting GUI functionality you want.

Thanks,

Jared

From: Steve Green
Date: Thu, May 07 2020 6:46AM
Subject: Re: Automated testing tools and viewport size
← Previous message | No next message

Thanks, the pope.tech service looks like it might be suitable so I'll take a look at that.

Steve