Alexander Neumann
24ec14738d
backend/test: Skip offset == length test
2017-05-28 12:33:47 +02:00
Alexander Neumann
79477fdfe4
backend/test: Randomize test suite
2017-05-28 12:33:47 +02:00
Pauline Middelink
f3d09ce7c8
Fix vet warnings
2017-05-17 01:34:33 +02:00
Alexander Neumann
be0e53c07b
tests: Add test for backend Save() from file
2017-05-14 19:55:32 +02:00
Alexander Neumann
66b4999765
tests: Remove code generation, use reflection
...
This simplifies the code.
2017-05-14 12:59:07 +02:00
Alexander Neumann
403e201e1a
tests: Improve robustness of config tests
2017-05-14 12:50:20 +02:00
Alexander Neumann
77a55fbe5c
tests: Add documentation
2017-05-14 11:48:30 +02:00
Alexander Neumann
77ebb95d3d
tests: Add BenchmarkLoadFile
2017-05-14 11:48:30 +02:00
Alexander Neumann
f142b1c22f
tests: Add benchmarks to test suite
2017-05-14 11:48:30 +02:00
Alexander Neumann
4ac0d3ad40
backend tests load: Use reader with Size() method
2017-05-13 19:56:11 +02:00
Alexander Neumann
a654f41ddb
Add docstring for package test
2017-05-12 21:19:32 +02:00
Alexander Neumann
fbf2462325
Rename backend test functions
2017-05-12 21:06:49 +02:00
Alexander Neumann
6f5fd72738
Implement test suite for backend tests
2017-05-12 21:03:55 +02:00
Alexander Neumann
63870d2830
Check error for Close()
2017-05-11 21:51:30 +02:00
Alexander Neumann
54e46f5984
Add MinimalData option for backend tests
2017-05-11 21:51:30 +02:00
Alexander Neumann
548d4eed95
Correct backend test for len = 0
2017-04-26 20:47:15 +02:00
Alexander Neumann
7b64b890d7
Simplify code
2017-04-14 00:00:02 +02:00
Alexander Neumann
698ba57597
backend/tests: Print error stacktrace if available
2017-04-10 22:42:33 +02:00
Alexander Neumann
6f76a6db66
rest: Make backend honor the REST protocol
2017-03-16 21:50:26 +01:00
Alexander Neumann
21b358c742
backend tests: Always close reader
2017-02-10 20:49:46 +01:00
Alexander Neumann
31f6093513
Fix tests
2017-01-27 12:47:34 +01:00
Alexander Neumann
b9bddeff39
Normalise the backend API
...
This makes the following changes, before:
type backend interface {
// Test a boolean value whether a File with the name and type exists.
Test(t FileType, name string) (bool, error)
// Remove removes a File with type t and name.
Remove(t FileType, name string) error
}
After:
type backend interface {
// Test a boolean value whether a File with the name and type exists.
Test(h Handle) (bool, error)
// Remove removes a File with type t and name.
Remove(h Handle) error
}
2017-01-26 22:02:22 +01:00
Alexander Neumann
925a3cfad7
backend: Check that backends do not close the reader
2017-01-25 17:12:03 +01:00
Alexander Neumann
03292d10cc
backend: Rename Get() -> Load()
2017-01-23 18:11:10 +01:00
Alexander Neumann
cfc9e8b2fa
backends: Remove Load()
2017-01-23 17:54:12 +01:00
Alexander Neumann
212936eb52
Make backend.LoadAll() similar to ioutil.ReadAll()
2017-01-23 17:54:12 +01:00
Alexander Neumann
05afedd950
Add backend.Get()
2017-01-23 17:54:11 +01:00
Alexander Neumann
9b48da5b4e
Change backend Save() function signature
2017-01-23 17:54:11 +01:00
Alexander Neumann
1dfd3b8aa3
Remove unused bits and pieces
...
Reported by https://github.com/dominikh/go-unused
2016-09-21 20:22:32 +02:00
Alexander Neumann
b628bcee27
Remove redundant ParseID
2016-09-04 14:38:18 +02:00
Alexander Neumann
bc42dbdf87
Create package restic/errors
2016-09-03 21:10:24 +02:00
Alexander Neumann
5e3a41dbd2
Rename struct member FileType -> Type
2016-09-03 21:10:24 +02:00
Alexander Neumann
4c95d2cfdc
wip
2016-09-03 21:10:24 +02:00
Alexander Neumann
cc6a8b6e15
wip
2016-09-03 21:10:24 +02:00
Alexander Neumann
b06845c545
Always use errors.Cause() for testing error values
2016-08-29 19:52:03 +02:00
Alexander Neumann
a60e3b5030
Make backend tests less verbose
2016-08-16 21:30:14 +02:00
Alexander Neumann
b350b443d0
Stop backend tests early on failure
2016-08-16 21:30:14 +02:00
Alexander Neumann
71924fb7c0
Add tests for Load() with negative offset
2016-08-16 21:30:14 +02:00
Alexander Neumann
ead6d11ecf
Backend tests: remove debug
2016-04-17 17:39:14 +02:00
Alexander Neumann
f7a10a9b9c
backend tests: Test accessing config
...
This commit adds real testing for accessing the config file with
different names.
2016-02-21 16:02:13 +01:00
Alexander Neumann
c0bd660a9e
Rename package
...
* github.com/restic/restic -> restic
2016-02-20 17:31:21 +01:00