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
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
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
Robin Appelman
fffe330bbc
Fix parameter order for Storage\Local::hash
2014-03-20 15:32:12 +01:00
Vincent Petry
66bc0f0848
Still return quota value when free space is unknown
...
Fixed the quota storage wrapper to correctly return the quota value when
the free space is not known (which usually happens when the disk_free_space
function is disabled)
2014-03-19 19:07:11 +01:00
Vincent Petry
48d63a6278
Return unencrypted_size of folder when queried
...
This fixes the "used space" to be based on the unencrypted size, not
encrypted size, to be consistent with how quota/space is handled when
encryption is enabled
2014-03-07 14:59:09 +01:00
Thomas Müller
ec45a3c0e2
Merge pull request #6962 from owncloud/quota-space-root
...
Allow passing a root folder to get the used space from in the quota wrapper
2014-02-20 16:47:59 +01:00
Vincent Petry
b2b35cd335
Fixed ext storage webdav path encoding
...
- Some WebDAV servers like lighttpd need paths in URLs to be properly
encoded
- Added error log output when curl connection failed
- Added check for 'resourcetype' in case the WebDAV server doesn't
support/return it
- Fixed touch() to return false if the server doesn't implement
PROPPATCH
- Added optional delay in WebDAV unit tests to use when testing against
lighttpd's WebDAV
2014-02-19 18:34:08 +01:00
Scrutinizer Auto-Fixer
adaee6a5a1
Scrutinizer Auto-Fixes
...
This patch was automatically generated as part of the following inspection:
https://scrutinizer-ci.com/g/owncloud/core/inspections/cdfecc4e-a37e-4233-8025-f0d7252a8720
Enabled analysis tools:
- PHP Analyzer
- JSHint
- PHP Copy/Paste Detector
- PHP PDepend
2014-02-19 09:31:54 +01:00
Robin Appelman
3afdcd85e7
Add unit test for quote wrapper size root
2014-02-04 16:05:12 +01:00
Vincent Petry
1af7dab535
Fixed quota wrapper to not wrap failed fopen streams
...
When calling fopen() on some storage types, these return false instead
of throwing an exception.
This fix makes sure that in case the stream wasn't opened (for example
when a file doesn't exist any more) the stream isn't wrapped.
Also added 'rb' as another case that doesn't need to be wrapped.
Fixes #6832
2014-01-19 18:51:36 +01:00
Vincent Petry
6cf9844e9c
Added unit test for the test() method
...
This is to make sure that method isn't broken
2013-12-03 14:35:53 +01:00
Vincent Petry
d69243ee51
Fixed FTP and SMB to use rmdir() when deleting folders
...
Some storages need to use different calls for deleting files or folders,
usually unlink() and rmdir().
Fixes #4532 (SMB dir deletion)
Fixes #5941 (FTP dir deletion)
Note that the extra is_dir() should be fast because it's read from the
stat cache.
2013-11-29 13:01:01 +01:00
Vincent Petry
2653d914d9
Merge pull request #6008 from owncloud/extstorage-smb-webdav-renamefix
...
Fixed SMB rename function to overwrite target file
2013-11-26 06:42:36 -08:00
Vincent Petry
712b47757a
Updated unit tests for SMB
...
- coverage for touch return value
- fixed directory provider to exclude unsupported cases
2013-11-26 12:53:03 +01:00
Vincent Petry
c3e34676ba
Improved unit test for "overwrite on move"
...
Now using a different content to make sure the file was overwritten.
2013-11-25 18:54:58 +01:00
Vincent Petry
af7118aa5d
Added unit test for "overwrite file on rename/move"
...
Also fixed "rename" unit test that was ready the result out of the wrong
file.
2013-11-25 18:52:14 +01:00
Vincent Petry
5b6d1d79d0
Fixed SMB file deletion success detection
...
Since unlink() smb4php doesn't return true on deletion success, we need
to check whether the file was deleted to confirm success.
Fixes #5866
2013-11-19 15:05:11 +01:00
Vincent Petry
34c92f6656
Now using HomeStorage for legacy home storage ids
...
Legacy home storage ids with the format "local://path/to/datadir/user1"
are now also wrapped by the HomeStorage.
2013-11-12 18:01:02 +01:00
Thomas Müller
d25c8b43e6
Merge pull request #5652 from owncloud/front-port-5647-master
...
[WIP] extend unit test to directories starting or ending in whitespace
2013-11-01 23:11:33 -07:00
Jörn Friedrich Dreyer
10b2d649af
extend unit test to directories starting or ending in whitespace
2013-10-31 14:24:43 +01:00
Robin Appelman
f1e6e80eb1
add specialized storage backend for home folders
2013-10-29 00:14:23 +01:00
Vincent Petry
c8df27de73
Fixed quota stream to not wrap read-only fopen calls
2013-10-25 12:33:16 +02:00
Robin Appelman
d8c71ba734
merge master in storage-wrapper-quota
2013-08-18 11:34:56 +02:00
Robin Appelman
cd8f0c21ce
add quota storage wrapper
2013-07-25 00:31:51 +02:00
Robin Appelman
a853968f7d
move storage wrapper test to new namespace
2013-07-25 00:31:51 +02:00
Thomas Müller
c517c845f6
Merge branch 'master' into storage-test-cleanup
...
Conflicts:
tests/lib/files/storage/storage.php
2013-07-24 01:01:36 +02:00
Robin Appelman
cfac7fcd53
Storage: remove some unneeded strict tests of mtime behaviour
2013-07-16 23:07:35 +02:00
Robin Appelman
97f0bc1c4a
Storage: remove tests for search
2013-07-16 23:05:23 +02:00
Christian Berendt
8c9e6db1b1
increasing allowed time difference
2013-07-08 15:03:55 +02:00
Christian Berendt
92e7392852
revoking additional tests
2013-07-04 09:01:36 +02:00
Christian Berendt
37254744b5
remove tests from the wrong test method
2013-07-03 18:41:14 +02:00
Christian Berendt
818e2a364a
test moving and copying of subdirectories
2013-07-03 18:38:34 +02:00
Christian Berendt
407753f594
move new tests into the correct test method
2013-07-03 18:34:33 +02:00
Christian Berendt
0a5e18335e
test working with files in subdirectories
2013-07-03 18:23:09 +02:00
Christian Berendt
e556b7ab55
test working with subdirectories
2013-07-03 18:16:50 +02:00
Christian Berendt
81acfc9498
test copying and moving files in subdirectories
2013-07-03 18:11:54 +02:00
Christian Berendt
21601fd784
increasing difference for modifcation time tests
...
one second is sometimes not enough when using a slow storage connection,
three seconds is working better (at least when testing against S3)
2013-07-03 18:08:19 +02:00
Thomas Müller
8beec2015a
Merge pull request #3763 from owncloud/recursive-rmdir
...
Make rmdir recursive for local storage
2013-06-30 09:16:32 -07:00
Robin Appelman
a7c70915d5
fix storage wrapper namespaces
2013-06-28 18:18:12 +02:00
Robin Appelman
63c898c064
Make rmdir recursive for local storage
2013-06-17 17:34:09 +02:00
Robin Appelman
ba9db19640
Add wrapper storage backend
2013-05-08 16:53:05 +02:00
Robin Appelman
258ad38fd3
Fix touch for creating new files
2013-04-10 13:48:24 +02:00
Thomas Mueller
a05820c659
fixing various filesystem/storage unit tests on windows
...
fixing copy operation on mapper
2013-03-12 15:30:10 +01:00
Thomas Mueller
191da024fa
new test cases added to search in sub folders
2013-02-15 17:40:52 +01:00
Thomas Mueller
c0f3d8578a
folder should be created :-(
2013-02-15 17:40:07 +01:00
Thomas Mueller
e3ba0c3082
adding a new test class for mapped local using a dot in the datadir - reflects the issue described in #1659
2013-02-15 14:46:09 +01:00
Thomas Müller
8174e5faf1
make MappedLocal available and testable within Linux as well
2013-02-09 19:03:03 +01:00
Thomas Mueller
fd8cb9974b
initial version of a local storage implementation which will use unique slugified filename on the local filesystem.
...
This implementation will only be enabled on windows based system to solve the issues around UTF-8 file names with php on windows.
2013-02-06 23:41:52 +01:00
Thomas Mueller
997259df4b
reuse \OC_Helper::tmpFolder()
2013-02-04 14:11:51 +01:00
Robin Appelman
930b9b9cd0
merge master into filesystem
2013-01-26 18:49:45 +01:00
Robin Appelman
5445b94416
merge master into filesystem
2013-01-16 19:04:50 +01:00
Robin Appelman
fb2d2bc201
merge master into filesystem
2012-10-11 22:54:39 +02:00
Robin Appelman
e7899e17de
merge phpunit into filesystem
2012-10-08 13:53:53 +02:00
Robin Appelman
96b798a59f
move storage backend test cases to their own namespace
2012-09-22 14:51:15 +02:00