2
0
mirror of https://github.com/xcat2/xcat-core.git synced 2025-05-30 09:36:41 +00:00

fix:line 6: user: command not found. add: arguments

This commit is contained in:
baiyuan 2014-02-24 04:14:18 -05:00
parent b77b8e7c7d
commit 86e663860d

View File

@ -1,11 +1,13 @@
#!/bin/bash
# IBM(c) 2014 EPL license http://www.eclipse.org/legal/epl-v10.html
# Test driver for xcatws.cgi
# Test driver for xcatws.cgi, pass two arguments to it, user and password.
# Usage example: ./xcatws-test.sh wsuer cluster
user = ''
pw = ''
format = 'format=json&pretty=1'
user=$1
pw=$2
format='format=json&pretty=1'
#todo: add a test case for every api call that is documented
#todo: figure out why i currently have to specify -k
@ -27,4 +29,4 @@ curl -X GET -k "https://127.0.0.1/xcatws/images/bp-netboot?userName=$user&passwo
#todo: remove when these test cases are in xcatws-test.pl
./xcatws-test.pl -u "https://127.0.0.1/xcatws/nodes/test001?userName=$user&password=$pw" -m GET
./xcatws-test.pl -u "https://127.0.0.1/xcatws/nodes/test001?userName=$user&password=$pw" -m PUT "nodepos.room=foo"
./xcatws-test.pl -u "https://127.0.0.1/xcatws/nodes/test001?userName=$user&password=$pw" -m PUT "nodepos.room=foo"