1clitest.couchbase_clitest.CouchbaseCliTest:
2    # Verify editing no settings succeeds
3    testSettingCluster,username=Administrator,password=password,expect-error=False
4    # Verify editing memory quota
5    testSettingCluster,username=Administrator,password=password,data-ramsize=274,expect-error=False
6    testSettingCluster,username=Administrator,password=password,index-ramsize=274,expect-error=False
7    testSettingCluster,username=Administrator,password=password,fts-ramsize=274,expect-error=False
8    testSettingCluster,username=Administrator,password=password,data-ramsize=274,index-ramsize=274,index-ramsize=274,expect-error=False
9    # Verify changing the cluster port
10    testSettingCluster,username=Administrator,password=password,port=5000,expect-error=False
11    # Verify changing the cluster username and password
12    testSettingCluster,username=Administrator,password=password,new-username=new_admin,new_password=new_pass,expect-error=False
13    testSettingCluster,username=Administrator,password=password,new-username=new_admin,expect-error=False
14    testSettingCluster,username=Administrator,password=password,new_password=new_pass,expect-error=False
15    # Verify with invalid memory quotas
16    testSettingCluster,username=Administrator,password=password,data-ramsize=27z4,expect-error=True,error-msg=argument --cluster-ramsize: invalid int value: '27z4'
17    testSettingCluster,username=Administrator,password=password,index-ramsize=27z4,expect-error=True,error-msg=argument --cluster-index-ramsize: invalid int value: '27z4'
18    testSettingCluster,username=Administrator,password=password,fts-ramsize=27z4,expect-error=True,error-msg=argument --cluster-fts-ramsize: invalid int value: '27z4'
19    # Verify that a password that is longer than 24 characters
20    testSettingCluster,username=Administrator,password=password,new-username=new_user,new-password=password_that_is_too_long,data-ramsize=256,expect-error=True,error-msg=Password length 25 exceeds maximum length of 24 characters
21    # Verify that changing the cluster name works
22    testSettingCluster,username=Administrator,password=password,name=mycluster,expect-error=False
23    testSettingCluster,username=Administrator,password=password,name=empty,expect-error=True,error-msg=argument --cluster-name: expected one argument
24    testSettingCluster,username=Administrator,password=password,name="my cluster",expect-error=False
25    # Verify that a password that is too short fails
26    testSettingCluster,username=Administrator,password=password,new-username=new_user,new-password=short,data-ramsize=256,expect-error=True,error-msg=The password must be at least 6 characters long.
27    # Verify that invalid username and password fail
28    testSettingCluster,username=myusername,password=mypassword,data-ramsize=256,expect-error=True,error-msg=unable to access the REST API - please check your username (-u) and password (-p)
29    # Verify that an invalid port fails
30    testSettingCluster,username=Administrator,password=password,port=99999,expect-error=True,error-msg=The port number must be greater than 1023 and less than 65536.
31    testSettingCluster,username=Administrator,password=password,port=100,expect-error=True,error-msg=The port number must be greater than 1023 and less than 65536.
32    testSettingCluster,username=Administrator,password=password,port=34z,expect-error=True,error-msg=argument --cluster-port: invalid int value: '34z'
33    # Verify that running against an uninitialized cluster fails
34    testSettingCluster,username=Administrator,password=password,data-ramsize=290,initialized=False,expect-error=True,error-msg=Cluster is not initialized, use cluster-init to initialize the cluster
35