Commit Graph

1561 Commits

Author SHA1 Message Date
Joas Schilling 4f92e4a233 Merge pull request #12808 from owncloud/add-special-parameterlist-to-manager
Add special parameterlist to manager
2014-12-12 13:03:26 +01:00
Lukas Reschke 26b0a89874 Add test for user without backend 2014-12-12 12:39:31 +01:00
Thomas Müller dcb88e395b rework api of DependencyAnalyzer 2014-12-12 12:34:53 +01:00
Vincent Petry 15ecb28d50 Make $userId mandatory for searchByTags
$userId is now a mandatory parameter for searchByTags.

Also fixed some places in the code where the argument was missing (Node
API and View)
2014-12-12 11:18:35 +01:00
Vincent Petry 25dde7e93b Added searchByTags to view, storage and cache 2014-12-11 17:38:50 +01:00
Thomas Müller f1d1714113 fix unit tests 2014-12-11 16:22:30 +01:00
Thomas Müller 6566dc83e7 single dependencies will not be represented as an array + fix unit tests 2014-12-11 15:37:45 +01:00
Joas Schilling e3dfddb48a Add test for getSpecialParameterList() 2014-12-11 15:01:45 +01:00
Morris Jobke 8fd90e04b6 Merge pull request #12781 from owncloud/jenkins-curl-open-basedir
[Jenkins only] curl open basedir
2014-12-11 14:15:24 +01:00
Joas Schilling 17d68e0638 Merge pull request #12780 from owncloud/make-datetimeformattertest-reliable
Use a fixed timestamp so we dont switch days/years with the getTimestampAgo
2014-12-11 14:11:07 +01:00
Joas Schilling affeea8c72 Use a fixed timestamp so we dont switch days/years with the getTimestampAgo 2014-12-11 13:22:05 +01:00
Joas Schilling cbad5c998b Correctly fallback to english, if the plural case is not translated 2014-12-11 12:42:21 +01:00
Vincent Petry 745d8706b9 Add user parameter to tag manager 2014-12-11 12:22:28 +01:00
Thomas Müller 5a03e0a5cf adding dependency to owncloud version - with fallback to requiremin and requiremax 2014-12-11 12:02:12 +01:00
Thomas Müller ee46548f57 adding dependencies for supported platforms 2014-12-11 12:02:12 +01:00
Thomas Müller 770f987659 adding supported libraries - including min and max version 2014-12-11 12:02:11 +01:00
Thomas Müller 08f1db4451 adding dependencies for command line tools 2014-12-11 12:02:11 +01:00
Lukas Reschke 9ea205dc3d Check if open_basedir is set
The file:// protocol does not work with curl when an open_basedir is set.

This fixes https://github.com/owncloud/core/issues/12016
2014-12-11 00:09:55 +01:00
Thomas Müller 6143232da6 Merge pull request #12746 from owncloud/skip-longpath-test-again
skip testLongPath()
2014-12-10 17:22:04 +01:00
Vincent Petry 5101bc54fa Add login/logout to TestCase base class 2014-12-10 16:11:27 +01:00
Robin Appelman 3898fbc0d2 Merge pull request #12750 from owncloud/cache-numericstorageidfix
Fix numeric storage id for cache wrapper
2014-12-10 15:03:41 +01:00
Joas Schilling fd2599cfc2 Merge pull request #12485 from owncloud/jenkins-12383
New DateTimeFormatter class for dates in other timezones and languages
2014-12-10 14:48:59 +01:00
Vincent Petry ebba54d490 Fix numeric storage id for cache wrapper 2014-12-10 13:05:31 +01:00
Jörn Friedrich Dreyer 363e9667ec Add Redis cache implementation, prefer over memcached, tests & config sample 2014-12-10 12:24:20 +01:00
Thomas Müller d648b548eb skip testLongPath() 2014-12-10 12:20:30 +01:00
Lukas Reschke 5dc6406b70 Add filter for 'backend' to user REST route
This adds a "backend" type filter to the index REST route which is a pre-requisite for https://github.com/owncloud/core/issues/12620

For example when calling `index.php/settings/users/users?offset=0&limit=10&gid=&pattern=&backend=OC_User_Database` only users within the backend `OC_User_Database` would be shown. (requires sending a CSRF token as well)

Depends upon https://github.com/owncloud/core/pull/12711
2014-12-10 12:07:34 +01:00
Joas Schilling 4d232e536e Deprecate Util::formatDate()
Make DateTimeFormatter a service and adjust tests that have been inaccurate
2014-12-10 11:58:56 +01:00
Lukas Reschke 5398bbdc00 Merge pull request #12711 from owncloud/add-backend-to-rest-index
Expose backend type via REST API
2014-12-10 11:56:45 +01:00
Thomas Müller 7028c7150d Merge pull request #12664 from owncloud/fix-12164
Use httphelper and cache response even when it is empty
2014-12-10 05:42:08 +01:00
Victor Dubiniuk adab0ca98a Remove leftover 2014-12-10 02:21:10 +03:00
Victor Dubiniuk c9fd3c9d29 Inject config 2014-12-10 01:13:38 +03:00
Morris Jobke 263e008d7b Merge pull request #12695 from owncloud/db-drop-table
Add dropTable to IDBConnection
2014-12-09 18:40:56 +01:00
Robin Appelman b66c0a1631 add unit tests for tableExists and dropTable 2014-12-09 17:26:53 +01:00
Joas Schilling 681caf882a Add sometests and copy tests from Util::formatDate to new class 2014-12-09 16:10:24 +01:00
Joas Schilling f53f25eafe Merge pull request #12409 from owncloud/tags-getTagsForObjectIds
Add getTagsForObjects in ITags
2014-12-09 13:27:38 +01:00
Lukas Reschke 7a290a3d6b Make class compatible 2014-12-09 12:25:22 +01:00
Lukas Reschke 4c13918bd8 Expose backend type via REST API
This change will expose the user backend via the REST API which is a pre-requisite for https://github.com/owncloud/core/issues/12620.

For example:
````json
[{"name":"9707A09E-CA9A-4ABE-A66A-3F632F16C409","displayname":"Document Conversion User Account","groups":[],"subadmin":[],"quota":"default","storageLocation":"\/Users\/lreschke\/Programming\/core\/data\/9707A09E-CA9A-4ABE-A66A-3F632F16C409","lastLogin":0,"backend":"OCA\\user_ldap\\USER_LDAP"},{"name":"ED86733E-745C-4E4D-90CB-278A9737DB3C","displayname":"Hacker","groups":[],"subadmin":[],"quota":"default","storageLocation":"\/Users\/lreschke\/Programming\/core\/data\/ED86733E-745C-4E4D-90CB-278A9737DB3C","lastLogin":0,"backend":"OCA\\user_ldap\\USER_LDAP"},{"name":"71CDF45B-E125-450D-983C-D9192F36EC88","displayname":"admin","groups":[],"subadmin":[],"quota":"default","storageLocation":"\/Users\/lreschke\/Programming\/core\/data\/71CDF45B-E125-450D-983C-D9192F36EC88","lastLogin":0,"backend":"OCA\\user_ldap\\USER_LDAP"},{"name":"admin","displayname":"admin","groups":["admin"],"subadmin":[],"quota":"default","storageLocation":"\/Users\/lreschke\/Programming\/core\/data\/admin","lastLogin":"1418057287","backend":"OC_User_Database"},{"name":"test","displayname":"test","groups":[],"subadmin":[],"quota":"default","storageLocation":"\/Users\/lreschke\/Programming\/core\/data\/test","lastLogin":0,"backend":"OC_User_Database"}]
```
2014-12-09 12:04:19 +01:00
Thomas Müller 5609d421cd Merge pull request #12672 from LEDfan/cm-per-unit
Fix Contactsmanager permission + unit test
2014-12-09 10:57:22 +01:00
Thomas Müller c36bac3abd Merge pull request #12406 from owncloud/drop-getApps-getUsers
Config cleanup - OC_Preferences refactoring
2014-12-09 09:36:38 +01:00
Lukas Reschke 25a87d4058 Merge pull request #12577 from owncloud/public-mount-api
Add a public api for apps to add mounts
2014-12-08 22:57:33 +01:00
Morris Jobke 9a7362dd0d drop unused isDebugMode and setDebugMode of OC_Config 2014-12-08 22:42:44 +01:00
Morris Jobke 0d4f0ab871 reduce OC_Preferences, OC_Config and \OCP\Config usage
* files_encryption
* files_versions
* files_trashbin
* tests
* status.php
* core
* server container
2014-12-08 22:42:37 +01:00
Morris Jobke 2d5fc9c1a6 Workaround to fix the too early init dilemma
* this needs to be properly fixed by a proper organisation of the base.php
* introduced fixDIInit() in AllConfig that moves the injection
  of DatabaseConnection to a later point in time
* problems mostly because of the autoconfig setup
2014-12-08 22:33:36 +01:00
Morris Jobke af91ee97c9 introduce preCondition for setUserValue to provide atomic check-and-update 2014-12-08 22:33:36 +01:00
Morris Jobke f0b10324ca Refactoring of OC_Preferences to AllConfig
* keep old static methods - mapped to new ones and deprecated
* removed deleteApp, getUsers, getApps because they are unused
* make AllConfig unit tests more robust against not cleaned up environments
2014-12-08 22:33:29 +01:00
Morris Jobke a9e411e076 migrate \OC\AllConfig to \OCP\IConfig 2014-12-08 22:29:43 +01:00
Morris Jobke 50c2a819a0 Extract interaction with config.php into SystemConfig
* introduce SystemConfig to avoid DI circle (used by database connection which is itself needed by AllConfig that itself contains the methods to access the config.php which then would need the database connection - did you get it? ;))
* use DI container and use that method in legacy code paths (for easier refactoring later)
* create and use getSystemConfig instead of query() in DI container
2014-12-08 22:29:42 +01:00
Vincent Petry cae600722e Add getTagsForObjects in ITags
Returns the list of tags that are set on the given object ids.
2014-12-08 22:02:00 +01:00
Victor Dubiniuk 81d5712419 Fix tests. Add two more test cases 2014-12-08 22:16:47 +03:00
Lukas Reschke c23957811d React on other statuscodes than 200 2014-12-08 16:35:13 +01:00
Lukas Reschke 8b3e389062 Add statuscodes 2014-12-08 15:32:59 +01:00
LEDfan 3d11e091d9 Mock interface 2014-12-08 13:18:00 +01:00
Lukas Reschke fe7d9a7ca0 Add REST route for user & group management
First step of a somewhat testable user management. - I know, the JSON returns are in an ugly format but the JS expects it that way. So let's keep it that way until we have time to fix the JS in the future.
2014-12-08 12:11:01 +01:00
LEDfan c05ff09651 Use PHPUnit mocks 2014-12-07 14:10:41 +01:00
LEDfan 88ad095cc7 Add unit test for contactsmanager 2014-12-07 08:39:15 +01:00
Victor Dubiniuk 2a3f5ccae3 Test OC\Updater::check 2014-12-06 20:17:59 +03:00
Morris Jobke 4ec1da3014 Merge pull request #12583 from owncloud/trim-port
Trim port from domain
2014-12-05 11:27:20 +01:00
Joas Schilling e81c2a49d1 Merge pull request #12622 from owncloud/disable-for-all
Disable when no sendmail is available
2014-12-05 10:10:43 +01:00
Morris Jobke b6975143ff Merge pull request #12619 from owncloud/use-also-original-hea
Merge headers
2014-12-04 16:59:42 +01:00
Robin Appelman f4701d7721 Add public api for mount configurations 2014-12-04 16:47:27 +01:00
Morris Jobke f3213571bb Merge pull request #12616 from owncloud/node-fileinfo
make \OC\Files\Node\Node implement the FileInfo interface
2014-12-04 16:34:30 +01:00
Lukas Reschke e1e8031798 Disable when no sendmail is available 2014-12-04 16:22:44 +01:00
Morris Jobke a0488453ac Merge pull request #12596 from owncloud/remove-travis-traces
Remove last traces of travis integration
2014-12-04 16:04:15 +01:00
Lukas Reschke d2e8358da2 Fix unit test 2014-12-04 15:54:32 +01:00
Robin Appelman 672495a1a3 make \OC\Files\Node\Node implement the FileInfo interface 2014-12-04 13:27:08 +01:00
Lukas Reschke 81541c56b6 Add test for IPv6 without port 2014-12-04 12:16:33 +01:00
Thomas Müller b55ac514ac no nested xml tags on dependencies 2014-12-04 11:40:33 +01:00
Thomas Müller 086ec3de15 adding command dependency 2014-12-04 11:40:33 +01:00
Thomas Müller b028a6afac adjust dependency analyzer to use attributes properly 2014-12-04 11:40:33 +01:00
Thomas Müller c80ec91f28 switch to different parsing implementation to get xml attributes properly handled 2014-12-04 11:40:33 +01:00
Thomas Müller ba52c996cf adding supported databases 2014-12-04 11:40:33 +01:00
Thomas Müller b469e9f6fb introduce dependency analyzer to take care of app dependencies
some more unit tests on xml info parser
2014-12-04 11:40:33 +01:00
Thomas Müller f74d568bda adding new dependency for php version in apps info.xml 2014-12-04 11:40:33 +01:00
Morris Jobke bf1b62a34a PHP < 5.4 is not supported anymore - see #12606 2014-12-04 11:05:45 +01:00
Morris Jobke 2c5e4b3d3f Remove last traces of travis integration 2014-12-04 10:09:13 +01:00
Lukas Reschke 69f5f6649e Trim port from domain
Depending on the used environment the port might be appended to the host header resulting in an inaccessible instance when initially setting up on a system with a different HTTP or HTTPS port. (for example test:500)

To test this setup ownCloud under a different port with and without this patch. (heads-up: localhost is always white-listed, so use a different domain)
2014-12-03 19:59:50 +01:00
Thomas Müller 3d9c72d2d9 Merge pull request #12544 from owncloud/fix-windows-unittests
Replace uniqid calls with $this->getUniqueID so tests pass again on windows
2014-12-03 17:49:10 +01:00
Morris Jobke e014a18b4a drop files_external tests from autotest - they will be executed with autotest-external.sh which is coming 2014-12-03 16:38:25 +01:00
Joas Schilling ea4c25609d Replace uniqid calls with $this->getUniqueID so tests pass again on windows 2014-12-03 12:10:55 +01:00
Lukas Reschke f0e6876f2e Merge pull request #12488 from owncloud/activity_group_multiple_conditions
activitymanager: concatenate queries with 'or'
2014-11-28 17:35:05 +01:00
Bjoern Schiessle bf2c9be066 concatenate queries with 'or' 2014-11-28 14:46:27 +01:00
Joas Schilling 9cfae2ed44 Skip lostcontroller sending email test on windows 2014-11-28 11:38:22 +01:00
Morris Jobke b188710af3 Merge pull request #12472 from owncloud/modifyCookies
Add functions to modify cookies to response class
2014-11-28 10:16:22 +01:00
Morris Jobke 7a9af8c40c Merge pull request #12443 from owncloud/issue/6101-all-classes-autoloadable
Issue/6101 Make all interfaces/classes autoloadable
2014-11-28 09:40:27 +01:00
Joas Schilling dfde04291e Move share interfaces to own files so they can be autoloaded 2014-11-27 17:47:19 +01:00
Robin Appelman 33b64868d7 Add storage and cache wrappers to apply a permissions mask to a storage 2014-11-27 15:25:57 +01:00
Robin Appelman abb6e89c5d Add storage and cache wrappers to jail a storage to a subfolder 2014-11-27 15:25:53 +01:00
Lukas Reschke 048139074d Add functions to modify cookies to response class
Currently there is no AppFramework way to modify cookies, which makes it unusable for quite some use-cases or results in untestable code.

This PR adds some basic functionalities to add and invalidate cookies.

Usage:
```php
$response = new TemplateResponse(...);
$response->addCookie('foo', 'bar');
$response->invalidateCookie('foo');
$response->addCookie('bar', 'foo', new \DateTime('2015-01-01 00:00'));
```

Existing cookies can be accessed with the AppFramework using `$this->request->getCookie($name)`.
2014-11-27 14:19:00 +01:00
Joas Schilling e1f3abf7a5 Correctly namespace and autoload DatabaseException 2014-11-27 11:10:04 +01:00
Morris Jobke 60e4aa120f Merge pull request #12350 from mprokop/link_expiration
fix calculation of expiration date if there is a default expiration date...
2014-11-26 10:19:12 +01:00
Morris Jobke c5fa8f1bdc Merge pull request #12421 from owncloud/issue/6101-remove-namespace-permission-constants
Issue/6101 remove namespace permission constants
2014-11-26 08:31:23 +01:00
Morris Jobke e9696a8c9a Merge pull request #12420 from owncloud/sqlite-wal-2
adding new config parameter for sqlite to specify the journal mode
2014-11-26 00:47:22 +01:00
Thomas Müller 5d4b7e0e2b fix failing unit test for the temp manager - concurrently executed unit tests influence each other 2014-11-25 22:16:48 +01:00
Joas Schilling 2c39aec8cb Replace deprecated constant with new class constant 2014-11-25 16:30:21 +01:00
Thomas Müller a6c088a1ef adding new config parameter for sqlite to specify the journal mode 2014-11-25 16:29:06 +01:00
Thomas Müller 5ce34fbaf6 handle invalid xml file 2014-11-25 11:53:28 +01:00
Thomas Müller d4f107d4dd simplify xml parser code 2014-11-25 11:53:28 +01:00
Thomas Müller c503ecd544 Introduce app info xml parser including basic unit test - necessary for #10777 2014-11-25 11:53:28 +01:00
Lukas Reschke eb1dcb87c1 Merge pull request #12380 from owncloud/remove-oc-migrate
Remove OC_Migrate
2014-11-25 00:25:37 +01:00
Thomas Müller ddacd7f900 Merge pull request #12294 from owncloud/route-postfix
Add route postfix to allow url versioning when only the http method changed
2014-11-24 16:32:54 +01:00