diff options
author | DR695H <dr695h@att.com> | 2019-08-28 10:52:51 -0400 |
---|---|---|
committer | DR695H <dr695h@att.com> | 2019-08-28 11:21:56 -0400 |
commit | f2b75da8dd38077c60cc2c852f73092980c1f906 (patch) | |
tree | f58fc4de4f54eec45e10717fabcb62d7cbe64182 /robotframework-onap/ONAPLibrary/JSONPathKeywords.py | |
parent | 566c583bbfe0b5a4e46af7ac53765a1340d11fc0 (diff) |
fix linter errors and copyright
Change-Id: Idf7384307623c70a9f7714a5d276f404873c5974
Issue-ID: TEST-198
Signed-off-by: DR695H <dr695h@att.com>
Diffstat (limited to 'robotframework-onap/ONAPLibrary/JSONPathKeywords.py')
-rw-r--r-- | robotframework-onap/ONAPLibrary/JSONPathKeywords.py | 5 |
1 files changed, 3 insertions, 2 deletions
diff --git a/robotframework-onap/ONAPLibrary/JSONPathKeywords.py b/robotframework-onap/ONAPLibrary/JSONPathKeywords.py index 22e5e04..d5ed23a 100644 --- a/robotframework-onap/ONAPLibrary/JSONPathKeywords.py +++ b/robotframework-onap/ONAPLibrary/JSONPathKeywords.py @@ -11,8 +11,9 @@ # WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. # See the License for the specific language governing permissions and # limitations under the License. -import json +import json +from six import string_types from robot.api.deco import keyword from jsonpath_rw import parse @@ -30,7 +31,7 @@ class JSONPathKeywords(object): which is converted into string if needed and then compares them, returning the matches.""" jsonpath_expr = parse(expression) - if isinstance(target, str) or isinstance(target, unicode): + if isinstance(target, string_types): search_json = json.dumps(target) else: search_json = target |