1
0
mirror of git://sourceware.org/git/lvm2.git synced 2024-10-28 20:25:52 +03:00
Commit Graph

115 Commits

Author SHA1 Message Date
Dave Wysochanski
a831b4920f Update test/api/test.c for simple tests involving pv/vg/lv name/uuid attributes.
Tests the following APIs:
- lvm_{pv|vg|lv}_get_{name|uuid}()
- lvm_{lvs|pvs}_in_vg()

Example:
lvm> vg_open VolGroup00
Success opening vg VolGroup00
lvm> vg_list_lvs VolGroup00
LVs in VG VolGroup00:
VolGroup00/LogVol00 (bFO4EU-UaDu-iuMm-N6BA-xcZc-nm3u-J5K5lu)
VolGroup00/LogVol01 (BHGsPK-PwzY-kye0-MEWa-a67z-BiYE-03ZjwM)
lvm> vg_list_pvs VolGroup00
PVs in VG VolGroup00:
/dev/sda2 (Be91pt-CqT0-4YJE-nGI6-Oisz-hy0N-l9CHgn)

Signed-off-by: Dave Wysochanski <dwysocha@redhat.com>
Acked-by: Thomas Woerner <twoerner@redhat.com>
2009-07-23 23:40:50 +00:00
Dave Wysochanski
eefacdfa04 Add a couple lvm_vg_open() calls to vgtest.c. 2009-07-22 22:25:30 +00:00
Dave Wysochanski
3d52ff1a75 Update api/test/vgtest.c error handling.
Reverts some of my 'cleanup' from last night.  For now we will use pass/fail
on API calls (either 'int' return or NULL/non-NULL handle), then use
lvm_errno() to get more specific errors.


Author: Dave Wysochanski <dwysocha@redhat.com>
2009-07-22 16:49:54 +00:00
Dave Wysochanski
ba15f0316a Update test/api/vgtest.c to use lvm_errno and lvm_errmsg.
Author: Dave Wysochanski <dwysocha@redhat.com>
2009-07-22 03:13:57 +00:00
Dave Wysochanski
41a3c26f07 Fix build environment of test/api: Make it usable for more than one test case.
Author: Thomas Woerner <twoerner@redhat.com>
Committer: Dave Wysochanski <dwysocha@redhat.com>
2009-07-21 13:51:05 +00:00
Dave Wysochanski
3dcd5b3017 Rename test/api/vgcreate.c to vgtest.c to reduce filename conflicts in tree.
Signed-off-by: Thomas Woerner <twoerner@redhat.com>
Signed-off-by: Dave Wysochanski <dwysocha@redhat.com>
2009-07-21 10:46:45 +00:00
Dave Wysochanski
2d5ba1f2d1 Fix compile warnings in vgcreate liblvm api unit test case.
Use const and PRIu64.

Signed-off-by: Thomas Woerner <twoerner@redhat.com>
Signed-off-by: Dave Wysochanski <dwysocha@redhat.com>


Author: Thomas Woerner <twoerner@redhat.com>
Committer: Dave Wysochanski <dwysocha@redhat.com>
2009-07-21 10:41:47 +00:00
Dave Wysochanski
867ff24616 Add liblvm test case for creating of a vg.
liblvm unit test case uses the following APIs:
- lvm_create, lvm_destroy
- lvm_vg_create, lvm_vg_extend, lvm_vg_set_extent_size, lvm_vg_write,
lvm_vg_remove, lvm_vg_close

Signed-off-by: Dave Wysochanski <dwysocha@redhat.com>
Acked-by: Alasdair G Kergon <agk@redhat.com>
2009-07-14 03:08:56 +00:00
Alasdair Kergon
572fefeb90 Rename liblvm.so to liblvm2app.so and use configure --enable-applib. 2009-05-22 14:44:59 +00:00
Dave Wysochanski
4afec75e94 Use liblvm.so instead of .a 2009-04-28 19:08:25 +00:00
Dave Wysochanski
96bfa40b47 Add libdevmapper to test/api building. 2009-04-20 20:46:06 +00:00
Dave Wysochanski
4df86ce1ac Remove unnecessary linker flags for liblvm. 2009-03-08 17:29:26 +00:00
Dave Wysochanski
77986fa71a Add DSO generation for new LVM application library.
Fix test/api/test build.
2009-03-08 17:06:55 +00:00
Thomas Woerner
5f4b7a2644 Added files lib/lvm.h and lib/lvm_base.c:
New structure lvm (used as an alias to cmd_context), new type definition lvm_t
for the lvm handle. Added functions lvm_create, lvm_destroy and
lvm_reload_config using the new handle.

Modified test/api/test.c:
Use new lvm.h header file and lvm_t handle.

Removed lib/lvm2.h


Author: Thomas Woerner <twoerner@redhat.com>
2009-02-24 13:03:45 +00:00
Dave Wysochanski
c7e363f98a Add liblvm interactive test infrastructure to build. 2008-12-07 19:37:07 +00:00