forked from openlp/openlp
Rename API and fix tests
This commit is contained in:
parent
6ea2025888
commit
2ddcbe63bb
@ -31,9 +31,9 @@ controller_views = Blueprint('controller', __name__)
|
||||
log = logging.getLogger(__name__)
|
||||
|
||||
|
||||
@controller_views.route('/live-item')
|
||||
def controller_text_api():
|
||||
log.debug('controller-v2-live-item')
|
||||
@controller_views.route('/live-items')
|
||||
def controller_live_items():
|
||||
log.debug('controller-v2-live-items')
|
||||
live_controller = Registry().get('live_controller')
|
||||
current_item = live_controller.service_item
|
||||
live_item = {}
|
||||
|
@ -36,7 +36,7 @@ def test_retrieve_live_item(flask_client, settings):
|
||||
Registry().register('live_controller', fake_live_controller)
|
||||
|
||||
# WHEN: The live-item endpoint is called
|
||||
res = flask_client.get('/api/v2/controller/live-item').get_json()
|
||||
res = flask_client.get('/api/v2/controller/live-items').get_json()
|
||||
|
||||
# THEN: The correct item data should be returned
|
||||
assert res == {'slides': [{'selected': True}]}
|
||||
|
Loading…
Reference in New Issue
Block a user