5
0
mirror of git://git.proxmox.com/git/pxar.git synced 2024-12-22 21:33:50 +03:00
Commit Graph

14 Commits

Author SHA1 Message Date
Wolfgang Bumiller
71194b54e4 ditch anyhow crate in examples/tests
mostly to shutup our current buildbot tests

Signed-off-by: Wolfgang Bumiller <w.bumiller@proxmox.com>
2021-05-17 11:46:53 +02:00
Wolfgang Bumiller
180186c567 explicitly pad StatxTimestamp with zeros
otherwise we can have random data in there

Signed-off-by: Wolfgang Bumiller <w.bumiller@proxmox.com>
2021-03-12 10:34:55 +01:00
Wolfgang Bumiller
318462ea3d fix decode_entry on special files
When using the random accessor to access FIFOs or sockets,
the ranged reader limits the data to only that entry, and
the `decode_entry` will never see a `PAYLOAD` or
`GOODBYE_TABLE` item to finish the entry.
Instead, it'll reach EOF and we need to handle this.
The accessor now tells the decoder to expect EOF as a valid
condition for ending the entry.

Signed-off-by: Wolfgang Bumiller <w.bumiller@proxmox.com>
2020-12-15 11:34:15 +01:00
Wolfgang Bumiller
2ea8aff22d rename Entry to Stat, add Metadata::builder_from_stat
Signed-off-by: Wolfgang Bumiller <w.bumiller@proxmox.com>
2020-08-25 12:25:07 +02:00
Wolfgang Bumiller
3a7b42d0ef add entry v1 compatiblity test
Signed-off-by: Wolfgang Bumiller <w.bumiller@proxmox.com>
2020-07-29 07:39:58 +02:00
Wolfgang Bumiller
c81b2e4e21 add some random access tests with hardlinks
Signed-off-by: Wolfgang Bumiller <w.bumiller@proxmox.com>
2020-06-26 14:12:57 +02:00
Wolfgang Bumiller
807a4fd6ba tests: add some ACLs
Signed-off-by: Wolfgang Bumiller <w.bumiller@proxmox.com>
2020-06-26 13:05:22 +02:00
Wolfgang Bumiller
1feb04d7b8 tests: cleanup warnings
Signed-off-by: Wolfgang Bumiller <w.bumiller@proxmox.com>
2020-06-26 11:20:45 +02:00
Wolfgang Bumiller
650070b0e6 tests: add fifos and sockets
Signed-off-by: Wolfgang Bumiller <w.bumiller@proxmox.com>
2020-06-26 11:12:00 +02:00
Wolfgang Bumiller
bb74cbfa21 document test helpers a bit
Signed-off-by: Wolfgang Bumiller <w.bumiller@proxmox.com>
2020-06-26 10:08:45 +02:00
Wolfgang Bumiller
ea8ff6368b remove custom PartialEq impl
Hardlink targets are now compared, but only the parts we
also actually decode, not the chosen names in
`Entry.link_key`.

This way we can just `==` compare entries as long as the
files we use for hardlinking use their canonical path as
key.

Signed-off-by: Wolfgang Bumiller <w.bumiller@proxmox.com>
2020-06-26 09:57:35 +02:00
Wolfgang Bumiller
1829ef0dd0 some initial sequential encoder/decoder testing
Tests basic files, hardlinks, symlinks. No special metadata
yet.

Signed-off-by: Wolfgang Bumiller <w.bumiller@proxmox.com>
2020-06-26 09:54:00 +02:00
Wolfgang Bumiller
8fe6038295 formatting fixups
Signed-off-by: Wolfgang Bumiller <w.bumiller@proxmox.com>
2020-06-25 13:56:48 +02:00
Wolfgang Bumiller
139932923c start tests directory
Signed-off-by: Wolfgang Bumiller <w.bumiller@proxmox.com>
2020-06-25 13:51:22 +02:00