Skip to content

Commit

Permalink
Merge pull request #67 from MichaelMcAleer/header-fix
Browse files Browse the repository at this point in the history
Header Typo
  • Loading branch information
rawstorage authored Oct 22, 2019
2 parents aa3dad6 + 67d84e9 commit 3a5f2dd
Show file tree
Hide file tree
Showing 5 changed files with 13 additions and 4 deletions.
2 changes: 1 addition & 1 deletion PyU4V/__init__.py
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@

from .univmax_conn import U4VConn # noqa: F401
__title__ = 'pyu4v'
__version__ = '3.1.4'
__version__ = '3.1.5'
__author__ = 'Dell EMC or its subsidiaries'
__license__ = 'MIT'
__copyright__ = 'Copyright 2019 Dell EMC Inc'
2 changes: 1 addition & 1 deletion PyU4V/rest_requests.py
Original file line number Diff line number Diff line change
Expand Up @@ -48,7 +48,7 @@ def __init__(self, username, password, verify, base_url,
self.base_url = base_url
self.headers = {'content-type': 'application/json',
'accept': 'application/json',
'application_type': application_type}
'application-type': application_type}
self.timeout = 120
self.session = self.establish_rest_session()

Expand Down
2 changes: 1 addition & 1 deletion README.rst
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,7 @@ eg: https://10.0.0.1:8443/univmax/restapi/docs.

VERSION 3

Please note that version '3.1.4' of the library is NOT BACKWARDS
Please note that version '3.1.5' of the library is NOT BACKWARDS
COMPATIBLE with scripts written with version 2.x of PyU4V, and does not
support any Unisphere for VMAX version earlier than 8.4 - PyU4V version 2.0.2.6 is
still available on Pip, and there is a 'stable/2.0' branch available on Github.
Expand Down
2 changes: 1 addition & 1 deletion setup.py
Original file line number Diff line number Diff line change
Expand Up @@ -23,7 +23,7 @@
from setuptools import setup

setup(name='PyU4V',
version='3.1.4',
version='3.1.5',
url='https://github.com/MichaelMcAleer/PyU4V/',
author='Dell Inc. or its subsidiaries',
author_email='Michael.Mcaleer@dell.com',
Expand Down
9 changes: 9 additions & 0 deletions tests/test_pyu4v.py
Original file line number Diff line number Diff line change
Expand Up @@ -501,6 +501,15 @@ def _get_request(self, url, params):

return status_code, return_object

def _establish_rest_session(self):
ref_headers = {'content-type': 'application/json',
'accept': 'application/json',
'application-type': 'pyu4v'}
self.assertEqual(ref_headers, self.rest.session.headers)
self.assertEqual('smc', self.rest.session.auth.username)
self.assertEqual('smc', self.rest.session.auth.password)
self.assertEqual(False, self.rest.session.verify)

def _sloprovisioning_volume(self, url, params):
return_object = self.data.volume_list[2]
if params:
Expand Down

0 comments on commit 3a5f2dd

Please sign in to comment.