Webylon 3.2 API Docs
  • Package
  • Class
  • Tree
  • Deprecated
  • Download
Version: current
  • 3.2
  • 3.1

Packages

  • 1c
    • exchange
      • catalog
  • auth
  • Booking
  • building
    • company
  • cart
    • shipping
    • steppedcheckout
  • Catalog
    • monument
  • cms
    • assets
    • batchaction
    • batchactions
    • bulkloading
    • comments
    • content
    • core
    • export
    • newsletter
    • publishers
    • reports
    • security
    • tasks
  • Dashboard
  • DataObjectManager
  • event
  • faq
  • forms
    • actions
    • core
    • fields-basic
    • fields-dataless
    • fields-datetime
    • fields-files
    • fields-formatted
    • fields-formattedinput
    • fields-relational
    • fields-structural
    • transformations
    • validators
  • googlesitemaps
  • guestbook
  • installer
  • newsletter
  • None
  • photo
    • gallery
  • PHP
  • polls
  • recaptcha
  • sapphire
    • api
    • bulkloading
    • control
    • core
    • cron
    • dev
    • email
    • fields-formattedinput
    • filesystem
    • formatters
    • forms
    • i18n
    • integration
    • misc
    • model
    • parsers
    • search
    • security
    • tasks
    • testing
    • tools
    • validation
    • view
    • widgets
  • seo
    • open
      • graph
  • sfDateTimePlugin
  • spamprotection
  • stealth
    • captha
  • subsites
  • userform
    • pagetypes
  • userforms
  • webylon
  • widgets

Classes

  • CliTestReporter
  • FunctionalTest
  • InstallerTest
  • JSTestRunner
  • PHPUnit_Framework_TestCase
  • SapphireTest
  • SapphireTestReporter
  • SapphireTestSuite
  • TestRunner
  • TestSession
  • TestSession_STResponseWrapper
  • TestViewer

Interfaces

  • TestOnly

Functions

  • hasPhpUnit

Class TestSession

Represents a test usage session of a web-app It will maintain session-state from request to request

Package: sapphire\testing
Located at sapphire/dev/TestSession.php

Methods summary

public
# __construct( )
public
# __destruct( )
public
# get( mixed $url, mixed $session = null, mixed $headers = null, mixed $cookies = null )

Submit a get request

Submit a get request

Uses

Director::test()
public
# post( mixed $url, mixed $data, mixed $headers = null, mixed $session = null, mixed $body = null, mixed $cookies = null )

Submit a post request

Submit a post request

Uses

Director::test()
public
# submitForm( mixed $formID, mixed $button = null, mixed $data = array() )

Submit the form with the given HTML ID, filling it out with the given data. Acts on the most recent response

Submit the form with the given HTML ID, filling it out with the given data. Acts on the most recent response

public
# followRedirection( )

If the last request was a 3xx response, then follow the redirection

If the last request was a 3xx response, then follow the redirection

public
# wasRedirected( )

Returns true if the last response was a 3xx redirection

Returns true if the last response was a 3xx redirection

public
# lastResponse( )

Get the most recent response, as an SS_HTTPResponse object

Get the most recent response, as an SS_HTTPResponse object

public
# lastContent( )

Get the most recent response's content

Get the most recent response's content

public
# cssParser( )
public
# lastPage( )

Get the last response as a SimplePage object

Get the last response as a SimplePage object

public
# session( )

Get the current session, as a Session object

Get the current session, as a Session object

Magic methods summary

Properties summary

protected mixed $controller
#

Param

Controller $controller Necessary to use the mock session created in TestSession::session() in the normal controller stack, e.g. to overwrite Member::currentUser() with custom login data.
[Raise a SilverStripe Framework issue/bug](https://github.com/silverstripe/silverstripe-framework/issues/new)
- [Raise a SilverStripe CMS issue/bug](https://github.com/silverstripe/silverstripe-cms/issues/new)
- Please use the Silverstripe Forums to ask development related questions. -
Webylon 3.2 API Docs API documentation generated by ApiGen 2.8.0