Disable implicit JS test asset generation

The JS test assets depend in a brittle way on the details of the tflow()
utility functions. We shouldn't have to fix JS tests when adjusting these.

Options:
    - Manually generate the test assets in a script.
    - Define the JS assets without using tflow, so they don't unexpextedly
    vary.
This commit is contained in:
Aldo Cortesi 2017-12-17 10:17:05 +13:00
parent f14ec2d8f0
commit ac335057a7
2 changed files with 3 additions and 3 deletions

View File

@ -322,7 +322,7 @@ class TestApp(tornado.testing.AsyncHTTPTestCase):
ws_client2 = yield websocket.websocket_connect(ws_url) ws_client2 = yield websocket.websocket_connect(ws_url)
ws_client2.close() ws_client2.close()
def test_generate_tflow_js(self): def _test_generate_tflow_js(self):
_tflow = app.flow_to_json(tflow.tflow(resp=True, err=True)) _tflow = app.flow_to_json(tflow.tflow(resp=True, err=True))
# Set some value as constant, so that _tflow.js would not change every time. # Set some value as constant, so that _tflow.js would not change every time.
_tflow['client_conn']['id'] = "4a18d1a0-50a1-48dd-9aa6-d45d74282939" _tflow['client_conn']['id'] = "4a18d1a0-50a1-48dd-9aa6-d45d74282939"

View File

@ -45,8 +45,8 @@ export default function(){
"port": 22, "port": 22,
"pretty_host": "address", "pretty_host": "address",
"scheme": "http", "scheme": "http",
"timestamp_end": 2, "timestamp_end": null,
"timestamp_start": 1 "timestamp_start": null
}, },
"response": { "response": {
"contentHash": "ab530a13e45914982b79f9b7e3fba994cfd1f3fb22f71cea1afbf02b460c6d1d", "contentHash": "ab530a13e45914982b79f9b7e3fba994cfd1f3fb22f71cea1afbf02b460c6d1d",