Mercurial > code > home > repos > streamed-graph
comparison tasks.py @ 29:45ed53428e74
fix configs to run tests (all in one bundle though)
author | drewp@bigasterisk.com |
---|---|
date | Sun, 15 Dec 2019 21:18:42 -0800 |
parents | 86270a59ae7b |
children | e54941d93356 |
comparison
equal
deleted
inserted
replaced
28:c751380b70c5 | 29:45ed53428e74 |
---|---|
5 def setup_npm(ctx): | 5 def setup_npm(ctx): |
6 ctx.run('yarn install') | 6 ctx.run('yarn install') |
7 | 7 |
8 @task | 8 @task |
9 def serve_demo(ctx): | 9 def serve_demo(ctx): |
10 ctx.run('yarn webpack-dev-server --config webpack-dev.config.ts --port 8082') | 10 ctx.run('yarn webpack-dev-server') |
11 | 11 |
12 @task | 12 @task |
13 def build(ctx): | 13 def build(ctx): |
14 ctx.run(f'yarn run webpack-cli --config webpack.config.js --mode production') # --debug --display-error-details | 14 ctx.run(f'yarn run webpack-build') # --debug --display-error-details |
15 ctx.run(f'cp build/streamed-graph.bundle.js /my/site/homepage/www/rdf/streamed-graph.bundle.js') | 15 ctx.run(f'cp build/streamed-graph.bundle.js /my/site/homepage/www/rdf/streamed-graph.bundle.js') |
16 ctx.run(f'cp streamed-graph.css /my/site/homepage/www/rdf/streamed-graph.css') | 16 ctx.run(f'cp src/streamed-graph.css /my/site/homepage/www/rdf/streamed-graph.css') |
17 | |
18 @task | |
19 def build_forever(ctx): | |
20 ctx.run(f'yarn run webpack-build-forever') | |
21 | |
22 @task | |
23 def dev_server(ctx): | |
24 ctx.run(f'yarn webpack-dev-server') | |
17 | 25 |
18 @task | 26 @task |
19 def test(ctx): | 27 def test(ctx): |
20 ctx.run(f'node_modules/.bin/webpack-cli --config webpack-test.config.ts') | 28 ctx.run(f'yarn test', pty=True) |
21 ctx.run(f'node_modules/.bin/ts-node node_modules/.bin/jasmine --config=jasmine.json') | 29 |
30 @task | |
31 def test_forever(ctx): | |
32 ctx.run(f'yarn test-forever', pty=True) | |
22 | 33 |
23 # one time per machine: | 34 # one time per machine: |
24 # yarn policies set-version v2 | 35 # yarn policies set-version v2 |
25 # in vscode, ctrl-p then: ext install ark120202.vscode-typescript-pnp-plugin | 36 # in vscode, ctrl-p then: ext install ark120202.vscode-typescript-pnp-plugin |
26 # or see https://next.yarnpkg.com/advanced/pnpify for a compatibility runner. | 37 # or see https://next.yarnpkg.com/advanced/pnpify for a compatibility runner. |