\BrowserTest
Tests for the {@link Browser}.
- Author: Matt Howlett
Synopsis
class BrowserTest
extends SapphireTest
{
- // members
- private static array $ie = ;
- private static array $firefox = ;
- private static array $chrome = ;
- private static array $safari = ;
- private static array $opera = ;
- private static array $android = ;
- private static array $googlebot = ;
- // methods
- public void testShouldParseChrome()
- public void testShouldParseSafari()
- public void testShouldParseFirefox()
- public void testShouldParseInternetExplorer()
- public void testShouldParseAndroid()
- public void testShouldParseOpera()
- public void testShouldParseGoogleBot()
- private void assertParse()
Hierarchy
Extends
- SapphireTest
Members
private
- $android
—
array
Android user agent fixtures mapped to their expected information. -
$chrome
Chrome user agent fixtures mapped to their expected information. -
$firefox
Firefox user agent fixtures mapped to their expected information. - $googlebot
—
array
Google bot user agent fixtures. -
$ie
Internet explorer user agent fixtures mapped to their expected information. -
$opera
Opera user agent fixtures mapped to their expected information. - $safari
—
array
Safari user agent fixtures mapped to their expected information.
Methods
private
- assertParse() — Asserts all agents in the given array match the expected name, version, system, device, engine and templated string.
public
- testShouldParseAndroid() — Should parse Android.
- testShouldParseChrome() — Should parse Chrome.
- testShouldParseFirefox() — Should parse Firefox.
- testShouldParseGoogleBot() — Should parse Google Bot.
- testShouldParseInternetExplorer() — Should parse Internet Explorer.
- testShouldParseOpera() — Should parse Opera.
- testShouldParseSafari() — Should parse Safari.