| Age | Commit message (Collapse) | Author |
|
|
|
Fix lastModified time calculation for samba.
|
|
Had to fixup the symlink code in Sftp, most importantly add a PathUtils
relativeTo to fixup relative links.
|
|
There is no reason to use the Java version when there is the Kotlin version (for now).
|
|
Otherwise you get problems with one file system uses seconds and
another milliseconds and suddenly two files that are created at
the same time does not have the same timestamp.
Makes the test suite take 2 seconds longer to run but it is
what it is.
|
|
Handles the docker start and stop and all that. Useful for adding
more tests that use a sftp instance.
|
|
|
|
Will be easier to include in other projects then.
And it is where TreeAbstractTest is.
|
|
Single as in merge in one direction, a source and a target.
Split merge in to calculating (done by SingleMerge) which returns
a number of steps to do. Modifier then applies the steps.
Still thinking of pair or two-way merge, need a database for that
or you can never remove any files.
|
|
removeLast resolved to kotlin extension method on Android 34 and older.
On 35 it resolves to a new Java method, that is API 35 only.
|
|
|
|
Remove unused parameter names, extra colons, code that is never
executed and an opinionated detekt check.
|
|
Too many useful things are "Incubating"
|
|
If no fingerprint is stored -> save whatever the server gives
If a fingerprint is stored -> error if fingerprint does not match
|
|
Tests switch between password authentication and private key
authentication depending on the hash of the method name.
It's a fairly even spread.
Update the docker config, it never wanted a pem file, it wanted
a ssh-rsa format public key.
|
|
Let ssh2 derive the public key from the private key. Much easier.
|
|
|
|
|
|
|
|
It's implementation specific if path is relative or absolute but
it contains the link target. Especially useful for NoTarget.
|
|
Fix implementations to work as expected
(that createDirectory/File/Link fails if an entry with that name
already exists).
|
|
|
|
Add tests for them, and add basename, currently unused, for completeness
|
|
And fix errors in MUTF-8 conversion in jni.cpp
|
|
When robolectric loads multiple SDK versions it initialize
the NativeSamba class multiple times but loading libsamba.so
multiple times doesn't work. Avoid the problem by going back to
only testing one SDK level for samba.
|
|
Not been able to test the symlink code (as it is SMB1 only), instead
of having a lot of (possibly, most likely) broken code that might
be used by someone, remove it all.
|
|
Leftover from early test, there is a tree already.
|
|
|
|
|
|
sftp implementation using libssh2 and openssl
|
|
Reads the abomination that is SAF, or Androids best effort to make
files and directories completely and utterly unusable on Android.
The androidTest was (and is) a pain, only known to work on a
Pixel3 API 34 emulator but it showed a lot of things that the
fake content provider in the unit tests failed to show.
|
|
|
|
Will make it possible to use TreeAbstractTest in androidTest
as well as unittest
|
|
For some reason robolectric doesn't pick up the right min and max
sdk by itself so it was testing the wrong versions
|
|
|
|
|
|
Most the tests test the Tree implementation and thus should work
on all such implementations. Current exception is symlinks which
Samba backend doesn't (currently?) support.
Improve the Samba remove methods to better match the expected behavior.
|
|
|
|
Using polling (every 10s) as libsmb2 has no watch/event support.
(Unsure if SMB protocol has any support).
|
|
Two bugs:
* Didn't consider smb2_context max read/write size.
* total was not increased when max was hit
|
|
Remove unused imports and shorten lone lines
|
|
|
|
Don't fiddle around with temp files and such. This needs to be
handled on a higher level. Otherwise, how do you know if the temp
file should be replaced or not when close is called?
|
|
follow symlinks = no doesn't have intended effect
|
|
Remember that jni::GlobalRef can be used on multiple threads so
we can't store the env, need to call AttachCurrentThread.
Fix AttachCurrentThread (g_vm was forgotten).
More consistent move and copy constructors in refs. Removed env()
method as it would only be valid for Param and Local anyway.
|
|
Also no unix extensions (as that is SMB1).
|
|
Kotlin + truth is somewhat pedantic at times
|
|
Current user needs to be in docker group (or in some other way have
access to the docker.socket) for this to work.
Two current problems:
* listRoot() fails, no directories are found.
* gradle hangs after running the samba tests
|
|
|
|
Some backends have resources to free, such as the SambaTree.
|