test/external_code: modify some remaining parts for switching to json

Change-Id: Ic79366a527e5aa23e4821ec88533b66e70eafde5
signed-off-by: wanghailiangx <hailiangx.e.wang@intel.com>
Reviewed-on: https://review.spdk.io/gerrit/c/spdk/spdk/+/4475
Tested-by: SPDK CI Jenkins <sys_sgci@intel.com>
Reviewed-by: Shuhei Matsumoto <shuhei.matsumoto.xt@hitachi.com>
Reviewed-by: Aleksey Marchuk <alexeymar@mellanox.com>
Reviewed-by: Changpeng Liu <changpeng.liu@intel.com>
This commit is contained in:
wanghailiangx 2020-09-30 10:41:11 -04:00 committed by Tomasz Zawadzki
parent 06b537bfdb
commit 83d6948ac7
4 changed files with 10 additions and 10 deletions

View File

@ -263,10 +263,10 @@ main(int argc, char **argv)
/*
* The user can provide the config file and bdev name at run time.
* For example, to use Malloc0 in file bdev.conf run with params
* ./hello_bdev -c bdev.conf -b Malloc0
* For example, to use Malloc0 in file bdev.json run with params
* ./hello_bdev --json bdev.json -b Malloc0
* To use passthru bdev PT0 run with params
* ./hello_bdev -c bdev.conf -b PT0
* ./hello_bdev --json bdev.json -b PT0
* If the bdev name is not specified,
* then Malloc0 is used by default
*/
@ -275,7 +275,7 @@ main(int argc, char **argv)
exit(rc);
}
if (opts.json_config_file == NULL) {
SPDK_ERRLOG("configfile must be specified using --json <conffile> e.g. -c bdev.conf\n");
SPDK_ERRLOG("configfile must be specified using --json <conffile> e.g. --json bdev.json\n");
exit(1);
}
hello_context.bdev_name = g_bdev_name;

View File

@ -21,25 +21,25 @@ export LD_LIBRARY_PATH=$LD_LIBRARY_PATH:$SPDK_LIB_DIR:$DPDK_LIB_DIR:"$test_root/
# The default target is to make both the app and bdev and link them against the combined SPDK shared library libspdk.so.
run_test "external_make_tc1" make -C $test_root hello_world_bdev_shared_combo
run_test "external_run_tc1" $test_root/hello_world/hello_bdev --json $test_root/hello_world/bdev_external.conf -b TestPT
run_test "external_run_tc1" $test_root/hello_world/hello_bdev --json $test_root/hello_world/bdev_external.json -b TestPT
make -C $test_root clean
# Make just the application linked against the combined SPDK shared library libspdk.so.
run_test "external_make_tc2" make -C $test_root hello_world_no_bdev_shared_combo
run_test "external_run_tc2" $test_root/hello_world/hello_bdev --json $test_root/hello_world/bdev.conf -b Malloc0
run_test "external_run_tc2" $test_root/hello_world/hello_bdev --json $test_root/hello_world/bdev.json -b Malloc0
make -C $test_root clean
# Make both the application and bdev against individual SPDK shared libraries.
run_test "external_make_tc3" make -C $test_root hello_world_bdev_shared_iso
run_test "external_run_tc3" $test_root/hello_world/hello_bdev --json $test_root/hello_world/bdev_external.conf -b TestPT
run_test "external_run_tc3" $test_root/hello_world/hello_bdev --json $test_root/hello_world/bdev_external.json -b TestPT
make -C $test_root clean
# Make just the application linked against individual SPDK shared libraries.
run_test "external_make_tc4" make -C $test_root hello_world_no_bdev_shared_iso
run_test "external_run_tc4" $test_root/hello_world/hello_bdev --json $test_root/hello_world/bdev.conf -b Malloc0
run_test "external_run_tc4" $test_root/hello_world/hello_bdev --json $test_root/hello_world/bdev.json -b Malloc0
make -C $test_root clean
@ -49,13 +49,13 @@ make -C $SPDK_DIR -j$(nproc)
# Make both the application and bdev against individual SPDK archives.
run_test "external_make_tc5" make -C $test_root hello_world_bdev_static
run_test "external_run_tc5" $test_root/hello_world/hello_bdev --json $test_root/hello_world/bdev_external.conf -b TestPT
run_test "external_run_tc5" $test_root/hello_world/hello_bdev --json $test_root/hello_world/bdev_external.json -b TestPT
make -C $test_root clean
# Make just the application linked against individual SPDK archives.
run_test "external_make_tc6" make -C $test_root hello_world_no_bdev_static
run_test "external_run_tc6" $test_root/hello_world/hello_bdev --json $test_root/hello_world/bdev.conf -b Malloc0
run_test "external_run_tc6" $test_root/hello_world/hello_bdev --json $test_root/hello_world/bdev.json -b Malloc0
make -C $test_root clean
make -C $SPDK_DIR -j$(nproc) clean