Commit 4a7154b9 authored by Jérome Perrin's avatar Jérome Perrin

slapproxy: Add a no-op computerBang method for compatibility with recent slapos

parent eb11cca3
...@@ -732,6 +732,10 @@ def softwareInstanceRename(): ...@@ -732,6 +732,10 @@ def softwareInstanceRename():
def getComputerPartitionStatus(): def getComputerPartitionStatus():
return xml_marshaller.xml_marshaller.dumps('Not implemented.') return xml_marshaller.xml_marshaller.dumps('Not implemented.')
@app.route('/computerBang', methods=['POST'])
def computerBang():
return xml_marshaller.xml_marshaller.dumps('')
@app.route('/getComputerPartitionCertificate', methods=['GET']) @app.route('/getComputerPartitionCertificate', methods=['GET'])
def getComputerPartitionCertificate(): def getComputerPartitionCertificate():
# proxy does not use partition certificate, but client calls this. # proxy does not use partition certificate, but client calls this.
......
...@@ -271,6 +271,14 @@ class TestInformation(BasicMixin, unittest.TestCase): ...@@ -271,6 +271,14 @@ class TestInformation(BasicMixin, unittest.TestCase):
response = xml_marshaller.xml_marshaller.loads(rv.data) response = xml_marshaller.xml_marshaller.loads(rv.data)
self.assertEquals({'certificate': '', 'key': ''}, response) self.assertEquals({'certificate': '', 'key': ''}, response)
def test_computerBang(self):
"""
Tests that computerBang method is implemented in slapproxy.
"""
rv = self.app.post( '/computerBang?computer_id=%s' % ( self.computer_id))
response = xml_marshaller.xml_marshaller.loads(rv.data)
self.assertEquals('', response)
class MasterMixin(BasicMixin, unittest.TestCase): class MasterMixin(BasicMixin, unittest.TestCase):
""" """
Define advanced tool for test proxy simulating behavior slap library tools Define advanced tool for test proxy simulating behavior slap library tools
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment