[zendframework/zf2#3461] PHPUnit test fix
[zendframework/zf2#3461] PHPUnit test fix

- $_SESSION is not always present from CLI and/or PHPUnit; check to see
  if it exists before using it. This prevents:
    - notice (undefined variable)
    - catchable fatal error (toArray returning null, which is then
      passed to fromArray() which expects an array)

zendframework/zend-session,MadCat34/zend-session,Maks3w/zend-session,oswaldderiemaecker/zend-session