Skip to content

Commit

Permalink
fix path_deploy() test case
Browse files Browse the repository at this point in the history
  • Loading branch information
wang0618 committed Nov 7, 2021
1 parent 35e895a commit f8869f9
Show file tree
Hide file tree
Showing 3 changed files with 4 additions and 2 deletions.
2 changes: 1 addition & 1 deletion .drone.yml
Original file line number Diff line number Diff line change
Expand Up @@ -26,5 +26,5 @@ steps:
- >
docker run --restart=always --name=pywebio-demos -v $PWD:/app_tmp
--label="traefik.http.services.pywebiodemos.loadbalancer.server.port=80"
-d python:3 bash -c "cp -r /app_tmp /app && cd /app && pip3 install . && pip3 install -r requirements.txt && python3 -m demos --port=80"
-d python:3 bash -c "cp -r /app_tmp /app && cd /app && pip3 install . && pip3 install -r requirements.txt && python3 demos/__main__.py --port=80"
- sleep 5 # wait container start
2 changes: 1 addition & 1 deletion demos/index.py
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
from demos.config import charts_demo_host
from config import charts_demo_host

from pywebio.output import put_markdown, put_row, put_html
from pywebio.session import info as session_info
Expand Down
2 changes: 2 additions & 0 deletions test/16.path_deploy.py
Original file line number Diff line number Diff line change
@@ -1,3 +1,4 @@
import os
import subprocess

from percy import percySnapshot
Expand Down Expand Up @@ -25,6 +26,7 @@ def test(server_proc: subprocess.Popen, browser: Chrome):


def start_test_server():
os.remove(os.path.join(demos_dir, 'index.py'))
path_deploy(demos_dir, port=8080, host='127.0.0.1', cdn=False)


Expand Down

0 comments on commit f8869f9

Please sign in to comment.