import robot
import time
import re
+import warnings
global _cache
def get(url, userId='admin', password='admin'):
"""Helps in making GET REST calls"""
-
+ warnings.warn(
+ "Use the Robot RequestsLibrary rather than this. See DatastoreCRUD.robot for examples",
+ DeprecationWarning
+ )
headers = {}
headers['Accept'] = 'application/xml'
def nonprintpost(url, userId, password, data):
"""Helps in making POST REST calls without outputs"""
+ warnings.warn(
+ "Use the Robot RequestsLibrary rather than this. See DatastoreCRUD.robot for examples",
+ DeprecationWarning
+ )
if userId is None:
userId = 'admin'
def post(url, userId, password, data):
"""Helps in making POST REST calls"""
+ warnings.warn(
+ "Use the Robot RequestsLibrary rather than this. See DatastoreCRUD.robot for examples",
+ DeprecationWarning
+ )
if userId is None:
userId = 'admin'
def delete(url, userId='admin', password='admin'):
"""Helps in making DELET REST calls"""
+ warnings.warn(
+ "Use the Robot RequestsLibrary rather than this. See DatastoreCRUD.robot for examples",
+ DeprecationWarning
+ )
print("delete all resources belonging to url"+url)
session = _cache.switch("CLUSTERING_DELETE")
resp = session.delete(url, auth=(userId, password)) # noqa