nextcloud/tests/lib
Lukas Reschke 886bda5f81 Refactor OC_Request into TrustedDomainHelper and IRequest
This changeset removes the static class `OC_Request` and moves the functions either into `IRequest` which is accessible via `\OC::$server::->getRequest()` or into a separated `TrustedDomainHelper` class for some helper methods which should not be publicly exposed.

This changes only internal methods and nothing on the public API. Some public functions in `util.php` have been deprecated though in favour of the new non-static functions.

Unfortunately some part of this code uses things like `__DIR__` and thus is not completely unit-testable. Where tests where possible they ahve been added though.

Fixes https://github.com/owncloud/core/issues/13976 which was requested in https://github.com/owncloud/core/pull/13973#issuecomment-73492969
2015-02-16 22:13:00 +01:00
..
app implement php code checker to detect usage of not allowed private APIs - including console command to check local code to be used by developers 2015-02-10 11:51:24 +01:00
appframework Refactor OC_Request into TrustedDomainHelper and IRequest 2015-02-16 22:13:00 +01:00
archive Make root tests extend the \Test\TestCase 2014-11-19 14:53:51 +01:00
backgroundjob Make remaining files extend the test base 2014-11-19 14:53:59 +01:00
cache Make root tests extend the \Test\TestCase 2014-11-19 14:53:51 +01:00
connector/sabre Fix webdav put for single file webdav shares 2015-01-29 12:47:12 +01:00
contacts Make class compatible 2014-12-09 12:25:22 +01:00
db Merge pull request #12995 from owncloud/tbelau666-master 2015-01-09 14:17:14 +01:00
files update test 2015-02-13 15:01:05 +01:00
group add isAdmin and isInGroup methods for the group manager 2014-12-17 17:41:57 +01:00
hooks Make remaining files extend the test base 2014-11-19 14:53:59 +01:00
memcache Add an array implementation of cache and use it if we are not debugging 2015-02-16 14:55:50 +01:00
ocs Replace uniqid calls with $this->getUniqueID so tests pass again on windows 2014-12-03 12:10:55 +01:00
public Make remaining files extend the test base 2014-11-19 14:53:59 +01:00
repair Updated the media type of some font types 2015-01-24 01:49:13 +01:00
security Refactor OC_Request into TrustedDomainHelper and IRequest 2015-02-16 22:13:00 +01:00
session Replace uniqid calls with $this->getUniqueID so tests pass again on windows 2014-12-03 12:10:55 +01:00
share Add a test for the post_shared hook shareType 2015-02-09 13:12:34 +01:00
template Make remaining files extend the test base 2014-11-19 14:53:59 +01:00
user introduce names for user backends - IUserBackend 2014-12-19 10:17:17 +01:00
activitymanager.php Add test for getSpecialParameterList() 2014-12-11 15:01:45 +01:00
allconfig.php Workaround to fix the too early init dilemma 2014-12-08 22:33:36 +01:00
api.php Replace uniqid calls with $this->getUniqueID so tests pass again on windows 2014-12-03 12:10:55 +01:00
app.php Merge pull request #13319 from owncloud/replace-line-breaks-in-app-description 2015-01-17 01:03:41 +01:00
appconfig.php Make root tests extend the \Test\TestCase 2014-11-19 14:53:51 +01:00
archive.php Make root tests extend the \Test\TestCase 2014-11-19 14:53:51 +01:00
autoloader.php Make root tests extend the \Test\TestCase 2014-11-19 14:53:51 +01:00
avatar.php Make root tests extend the \Test\TestCase 2014-11-19 14:53:51 +01:00
cache.php Make remaining files extend the test base 2014-11-19 14:53:59 +01:00
config.php Add a method to set/unset multiple config values in one call 2015-01-23 11:00:53 +01:00
contactsmanager.php Mock interface 2014-12-08 13:18:00 +01:00
datetimeformatter.php Use a fixed timestamp so we dont switch days/years with the getTimestampAgo 2014-12-11 13:22:05 +01:00
db.php Replace uniqid calls with $this->getUniqueID so tests pass again on windows 2014-12-03 12:10:55 +01:00
dbschema.php Make root tests extend the \Test\TestCase 2014-11-19 14:53:51 +01:00
errorHandler.php Make root tests extend the \Test\TestCase 2014-11-19 14:53:51 +01:00
geo.php Make root tests extend the \Test\TestCase 2014-11-19 14:53:51 +01:00
group.php Do not use uniqid in Group and User tests as it is not unique on windows 2014-11-06 17:36:35 +01:00
helper.php Make root tests extend the \Test\TestCase 2014-11-19 14:53:51 +01:00
helperstorage.php reduce OC_Preferences, OC_Config and \OCP\Config usage 2014-12-08 22:42:37 +01:00
httphelper.php Next step in server-to-server sharing next generation, see #12285 2014-12-19 15:20:24 +01:00
image.php Make root tests extend the \Test\TestCase 2014-11-19 14:53:51 +01:00
installer.php Make root tests extend the \Test\TestCase 2014-11-19 14:53:51 +01:00
l10n.php Correctly fallback to english, if the plural case is not translated 2014-12-11 12:42:21 +01:00
largefilehelper.php Make root tests extend the \Test\TestCase 2014-11-19 14:53:51 +01:00
largefilehelpergetfilesize.php Check if open_basedir is set 2014-12-11 00:09:55 +01:00
logger.php Make root tests extend the \Test\TestCase 2014-11-19 14:53:51 +01:00
mail.php Fix undefined offset 1 for wrong user mail address 2015-01-22 16:23:50 +01:00
naturalsort.php Make root tests extend the \Test\TestCase 2014-11-19 14:53:51 +01:00
preview.php Make root tests extend the \Test\TestCase 2014-11-19 14:53:51 +01:00
repair.php Make root tests extend the \Test\TestCase 2014-11-19 14:53:51 +01:00
setup.php Add version to .htaccess 2015-01-08 12:49:02 +01:00
streamwrappers.php HHVM Workaround: Do not use Exception from Stream. 2015-01-09 17:01:17 +01:00
tags.php Fix chunked query for tags + unit test 2015-01-19 17:05:44 +01:00
template.php Deprecate Util::formatDate() 2014-12-10 11:58:56 +01:00
templatelayout.php Refactor OC_Request into TrustedDomainHelper and IRequest 2015-02-16 22:13:00 +01:00
tempmanager.php fix failing unit test for the temp manager - concurrently executed unit tests influence each other 2014-11-25 22:16:48 +01:00
testcase.php Add login/logout to TestCase base class 2014-12-10 16:11:27 +01:00
updater.php Next step in server-to-server sharing next generation, see #12285 2014-12-19 15:20:24 +01:00
urlgenerator.php Make root tests extend the \Test\TestCase 2014-11-19 14:53:51 +01:00
user.php Make root tests extend the \Test\TestCase 2014-11-19 14:53:51 +01:00
util.php Move timezone logic out of server.php 2014-12-16 16:16:22 +01:00
utilcheckserver.php Make root tests extend the \Test\TestCase 2014-11-19 14:53:51 +01:00
vobject.php Make root tests extend the \Test\TestCase 2014-11-19 14:53:51 +01:00