Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with
or
.
Download ZIP
Browse files

CBQE-1457: add tests for buckets using ports till 1023

Change-Id: I14a77c714d1c1f73f7f97bbf69d77c19d1cf44f8
Reviewed-on: http://review.couchbase.org/39078
Reviewed-by: Andrei Baranouski <andrei.baranouski@gmail.com>
Tested-by: buildbot <build@couchbase.com>
  • Loading branch information...
commit 3ffacd485fdbd535d0d27f8add634b010d5adda9 1 parent 7d51191
@IrynaMironava IrynaMironava authored
Showing with 15 additions and 2 deletions.
  1. +2 −1  conf/py-buckettests.conf
  2. +13 −1 pytests/buckettests.py
View
3  conf/py-buckettests.conf
@@ -25,4 +25,5 @@ buckettests.CreateBucketTests:
test_win_specific_names,default_bucket=False,bucket_name=AUX,bucket_type=standard
test_win_specific_names,default_bucket=False,bucket_name=COM1,bucket_type=standard
test_win_specific_names,default_bucket=False,bucket_name=LPT1,bucket_type=standard
- test_win_specific_names,default_bucket=False,bucket_name=PRN,bucket_type=standard
+ test_win_specific_names,default_bucket=False,bucket_name=PRN,bucket_type=standard
+ test_create_bucket_used_port,default_bucket=False
View
14 pytests/buckettests.py
@@ -50,13 +50,25 @@ def test_win_specific_names(self):
finally:
try:
self.log.info('Will check if ns_server is running')
- RestConnection(self.master)
+ rest = RestConnection(self.master)
self.assertTrue(RestHelper(rest).is_ns_server_running(timeout_in_seconds=60))
except:
self._reinstall(version)
self.fail("ns_server is not running after bucket '%s' creation" %(
self.bucket_name))
+ def test_create_bucket_used_port(self):
+ ports = [25, 68, 80, 135, 139, 143, 500]
+ for port in ports:
+ try:
+ self.cluster.create_standard_bucket(self.server, self.bucket_name + str(port), port, self.bucket_size, self.num_replicas)
+ except:
+ self.log.info('Error appears as expected')
+ rest = RestConnection(self.master)
+ self.assertTrue(RestHelper(rest).is_ns_server_running(timeout_in_seconds=60))
+ else:
+ raise Exception('User has to be unable to create a bucket using port %s' % port)
+
# Bucket creation with names as mentioned in MB-5844(isasl.pw, ns_log)
def test_valid_bucket_name(self, password='password'):
tasks = []
Please sign in to comment.
Something went wrong with that request. Please try again.