Gentoo Websites Logo
Go to: Gentoo Home Documentation Forums Lists Bugs Planet Store Wiki Get Gentoo!
View | Details | Raw Unified | Return to bug 257714 | Differences between
and this patch

Collapse All | Expand All

(-)safecopy-1.3.nogentoo/test/test0/test.sh (-1 / +1 lines)
Lines 2-12 Link Here
2
2
3
basedir="$1";
3
basedir="$1";
4
tmpdir="$2";
4
tmpdir="$2";
5
5
6
safecopy="$basedir/src/safecopy";
6
safecopy="$basedir/src/safecopy";
7
safecopydebug="../libsafecopydebug/src/libsafecopydebuglb.so.1.0";
7
safecopydebug="../libsafecopydebug/src/libsafecopydebuglb.so.1.0: $LD_PRELOAD";
8
8
9
echo -n " - Testing test debug library functionality: ";
9
echo -n " - Testing test debug library functionality: ";
10
10
11
# test if the test libray gets loaded and works. the destination file must be cropped at 2048 byte
11
# test if the test libray gets loaded and works. the destination file must be cropped at 2048 byte
12
# since cat - unlike safecopy - can not read beyond IO errors.
12
# since cat - unlike safecopy - can not read beyond IO errors.
(-)safecopy-1.3.nogentoo/test/test1/test.sh (-1 / +1 lines)
Lines 2-12 Link Here
2
2
3
basedir="$1";
3
basedir="$1";
4
tmpdir="$2";
4
tmpdir="$2";
5
5
6
safecopy="$basedir/src/safecopy";
6
safecopy="$basedir/src/safecopy";
7
safecopydebug="../libsafecopydebug/src/libsafecopydebuglb.so.1.0";
7
safecopydebug="../libsafecopydebug/src/libsafecopydebuglb.so.1.0: $LD_PRELOAD";
8
8
9
echo -n " - Testing safecopy 1: Simple plain file copy: ";
9
echo -n " - Testing safecopy 1: Simple plain file copy: ";
10
10
11
# test without the deug library. safecopy must duplicate the file
11
# test without the deug library. safecopy must duplicate the file
12
# without errors
12
# without errors
(-)safecopy-1.3.nogentoo/test/test10/test.sh (-1 / +1 lines)
Lines 1-11 Link Here
1
#!/bin/sh
1
#!/bin/sh
2
basedir="$1";
2
basedir="$1";
3
tmpdir="$2";
3
tmpdir="$2";
4
4
5
safecopy="$basedir/src/safecopy";
5
safecopy="$basedir/src/safecopy";
6
safecopydebug="../libsafecopydebug/src/libsafecopydebuglb.so.1.0";
6
safecopydebug="../libsafecopydebug/src/libsafecopydebuglb.so.1.0: $LD_PRELOAD";
7
7
8
echo -n " - Testing safecopy 10: Incremental recovery with blocksize variation and exclude blocks ";
8
echo -n " - Testing safecopy 10: Incremental recovery with blocksize variation and exclude blocks ";
9
9
10
# main emphasis on this test is that no data from exclude blocks are ever read nor written.
10
# main emphasis on this test is that no data from exclude blocks are ever read nor written.
11
11
(-)safecopy-1.3.nogentoo/test/test11/test.sh (-1 / +1 lines)
Lines 1-11 Link Here
1
#!/bin/sh
1
#!/bin/sh
2
basedir="$1";
2
basedir="$1";
3
tmpdir="$2";
3
tmpdir="$2";
4
4
5
safecopy="$basedir/src/safecopy";
5
safecopy="$basedir/src/safecopy";
6
safecopydebug="../libsafecopydebug/src/libsafecopydebuglb.so.1.0";
6
safecopydebug="../libsafecopydebug/src/libsafecopydebuglb.so.1.0: $LD_PRELOAD";
7
7
8
echo -n " - Testing safecopy 11: Incremental recovery with startoffset, size limit and exclude list: ";
8
echo -n " - Testing safecopy 11: Incremental recovery with startoffset, size limit and exclude list: ";
9
9
10
# main emphasis on this test is that no data from exclude blocks are ever read nor written.
10
# main emphasis on this test is that no data from exclude blocks are ever read nor written.
11
11
(-)safecopy-1.3.nogentoo/test/test2/test.sh (-1 / +1 lines)
Lines 2-12 Link Here
2
2
3
basedir="$1";
3
basedir="$1";
4
tmpdir="$2";
4
tmpdir="$2";
5
5
6
safecopy="$basedir/src/safecopy";
6
safecopy="$basedir/src/safecopy";
7
safecopydebug="../libsafecopydebug/src/libsafecopydebuglb.so.1.0";
7
safecopydebug="../libsafecopydebug/src/libsafecopydebuglb.so.1.0: $LD_PRELOAD";
8
8
9
echo -n " - Testing safecopy 2: Soft recovery: ";
9
echo -n " - Testing safecopy 2: Soft recovery: ";
10
10
11
# safecopy - must succesfully read despite the first two read attempts of block 2 will fail
11
# safecopy - must succesfully read despite the first two read attempts of block 2 will fail
12
LD_PRELOAD="$safecopydebug" $safecopy -R 3 -b 1024 -f 4* -o "$tmpdir/test1.badblocks" debug "$tmpdir/test1.dat" >/dev/null 2>&1;
12
LD_PRELOAD="$safecopydebug" $safecopy -R 3 -b 1024 -f 4* -o "$tmpdir/test1.badblocks" debug "$tmpdir/test1.dat" >/dev/null 2>&1;
(-)safecopy-1.3.nogentoo/test/test3/test.sh (-1 / +1 lines)
Lines 2-12 Link Here
2
2
3
basedir="$1";
3
basedir="$1";
4
tmpdir="$2";
4
tmpdir="$2";
5
5
6
safecopy="$basedir/src/safecopy";
6
safecopy="$basedir/src/safecopy";
7
safecopydebug="../libsafecopydebug/src/libsafecopydebuglb.so.1.0";
7
safecopydebug="../libsafecopydebug/src/libsafecopydebuglb.so.1.0: $LD_PRELOAD";
8
8
9
echo -n " - Testing safecopy 3: Soft recovery + hard errors: ";
9
echo -n " - Testing safecopy 3: Soft recovery + hard errors: ";
10
10
11
# safecopy must succesfully recover from the soft error but write the hard error to the badblock list correctly
11
# safecopy must succesfully recover from the soft error but write the hard error to the badblock list correctly
12
LD_PRELOAD="$safecopydebug" $safecopy -R 3 -b 1024 -f 4* -o "$tmpdir/test1.badblocks" debug "$tmpdir/test1.dat" >/dev/null 2>&1;
12
LD_PRELOAD="$safecopydebug" $safecopy -R 3 -b 1024 -f 4* -o "$tmpdir/test1.badblocks" debug "$tmpdir/test1.dat" >/dev/null 2>&1;
(-)safecopy-1.3.nogentoo/test/test4/test.sh (-1 / +1 lines)
Lines 2-12 Link Here
2
2
3
basedir="$1";
3
basedir="$1";
4
tmpdir="$2";
4
tmpdir="$2";
5
5
6
safecopy="$basedir/src/safecopy";
6
safecopy="$basedir/src/safecopy";
7
safecopydebug="../libsafecopydebug/src/libsafecopydebuglb.so.1.0";
7
safecopydebug="../libsafecopydebug/src/libsafecopydebuglb.so.1.0: $LD_PRELOAD";
8
8
9
echo -n " - Testing safecopy 4: Unreadable end of file: ";
9
echo -n " - Testing safecopy 4: Unreadable end of file: ";
10
10
11
# safecopy writes a shortened output file since the last blocks are unreadable. The badblocks output must state these short read blocks
11
# safecopy writes a shortened output file since the last blocks are unreadable. The badblocks output must state these short read blocks
12
LD_PRELOAD="$safecopydebug" $safecopy -R 2 -b 1024 -f 4* -o "$tmpdir/test1.badblocks" debug "$tmpdir/test1.dat" >/dev/null 2>&1;
12
LD_PRELOAD="$safecopydebug" $safecopy -R 2 -b 1024 -f 4* -o "$tmpdir/test1.badblocks" debug "$tmpdir/test1.dat" >/dev/null 2>&1;
(-)safecopy-1.3.nogentoo/test/test5/test.sh (-1 / +1 lines)
Lines 2-12 Link Here
2
2
3
basedir="$1";
3
basedir="$1";
4
tmpdir="$2";
4
tmpdir="$2";
5
5
6
safecopy="$basedir/src/safecopy";
6
safecopy="$basedir/src/safecopy";
7
safecopydebug="../libsafecopydebug/src/libsafecopydebuglb.so.1.0";
7
safecopydebug="../libsafecopydebug/src/libsafecopydebuglb.so.1.0: $LD_PRELOAD";
8
8
9
echo -n " - Testing safecopy 5: Completely unreadable file: ";
9
echo -n " - Testing safecopy 5: Completely unreadable file: ";
10
10
11
# safecopy: unreadable file without marking. result must be an empty file and a complete block list
11
# safecopy: unreadable file without marking. result must be an empty file and a complete block list
12
LD_PRELOAD="$safecopydebug" $safecopy -R 2 -b 1024 -f 4* -o "$tmpdir/test1.badblocks" debug "$tmpdir/test1.dat" >/dev/null 2>&1;
12
LD_PRELOAD="$safecopydebug" $safecopy -R 2 -b 1024 -f 4* -o "$tmpdir/test1.badblocks" debug "$tmpdir/test1.dat" >/dev/null 2>&1;
(-)safecopy-1.3.nogentoo/test/test6/test.sh (-1 / +1 lines)
Lines 1-11 Link Here
1
#!/bin/sh
1
#!/bin/sh
2
basedir="$1";
2
basedir="$1";
3
tmpdir="$2";
3
tmpdir="$2";
4
4
5
safecopy="$basedir/src/safecopy";
5
safecopy="$basedir/src/safecopy";
6
safecopydebug="../libsafecopydebug/src/libsafecopydebuglb.so.1.0";
6
safecopydebug="../libsafecopydebug/src/libsafecopydebuglb.so.1.0: $LD_PRELOAD";
7
7
8
echo -n " - Testing safecopy 6: Incremental recovery: ";
8
echo -n " - Testing safecopy 6: Incremental recovery: ";
9
9
10
# safecopy regular run with badblocks output - produces some reference files
10
# safecopy regular run with badblocks output - produces some reference files
11
LD_PRELOAD="$safecopydebug" $safecopy -R 2 -b 1024 -f 4* -r 4* -o "$tmpdir/test1.badblocks" debug "$tmpdir/test1.dat" >/dev/null 2>&1;
11
LD_PRELOAD="$safecopydebug" $safecopy -R 2 -b 1024 -f 4* -r 4* -o "$tmpdir/test1.badblocks" debug "$tmpdir/test1.dat" >/dev/null 2>&1;
(-)safecopy-1.3.nogentoo/test/test7/test.sh (-1 / +1 lines)
Lines 1-11 Link Here
1
#!/bin/sh
1
#!/bin/sh
2
basedir="$1";
2
basedir="$1";
3
tmpdir="$2";
3
tmpdir="$2";
4
4
5
safecopy="$basedir/src/safecopy";
5
safecopy="$basedir/src/safecopy";
6
safecopydebug="../libsafecopydebug/src/libsafecopydebuglb.so.1.0";
6
safecopydebug="../libsafecopydebug/src/libsafecopydebuglb.so.1.0: $LD_PRELOAD";
7
7
8
echo -n " - Testing safecopy 7: Incremental recovery with blocksize variation ";
8
echo -n " - Testing safecopy 7: Incremental recovery with blocksize variation ";
9
9
10
# safecopy regular run with badblocks output - produces some reference files with and withouzt marked badblocks
10
# safecopy regular run with badblocks output - produces some reference files with and withouzt marked badblocks
11
LD_PRELOAD="$safecopydebug" $safecopy -R 2 -b 1150 -f 4* -r 4* -o "$tmpdir/test1.badblocks" debug "$tmpdir/test1.dat" >/dev/null 2>&1;
11
LD_PRELOAD="$safecopydebug" $safecopy -R 2 -b 1150 -f 4* -r 4* -o "$tmpdir/test1.badblocks" debug "$tmpdir/test1.dat" >/dev/null 2>&1;
(-)safecopy-1.3.nogentoo/test/test8/test.sh (-1 / +1 lines)
Lines 1-11 Link Here
1
#!/bin/sh
1
#!/bin/sh
2
basedir="$1";
2
basedir="$1";
3
tmpdir="$2";
3
tmpdir="$2";
4
4
5
safecopy="$basedir/src/safecopy";
5
safecopy="$basedir/src/safecopy";
6
safecopydebug="../libsafecopydebug/src/libsafecopydebuglb.so.1.0";
6
safecopydebug="../libsafecopydebug/src/libsafecopydebuglb.so.1.0: $LD_PRELOAD";
7
7
8
echo -n " - Testing safecopy 8: Incremental recovery with startoffset and size limit: ";
8
echo -n " - Testing safecopy 8: Incremental recovery with startoffset and size limit: ";
9
9
10
# safecopy regular run with badblocks output - produces some reference files
10
# safecopy regular run with badblocks output - produces some reference files
11
LD_PRELOAD="$safecopydebug" $safecopy -R 2 -b 1024 -f 4* -r 4* -o "$tmpdir/test1.badblocks" debug "$tmpdir/test1.dat" -s 2 -l 16 >/dev/null 2>&1;
11
LD_PRELOAD="$safecopydebug" $safecopy -R 2 -b 1024 -f 4* -r 4* -o "$tmpdir/test1.badblocks" debug "$tmpdir/test1.dat" -s 2 -l 16 >/dev/null 2>&1;
(-)safecopy-1.3.nogentoo/test/test9/test.sh (-1 / +1 lines)
Lines 1-11 Link Here
1
#!/bin/sh
1
#!/bin/sh
2
basedir="$1";
2
basedir="$1";
3
tmpdir="$2";
3
tmpdir="$2";
4
4
5
safecopy="$basedir/src/safecopy";
5
safecopy="$basedir/src/safecopy";
6
safecopydebug="../libsafecopydebug/src/libsafecopydebuglb.so.1.0";
6
safecopydebug="../libsafecopydebug/src/libsafecopydebuglb.so.1.0: $LD_PRELOAD";
7
7
8
echo -n " - Testing safecopy 9: Incremental recovery with exclude blocks: ";
8
echo -n " - Testing safecopy 9: Incremental recovery with exclude blocks: ";
9
9
10
# main emphasis on this test is that no data from exclude blocks are ever read nor written.
10
# main emphasis on this test is that no data from exclude blocks are ever read nor written.
11
11

Return to bug 257714