This commit is contained in:
@@ -39,6 +39,12 @@ class ddOperApiTest(unittest.TestCase):
|
|||||||
self.assertTrue(len(locations.data) > 0)
|
self.assertTrue(len(locations.data) > 0)
|
||||||
self.assertEqual(type(locations.data[0]["properties"]["locationName"]), str)
|
self.assertEqual(type(locations.data[0]["properties"]["locationName"]), str)
|
||||||
|
|
||||||
|
def test_quantities(self):
|
||||||
|
quantities = self.client.quantities()
|
||||||
|
self.assertEqual(type(quantities), ddOperApi.ddOperQuantitie)
|
||||||
|
self.assertTrue(len(quantities.data) > 0)
|
||||||
|
self.assertEqual(type(quantities.data[0]), str)
|
||||||
|
|
||||||
def main():
|
def main():
|
||||||
unittest.main()
|
unittest.main()
|
||||||
|
|
||||||
|
@@ -107,7 +107,21 @@ def locations():
|
|||||||
"locationNameSpace": "TS.DDOPER",
|
"locationNameSpace": "TS.DDOPER",
|
||||||
"displayNameGlobal": "Test location 3"
|
"displayNameGlobal": "Test location 3"
|
||||||
}
|
}
|
||||||
}]}
|
}
|
||||||
|
],
|
||||||
|
"_comment": "MKK-DL: Location catalogue"
|
||||||
|
}
|
||||||
|
return(jsonReturn(ret))
|
||||||
|
|
||||||
|
@app.route("/dd-oper/2.0/quantities")
|
||||||
|
def quantities():
|
||||||
|
ret = { "provider": provider("QuantityListResponse"),
|
||||||
|
"results": [
|
||||||
|
"time",
|
||||||
|
"null"
|
||||||
|
],
|
||||||
|
"_comment": "MKK-DL: Quantities catalogue"
|
||||||
|
}
|
||||||
return(jsonReturn(ret))
|
return(jsonReturn(ret))
|
||||||
|
|
||||||
def forkTestServer():
|
def forkTestServer():
|
||||||
|
Reference in New Issue
Block a user