Commit Graph

2650 Commits

Author SHA1 Message Date
Björn Schießle efc030aa25 don't allow to create a federated share if source and target server are the same 2015-12-14 17:16:14 +01:00
Thomas Müller f831d93f3f Merge pull request #20878 from owncloud/proper-htaccess-support-in-code-signing-checker
Also run .htaccess routine when installing on another system than Apache
2015-12-11 11:46:37 +01:00
Thomas Müller 6317ba8cb4 Merge pull request #21135 from owncloud/add-polyfill
Add polyfills for PHP55, PHP56 and PHP70 functionalities
2015-12-11 11:40:51 +01:00
Lukas Reschke f3360d51c6 Use PHP polyfills 2015-12-11 08:47:36 +01:00
Scrutinizer Auto-Fixer ffc49a24f0 Scrutinizer Auto-Fixes
This commit consists of patches automatically generated for this project on https://scrutinizer-ci.com
2015-12-10 16:43:37 +01:00
Thomas Müller df15d54db6 Merge pull request #21072 from owncloud/db-lock-ttl
Remove all locks after ttl from the db
2015-12-10 13:51:18 +01:00
Thomas Müller 75c3d64635 Merge pull request #21105 from owncloud/fix-risky-test-comments
Add assertion to test
2015-12-10 11:02:27 +01:00
Lukas Reschke 29b6a03fc1 Add assertion to test
This seems to be missing on that test.
2015-12-10 09:29:24 +01:00
Lukas Reschke 715b0941ee Make compatible with PHPUnit 5.1
`addWarning` needs to be defined as well for it:

```
➜  master git:(master) ✗ bash autotest.sh sqlite
Using PHP executable /usr/local/opt/php56/bin/php
Parsing all files in lib/public for the presence of @since or @deprecated on each method...

Using database oc_autotest
Setup environment for sqlite testing on local storage ...
Installing ....
ownCloud is not installed - only a limited number of commands are available
Mac OS X is not supported and ownCloud will not work properly on this platform. Use it at your own risk!
 -> For the best results, please consider using a GNU/Linux server instead.
creating sqlite db
ownCloud was successfully installed
Testing with sqlite ...
No coverage
/usr/local/bin/phpunit --configuration phpunit-autotest.xml --log-junit autotest-results-sqlite.xml
PHP Notice:  Constant PHPUNIT_RUN already defined in /Users/lukasreschke/Documents/Programming/master/apps/firstrunwizard/tests/bootstrap.php on line 6
PHP Stack trace:
PHP   1. {main}() /usr/local/Cellar/phpunit/5.1.0/libexec/phpunit-5.1.0.phar:0
PHP   2. PHPUnit_TextUI_Command::main() /usr/local/Cellar/phpunit/5.1.0/libexec/phpunit-5.1.0.phar:514
PHP   3. PHPUnit_TextUI_Command->run() phar:///usr/local/Cellar/phpunit/5.1.0/libexec/phpunit-5.1.0.phar/phpunit/TextUI/Command.php:106
PHP   4. PHPUnit_TextUI_Command->handleArguments() phar:///usr/local/Cellar/phpunit/5.1.0/libexec/phpunit-5.1.0.phar/phpunit/TextUI/Command.php:117
PHP   5. PHPUnit_Util_Configuration->getTestSuiteConfiguration() phar:///usr/local/Cellar/phpunit/5.1.0/libexec/phpunit-5.1.0.phar/phpunit/TextUI/Command.php:663
PHP   6. PHPUnit_Util_Configuration->getTestSuite() phar:///usr/local/Cellar/phpunit/5.1.0/libexec/phpunit-5.1.0.phar/phpunit/Util/Configuration.php:796
PHP   7. PHPUnit_Framework_TestSuite->addTestFile() phar:///usr/local/Cellar/phpunit/5.1.0/libexec/phpunit-5.1.0.phar/phpunit/Util/Configuration.php:926
PHP   8. PHPUnit_Util_Fileloader::checkAndLoad() phar:///usr/local/Cellar/phpunit/5.1.0/libexec/phpunit-5.1.0.phar/phpunit/Framework/TestSuite.php:335
PHP   9. PHPUnit_Util_Fileloader::load() phar:///usr/local/Cellar/phpunit/5.1.0/libexec/phpunit-5.1.0.phar/phpunit/Util/Fileloader.php:38
PHP  10. include_once() phar:///usr/local/Cellar/phpunit/5.1.0/libexec/phpunit-5.1.0.phar/phpunit/Util/Fileloader.php:56
PHP  11. loadDirectory() /Users/lukasreschke/Documents/Programming/master/tests/apps.php:42
PHP  12. require_once() /Users/lukasreschke/Documents/Programming/master/tests/apps.php:20
PHP  13. define() /Users/lukasreschke/Documents/Programming/master/apps/firstrunwizard/tests/bootstrap.php:6
PHP Fatal error:  Class StartSessionListener contains 1 abstract method and must therefore be declared abstract or implement the remaining methods (PHPUnit_Framework_TestListener::addWarning) in /Users/lukasreschke/Documents/Programming/master/tests/startsessionlistener.php on line 47
PHP Stack trace:
PHP   1. {main}() /usr/local/Cellar/phpunit/5.1.0/libexec/phpunit-5.1.0.phar:0
PHP   2. PHPUnit_TextUI_Command::main() /usr/local/Cellar/phpunit/5.1.0/libexec/phpunit-5.1.0.phar:514
PHP   3. PHPUnit_TextUI_Command->run() phar:///usr/local/Cellar/phpunit/5.1.0/libexec/phpunit-5.1.0.phar/phpunit/TextUI/Command.php:106
PHP   4. PHPUnit_TextUI_TestRunner->doRun() phar:///usr/local/Cellar/phpunit/5.1.0/libexec/phpunit-5.1.0.phar/phpunit/TextUI/Command.php:155
PHP   5. PHPUnit_TextUI_TestRunner->handleConfiguration() phar:///usr/local/Cellar/phpunit/5.1.0/libexec/phpunit-5.1.0.phar/phpunit/TextUI/TestRunner.php:153
PHP   6. require_once() phar:///usr/local/Cellar/phpunit/5.1.0/libexec/phpunit-5.1.0.phar/phpunit/TextUI/TestRunner.php:805
```
2015-12-10 09:22:41 +01:00
Arthur Schiwon 81d763be42 use expectedException annotation, not via method call, for consistency 2015-12-09 16:55:07 +01:00
Arthur Schiwon fdd06ba1f8 use getLastInsertId from query builder for convenience 2015-12-09 16:33:34 +01:00
Robin Appelman e191953942 Remove all locks after ttl from the db 2015-12-09 14:53:24 +01:00
Arthur Schiwon 8e298f51f8 adjust test's fakemanager to interface change 2015-12-09 14:38:01 +01:00
Arthur Schiwon 0c1c029571 hardening, add some checks for whitespace-only strings 2015-12-09 14:34:23 +01:00
Arthur Schiwon 8acbb7aef9 rework test about overwriting default comments manager 2015-12-09 14:34:23 +01:00
Arthur Schiwon d3692c3283 namespaces for tests 2015-12-09 14:34:23 +01:00
Arthur Schiwon 9a440c06b0 OC not oc 2015-12-09 14:34:23 +01:00
Arthur Schiwon e3dbc3d40c different strategy in cleaning up after user was deleted
we do not listen to deletion hooks anymore, because there is no guarantee that they
will be heard - requires that something fetches the CommentsManager first.

Instead, in the user deletion routine the clean up method will be called directly. Same way
as it happens for files, group memberships, config values.
2015-12-09 14:34:23 +01:00
Arthur Schiwon 2ce2de0ae5 add icommentsmanger and icomment implementation
register CommentsManager service, allow override, document in config.sample.php

don't insert autoincrement ids in tests, because of dislikes from oracle and pgsql

specify timezone in null date

only accepts strings for ID parameter that can be converted to int

replace forgotten hardcoded IDs in tests

react on deleted users

react on file deletion

Postgresql compatibility

lastInsertId needs *PREFIX* with the table name

do not listen for file deletion, because it is not reliable (trashbin, external storages)

add runtime cache for comments
2015-12-09 14:34:23 +01:00
Thomas Müller 7fb2f7f5fe Merge pull request #21068 from owncloud/fix-exit-code-autotest-external
Fix exit code autotest external
2015-12-09 13:02:25 +01:00
Thomas Müller bb02488cc2 remove deprecated strict setting 2015-12-09 12:10:12 +01:00
Thomas Müller 5c95939bf3 Merge pull request #21061 from owncloud/fix-oracle-last-insert-id-test
Fix the last insert id test by changing to an autoincremen…
2015-12-09 11:53:43 +01:00
Thomas Müller bc744ff6de Merge pull request #21038 from owncloud/share-computesharepermissions-notstore
Fix (re)share permission checks in a few code paths
2015-12-09 10:04:56 +01:00
Joas Schilling 5c0be3b565 Fix the last insert id test by changing to an autoincrement table 2015-12-09 09:51:33 +01:00
Vincent Petry 28e9bc1156 Fix more unit tests to pass a mock storage instead of null to FileInfo 2015-12-08 16:33:39 +01:00
Thomas Müller 45fe8271ab Merge pull request #21030 from owncloud/querybuilder-new-features
Querybuilder new features
2015-12-08 13:51:45 +01:00
Thomas Müller 85409b6701 Merge pull request #20786 from owncloud/systemtags-dav
DAV endpoint for system tags
2015-12-08 13:51:25 +01:00
Joas Schilling 9f98849306 Add a method to the get "to use" table and column name 2015-12-08 11:04:28 +01:00
Thomas Müller fe8dc0bd5e Merge pull request #21022 from owncloud/get-rid-of-by-reference
Get rid of by reference
2015-12-08 11:04:25 +01:00
Joas Schilling a3391248e4 Add select distinct to the query builder 2015-12-08 09:49:21 +01:00
Joas Schilling f2c7acb3c0 Allow getting the last insert id without much hassle 2015-12-08 09:40:20 +01:00
Lukas Reschke 6d3eb7673d Add unit test for nested arrays 2015-12-08 09:07:38 +01:00
Lukas Reschke 8289943a0f Do not trust casting 2015-12-08 08:50:00 +01:00
Lukas Reschke 0a89073c47 Run .htaccess updates in any case
This is the same what we also do in updater.php and thus this aligns the code. Makes the code paths more consistent.
2015-12-08 08:16:24 +01:00
Scrutinizer Auto-Fixer 453e1bf66e Scrutinizer Auto-Fixes
This commit consists of patches automatically generated for this project on https://scrutinizer-ci.com
2015-12-07 15:43:36 +00:00
Thomas Müller a9e5faf7d0 Merge pull request #20981 from owncloud/issue-19848-multiple-emails-for-sharelink
Allow sending a share email to multiple users
2015-12-07 15:17:19 +01:00
Joas Schilling 820c3b852d Add a unit test for single user case as well 2015-12-07 12:01:02 +01:00
Joas Schilling 5b87413792 Allow sending a share email to multiple users 2015-12-07 10:49:34 +01:00
Thomas Müller e44b164f40 Merge pull request #20569 from owncloud/issue_20427
Show external storage status in file list + prompt credentials if different
2015-12-07 10:27:35 +01:00
Thomas Müller 0c3d97921f Merge pull request #20904 from owncloud/view-mime-filter
Fix mimetype filter in getDirectoryContent
2015-12-07 10:20:43 +01:00
Vincent Petry 316b907a13 Fixed system tags DAV and API and docs 2015-12-04 17:30:50 +01:00
Roeland Jago Douma a619629ac0 Only try to load avatars in the user list if there is any 2015-12-04 14:56:49 +01:00
Thomas Müller 602b636d3e Merge pull request #20807 from owncloud/dont-append-redirect-url-if-user-is-already-logged-in
Don't append redirect URL if user is logged-in
2015-12-03 16:53:59 +01:00
Thomas Müller 0fe5506e91 Merge pull request #20921 from owncloud/last-OC_Config-removals-in-tests
Reduce OC_Config usage in tests/
2015-12-03 15:24:41 +01:00
Morris Jobke cbe6eeffa1 last change of OC_Config to the proper interface in tests/ 2015-12-03 14:03:05 +01:00
Thomas Müller 2d1cc8aaeb Merge pull request #19461 from owncloud/reuse_code
reuse code
2015-12-03 13:55:50 +01:00
Morris Jobke 542ce7dd0d Reduce OC_Config usage in tests/ 2015-12-03 13:48:19 +01:00
Robin Appelman 19b2fe6a3a Fix mimetype filter in getDirectoryContent 2015-12-03 13:09:13 +01:00
Jesus Macias Portela dcfbbe4737 Merge branch 'master' into issue_20427 2015-12-03 12:35:49 +01:00
Morris Jobke e9c8f82fc5 Replace OC_Config in tests with IConfig calls 2015-12-03 09:38:41 +01:00