Documentation

ScheduleDeliverTest extends DAVServerTest
in package
Uses PHPUnitAssertions

This class may be used as a basis for other webdav-related unittests.

This class is supposed to provide a reasonably big framework to quickly get a testing environment running.

Table of Contents

$autoLogin  : mixed
If this string is set, we will automatically log in the user with this name.
$caldavCalendars  : mixed
An array with calendars. Every calendar should have - principaluri - uri.
$setupACL  : mixed
$setupCalDAV  : mixed
$setupCalDAVScheduling  : mixed
$aclPlugin  : Plugin
$authPlugin  : Plugin
$caldavBackend  : mixed
$caldavCalendarObjects  : mixed
$caldavICSExportPlugin  : ICSExportPlugin
$caldavPlugin  : Plugin
$caldavSchedulePlugin  : Plugin
CalDAV scheduling plugin.
$caldavSharingPlugin  : SharingPlugin
$calendarObjectUri  : mixed
$carddavAddressBooks  : mixed
$carddavBackend  : mixed
$carddavCards  : mixed
$carddavPlugin  : Plugin
$locksBackend  : mixed
$locksPlugin  : Plugin
$principalBackend  : mixed
$propertyStorageBackend  : mixed
$propertyStoragePlugin  : mixed
$server  : Server
$setupCalDAVICSExport  : mixed
$setupCalDAVSharing  : mixed
$setupCalDAVSubscriptions  : mixed
$setupCardDAV  : mixed
$setupFiles  : mixed
$setupLocks  : mixed
$setupPropertyStorage  : mixed
$setupSharing  : mixed
$sharingPlugin  : Plugin
Sharing plugin.
$tree  : mixed
assertHttpStatus()  : mixed
assertItemsInInbox()  : mixed
assertVObjectEqualsVObject()  : mixed
This method tests whether two vcards or icalendar objects are semantically identical.
autoLogin()  : mixed
This function takes a username and sets the server in a state where this user is logged in, and no longer requires an authentication check.
deliver()  : mixed
initializeEverything()  : mixed
putPath()  : mixed
Creates or updates a node at the specified path.
request()  : Response
Makes a request, and returns a response object.
setup()  : void
setUpBackends()  : mixed
setUpTree()  : mixed
Override this to provide your own Tree for your test-case.
testDeletedInvite()  : mixed
testDeletedInviteSchedulingDisabled()  : mixed
testDeletedInviteWrongUrl()  : mixed
testInviteNoACLPlugin()  : mixed
testInviteNoCalendarHomeSet()  : mixed
testInviteNoDefaultCalendar()  : mixed
testInviteNoInboxUrl()  : mixed
testInviteNoScheduler()  : mixed
testInviteUnknownUser()  : mixed
testNewInvite()  : mixed
testNewInviteSchedulingDisabled()  : mixed
testNewOnWrongCollection()  : mixed
testReply()  : mixed
testUnbindIgnoredOnMove()  : mixed
A MOVE request will trigger an unbind on a scheduling resource.
testUpdatedInvite()  : mixed
testUpdatedInviteSchedulingDisabled()  : mixed
testUpdatedInviteWrongPath()  : mixed

Properties

$autoLogin

If this string is set, we will automatically log in the user with this name.

public mixed $autoLogin = 'user1'

$caldavCalendars

An array with calendars. Every calendar should have - principaluri - uri.

public mixed $caldavCalendars = [['principaluri' => 'principals/user1', 'uri' => 'cal'], ['principaluri' => 'principals/user2', 'uri' => 'cal']]

$caldavCalendarObjects

protected mixed $caldavCalendarObjects = []

$carddavAddressBooks

protected mixed $carddavAddressBooks = []

$propertyStorageBackend

protected mixed $propertyStorageBackend

$propertyStoragePlugin

protected mixed $propertyStoragePlugin

$setupCalDAVICSExport

protected mixed $setupCalDAVICSExport = false

$setupCalDAVSharing

protected mixed $setupCalDAVSharing = false

$setupCalDAVSubscriptions

protected mixed $setupCalDAVSubscriptions = false

$setupPropertyStorage

protected mixed $setupPropertyStorage = false

Methods

assertHttpStatus()

public assertHttpStatus(mixed $expectedStatus, Request $req) : mixed
Parameters
$expectedStatus : mixed
$req : Request
Return values
mixed

assertItemsInInbox()

public assertItemsInInbox(mixed $user, mixed $count) : mixed
Parameters
$user : mixed
$count : mixed
Return values
mixed

assertVObjectEqualsVObject()

This method tests whether two vcards or icalendar objects are semantically identical.

public assertVObjectEqualsVObject(resource|string|Component $expected, resource|string|Component $actual[, string $message = '' ]) : mixed

It supports objects being supplied as strings, streams or Sabre\VObject\Component instances.

PRODID is removed from both objects as this is often changes and would just get in the way.

CALSCALE will automatically get removed if it's set to GREGORIAN.

Any property that has the value ANY will be treated as a wildcard.

Parameters
$expected : resource|string|Component
$actual : resource|string|Component
$message : string = ''
Return values
mixed

autoLogin()

This function takes a username and sets the server in a state where this user is logged in, and no longer requires an authentication check.

public autoLogin(string $userName) : mixed
Parameters
$userName : string
Return values
mixed

deliver()

public deliver(mixed $oldObject, mixed &$newObject[, mixed $disableScheduling = false ][, mixed $method = 'PUT' ]) : mixed
Parameters
$oldObject : mixed
$newObject : mixed
$disableScheduling : mixed = false
$method : mixed = 'PUT'
Return values
mixed

initializeEverything()

public initializeEverything() : mixed
Return values
mixed

putPath()

Creates or updates a node at the specified path.

public putPath(string $path, string $data) : mixed

This circumvents sabredav's internal server apis, so all events and access control is skipped.

Parameters
$path : string
$data : string
Return values
mixed

request()

Makes a request, and returns a response object.

public request(array<string|int, mixed>|Request $request[, int $expectedStatus = null ]) : Response

You can either pass an instance of Sabre\HTTP\Request, or an array, which will then be used as the _SERVER array.

If $expectedStatus is set, we'll compare it with the HTTP status of the returned response. If it doesn't match, we'll immediately fail the test.

Parameters
$request : array<string|int, mixed>|Request
$expectedStatus : int = null
Return values
Response

setUpBackends()

public setUpBackends() : mixed
Return values
mixed

setUpTree()

Override this to provide your own Tree for your test-case.

public setUpTree() : mixed
Return values
mixed

testDeletedInviteSchedulingDisabled()

public testDeletedInviteSchedulingDisabled() : mixed
Return values
mixed

testDeletedInviteWrongUrl()

public testDeletedInviteWrongUrl() : mixed
Return values
mixed

testInviteNoACLPlugin()

public testInviteNoACLPlugin() : mixed
Return values
mixed

testInviteNoCalendarHomeSet()

public testInviteNoCalendarHomeSet() : mixed
Return values
mixed

testInviteNoDefaultCalendar()

public testInviteNoDefaultCalendar() : mixed
Return values
mixed

testInviteNoInboxUrl()

public testInviteNoInboxUrl() : mixed
Return values
mixed

testInviteNoScheduler()

public testInviteNoScheduler() : mixed
Return values
mixed

testInviteUnknownUser()

public testInviteUnknownUser() : mixed
Return values
mixed

testNewInviteSchedulingDisabled()

public testNewInviteSchedulingDisabled() : mixed
Return values
mixed

testNewOnWrongCollection()

public testNewOnWrongCollection() : mixed
Return values
mixed

testUnbindIgnoredOnMove()

A MOVE request will trigger an unbind on a scheduling resource.

public testUnbindIgnoredOnMove() : mixed

However, we must not treat it as a cancellation, it just got moved to a different calendar.

Return values
mixed

testUpdatedInviteSchedulingDisabled()

public testUpdatedInviteSchedulingDisabled() : mixed
Return values
mixed

testUpdatedInviteWrongPath()

public testUpdatedInviteWrongPath() : mixed
Return values
mixed

Search results