Tests for NetApp volume driver
-
class FakeDfmServerHandler(request, client_address, server)
Bases: BaseHTTPServer.BaseHTTPRequestHandler
HTTP handler that fakes enough stuff to allow the driver to run
-
do_GET(s)
Respond to a GET request.
-
do_POST(s)
Respond to a POST request.
-
class FakeHTTPConnection(host, timeout=None)
Bases: object
A fake httplib.HTTPConnection for netapp tests
Requests made via this connection actually get translated and routed into
the fake Dfm handler above, we then turn the response into
the httplib.HTTPResponse that the caller expects.
-
getresponse()
-
getresponsebody()
-
request(method, path, data=None, headers=None)
-
set_debuglevel(level)
-
class FakeHttplibSocket(value)
Bases: object
A fake socket implementation for httplib.HTTPResponse
-
makefile(mode, _other)
Returns the socket’s internal buffer
-
class NetAppDriverTestCase(methodName='runTest')
Bases: nova.test.TestCase
Test case for NetAppISCSIDriver
-
INITIATOR = 'iqn.1993-08.org.debian:01:23456789'
-
PROJECT_ID = 'testproj'
-
STORAGE_SERVICE = 'Openstack Service'
-
STORAGE_SERVICE_PREFIX = 'Openstack Service-'
-
VOLUME_NAME = 'volume-00000001'
-
VOLUME_SIZE = 2147483648L
-
VOLUME_TYPE = ''
-
setUp()
-
test_connect()
-
test_create_destroy()
-
test_map_unmap()