Jonas Meurer
7c76e85dde
Use IURLGenerator function to get value of `\OC::$WEBROOT` global
Signed-off-by: Jonas Meurer <jonas@freesources.org>
2年前
Roeland Jago Douma
72a9c35be3
Remove some IRouter methods
This is not the end. IRouter needs to burn.
But it is a start.
🎵 we didn't start the fire 🎵
Signed-off-by: Roeland Jago Douma <roeland@famdouma.nl>
4年前
Morris Jobke
387cac4c5f
Properly inject IRouter into URLGenerator to properly encapsulate tests
Signed-off-by: Morris Jobke <hey@morrisjobke.de>
3年前
Morris Jobke
053ee7b386
Only load routes of the app which is requested
* Add fallback to load all routes if needed
* Move partial loaded routes test to proper place
Signed-off-by: Morris Jobke <hey@morrisjobke.de>
5年前
Morris Jobke
234b510652
Change PHPDoc type hint from PHPUnit_Framework_MockObject_MockObject to \PHPUnit\Framework\MockObject\MockObject
Signed-off-by: Morris Jobke <hey@morrisjobke.de>
3年前
Christoph Wurst
1584c9ae9c
Add visibility to all methods and position of static keyword
Signed-off-by: Christoph Wurst <christoph@winzerhof-wurst.at>
4年前
Christoph Wurst
caff1023ea
Format control structures, classes, methods and function
To continue this formatting madness, here's a tiny patch that adds
unified formatting for control structures like if and loops as well as
classes, their methods and anonymous functions. This basically forces
the constructs to start on the same line. This is not exactly what PSR2
wants, but I think we can have a few exceptions with "our" style. The
starting of braces on the same line is pracrically standard for our
code.
This also removes and empty lines from method/function bodies at the
beginning and end.
Signed-off-by: Christoph Wurst <christoph@winzerhof-wurst.at>
4年前
Christoph Wurst
41b5e5923a
Use exactly one empty line after the namespace declaration
For PSR2
Signed-off-by: Christoph Wurst <christoph@winzerhof-wurst.at>
4年前
Roeland Jago Douma
3a7cf40aaa
Mode to modern phpunit
Signed-off-by: Roeland Jago Douma <roeland@famdouma.nl>
4年前
Roeland Jago Douma
c007ca624f
Make phpunit8 compatible
Signed-off-by: Roeland Jago Douma <roeland@famdouma.nl>
4年前
Joas Schilling
b8fcf6e9b3
Allow empty strings in getAbsoluteURL
Signed-off-by: Joas Schilling <coding@schilljs.com>
5年前
Joas Schilling
2b18b9ae96
Update the URLGenerator test to current state of art
Signed-off-by: Joas Schilling <coding@schilljs.com>
5年前
Roeland Jago Douma
c97b4274cc
Add function to generate urls for OCS routes
fixes #11617
The OCS routes are only absolute for now as they are often exposed to
the outside anyway and are on a different endpoint than index.php in
anyway.
Signed-off-by: Roeland Jago Douma <roeland@famdouma.nl>
5年前
John Molakvoæ (skjnldsv)
c0c4443ffc
Fixed tests
Signed-off-by: John Molakvoæ (skjnldsv) <skjnldsv@protonmail.com>
6年前
Julius Härtl
f039ba7480
Add tests and inject IRequest
Signed-off-by: Julius Härtl <jus@bitgrid.net>
7年前
Roeland Jago Douma
2164085f22
Fix urlgenerator test
Signed-off-by: Roeland Jago Douma <roeland@famdouma.nl>
7年前
Roeland Jago Douma
478b86e5e5
Fix getMock UrlGeneratortest
7年前
Joas Schilling
9a4253ef7c
Fix lib/
8年前
Thomas Müller
f9fc254672
Add DB group to some files_external tests
Adding group Db to federation tests and ldap tests
Add group DB to Test_UrlGenerator
Adding group DB to trashbin and versions tests
Adding group DB to Test_Util_CheckServer for pg
8年前
Lukas Reschke
daa388ce8d
Move index.php from files to AppFramework
1. Allows it to use the more secure CSP rules of the AppFramework.
2. Adds some unit tests.
8年前
Lukas Reschke
9e2ebf2dce
Cache \OC\URLGenerator::imagePath
\OC\URLGenerator::imagePath is a really expensive operation due to all the I/O handling and can really benefit from caching.
9年前
Joas Schilling
cb3a598cdb
Make root tests extend the \Test\TestCase
9年前
Lukas Reschke
3ad9489634
Add unit test
This unit test is shitty but at least it works...
9年前
Morris Jobke
dc36d30953
Remove all occurences of @brief and @returns from PHPDoc
* test case added to avoid adding them later
10年前
Thomas Tanghus
df9d9ac958
Remove unused var
10年前
Thomas Tanghus
dd36d4b894
Add tests for linkTo, linkToPublic, linkToRemote, linkToRemoteBase
10年前
Thomas Tanghus
ada8d4e0c9
Fix unit tests
10年前
Bjoern Schiessle
1ae6e9ec21
add unit test for \OC\URLGenerator::getAbsoluteURL to verify #6935
10年前