Commit Graph

1073 Commits

Author SHA1 Message Date
Björn Schießle 050df76830 Merge pull request #8599 from owncloud/sharing_disable_for_groups
allow admin to disable sharing for specific groups of users
2014-05-22 08:19:27 -04:00
Bjoern Schiessle 12338e0ef0 allow admin to disable sharing for specific groups of users 2014-05-22 10:43:44 +02:00
Joas Schilling d621a6fe5e Clean the database after the test 2014-05-21 16:00:21 +02:00
Joas Schilling 66f94273c6 Add a lot of users for testing 2014-05-21 13:17:29 +02:00
Joas Schilling 457a4aa425 Add test case for getValueForUsers() 2014-05-21 11:36:01 +02:00
Morris Jobke dc36d30953 Remove all occurences of @brief and @returns from PHPDoc
* test case added to avoid adding them later
2014-05-19 17:50:53 +02:00
Morris Jobke 804020bb6d Merge pull request #7363 from owncloud/optimize-startup-queries
Optimize some queries that are always executed when loading base.php
2014-05-19 01:21:37 +02:00
Vincent Petry 9d38e3602b Namespacing for FileList, FileActions and trashbin app
- FileList is now an instantiable class
- FileActions is now in namespace
- added App class for trashbin app
- moved trashbin overrides into classes extending FileList
- replaced many static calls with "this." or "self." to make the classes
  reusable/extendable
- new URL parameter "view" to specify which view is shown, for example
  "files" or "trashbin"
- added OC.Util.History utility class in core for handling history
- moved URL handling/routing to OCA.Files.App
- popstate will correctly update the current view and notify the view of
  the URL change so it can update the current dir
- added JS unitt tests for the trashbin app
- fixed public app to work with the new namespaces
2014-05-15 17:51:04 +02:00
Bernhard Posselt 9e36c33104 use fetch method instead of fetchRow because fetchRow is only an owncloud internal alias that exists purely for compability 2014-05-14 01:09:48 +02:00
Thomas Müller 5fb94bf76f Merge pull request #8542 from owncloud/phpdoc-improvements
PHPDoc Improvements
2014-05-13 23:23:11 +02:00
Lukas Reschke b0381cfe12 Add tests for other types that PHP might cast
Addition to https://github.com/owncloud/core/pull/8572
2014-05-13 22:01:11 +02:00
Robin McCorkell 875a8acedf Fix Scrutinizer errors about missing user backend 2014-05-13 19:08:14 +01:00
Thomas Müller f5bc680f9c Merge pull request #8572 from owncloud/core-getabsolutepathwithzero
Fixed getAbsolutePath case when path is "0"
2014-05-13 17:41:18 +02:00
Vincent Petry bab8c1f8e5 Fixed getAbsolutePath case when path is "0"
Make sure to correctly check for string emptiness when the passed path
is "0".
2014-05-13 17:38:46 +02:00
Bernhard Posselt a152e320f6 make it possible to omit parameters and use the default parameters from the controller method 2014-05-13 10:40:49 +02:00
Thomas Müller 1d18fd4e6d Merge pull request #8482 from owncloud/public-logger
Make logger available in the container
2014-05-12 16:40:58 +02:00
Thomas Müller 93dbb39e77 adding unit test for message interpolation 2014-05-12 14:17:36 +02:00
Morris Jobke 2054837d01 Merge pull request #8541 from owncloud/hardenIsSubDirectory
Harden issubdirectory()
2014-05-12 01:42:25 +02:00
Morris Jobke 6499995474 Merge pull request #8477 from owncloud/better-controllers
Better appframework controllers
2014-05-12 01:07:49 +02:00
Morris Jobke 7a6ff56b13 Merge pull request #8274 from owncloud/appframework-db
Port database layer from appframework to core
2014-05-12 00:12:19 +02:00
Bernhard Posselt 63f2f16b85 use new controllermethodreflector for corsmiddleware 2014-05-11 17:55:59 +02:00
Bernhard Posselt 1d45239c65 adjust license headers to new mail address 2014-05-11 17:54:08 +02:00
Bernhard Posselt cb666c18d6 rename formatter to responder, formatResponse to buildResponse 2014-05-11 17:54:08 +02:00
Bernhard Posselt d8da79cab0 add test for not failing when adding more comments after type parameters, do not limit x-www-form-urlencoded to POST 2014-05-11 17:54:08 +02:00
Bernhard Posselt 80648da431 implement most of the basic stuff that was suggested in #8290 2014-05-11 17:54:08 +02:00
Bernhard Posselt a252f59cd4 Merge pull request #8504 from owncloud/cors-middleware
Add cors middleware
2014-05-11 16:54:34 +02:00
Lukas Reschke fd5b2d11d6 Rename issubdirectory to isSubDirectory 2014-05-11 15:50:59 +02:00
Bernhard Posselt 9a4d204b55 add cors middleware
remove methodannotationreader namespace

fix namespace for server container

fix tests

fail if with cors credentials header is set to true, implement a reusable preflighted cors method in the controller baseclass, make corsmiddleware private and register it for every request

remove uneeded  local in cors middleware registratio

dont uppercase cors to easily use it from routes

fix indention

comment fixes

explicitely set allow credentials header to false

dont depend on better controllers PR, fix that stuff later

split cors methods to be in a seperate controller for exposing apis

remove protected definitions from apicontroller since controller has it
2014-05-09 23:34:41 +02:00
Lukas Reschke 1083085e6e Merge pull request #7546 from owncloud/no_freaking_tag_dupes
Tags cleanup
2014-05-09 22:10:45 +02:00
Bart Visscher f569c721a6 Merge branch 'master' into optimize-startup-queries
Conflicts:
	apps/files_sharing/lib/sharedstorage.php
	tests/lib/group/manager.php

removed hasFilesSharedWith from lib/public/share.php and
sharedstorage.php to fix merge
2014-05-07 17:54:38 +02:00
Vincent Petry 75d81eefc1 Merge pull request #8223 from owncloud/fix_linkToPublic
Fix linkToPublic and linkToAbsolute.
2014-05-07 14:40:59 +02:00
Thomas Müller 45f8d2d3ff Merge pull request #8456 from owncloud/extstorage-unittestssuite
Added ext storage app in autotest unit test run
2014-05-05 19:48:35 +02:00
Vincent Petry 0c8ae6eb66 Added ext storage app in autotest unit test run
To make sure that the dynamic mount config and config classes from
external storages are tested, these are now added into the autotest.sh
test run by enabling the app.
2014-05-05 15:03:10 +02:00
Vincent Petry 1a454f61ed Merge pull request #8386 from owncloud/fix_6946_master
Fix 6946 master
2014-05-05 14:08:45 +02:00
Morris Jobke 623161b9a9 Merge pull request #8023 from flyser/master
Fix setting the max-upload-size for really large values.
2014-05-03 11:49:38 +02:00
Joas Schilling ced2a4fcf2 Remove unneccessary statement from test 2014-04-29 10:42:49 +02:00
Joas Schilling 39bf700790 Update tests to test for create and update aswell 2014-04-29 10:34:28 +02:00
Arthur Schiwon 837a02184b the group manager calls exists check less often, adjust test accordingly 2014-04-28 19:19:37 +02:00
Arthur Schiwon 45e42c25de Group Database backend must not gather user details itself but ask user
backends. This is a port to master from PR #7745

remove OC_GROUP_BACKEND_GET_DISPLAYNAME option for group backends

Conflicts:
	lib/private/group/backend.php

LDAP: getDisplayNamesInGroup is not an option for group backends anymore

Conflicts:
	apps/user_ldap/group_ldap.php
	apps/user_ldap/group_proxy.php

clean up group backends

Conflicts:
	lib/private/group/database.php

remove now unnecessary test

implement getDisplayNames in group manager

adjust user manager tests

test for group manager's displayNamesInGroup

trim must not be used in empty in PHP < 5.5

keep the constant to not provoke PHP warnings

Conflicts:
	lib/private/group/backend.php
2014-04-28 13:49:56 +02:00
Lukas Reschke 96c06c14d8 Merge pull request #8341 from owncloud/template-tests-output-buffering
Improve Template Tests by Removing Manual Output Buffering
2014-04-26 12:29:36 +02:00
Robin Appelman 4109521cce remove outdated test 2014-04-25 12:24:18 +02:00
Robin Appelman 6c20a014ea merge master into webdav-injection 2014-04-25 11:47:06 +02:00
Andreas Fischer 916b265cd5 Normalise testcleanuplistener.php indentation and end of file. 2014-04-24 16:42:28 +02:00
Andreas Fischer f45080e811 Use PHPUnit's expectOutputString() instead of performing output buffering. 2014-04-24 15:45:07 +02:00
Andreas Fischer 88778b569e Split testP() tests into multiple methods. 2014-04-24 15:36:02 +02:00
Andreas Fischer 0d3ddd9e11 Remove redundant test case for non-HTML string. 2014-04-24 15:34:09 +02:00
Andreas Fischer e85fe01faf Make PHPUnit_Framework_TestListener implementations compatible to 4.0. 2014-04-24 15:16:57 +02:00
Andreas Fischer f9091a8584 Merge pull request #8304 from owncloud/add-xss-tests
Add unit tests for arrays and quotationmark

* owncloud/add-xss-tests:
  Remove uneeded newline
  Fix indentation
  Add unit tests for arrays and "
2014-04-24 15:09:36 +02:00
Bjoern Schiessle 6650be9913 add setting to set default expire date 2014-04-24 13:34:31 +02:00
Bernhard Posselt 5199e4508a dont update entity and dont run an update query if an entity wasnt changed at all 2014-04-23 13:43:17 +02:00
Lukas Reschke 9d3b639ce6 Remove uneeded newline 2014-04-22 20:11:34 +02:00
Lukas Reschke 589c74e176 Fix indentation 2014-04-22 20:10:46 +02:00
Lukas Reschke f07180639c Add unit tests for arrays and "
OC_Util::sanitizeHTML() also supports array but we actually had no unit test for it. Additionally this commit introduces a test for escaping " into &quot;
2014-04-22 20:09:55 +02:00
Robin Appelman 3821a09689 merge master into webdav-injection 2014-04-22 12:25:49 +02:00
Bernhard Posselt 7e447f4f42 make download and redirectresponse public 2014-04-20 16:12:46 +02:00
Bernhard Posselt 309aa3bcd2 fix phpdoc for entities 2014-04-20 02:55:59 +02:00
Bernhard Posselt 4a7e0561ca move db into iservercontainer 2014-04-19 19:30:12 +02:00
Bernhard Posselt 0fe4db0992 remove unusued variable 2014-04-19 16:02:15 +02:00
Bernhard Posselt f4bc5ee863 remove unusued variable 2014-04-19 16:00:19 +02:00
Bernhard Posselt 93237d87ec fix scrutinizer issues 2014-04-19 15:25:36 +02:00
Bernhard Posselt f260951825 port database layer from appframework to core 2014-04-19 14:56:16 +02:00
Morris Jobke 5a1a056c6d Merge pull request #8183 from owncloud/move-security-headers
Move security headers
2014-04-16 23:46:20 +02:00
Thomas Tanghus df9d9ac958 Remove unused var 2014-04-16 14:34:13 +02:00
Thomas Tanghus dd36d4b894 Add tests for linkTo, linkToPublic, linkToRemote, linkToRemoteBase 2014-04-16 14:32:08 +02:00
Robin Appelman 295b75cca9 merge master into webdav-injection 2014-04-15 20:05:43 +02:00
Robin Appelman c82adb8c5d merge master into webdav-injection 2014-04-15 20:03:00 +02:00
Lukas Reschke ffab31e3ee Merge pull request #8197 from owncloud/secure_mimetypes
White-list known secure mime types. Refs. #8184
2014-04-15 19:50:33 +02:00
Arthur Schiwon 450de0091a adjust tests accordingly 2014-04-15 17:53:57 +02:00
Lukas Reschke 340089f270 Merge pull request #8059 from owncloud/countUsersInGroup
add optional countUsersInGroup method to group backends
2014-04-14 20:45:12 +02:00
Lukas Reschke 9046f7b2f8 Merge pull request #8178 from owncloud/fix-request-parameters
Correctly process request parameters other than GET or POST, dont use gl...
2014-04-14 20:42:26 +02:00
Thomas Tanghus 51e47319ef White-list known secure mime types. Refs. #8184 2014-04-14 17:17:50 +02:00
Thomas Müller 8df19c4379 Merge pull request #8019 from owncloud/thumbnail_fixes
Thumbnail fixes
2014-04-14 16:23:03 +02:00
Lukas Reschke b04d95b116 Remove uneeded usages of nosniff 2014-04-13 12:48:16 +02:00
Bernhard Posselt 62cce982bb default to GET request when no method is set to fix unittests, also set parsed json parameters on the post attribute 2014-04-12 16:17:49 +02:00
Vincent Petry e92fe47d2a Remove annoying karma 404 warnings for images
Karma now serves images from core to avoid polluting the logs with a lot
of 404 warnings.

This also makes it easier to read the test errors during development.
2014-04-11 15:25:40 +02:00
Thomas Müller 7325aefbd1 Merge pull request #8112 from owncloud/karma-enableautowatch
Enable autowatch for karma
2014-04-10 16:57:28 +02:00
Thomas Müller 26a89e369e Merge pull request #8137 from owncloud/routeing-requirements
add requirements to routing
2014-04-10 16:23:01 +02:00
Vincent Petry 6cc578d1a7 Merge pull request #8018 from owncloud/ocs_result_success_is_100
OC_OCS_Result Class, Only accept 100 code as success
2014-04-10 13:03:10 +02:00
Bernhard Posselt 70c88027db add requirements to routing 2014-04-09 21:57:32 +02:00
Thomas Müller 73ac3d0fcd Merge pull request #7643 from owncloud/chainable_response
Chainable Response in AppFramework
2014-04-08 22:42:43 +02:00
Vincent Petry bfb1e0867f Enable autowatch for karma
This way unit tests can be run in multiple browsers with the command
line and tests will re-run automatically when files are changed.
2014-04-08 17:21:11 +02:00
Thomas Müller a4fc92b05b class Test_Config is already declared 2014-04-08 14:15:33 +02:00
Arthur Schiwon 9597f41904 add group tests 2014-04-08 12:32:30 +02:00
Thomas Müller 240d1ae6b9 unit test testSetAppValueIfSetToNull() added 2014-04-07 20:56:43 +02:00
Fabian Henze 1245ff8f31 Add unit tests for OC_Helper::phpFileSize function 2014-04-07 15:31:34 +02:00
Thomas Müller ccf1287fbf adding unit test for cache mechanism 2014-04-04 16:21:50 +02:00
Thomas Müller f029312e5b fixing typos/spellings 2014-04-04 11:37:47 +02:00
Thomas Müller 20f26068e7 Merge pull request #7476 from owncloud/type-hinting
Type hinting
2014-04-03 20:02:27 +02:00
tomneedham b00592ade5 Fix test case for api response code 2014-04-03 14:47:55 +00:00
Thomas Müller a2efdb8722 Merge pull request #7970 from owncloud/webdav-upload-hash
Fix uploading files containing a # in the path for webdav
2014-04-03 16:09:44 +02:00
Vincent Petry 4cc70ec39d Merge pull request #7979 from owncloud/core-fixfilegetcontentsloop
Correctly read the full stream in file_get_contents
2014-04-02 10:55:50 +02:00
Thomas Müller 82d1ea240e Merge pull request #7884 from owncloud/use-idn_to_ascii-if-available
idn_to_ascii is only used if available
2014-04-01 22:51:23 +02:00
Vincent Petry d6ce45fe61 Correctly read the full stream in file_get_contents
When using user-defined stream wrappers, PHP will
return a maximum of 8192 bytes even if more was
requested.

This fix uses stream_get_contents to make sure the full stream is read
and not only the first 8 KB.

Added unit test with a bigger test file to cover this case.
2014-04-01 10:07:16 +02:00
Bart Visscher 6b061c236d Merge branch 'master' into type-hinting
Conflicts:
	lib/private/image.php
	lib/private/l10n.php
	lib/private/request.php
	lib/private/share/mailnotifications.php
	lib/private/template/base.php
2014-03-31 21:38:54 +02:00
Robin Appelman 76c63a5760 Fix uploading files containing a # in the path for webdav 2014-03-31 17:00:32 +02:00
Thomas Müller 70db348475 Merge pull request #7824 from owncloud/hash-parameter-order
Fix parameter order for Storage\Local::hash
2014-03-28 13:06:07 +01:00
Vincent Petry d0012e729a Merge pull request #7879 from owncloud/sharing_cleanup_public_api
sharing api cleanup, first step
2014-03-28 12:23:11 +01:00
Vincent Petry 5068c57845 Merge pull request #7613 from owncloud/fix_urlGenerator2
Add \OC::$WEBROOT to URLGenerator::getAbsoluteURL()
2014-03-28 12:12:49 +01:00
Vincent Petry 040f430f0c Merge pull request #7829 from owncloud/cachefolderlocation
Cache folder is now configurable
2014-03-28 12:08:38 +01:00
Vincent Petry ef2c176eef Merge pull request #7678 from owncloud/test-bootstrap-fileproxy-cleanup
Cleanup the fileproxy proxies on test bootstrap
2014-03-28 11:33:57 +01:00