aboutsummaryrefslogtreecommitdiffstats
path: root/lib/common_test/test/ct_netconfc_SUITE_data/netconfc1_SUITE.erl
diff options
context:
space:
mode:
authorSiri Hansen <[email protected]>2014-09-22 16:45:58 +0200
committerSiri Hansen <[email protected]>2014-09-23 11:06:35 +0200
commit79e047a16854fb61232b8b7a6bb6396cdc730020 (patch)
treebf5155eee492c5e03b43c8b2007813de81e9a990 /lib/common_test/test/ct_netconfc_SUITE_data/netconfc1_SUITE.erl
parent71e5c61fb22919b51d96c2b4e5fe12a567e0a11a (diff)
downloadotp-79e047a16854fb61232b8b7a6bb6396cdc730020.tar.gz
otp-79e047a16854fb61232b8b7a6bb6396cdc730020.tar.bz2
otp-79e047a16854fb61232b8b7a6bb6396cdc730020.zip
[ct_netconfc] Add optional parameters to edit-config
Earlier there was no way to add optional parameters like default-operation to an edit-config request sent with ct_netconfc:edit_config/3,4, you had to use ct_netconfc:send_rpc/2,3. For simplicity and completion, a new optional argument, OptParams, is now added to the edit_config function.
Diffstat (limited to 'lib/common_test/test/ct_netconfc_SUITE_data/netconfc1_SUITE.erl')
-rw-r--r--lib/common_test/test/ct_netconfc_SUITE_data/netconfc1_SUITE.erl13
1 files changed, 13 insertions, 0 deletions
diff --git a/lib/common_test/test/ct_netconfc_SUITE_data/netconfc1_SUITE.erl b/lib/common_test/test/ct_netconfc_SUITE_data/netconfc1_SUITE.erl
index f2adeb9065..332e54d1a7 100644
--- a/lib/common_test/test/ct_netconfc_SUITE_data/netconfc1_SUITE.erl
+++ b/lib/common_test/test/ct_netconfc_SUITE_data/netconfc1_SUITE.erl
@@ -76,6 +76,7 @@ all() ->
get_config,
get_config_xpath,
edit_config,
+ edit_config_opt_params,
copy_config,
delete_config,
lock,
@@ -400,6 +401,18 @@ edit_config(Config) ->
?ok = ct_netconfc:close_session(Client),
ok.
+edit_config_opt_params(Config) ->
+ DataDir = ?config(data_dir,Config),
+ {ok,Client} = open_success(DataDir),
+ ?NS:expect_reply({'edit-config',{'default-operation',"none"}},ok),
+ ?ok = ct_netconfc:edit_config(Client,running,
+ {server,[{xmlns,"myns"}],
+ [{name,["myserver"]}]},
+ [{'default-operation',["none"]}]),
+ ?NS:expect_do_reply('close-session',close,ok),
+ ?ok = ct_netconfc:close_session(Client),
+ ok.
+
copy_config(Config) ->
DataDir = ?config(data_dir,Config),
{ok,Client} = open_success(DataDir),