Chromium Code Reviews| Index: tests/run_cgpt_tests.sh |
| diff --git a/tests/run_cgpt_tests.sh b/tests/run_cgpt_tests.sh |
| index b70af2f3046f5db705ccbf16ee062640170b836a..9171a8699d55e95a4560b861a6403f7647e65a6e 100755 |
| --- a/tests/run_cgpt_tests.sh |
| +++ b/tests/run_cgpt_tests.sh |
| @@ -9,16 +9,19 @@ |
| # Load common constants and variables. |
| . "$(dirname "$0")/common.sh" |
| -GPT=$1 |
| +GPT=$(readlink -f "$1") |
| [ -x "$GPT" ] || error "Can't execute $GPT" |
| -warning "testing $GPT" |
| + |
| +# Run tests in a dedicated directory for easy cleanup or debugging. |
| +DIR="${TEST_DIR}/cgpt_test_dir" |
| +[ -d "$DIR" ] || mkdir -p "$DIR" |
| +warning "testing $GPT in $DIR" |
| +cd "$DIR" |
| echo "Create an empty file to use as the device..." |
| NUM_SECTORS=1000 |
| -DEV=$(mktemp) |
| -BOOTFILE=$(mktemp) |
| +DEV=fake_dev.bin |
| dd if=/dev/zero of=${DEV} conv=notrunc bs=512 count=${NUM_SECTORS} 2>/dev/null |
| -trap "rm -f ${DEV}" EXIT |
|
vb
2010/08/19 23:15:35
so who's be cleaning up this stuff now?
Randall Spangler
2010/08/19 23:30:40
(Are you leaving it around so you can run the test
Bill Richardson
2010/08/19 23:59:34
Nobody's cleaning it up. The new directory sits in
|
| echo "Create a bunch of partitions, using the real GUID types..." |