Skip to content

Commit

Permalink
nbd/001: change to use lsblk raw output format
Browse files Browse the repository at this point in the history
lsblk -n ouput format changed due to the substantial changes
in libsmartcols, which lsblk relies on for generating output,
fix it by using the raw format

Fixes: #132

Signed-off-by: Yi Zhang <yi.zhang@redhat.com>
  • Loading branch information
yizhanglinux committed Feb 20, 2024
1 parent ac3d8d0 commit cc9ec39
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 4 deletions.
4 changes: 2 additions & 2 deletions tests/nbd/001
Original file line number Diff line number Diff line change
Expand Up @@ -19,12 +19,12 @@ test() {
_start_nbd_server
nbd-client -L -N export localhost /dev/nbd0 >> "$FULL" 2>&1
parted -s /dev/nbd0 print 2>> "$FULL" | grep 'Disk /dev/nbd0'
lsblk -n /dev/nbd0
lsblk --raw --noheadings /dev/nbd0

echo "Setting size to 1gib"
src/nbdsetsize /dev/nbd0 1073741824

lsblk -n /dev/nbd0
lsblk --raw --noheadings /dev/nbd0
parted -s /dev/nbd0 print 2>> "$FULL" | grep 'Disk /dev/nbd0'

nbd-client -d /dev/nbd0 >> "$FULL" 2>&1
Expand Down
4 changes: 2 additions & 2 deletions tests/nbd/001.out
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
Running nbd/001
Disk /dev/nbd0: 10.7GB
nbd0 43:0 0 10G 0 disk
nbd0 43:0 0 10G 0 disk
Setting size to 1gib
nbd0 43:0 0 1G 0 disk
nbd0 43:0 0 1G 0 disk
Disk /dev/nbd0: 1074MB

0 comments on commit cc9ec39

Please sign in to comment.