diff --git a/.gitattributes b/.gitattributes index e39adcbe7a..1ac248c46f 100644 --- a/.gitattributes +++ b/.gitattributes @@ -4,6 +4,7 @@ /.gitattributes export-ignore /.gitignore export-ignore /.php_cs.dist export-ignore +/.php-cs-fixer.dist.php export-ignore /CHANGELOG.md export-ignore /CONTRIBUTING.md export-ignore /phpstan.neon export-ignore diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index b256d4cc55..7ac0f0686d 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -30,7 +30,7 @@ jobs: run: echo "dir=$(composer config cache-files-dir)" >> $GITHUB_OUTPUT - name: Cache composer dependencies - uses: actions/cache@v3 + uses: actions/cache@v4 with: path: ${{ steps.composer-cache.outputs.dir }} # Use composer.json for key, if composer.lock is not committed. @@ -93,7 +93,7 @@ jobs: run: echo "dir=$(composer config cache-files-dir)" >> $GITHUB_OUTPUT - name: Cache composer dependencies - uses: actions/cache@v3 + uses: actions/cache@v4 with: path: ${{ steps.composer-cache.outputs.dir }} # Use composer.json for key, if composer.lock is not committed. @@ -126,5 +126,5 @@ jobs: SABRE_PGSQLDSN: "pgsql:host=127.0.0.1;port=5432;dbname=sabredav_test;user=postgres;password=postgres" RUN_TEST_WITH_STREAMING_PROPFIND: "true" - - uses: codecov/codecov-action@v3 + - uses: codecov/codecov-action@v4 if: matrix.coverage != 'none' diff --git a/bin/googlecode_upload.py b/bin/googlecode_upload.py deleted file mode 100755 index caafd5deda..0000000000 --- a/bin/googlecode_upload.py +++ /dev/null @@ -1,248 +0,0 @@ -#!/usr/bin/env python -# -# Copyright 2006, 2007 Google Inc. All Rights Reserved. -# Author: danderson@google.com (David Anderson) -# -# Script for uploading files to a Google Code project. -# -# This is intended to be both a useful script for people who want to -# streamline project uploads and a reference implementation for -# uploading files to Google Code projects. -# -# To upload a file to Google Code, you need to provide a path to the -# file on your local machine, a small summary of what the file is, a -# project name, and a valid account that is a member or owner of that -# project. You can optionally provide a list of labels that apply to -# the file. The file will be uploaded under the same name that it has -# in your local filesystem (that is, the "basename" or last path -# component). Run the script with '--help' to get the exact syntax -# and available options. -# -# Note that the upload script requests that you enter your -# googlecode.com password. This is NOT your Gmail account password! -# This is the password you use on googlecode.com for committing to -# Subversion and uploading files. You can find your password by going -# to http://code.google.com/hosting/settings when logged in with your -# Gmail account. If you have already committed to your project's -# Subversion repository, the script will automatically retrieve your -# credentials from there (unless disabled, see the output of '--help' -# for details). -# -# If you are looking at this script as a reference for implementing -# your own Google Code file uploader, then you should take a look at -# the upload() function, which is the meat of the uploader. You -# basically need to build a multipart/form-data POST request with the -# right fields and send it to https://PROJECT.googlecode.com/files . -# Authenticate the request using HTTP Basic authentication, as is -# shown below. -# -# Licensed under the terms of the Apache Software License 2.0: -# http://www.apache.org/licenses/LICENSE-2.0 -# -# Questions, comments, feature requests and patches are most welcome. -# Please direct all of these to the Google Code users group: -# http://groups.google.com/group/google-code-hosting - -"""Google Code file uploader script. -""" - -__author__ = 'danderson@google.com (David Anderson)' - -import httplib -import os.path -import optparse -import getpass -import base64 -import sys - - -def upload(file, project_name, user_name, password, summary, labels=None): - """Upload a file to a Google Code project's file server. - - Args: - file: The local path to the file. - project_name: The name of your project on Google Code. - user_name: Your Google account name. - password: The googlecode.com password for your account. - Note that this is NOT your global Google Account password! - summary: A small description for the file. - labels: an optional list of label strings with which to tag the file. - - Returns: a tuple: - http_status: 201 if the upload succeeded, something else if an - error occurred. - http_reason: The human-readable string associated with http_status - file_url: If the upload succeeded, the URL of the file on Google - Code, None otherwise. - """ - # The login is the user part of user@gmail.com. If the login provided - # is in the full user@domain form, strip it down. - if user_name.endswith('@gmail.com'): - user_name = user_name[:user_name.index('@gmail.com')] - - form_fields = [('summary', summary)] - if labels is not None: - form_fields.extend([('label', l.strip()) for l in labels]) - - content_type, body = encode_upload_request(form_fields, file) - - upload_host = '%s.googlecode.com' % project_name - upload_uri = '/files' - auth_token = base64.b64encode('%s:%s'% (user_name, password)) - headers = { - 'Authorization': 'Basic %s' % auth_token, - 'User-Agent': 'Googlecode.com uploader v0.9.4', - 'Content-Type': content_type, - } - - server = httplib.HTTPSConnection(upload_host) - server.request('POST', upload_uri, body, headers) - resp = server.getresponse() - server.close() - - if resp.status == 201: - location = resp.getheader('Location', None) - else: - location = None - return resp.status, resp.reason, location - - -def encode_upload_request(fields, file_path): - """Encode the given fields and file into a multipart form body. - - fields is a sequence of (name, value) pairs. file is the path of - the file to upload. The file will be uploaded to Google Code with - the same file name. - - Returns: (content_type, body) ready for httplib.HTTP instance - """ - BOUNDARY = '----------Googlecode_boundary_reindeer_flotilla' - CRLF = '\r\n' - - body = [] - - # Add the metadata about the upload first - for key, value in fields: - body.extend( - ['--' + BOUNDARY, - 'Content-Disposition: form-data; name="%s"' % key, - '', - value, - ]) - - # Now add the file itself - file_name = os.path.basename(file_path) - f = open(file_path, 'rb') - file_content = f.read() - f.close() - - body.extend( - ['--' + BOUNDARY, - 'Content-Disposition: form-data; name="filename"; filename="%s"' - % file_name, - # The upload server determines the mime-type, no need to set it. - 'Content-Type: application/octet-stream', - '', - file_content, - ]) - - # Finalize the form body - body.extend(['--' + BOUNDARY + '--', '']) - - return 'multipart/form-data; boundary=%s' % BOUNDARY, CRLF.join(body) - - -def upload_find_auth(file_path, project_name, summary, labels=None, - user_name=None, password=None, tries=3): - """Find credentials and upload a file to a Google Code project's file server. - - file_path, project_name, summary, and labels are passed as-is to upload. - - Args: - file_path: The local path to the file. - project_name: The name of your project on Google Code. - summary: A small description for the file. - labels: an optional list of label strings with which to tag the file. - config_dir: Path to Subversion configuration directory, 'none', or None. - user_name: Your Google account name. - tries: How many attempts to make. - """ - - while tries > 0: - if user_name is None: - # Read username if not specified or loaded from svn config, or on - # subsequent tries. - sys.stdout.write('Please enter your googlecode.com username: ') - sys.stdout.flush() - user_name = sys.stdin.readline().rstrip() - if password is None: - # Read password if not loaded from svn config, or on subsequent tries. - print 'Please enter your googlecode.com password.' - print '** Note that this is NOT your Gmail account password! **' - print 'It is the password you use to access Subversion repositories,' - print 'and can be found here: http://code.google.com/hosting/settings' - password = getpass.getpass() - - status, reason, url = upload(file_path, project_name, user_name, password, - summary, labels) - # Returns 403 Forbidden instead of 401 Unauthorized for bad - # credentials as of 2007-07-17. - if status in [httplib.FORBIDDEN, httplib.UNAUTHORIZED]: - # Rest for another try. - user_name = password = None - tries = tries - 1 - else: - # We're done. - break - - return status, reason, url - - -def main(): - parser = optparse.OptionParser(usage='googlecode-upload.py -s SUMMARY ' - '-p PROJECT [options] FILE') - parser.add_option('-s', '--summary', dest='summary', - help='Short description of the file') - parser.add_option('-p', '--project', dest='project', - help='Google Code project name') - parser.add_option('-u', '--user', dest='user', - help='Your Google Code username') - parser.add_option('-w', '--password', dest='password', - help='Your Google Code password') - parser.add_option('-l', '--labels', dest='labels', - help='An optional list of comma-separated labels to attach ' - 'to the file') - - options, args = parser.parse_args() - - if not options.summary: - parser.error('File summary is missing.') - elif not options.project: - parser.error('Project name is missing.') - elif len(args) < 1: - parser.error('File to upload not provided.') - elif len(args) > 1: - parser.error('Only one file may be specified.') - - file_path = args[0] - - if options.labels: - labels = options.labels.split(',') - else: - labels = None - - status, reason, url = upload_find_auth(file_path, options.project, - options.summary, labels, - options.user, options.password) - if url: - print 'The file was uploaded successfully.' - print 'URL: %s' % url - return 0 - else: - print 'An error occurred. Your file was not uploaded.' - print 'Google Code upload server said: %s (%s)' % (reason, status) - return 1 - - -if __name__ == '__main__': - sys.exit(main()) diff --git a/lib/CalDAV/Backend/BackendInterface.php b/lib/CalDAV/Backend/BackendInterface.php index 8bfa7446ab..ccaa2519ac 100644 --- a/lib/CalDAV/Backend/BackendInterface.php +++ b/lib/CalDAV/Backend/BackendInterface.php @@ -221,7 +221,7 @@ public function deleteCalendarObject($calendarId, $objectUri); * * This default may well be good enough for personal use, and calendars * that aren't very large. But if you anticipate high usage, big calendars - * or high loads, you are strongly adviced to optimize certain paths. + * or high loads, you are strongly advised to optimize certain paths. * * The best way to do so is override this method and to optimize * specifically for 'common filters'. diff --git a/lib/CalDAV/Backend/NotificationSupport.php b/lib/CalDAV/Backend/NotificationSupport.php index 6e48d54547..5c04ae44c5 100644 --- a/lib/CalDAV/Backend/NotificationSupport.php +++ b/lib/CalDAV/Backend/NotificationSupport.php @@ -36,7 +36,7 @@ interface NotificationSupport extends BackendInterface public function getNotificationsForPrincipal($principalUri); /** - * This deletes a specific notifcation. + * This deletes a specific notification. * * This may be called by a client once it deems a notification handled. * diff --git a/lib/CalDAV/Backend/PDO.php b/lib/CalDAV/Backend/PDO.php index b9f112cf8d..634b9828c5 100644 --- a/lib/CalDAV/Backend/PDO.php +++ b/lib/CalDAV/Backend/PDO.php @@ -196,7 +196,7 @@ public function getCalendarsForUser($principalUri) //$stmt2 = $this->pdo->prepare('SELECT principaluri FROM ' . $this->calendarInstancesTableName . ' WHERE access = 1 AND id = ?'); //$stmt2->execute([$row['id']]); - // read-only is for backwards compatbility. Might go away in + // read-only is for backwards compatibility. Might go away in // the future. $calendar['read-only'] = \Sabre\DAV\Sharing\Plugin::ACCESS_READ === (int) $row['access']; } @@ -730,7 +730,7 @@ public function deleteCalendarObject($calendarId, $objectUri) * * This default may well be good enough for personal use, and calendars * that aren't very large. But if you anticipate high usage, big calendars - * or high loads, you are strongly adviced to optimize certain paths. + * or high loads, you are strongly advised to optimize certain paths. * * The best way to do so is override this method and to optimize * specifically for 'common filters'. diff --git a/lib/CalDAV/Calendar.php b/lib/CalDAV/Calendar.php index 6c0bf54115..ba8c704a5d 100644 --- a/lib/CalDAV/Calendar.php +++ b/lib/CalDAV/Calendar.php @@ -435,7 +435,7 @@ public function getSyncToken() * return null. * * The limit is 'suggestive'. You are free to ignore it. - * TODO: RFC6578 Setion 3.7 says that the server must fail when the server + * TODO: RFC6578 Section 3.7 says that the server must fail when the server * cannot truncate according to the limit, so it may not be just suggestive. * * @param string $syncToken diff --git a/lib/CalDAV/Notifications/Node.php b/lib/CalDAV/Notifications/Node.php index 7d3a3f46bd..5bf9a6018b 100644 --- a/lib/CalDAV/Notifications/Node.php +++ b/lib/CalDAV/Notifications/Node.php @@ -70,7 +70,7 @@ public function getName() /** * Returns the etag for the notification. * - * The etag must be surrounded by litteral double-quotes. + * The etag must be surrounded by literal double-quotes. * * @return string */ @@ -101,7 +101,7 @@ public function delete() /** * Returns the owner principal. * - * This must be a url to a principal, or null if there's no owner + * This must be an url to a principal, or null if there's no owner * * @return string|null */ diff --git a/lib/CalDAV/Plugin.php b/lib/CalDAV/Plugin.php index 98f4f554c2..ccb722f857 100644 --- a/lib/CalDAV/Plugin.php +++ b/lib/CalDAV/Plugin.php @@ -720,7 +720,7 @@ public function beforeWriteContent($path, DAV\IFile $node, &$data, &$modified) return; } - // We're onyl interested in ICalendarObject nodes that are inside of a + // We're only interested in ICalendarObject nodes that are inside of a // real calendar. This is to avoid triggering validation and scheduling // for non-calendars (such as an inbox). list($parent) = Uri\split($path); @@ -913,7 +913,7 @@ protected function validateICalendar(&$data, $path, &$modified, RequestInterface } /** - * This method is triggered whenever a subsystem reqeuests the privileges + * This method is triggered whenever a subsystem requests the privileges * that are supported on a particular node. */ public function getSupportedPrivilegeSet(INode $node, array &$supportedPrivilegeSet) diff --git a/lib/CalDAV/SharingPlugin.php b/lib/CalDAV/SharingPlugin.php index f7dca9be69..bacfe04415 100644 --- a/lib/CalDAV/SharingPlugin.php +++ b/lib/CalDAV/SharingPlugin.php @@ -136,7 +136,7 @@ public function propFindLate(DAV\PropFind $propFind, DAV\INode $node) } /** - * This method is trigged when a user attempts to update a node's + * This method is triggered when a user attempts to update a node's * properties. * * A previous draft of the sharing spec stated that it was possible to use diff --git a/lib/CalDAV/Xml/Request/CalendarMultiGetReport.php b/lib/CalDAV/Xml/Request/CalendarMultiGetReport.php index 3b3a94b268..4771a20702 100644 --- a/lib/CalDAV/Xml/Request/CalendarMultiGetReport.php +++ b/lib/CalDAV/Xml/Request/CalendarMultiGetReport.php @@ -48,7 +48,7 @@ class CalendarMultiGetReport implements XmlDeserializable public $expand = null; /** - * The mimetype of the content that should be returend. Usually + * The mimetype of the content that should be returned. Usually * text/calendar. * * @var string diff --git a/lib/CalDAV/Xml/Request/CalendarQueryReport.php b/lib/CalDAV/Xml/Request/CalendarQueryReport.php index b3cc299d3d..5a4df46742 100644 --- a/lib/CalDAV/Xml/Request/CalendarQueryReport.php +++ b/lib/CalDAV/Xml/Request/CalendarQueryReport.php @@ -48,7 +48,7 @@ class CalendarQueryReport implements XmlDeserializable public $expand = null; /** - * The mimetype of the content that should be returend. Usually + * The mimetype of the content that should be returned. Usually * text/calendar. * * @var string diff --git a/lib/CardDAV/Backend/BackendInterface.php b/lib/CardDAV/Backend/BackendInterface.php index 6ef34d173c..f9955ac832 100644 --- a/lib/CardDAV/Backend/BackendInterface.php +++ b/lib/CardDAV/Backend/BackendInterface.php @@ -88,7 +88,7 @@ public function deleteAddressBook($addressBookId); * * size - The size of the card in bytes. * * If these last two properties are provided, less time will be spent - * calculating them. If they are specified, you can also ommit carddata. + * calculating them. If they are specified, you can also omit carddata. * This may speed up certain requests, especially with large cards. * * @param mixed $addressbookId @@ -98,7 +98,7 @@ public function deleteAddressBook($addressBookId); public function getCards($addressbookId); /** - * Returns a specfic card. + * Returns a specific card. * * The same set of properties must be returned as with getCards. The only * exception is that 'carddata' is absolutely required. diff --git a/lib/CardDAV/Backend/PDO.php b/lib/CardDAV/Backend/PDO.php index 4ca9284a9e..7b935a4aec 100644 --- a/lib/CardDAV/Backend/PDO.php +++ b/lib/CardDAV/Backend/PDO.php @@ -205,7 +205,7 @@ public function deleteAddressBook($addressBookId) * * size - The size of the card in bytes. * * If these last two properties are provided, less time will be spent - * calculating them. If they are specified, you can also ommit carddata. + * calculating them. If they are specified, you can also omit carddata. * This may speed up certain requests, especially with large cards. * * @param mixed $addressbookId diff --git a/lib/CardDAV/Xml/Request/AddressBookQueryReport.php b/lib/CardDAV/Xml/Request/AddressBookQueryReport.php index e1096fe28e..02402f6c79 100644 --- a/lib/CardDAV/Xml/Request/AddressBookQueryReport.php +++ b/lib/CardDAV/Xml/Request/AddressBookQueryReport.php @@ -82,7 +82,7 @@ class AddressBookQueryReport implements XmlDeserializable public $test; /** - * The mimetype of the content that should be returend. Usually + * The mimetype of the content that should be returned. Usually * text/vcard. * * @var string diff --git a/lib/DAV/Auth/Backend/PDOBasicAuth.php b/lib/DAV/Auth/Backend/PDOBasicAuth.php index 39324e4db8..d142cbfbfd 100644 --- a/lib/DAV/Auth/Backend/PDOBasicAuth.php +++ b/lib/DAV/Auth/Backend/PDOBasicAuth.php @@ -44,7 +44,7 @@ class PDOBasicAuth extends AbstractBasic * Digest prefix: * if the backend you are using for is prefixing * your password hashes set this option to your prefix to - * cut it off before verfiying. + * cut it off before verifying. * * @var string */ diff --git a/lib/DAV/Browser/Plugin.php b/lib/DAV/Browser/Plugin.php index 89495e5dbd..a8a6f430e4 100644 --- a/lib/DAV/Browser/Plugin.php +++ b/lib/DAV/Browser/Plugin.php @@ -522,7 +522,7 @@ public function htmlActionsPanel(DAV\INode $node, &$output, $path) /** * This method takes a path/name of an asset and turns it into url - * suiteable for http access. + * suitable for http access. * * @param string $assetName * diff --git a/lib/DAV/Exception/InvalidSyncToken.php b/lib/DAV/Exception/InvalidSyncToken.php index 37b28ca544..f28d20f414 100644 --- a/lib/DAV/Exception/InvalidSyncToken.php +++ b/lib/DAV/Exception/InvalidSyncToken.php @@ -9,7 +9,7 @@ /** * InvalidSyncToken. * - * This exception is emited for the {DAV:}valid-sync-token pre-condition, as + * This exception is emitted for the {DAV:}valid-sync-token pre-condition, as * defined in rfc6578, section 3.2. * * http://tools.ietf.org/html/rfc6578#section-3.2 diff --git a/lib/DAV/Exception/TooManyMatches.php b/lib/DAV/Exception/TooManyMatches.php index 3f7d2d5fb5..ef6f502433 100644 --- a/lib/DAV/Exception/TooManyMatches.php +++ b/lib/DAV/Exception/TooManyMatches.php @@ -9,7 +9,7 @@ /** * TooManyMatches. * - * This exception is emited for the {DAV:}number-of-matches-within-limits + * This exception is emitted for the {DAV:}number-of-matches-within-limits * post-condition, as defined in rfc6578, section 3.2. * * http://tools.ietf.org/html/rfc6578#section-3.2 diff --git a/lib/DAV/INodeByPath.php b/lib/DAV/INodeByPath.php index 4d63a33bd7..349ea10530 100644 --- a/lib/DAV/INodeByPath.php +++ b/lib/DAV/INodeByPath.php @@ -9,7 +9,7 @@ * * This interface adds a tiny bit of functionality to collections. * - * Getting a node that is deep in the tree normally requires going trough each parent node + * Getting a node that is deep in the tree normally requires going through each parent node * which can cause a significant performance overhead. * * Implementing this interface allows solving this overhead by directly jumping to the target node. diff --git a/lib/DAV/Sharing/Plugin.php b/lib/DAV/Sharing/Plugin.php index e7adbeee66..d766ae0de9 100644 --- a/lib/DAV/Sharing/Plugin.php +++ b/lib/DAV/Sharing/Plugin.php @@ -194,7 +194,7 @@ public function httpPost(RequestInterface $request, ResponseInterface $response) } /** - * This method is triggered whenever a subsystem reqeuests the privileges + * This method is triggered whenever a subsystem requests the privileges * hat are supported on a particular node. * * We need to add a number of privileges for scheduling purposes. diff --git a/lib/DAVACL/Plugin.php b/lib/DAVACL/Plugin.php index 46d680e154..f0497844d6 100644 --- a/lib/DAVACL/Plugin.php +++ b/lib/DAVACL/Plugin.php @@ -716,7 +716,7 @@ public function getPrincipalByUri($uri) * @param array $requestedProperties this is the list of properties to * return for every match * @param string $collectionUri the principal collection to search on. - * If this is ommitted, the standard + * If this is omitted, the standard * principal collection-set will be used * @param string $test "allof" to use AND to search the * properties. 'anyof' for OR. diff --git a/lib/DAVACL/PrincipalBackend/PDO.php b/lib/DAVACL/PrincipalBackend/PDO.php index 17bc245c5f..178bd7276f 100644 --- a/lib/DAVACL/PrincipalBackend/PDO.php +++ b/lib/DAVACL/PrincipalBackend/PDO.php @@ -80,7 +80,7 @@ public function __construct(\PDO $pdo) * return any additional properties if you wish so. Common properties are: * {DAV:}displayname * {http://sabredav.org/ns}email-address - This is a custom SabreDAV - * field that's actualy injected in a number of other properties. If + * field that's actually injected in a number of other properties. If * you have an email address, use this property. * * @param string $prefixPath diff --git a/lib/DAVACL/Xml/Property/Principal.php b/lib/DAVACL/Xml/Property/Principal.php index 52092128f3..5b9ee45172 100644 --- a/lib/DAVACL/Xml/Property/Principal.php +++ b/lib/DAVACL/Xml/Property/Principal.php @@ -149,7 +149,7 @@ public function toHtml(HtmlOutputHelper $html) /** * The deserialize method is called during xml parsing. * - * This method is called staticly, this is because in theory this method + * This method is called statically, this is because in theory this method * may be used as a type of constructor, or factory method. * * Often you want to return an instance of the current class, but you are diff --git a/tests/Sabre/CalDAV/Backend/AbstractPDOTest.php b/tests/Sabre/CalDAV/Backend/AbstractPDOTest.php index 769d215264..ae69784d1a 100644 --- a/tests/Sabre/CalDAV/Backend/AbstractPDOTest.php +++ b/tests/Sabre/CalDAV/Backend/AbstractPDOTest.php @@ -952,7 +952,7 @@ public function testGetChanges() $result = $backend->getChangesForCalendar($id, $currentToken, 1, 2); - // according to RFC6578 Section 3.6, the result including syncToken must correpsond to one time (syncToken=8 here) + // according to RFC6578 Section 3.6, the result including syncToken must correspond to one time (syncToken=8 here) self::assertEquals([ 'syncToken' => 8, 'modified' => [], diff --git a/tests/Sabre/CalDAV/Backend/MockSharing.php b/tests/Sabre/CalDAV/Backend/MockSharing.php index 1526e6e500..32d8f10a83 100644 --- a/tests/Sabre/CalDAV/Backend/MockSharing.php +++ b/tests/Sabre/CalDAV/Backend/MockSharing.php @@ -74,7 +74,7 @@ public function getNotificationsForPrincipal($principalUri) } /** - * This deletes a specific notifcation. + * This deletes a specific notification. * * This may be called by a client once it deems a notification handled. * diff --git a/tests/Sabre/CalDAV/Issue203Test.php b/tests/Sabre/CalDAV/Issue203Test.php index 902bab0ac9..0c02d83315 100644 --- a/tests/Sabre/CalDAV/Issue203Test.php +++ b/tests/Sabre/CalDAV/Issue203Test.php @@ -113,7 +113,7 @@ public function testIssue203() ], ]; - // try to match agains $expectedEvents array + // try to match against $expectedEvents array foreach ($expectedEvents as $expectedEvent) { $matching = false; diff --git a/tests/Sabre/CardDAV/Backend/Mock.php b/tests/Sabre/CardDAV/Backend/Mock.php index 6a570b1524..bef257cfe3 100644 --- a/tests/Sabre/CardDAV/Backend/Mock.php +++ b/tests/Sabre/CardDAV/Backend/Mock.php @@ -120,7 +120,7 @@ public function deleteAddressBook($addressBookId) * * size - The size of the card in bytes. * * If these last two properties are provided, less time will be spent - * calculating them. If they are specified, you can also ommit carddata. + * calculating them. If they are specified, you can also omit carddata. * This may speed up certain requests, especially with large cards. * * @param mixed $addressBookId @@ -150,7 +150,7 @@ public function getCards($addressBookId) } /** - * Returns a specfic card. + * Returns a specific card. * * The same set of properties must be returned as with getCards. The only * exception is that 'carddata' is absolutely required. diff --git a/tests/Sabre/DAV/Auth/Backend/Mock.php b/tests/Sabre/DAV/Auth/Backend/Mock.php index fca7f722f1..c1c223f3da 100644 --- a/tests/Sabre/DAV/Auth/Backend/Mock.php +++ b/tests/Sabre/DAV/Auth/Backend/Mock.php @@ -62,7 +62,7 @@ public function check(RequestInterface $request, ResponseInterface $response) * This method is called when a user could not be authenticated, and * authentication was required for the current request. * - * This gives you the oppurtunity to set authentication headers. The 401 + * This gives you the opportunity to set authentication headers. The 401 * status code will already be set. * * In this case of Basic Auth, this would for example mean that the diff --git a/tests/Sabre/DAV/HttpPutTest.php b/tests/Sabre/DAV/HttpPutTest.php index cdc567c944..94d95922ce 100644 --- a/tests/Sabre/DAV/HttpPutTest.php +++ b/tests/Sabre/DAV/HttpPutTest.php @@ -307,7 +307,7 @@ public function testFinderPutSuccess() } /** - * Same as the last one, but in this case we're mimicing a failed request. + * Same as the last one, but in this case we're mimicking a failed request. * * @depends testFinderPutSuccess */ diff --git a/tests/Sabre/DAV/Sync/MockSyncCollection.php b/tests/Sabre/DAV/Sync/MockSyncCollection.php index d24ba0af72..9a37d4ac31 100644 --- a/tests/Sabre/DAV/Sync/MockSyncCollection.php +++ b/tests/Sabre/DAV/Sync/MockSyncCollection.php @@ -137,7 +137,7 @@ function ($item) { if ($limit) { // If there's a limit, we may need to cut things off. - // This alghorithm is weird and stupid, but it works. + // This algorithm is weird and stupid, but it works. $left = $limit - (count($modified) + count($deleted)); if ($left > 0) { continue;